├── app ├── .gitignore ├── app-release.apk ├── src │ └── main │ │ ├── assets │ │ └── fonts │ │ │ └── Jaden.ttf │ │ ├── res │ │ ├── mipmap-hdpi │ │ │ ├── plus.png │ │ │ ├── circle.png │ │ │ ├── ic_launcher.png │ │ │ ├── ic_launcher1.png │ │ │ ├── ic_launcher2.png │ │ │ ├── ic_launcher3.png │ │ │ └── plus_selected.png │ │ ├── mipmap-xhdpi │ │ │ ├── minus_50.png │ │ │ ├── plus_50.png │ │ │ └── ic_launcher.png │ │ ├── mipmap-mdpi │ │ │ └── ic_launcher.png │ │ ├── mipmap-xxhdpi │ │ │ ├── ic_launcher.png │ │ │ ├── tab1_normal.png │ │ │ ├── tab2_normal.png │ │ │ ├── tab3_normal.png │ │ │ ├── tab4_normal.png │ │ │ ├── tab5_normal.png │ │ │ ├── tab1_selected.png │ │ │ ├── tab2_selected.png │ │ │ ├── tab3_selected.png │ │ │ ├── tab4_selected.png │ │ │ └── tab5_selected.png │ │ ├── mipmap-xxxhdpi │ │ │ └── ic_launcher.png │ │ ├── values │ │ │ ├── colors.xml │ │ │ ├── dimens.xml │ │ │ ├── strings.xml │ │ │ └── styles.xml │ │ ├── drawable │ │ │ ├── color.xml │ │ │ ├── tab_btn_bg.xml │ │ │ └── tab_bg.xml │ │ ├── values-w820dp │ │ │ └── dimens.xml │ │ └── layout │ │ │ ├── view_mitem.xml │ │ │ ├── activity_say.xml │ │ │ ├── tab4.xml │ │ │ ├── activity_main.xml │ │ │ ├── tab2.xml │ │ │ ├── tab3.xml │ │ │ └── tab1.xml │ │ ├── java │ │ └── com │ │ │ └── jpeng │ │ │ └── demo │ │ │ ├── SayActivity.java │ │ │ ├── Adapter.java │ │ │ ├── Tab4Pager.java │ │ │ ├── NoScrollViewPager.java │ │ │ ├── Tab3Pager.java │ │ │ ├── Tab2Pager.java │ │ │ ├── Tab1Pager.java │ │ │ └── MainActivity.java │ │ └── AndroidManifest.xml ├── build.gradle └── proguard-rules.pro ├── library ├── .gitignore ├── src │ └── main │ │ ├── AndroidManifest.xml │ │ ├── java │ │ └── com │ │ │ └── jpeng │ │ │ └── jptabbar │ │ │ ├── animate │ │ │ ├── AnimationType.java │ │ │ ├── Animatable.java │ │ │ ├── RotateAnimater.java │ │ │ ├── FlipAnimater.java │ │ │ ├── JumpAnimater.java │ │ │ ├── Scale2Animater.java │ │ │ └── ScaleAnimater.java │ │ │ ├── BadgeDismissListener.java │ │ │ ├── TabException.java │ │ │ ├── anno │ │ │ ├── NorIcons.java │ │ │ ├── SeleIcons.java │ │ │ └── Titles.java │ │ │ ├── OnTabSelectListener.java │ │ │ ├── badgeview │ │ │ ├── DragDismissDelegate.java │ │ │ ├── Badgeable.java │ │ │ ├── BadgeRelativeLayout.java │ │ │ ├── BadgeViewUtil.java │ │ │ ├── ExplosionAnimator.java │ │ │ ├── BadgeViewHelper.java │ │ │ └── DragBadgeView.java │ │ │ ├── DensityUtils.java │ │ │ ├── JPTabItem.java │ │ │ └── JPTabBar.java │ │ └── res │ │ └── values │ │ └── attrs.xml ├── proguard-rules.pro └── build.gradle ├── settings.gradle ├── screenshots ├── main.gif └── animation.gif ├── .idea ├── copyright │ └── profiles_settings.xml ├── vcs.xml ├── modules.xml ├── compiler.xml ├── gradle.xml └── misc.xml ├── gradle └── wrapper │ ├── gradle-wrapper.jar │ └── gradle-wrapper.properties ├── .gitignore ├── .travis.yml ├── gradle.properties ├── gradlew.bat ├── gradlew ├── README_CN.md ├── LICENSE └── README.md /app/.gitignore: -------------------------------------------------------------------------------- 1 | /build 2 | -------------------------------------------------------------------------------- /library/.gitignore: -------------------------------------------------------------------------------- 1 | /build 2 | -------------------------------------------------------------------------------- /settings.gradle: -------------------------------------------------------------------------------- 1 | include ':app', ':library' 2 | -------------------------------------------------------------------------------- /library/src/main/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /app/app-release.apk: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/peng8350/JPTabBar/HEAD/app/app-release.apk -------------------------------------------------------------------------------- /screenshots/main.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/peng8350/JPTabBar/HEAD/screenshots/main.gif -------------------------------------------------------------------------------- /screenshots/animation.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/peng8350/JPTabBar/HEAD/screenshots/animation.gif -------------------------------------------------------------------------------- /.idea/copyright/profiles_settings.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | -------------------------------------------------------------------------------- /app/src/main/assets/fonts/Jaden.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/peng8350/JPTabBar/HEAD/app/src/main/assets/fonts/Jaden.ttf -------------------------------------------------------------------------------- /gradle/wrapper/gradle-wrapper.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/peng8350/JPTabBar/HEAD/gradle/wrapper/gradle-wrapper.jar -------------------------------------------------------------------------------- /app/src/main/res/mipmap-hdpi/plus.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/peng8350/JPTabBar/HEAD/app/src/main/res/mipmap-hdpi/plus.png -------------------------------------------------------------------------------- /app/src/main/res/mipmap-hdpi/circle.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/peng8350/JPTabBar/HEAD/app/src/main/res/mipmap-hdpi/circle.png -------------------------------------------------------------------------------- /app/src/main/res/mipmap-xhdpi/minus_50.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/peng8350/JPTabBar/HEAD/app/src/main/res/mipmap-xhdpi/minus_50.png -------------------------------------------------------------------------------- /app/src/main/res/mipmap-xhdpi/plus_50.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/peng8350/JPTabBar/HEAD/app/src/main/res/mipmap-xhdpi/plus_50.png -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | *.iml 2 | .gradle 3 | /local.properties 4 | /.idea/workspace.xml 5 | /.idea/libraries 6 | .DS_Store 7 | /build 8 | /captures 9 | -------------------------------------------------------------------------------- /app/src/main/res/mipmap-hdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/peng8350/JPTabBar/HEAD/app/src/main/res/mipmap-hdpi/ic_launcher.png -------------------------------------------------------------------------------- /app/src/main/res/mipmap-hdpi/ic_launcher1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/peng8350/JPTabBar/HEAD/app/src/main/res/mipmap-hdpi/ic_launcher1.png -------------------------------------------------------------------------------- /app/src/main/res/mipmap-hdpi/ic_launcher2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/peng8350/JPTabBar/HEAD/app/src/main/res/mipmap-hdpi/ic_launcher2.png -------------------------------------------------------------------------------- /app/src/main/res/mipmap-hdpi/ic_launcher3.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/peng8350/JPTabBar/HEAD/app/src/main/res/mipmap-hdpi/ic_launcher3.png -------------------------------------------------------------------------------- /app/src/main/res/mipmap-mdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/peng8350/JPTabBar/HEAD/app/src/main/res/mipmap-mdpi/ic_launcher.png -------------------------------------------------------------------------------- /app/src/main/res/mipmap-xhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/peng8350/JPTabBar/HEAD/app/src/main/res/mipmap-xhdpi/ic_launcher.png -------------------------------------------------------------------------------- /app/src/main/res/mipmap-hdpi/plus_selected.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/peng8350/JPTabBar/HEAD/app/src/main/res/mipmap-hdpi/plus_selected.png -------------------------------------------------------------------------------- /app/src/main/res/mipmap-xxhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/peng8350/JPTabBar/HEAD/app/src/main/res/mipmap-xxhdpi/ic_launcher.png -------------------------------------------------------------------------------- /app/src/main/res/mipmap-xxhdpi/tab1_normal.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/peng8350/JPTabBar/HEAD/app/src/main/res/mipmap-xxhdpi/tab1_normal.png -------------------------------------------------------------------------------- /app/src/main/res/mipmap-xxhdpi/tab2_normal.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/peng8350/JPTabBar/HEAD/app/src/main/res/mipmap-xxhdpi/tab2_normal.png -------------------------------------------------------------------------------- /app/src/main/res/mipmap-xxhdpi/tab3_normal.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/peng8350/JPTabBar/HEAD/app/src/main/res/mipmap-xxhdpi/tab3_normal.png -------------------------------------------------------------------------------- /app/src/main/res/mipmap-xxhdpi/tab4_normal.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/peng8350/JPTabBar/HEAD/app/src/main/res/mipmap-xxhdpi/tab4_normal.png -------------------------------------------------------------------------------- /app/src/main/res/mipmap-xxhdpi/tab5_normal.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/peng8350/JPTabBar/HEAD/app/src/main/res/mipmap-xxhdpi/tab5_normal.png -------------------------------------------------------------------------------- /app/src/main/res/mipmap-xxxhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/peng8350/JPTabBar/HEAD/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png -------------------------------------------------------------------------------- /app/src/main/res/mipmap-xxhdpi/tab1_selected.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/peng8350/JPTabBar/HEAD/app/src/main/res/mipmap-xxhdpi/tab1_selected.png -------------------------------------------------------------------------------- /app/src/main/res/mipmap-xxhdpi/tab2_selected.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/peng8350/JPTabBar/HEAD/app/src/main/res/mipmap-xxhdpi/tab2_selected.png -------------------------------------------------------------------------------- /app/src/main/res/mipmap-xxhdpi/tab3_selected.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/peng8350/JPTabBar/HEAD/app/src/main/res/mipmap-xxhdpi/tab3_selected.png -------------------------------------------------------------------------------- /app/src/main/res/mipmap-xxhdpi/tab4_selected.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/peng8350/JPTabBar/HEAD/app/src/main/res/mipmap-xxhdpi/tab4_selected.png -------------------------------------------------------------------------------- /app/src/main/res/mipmap-xxhdpi/tab5_selected.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/peng8350/JPTabBar/HEAD/app/src/main/res/mipmap-xxhdpi/tab5_selected.png -------------------------------------------------------------------------------- /.idea/vcs.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | -------------------------------------------------------------------------------- /app/src/main/res/values/colors.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | #3F51B5 4 | #303F9F 5 | #FF4081 6 | 7 | -------------------------------------------------------------------------------- /app/src/main/res/values/dimens.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 16dp 4 | 16dp 5 | 6 | -------------------------------------------------------------------------------- /app/src/main/res/values/strings.xml: -------------------------------------------------------------------------------- 1 | 2 | JPTabBar 3 | 徽章测试 4 | 动画类型 5 | 特殊设置 6 | 调试区域 7 | 8 | -------------------------------------------------------------------------------- /.travis.yml: -------------------------------------------------------------------------------- 1 | language: android 2 | jdk: oraclejdk8 3 | android: 4 | components: 5 | - platform-tools 6 | - tools 7 | - build-tools-23.0.1 8 | - android-22 9 | - extra-android-support 10 | - extra-android-m2repository 11 | 12 | script: 13 | - cd library -------------------------------------------------------------------------------- /gradle/wrapper/gradle-wrapper.properties: -------------------------------------------------------------------------------- 1 | #Mon Dec 28 10:00:20 PST 2015 2 | distributionBase=GRADLE_USER_HOME 3 | distributionPath=wrapper/dists 4 | zipStoreBase=GRADLE_USER_HOME 5 | zipStorePath=wrapper/dists 6 | distributionUrl=https\://services.gradle.org/distributions/gradle-2.10-all.zip 7 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/color.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /library/src/main/java/com/jpeng/jptabbar/animate/AnimationType.java: -------------------------------------------------------------------------------- 1 | package com.jpeng.jptabbar.animate; 2 | 3 | /** 4 | * Author jpeng 5 | * Date: 17-9-4 6 | * E-mail:peng8350@gmail.com 7 | */ 8 | public enum AnimationType { 9 | FLIP, 10 | ROTATE, 11 | SCALE, 12 | JUMP, 13 | SCALE2, 14 | NONE, 15 | } 16 | -------------------------------------------------------------------------------- /library/src/main/java/com/jpeng/jptabbar/BadgeDismissListener.java: -------------------------------------------------------------------------------- 1 | package com.jpeng.jptabbar; 2 | 3 | /** 4 | * Author jpeng 5 | * Date: 16-11-15 6 | * E-mail:peng8350@gmail.com 7 | * 徽章消失回调监听者 8 | */ 9 | public interface BadgeDismissListener { 10 | /** 11 | * TabItem徽章消失的回调 12 | */ 13 | void onDismiss(int position); 14 | } 15 | -------------------------------------------------------------------------------- /app/src/main/res/values-w820dp/dimens.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | 64dp 6 | 7 | -------------------------------------------------------------------------------- /app/src/main/res/layout/view_mitem.xml: -------------------------------------------------------------------------------- 1 | 2 | 9 | 10 | -------------------------------------------------------------------------------- /app/src/main/res/values/styles.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 9 | -------------------------------------------------------------------------------- /library/src/main/java/com/jpeng/jptabbar/TabException.java: -------------------------------------------------------------------------------- 1 | package com.jpeng.jptabbar; 2 | 3 | /** 4 | * Author jpeng 5 | * Date: 16-11-13 下午1:41 6 | * E-mail:peng8350@gmail.com 7 | * Tab异常类 8 | */ 9 | public class TabException extends NullPointerException { 10 | public TabException() { 11 | super(); 12 | } 13 | 14 | public TabException(String detailMessage) { 15 | super(detailMessage); 16 | } 17 | } 18 | -------------------------------------------------------------------------------- /app/src/main/res/drawable/tab_btn_bg.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 8 | 9 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /library/src/main/java/com/jpeng/jptabbar/anno/NorIcons.java: -------------------------------------------------------------------------------- 1 | package com.jpeng.jptabbar.anno; 2 | 3 | import java.lang.annotation.ElementType; 4 | import java.lang.annotation.Retention; 5 | import java.lang.annotation.RetentionPolicy; 6 | import java.lang.annotation.Target; 7 | 8 | /** 9 | * Author jpeng 10 | * Date: 16-11-13 11 | * E-mail:peng8350@gmail.com 12 | * 没有选中图标互借 13 | */ 14 | @Retention(RetentionPolicy.RUNTIME) 15 | @Target(ElementType.FIELD) 16 | public @interface NorIcons { 17 | } 18 | -------------------------------------------------------------------------------- /library/src/main/java/com/jpeng/jptabbar/anno/SeleIcons.java: -------------------------------------------------------------------------------- 1 | package com.jpeng.jptabbar.anno; 2 | 3 | import java.lang.annotation.ElementType; 4 | import java.lang.annotation.Retention; 5 | import java.lang.annotation.RetentionPolicy; 6 | import java.lang.annotation.Target; 7 | 8 | /** 9 | * Author jpeng 10 | * Date: 16-11-13 11 | * E-mail:peng8350@gmail.com 12 | * 选中图标注解 13 | */ 14 | @Retention(RetentionPolicy.RUNTIME) 15 | @Target(ElementType.FIELD) 16 | public @interface SeleIcons { 17 | } 18 | -------------------------------------------------------------------------------- /app/src/main/res/layout/activity_say.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /library/src/main/java/com/jpeng/jptabbar/anno/Titles.java: -------------------------------------------------------------------------------- 1 | package com.jpeng.jptabbar.anno; 2 | 3 | import java.lang.annotation.ElementType; 4 | import java.lang.annotation.Retention; 5 | import java.lang.annotation.RetentionPolicy; 6 | import java.lang.annotation.Target; 7 | 8 | /** 9 | * Author jpeng 10 | * Date: 16-11-13 11 | * E-mail:peng8350@gmail.com 12 | * 标题注解 13 | */ 14 | 15 | @Retention(RetentionPolicy.RUNTIME) 16 | @Target(ElementType.FIELD) 17 | public @interface Titles { 18 | 19 | } 20 | -------------------------------------------------------------------------------- /app/src/main/java/com/jpeng/demo/SayActivity.java: -------------------------------------------------------------------------------- 1 | package com.jpeng.demo; 2 | 3 | import android.os.Bundle; 4 | import android.support.annotation.Nullable; 5 | import android.support.v7.app.AppCompatActivity; 6 | 7 | /** 8 | * Created by jpeng on 16-11-25. 9 | */ 10 | public class SayActivity extends AppCompatActivity{ 11 | 12 | @Override 13 | protected void onCreate(@Nullable Bundle savedInstanceState) { 14 | super.onCreate(savedInstanceState); 15 | setContentView(R.layout.activity_say); 16 | } 17 | } 18 | -------------------------------------------------------------------------------- /app/src/main/res/layout/tab4.xml: -------------------------------------------------------------------------------- 1 | 2 | 7 | 8 |