Giter Club home page Giter Club logo

easytabs's People

Contributors

gilgoldzweig avatar or-dvir avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

easytabs's Issues

bug: setCurrentItem() does not scroll tab to proper position

hi
i found a bug when setting current page of viewpager programatically.
i have this piece of code:

`EasyTabsBuilder.with(mTabs)
					   .addTabs(tabsArray)
					   .setTabLayoutScrollable(true)
					   .Build();

		mTabs.getViewPager().setCurrentItem(tabToSelect);`

the content is fine, it shows the tabToSelect fragment. however the tablayout is not scrolling and still showing original position.

see these photo:
19141798_10154746824825208_342615726_n

notice that the content says "10" - thats the content for tab number 10, but the tab layout is still in the initial position

Fragments getting mixed with other fragments

I am using EasyTabs in two different fragments, say Frag1 and Frag2. When I switch between Frag1 and Frag2 by selecting an option from navigation drawer, I see fragments which I have added to EasyTabs of Frag1 in Frag2.

On debugging, I found that the FragmentManager holds 'active' and 'added' fragments of the old fragment Frag1 even when I switched to Frag2.

NOTE: While starting the application for the first time, Frag1 loads perfectly with its fragments for each tab. Issue occurs when I want to switch from Frag1 to Frag2.

What am I missing here?

Tabs disappears when switch fragments

Hello.
I have been using EasyTabs for quite a while now and it truly is a great work. But recently I have used it in a fragment, but the problem is that whenever I switch to other fragments and then come back to the fragment containing the tabs, the tabs just disappears along with whatever were in them. It is just blank. What can I do to resolve this? Please respond as soon as possible.
Thank you!!

Tab text size

Hey, How to change Tab text sizes? I have defined the style with custom size and set test app:tabTextAppearance to this view but size remains same, can you please help?

Go to position

Is there any method I can send the user to a certain position?

Manifest merger failed : Attribute application@allowBackup value

I import the library to my app by gradle.
I got this building error :
"Manifest merger failed : Attribute application@allowBackup value=(false)".
I think you should remove allowBackup attribute from your library. (Lib should not have that attribute).

Thank you very much for the great lib.

Inflation Error

@gilgoldzweig
Looks like a great library, setup tabs without adapter code in no time, Although I m unable to use it.
Here is my xml layout

<?xml version="1.0" encoding="utf-8"?>
<nl.psdcompany.duonavigationdrawer.views.DuoDrawerLayout xmlns:android="http://schemas.android.com/apk/res/android"
    xmlns:app="http://schemas.android.com/apk/res-auto"
    xmlns:tools="http://schemas.android.com/tools"
    android:id="@+id/drawer"
    android:layout_width="match_parent"
    android:layout_height="match_parent"
    tools:context="coutloot.businessmanager.departments.inventory.inventory_home">

    <nl.psdcompany.duonavigationdrawer.views.DuoMenuView xmlns:android="http://schemas.android.com/apk/res/android"
        xmlns:app="http://schemas.android.com/apk/res-auto"
        android:layout_width="match_parent"
        android:layout_height="match_parent"
        android:orientation="vertical"
        android:tag="@string/tag_menu" />

    <LinearLayout
        android:layout_width="match_parent"
        android:layout_height="match_parent"
        android:background="@color/white"
        android:orientation="vertical"
        android:tag="@string/tag_content">

        <android.support.v7.widget.Toolbar
            android:id="@+id/toolbar"
            android:layout_width="match_parent"
            android:layout_height="?attr/actionBarSize"
            android:background="@color/colorPrimary"
            android:elevation="4dp"
            android:theme="@style/ThemeOverlay.AppCompat.Dark.ActionBar"
            app:popupTheme="@style/ThemeOverlay.AppCompat.Light">
        </android.support.v7.widget.Toolbar>

        <goldzweigapps.tabs.View.EasyTabs
            android:id="@+id/tabs"
            android:layout_width="match_parent"
            android:layout_height="fill_parent"/>

    </LinearLayout>

</nl.psdcompany.duonavigationdrawer.views.DuoDrawerLayout>

here is error which m getting for nothing written in my java class

