当前位置: 首页>>代码示例>>Java>>正文


Java PagerSlidingTabStrip.setVisibility方法代码示例

本文整理汇总了Java中com.astuetz.PagerSlidingTabStrip.setVisibility方法的典型用法代码示例。如果您正苦于以下问题:Java PagerSlidingTabStrip.setVisibility方法的具体用法?Java PagerSlidingTabStrip.setVisibility怎么用?Java PagerSlidingTabStrip.setVisibility使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在com.astuetz.PagerSlidingTabStrip的用法示例。


在下文中一共展示了PagerSlidingTabStrip.setVisibility方法的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: onCreateView

import com.astuetz.PagerSlidingTabStrip; //导入方法依赖的package包/类
@Override
        public View onCreateView(LayoutInflater inflater, ViewGroup container,
                                 Bundle savedInstanceState) {
            View rootView = inflater.inflate(R.layout.fragment_a, container, false);
            pager = (ViewPager) rootView.findViewById(R.id.pager);
            myPagerAdapter = new MyPagerAdapter(getChildFragmentManager());
            pager.setAdapter(myPagerAdapter);
            final int parent_position = getArguments().getInt(ARG_SECTION_NUMBER);
            myPagerAdapter.setInfoList(siteList.get(parent_position).getInfo());
            myPagerAdapter.notifyDataSetChanged();
            // Bind the tabs to the ViewPager
            tabs = (PagerSlidingTabStrip) rootView.findViewById(R.id.tabs);
//            tabs.setShouldExpand(true);





            tabs.setViewPager(pager);
            if (myPagerAdapter.getCount() == 1) {
                tabs.setVisibility(View.GONE);
            }
            return rootView;
        }
 
开发者ID:zlisthq,项目名称:zlist-android,代码行数:25,代码来源:MainActivity.java

示例2: onCreateView

import com.astuetz.PagerSlidingTabStrip; //导入方法依赖的package包/类
@Override
public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) {
    View v = inflater.inflate(R.layout.viewpager_with_tabs, container, false);

    if (MizLib.hasLollipop())
        ((ActionBarActivity) getActivity()).getSupportActionBar().setElevation(0);

    mViewPager = (ViewPager) v.findViewById(R.id.awesomepager);
    mViewPager.setPageMargin(MizLib.convertDpToPixels(getActivity(), 16));

    mTabs = (PagerSlidingTabStrip) v.findViewById(R.id.tabs);

    mViewPager.setAdapter(new PagerAdapter(getChildFragmentManager()));
    mTabs.setViewPager(mViewPager);
    mTabs.setVisibility(View.VISIBLE);

    // Work-around a bug that sometimes happens with the tabs
    mViewPager.setCurrentItem(0);

    if (MizLib.hasLollipop())
        mTabs.setElevation(1f);

    return v;
}
 
开发者ID:MizzleDK,项目名称:Mizuu,代码行数:25,代码来源:MovieLibraryOverviewFragment.java

示例3: onCreateView

import com.astuetz.PagerSlidingTabStrip; //导入方法依赖的package包/类
@Override
public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) {
    View rootView = inflater.inflate(R.layout.fragment_category, container, false);
    mPagerSlidingTabStrip = (PagerSlidingTabStrip) rootView.findViewById(R.id.tab_fragment_category);
    mViewPager = (ViewPager) rootView.findViewById(R.id.viewpager_fragment_category);
    mProgressBar = (ProgressBar) rootView.findViewById(R.id.progress_bar_fragment_category);
    mProgressBar.setVisibility(View.VISIBLE);
    mPagerSlidingTabStrip.setVisibility(View.GONE);
    return rootView;
}
 
开发者ID:hoyin258,项目名称:MisterWok,代码行数:11,代码来源:CategoryListFragment.java

示例4: onCreate

import com.astuetz.PagerSlidingTabStrip; //导入方法依赖的package包/类
@Override
public void onCreate(Bundle savedInstanceState) {
	super.onCreate(savedInstanceState);

	MizuuApplication.setupTheme(this);

       if (MizLib.hasLollipop())
           getSupportActionBar().setElevation(0);

       mTmdbId = getIntent().getExtras().getString("tmdbId");
       mCollectionId = getIntent().getExtras().getString("collectionId");
       mToolbarColor = getIntent().getExtras().getInt(IntentKeys.TOOLBAR_COLOR);
	mTmdbApiKey = MizLib.getTmdbApiKey(this);

       mProgressBar = (ProgressBar) findViewById(R.id.progressbar);
       mProgressBar.setVisibility(View.VISIBLE);

       mViewPager = (ViewPager) findViewById(R.id.awesomepager);
       mViewPager.setOffscreenPageLimit(2);
       mViewPager.setPageMargin(MizLib.convertDpToPixels(this, 16));

       mTabs = (PagerSlidingTabStrip) findViewById(R.id.tabs);
       mTabs.setVisibility(View.GONE);

	if (savedInstanceState != null) {
           mJson = savedInstanceState.getString("json", "");
           mBaseUrl = savedInstanceState.getString("baseUrl");
           mCollection = savedInstanceState.getString("collection");
		setupActionBarStuff();

           mViewPager.setCurrentItem(savedInstanceState.getInt("tab", 0));
	} else {
		new MovieLoader(getApplicationContext()).execute(mTmdbId, mCollectionId);
	}
}
 
开发者ID:MizzleDK,项目名称:Mizuu,代码行数:36,代码来源:MovieCoverFanartBrowser.java

示例5: onCreate

import com.astuetz.PagerSlidingTabStrip; //导入方法依赖的package包/类
@Override
public void onCreate(Bundle savedInstanceState) {
	super.onCreate(savedInstanceState);

       MizuuApplication.setupTheme(this);

       if (MizLib.hasLollipop())
           getSupportActionBar().setElevation(0);
       getSupportActionBar().setDisplayHomeAsUpEnabled(true);

	tvdbId = getIntent().getExtras().getString("id");
       mToolbarColor = getIntent().getExtras().getInt(IntentKeys.TOOLBAR_COLOR);

       mProgressBar = (ProgressBar) findViewById(R.id.progressbar);
       mProgressBar.setVisibility(View.VISIBLE);

       mViewPager = (ViewPager) findViewById(R.id.awesomepager);
       mViewPager.setOffscreenPageLimit(2);
       mViewPager.setPageMargin(MizLib.convertDpToPixels(this, 16));

       mTabs = (PagerSlidingTabStrip) findViewById(R.id.tabs);
       mTabs.setVisibility(View.GONE);

       setupActionBarStuff();

	if (savedInstanceState != null) {
           mViewPager.setCurrentItem(savedInstanceState.getInt("tab", 0));
	}
}
 
开发者ID:MizzleDK,项目名称:Mizuu,代码行数:30,代码来源:ShowCoverFanartBrowser.java


注:本文中的com.astuetz.PagerSlidingTabStrip.setVisibility方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。