FATAL EXCEPTION: main
                                                                          Process: coutloot.businessmanager, PID: 28364
                                                                          java.lang.RuntimeException: Unable to start activity ComponentInfo{coutloot.businessmanager/coutloot.businessmanager.departments.inventory.inventory_home}: android.view.InflateException: Binary XML file line #0: Binary XML file line #0: Error inflating class goldzweigapps.tabs.View.EasyTabs
                                                                              at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2449)
                                                                              at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2509)
                                                                              at android.app.ActivityThread.access$1000(ActivityThread.java:153)
                                                                              at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1373)
                                                                              at android.os.Handler.dispatchMessage(Handler.java:102)
                                                                              at android.os.Looper.loop(Looper.java:154)
                                                                              at android.app.ActivityThread.main(ActivityThread.java:5523)
                                                                              at java.lang.reflect.Method.invoke(Native Method)
                                                                              at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:739)
                                                                              at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:629)
                                                                           Caused by: android.view.InflateException: Binary XML file line #0: Binary XML file line #0: Error inflating class goldzweigapps.tabs.View.EasyTabs
                                                                              at android.view.LayoutInflater.inflate(LayoutInflater.java:543)
                                                                              at android.view.LayoutInflater.inflate(LayoutInflater.java:427)
                                                                              at android.view.LayoutInflater.inflate(LayoutInflater.java:374)
                                                                              at android.support.v7.app.AppCompatDelegateImplV9.setContentView(AppCompatDelegateImplV9.java:287)
                                                                              at android.support.v7.app.AppCompatActivity.setContentView(AppCompatActivity.java:139)
                                                                              at coutloot.businessmanager.departments.inventory.inventory_home.onCreate(inventory_home.java:24)
                                                                              at android.app.Activity.performCreate(Activity.java:6303)
                                                                              at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1108)
                                                                              at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2402)
                                                                              at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2509) 
                                                                              at android.app.ActivityThread.access$1000(ActivityThread.java:153) 
                                                                              at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1373) 
                                                                              at android.os.Handler.dispatchMessage(Handler.java:102) 
                                                                              at android.os.Looper.loop(Looper.java:154) 
                                                                              at android.app.ActivityThread.main(ActivityThread.java:5523) 
                                                                              at java.lang.reflect.Method.invoke(Native Method) 
                                                                              at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:739) 
                                                                              at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:629) 
                                                                           Caused by: android.view.InflateException: Binary XML file line #0: Error inflating class goldzweigapps.tabs.View.EasyTabs
                                                                              at android.view.LayoutInflater.createView(LayoutInflater.java:649)
                                                                              at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:768)
                                                                              at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:708)
                                                                              at android.view.LayoutInflater.rInflate(LayoutInflater.java:839)
                                                                              at android.view.LayoutInflater.rInflateChildren(LayoutInflater.java:802)
                                                                              at android.view.LayoutInflater.rInflate(LayoutInflater.java:842)
                                                                              at android.view.LayoutInflater.rInflateChildren(LayoutInflater.java:802)
                                                                              at android.view.LayoutInflater.inflate(LayoutInflater.java:519)
                                                                              at android.view.LayoutInflater.inflate(LayoutInflater.java:427) 
                                                                              at android.view.LayoutInflater.inflate(LayoutInflater.java:374) 
                                                                              at android.support.v7.app.AppCompatDelegateImplV9.setContentView(AppCompatDelegateImplV9.java:287) 
                                                                              at android.support.v7.app.AppCompatActivity.setContentView(AppCompatActivity.java:139) 
                                                                              at coutloot.businessmanager.departments.inventory.inventory_home.onCreate(inventory_home.java:24) 
                                                                              at android.app.Activity.performCreate(Activity.java:6303) 
                                                                              at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1108) 
                                                                              at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2402) 
                                                                              at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2509) 
                                                                              at android.app.ActivityThread.access$1000(ActivityThread.java:153) 
                                                                              at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1373) 
                                                                              at android.os.Handler.dispatchMessage(Handler.java:102) 
                                                                              at android.os.Looper.loop(Looper.java:154) 
                                                                              at android.app.ActivityThread.main(ActivityThread.java:5523) 
                                                                              at java.lang.reflect.Method.invoke(Native Method) 
                                                                              at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:739) 
                                                                              at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:629) 
                                                                           Caused by: java.lang.reflect.InvocationTargetException
                                                                              at java.lang.reflect.Constructor.newInstance(Native Method)
                                                                              at android.view.LayoutInflater.createView(LayoutInflater.java:623)
                                                                              at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:768) 
                                                                              at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:708) 
                                                                              at android.view.LayoutInflater.rInflate(LayoutInflater.java:839) 
                                                                              at android.view.LayoutInflater.rInflateChildren(LayoutInflater.java:802) 
                                                                              at android.view.LayoutInflater.rInflate(LayoutInflater.java:842) 
                                                                              at android.view.LayoutInflater.rInflateChildren(LayoutInflater.java:802) 
                                                                              at android.view.LayoutInflater.inflate(LayoutInflater.java:519) 
                                                                              at android.view.LayoutInflater.inflate(LayoutInflater.java:427) 
                                                                              at android.view.LayoutInflater.inflate(LayoutInflater.java:374) 
                                                                              at android.support.v7.app.AppCompatDelegateImplV9.setContentView(AppCompatDelegateImplV9.java:287) 
                                                                              at android.support.v7.app.AppCompatActivity.setContentView(AppCompatActivity.java:139) 
                                                                              at coutloot.businessmanager.departments.inventory.inventory_home.onCreate(inventory_home.java:24) 
                                                                              at android.app.Activity.performCreate(Activity.java:6303) 
                                                                              at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1108) 
                                                                              at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2402) 
                                                                              at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2509) 
                                                                              at android.app.ActivityThread.access$1000(ActivityThread.java:153) 
                                                                              at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1373) 
                                                                              at android.os.Handler.dispatchMessage(Handler.java:102) 
                                                                              at android.os.Looper.loop(Looper.java:154) 
                                                                              at android.app.ActivityThread.main(ActivityThread.java:5523) 
                                                                              at java.lang.reflect.Method.invoke(Native Method) 
                                                                              at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:739) 
                                                                              at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:629) 
                                                                           Caused by: java.lang.ClassCastException: goldzweigapps.tabs.View.EasyTabs cannot be cast to android.support.design.widget.TabLayout
                                                                              at goldzweigapps.tabs.View.EasyTabs.<init>(EasyTabs.java:35)
                                                                              at java.lang.reflect.Constructor.newInstance(Native Method) 

bug with ViewPagerAdapter class

the title may be a bit misleading... the bug is actually in the class FragmentPagerAdapter which you extend. this class has a bug where sometimes the ViewPager will display old fragments with old information.
luckily there is a very easy solution for this:
instead of extending FragmentPagerAdapter, you need to extend FragmentStatePagerAdapter

currently i have copied a few of the library classes to my own project so i can make that change.
please apply this fix at the library level.

failed to resolve EastTabs:1.1

hi.
trying to use this library but i get error:
Error:(48, 13) Failed to resolve: tech.goldzweigapps:EasyTabs:1.1

here is my gradle file:
`apply plugin: 'com.android.application'

android {
compileSdkVersion 25
buildToolsVersion "24.0.3"
defaultConfig {
applicationId "or_dvir.hotmail.com.githubbrowser"
minSdkVersion 15
targetSdkVersion 22
versionCode 1
versionName "1.0"
testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
}
buildTypes {
release {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
}
}
}

android.packagingOptions {
exclude 'META-INF/NOTICE'
exclude 'META-INF/notice'
exclude 'META-INF/notice.txt'
exclude 'META-INF/LICENSE'
exclude 'META-INF/license'
exclude 'META-INF/license.txt'

exclude 'META-INF/ASL2.0'
exclude 'META-INF/asl2.0'
exclude 'META-INF/asl2.0.txt'

}

repositories { maven { url "https://jitpack.io" } }

dependencies {
compile fileTree(dir: 'libs', include: ['*.jar'])
androidTestCompile('com.android.support.test.espresso:espresso-core:2.2.2', {
exclude group: 'com.android.support', module: 'support-annotations'
})
testCompile 'junit:junit:4.12'

compile 'com.squareup.picasso:picasso:2.5.2'
compile 'org.codehaus.jackson:jackson-mapper-asl:1.9.13'
compile 'com.octo.android.robospice:robospice:1.4.14'
compile 'com.octo.android.robospice:robospice-spring-android:1.4.14'
compile 'com.android.support:design:25.0.0'
compile 'tech.goldzweigapps:EasyTabs:1.1'

}
`

add this to readme file

please add to the readme file that setting setTabLayoutScrollable(true) means that tabs will NOT be distributed evenly. (and if set to false, then they will be)

Icon fading.

Enabling icon fading only support up to 15 icons

Unable to replace TabItem in FragmentTransaction

I'm trying to use FragmentTransaction#replace on one tab created by EasyTabs, but I can't make it work. Right now, I am able to create the desired Fragment above the Fragment create by EasyTabs using this code, where R.id.easytabs_host is the view id of the EasyTabs component in the layout:

final FragmentTransaction transaction = getFragmentManager().beginTransaction();
transaction.replace(R.id.easytabs_host, resultFragment).addToBackStack(null).commit();

What's the containerViewId I should use to make it work?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.