通过更改片段来更改工具栏,例如 instagram 应用程序
Change Toolbar with change of Fragment like instagram app
我正在尝试实现完全像 Instagram 应用程序导航系统,其中有一个固定的底部栏,用户可以通过单击底部栏中的图标在屏幕之间导航,因此工具栏标题和工具栏后退导航应该更改。
我对此进行了大量研究,发现的解决方案很少,但其中 none 是完美的。
类似问题:-
Implementing Instagram like in-app navigation system on Android
使用 ViewPager :- 目前我正在遵循这种模式,在每个 ViewPager 选项卡中制作多个片段堆栈
https://tausiq.wordpress.com/2014/06/06/android-multiple-fragments-stack-in-each-viewpager-tab/
我有一个创建 instagram-like 导航的任务,希望您可以在此处找到一些详细信息:
FragmentMetaData
class 对我来说看起来像:
public class FragmentMetaData {
public final String className;
public final Bundle fragmentBundle;
public FragmentMetaData(final String className, final Bundle fragmentBundle) {
this.className = className;
this.fragmentBundle = fragmentBundle;
}
}
希望对你有所帮助
我正在尝试实现完全像 Instagram 应用程序导航系统,其中有一个固定的底部栏,用户可以通过单击底部栏中的图标在屏幕之间导航,因此工具栏标题和工具栏后退导航应该更改。
我对此进行了大量研究,发现的解决方案很少,但其中 none 是完美的。
类似问题:- Implementing Instagram like in-app navigation system on Android
使用 ViewPager :- 目前我正在遵循这种模式,在每个 ViewPager 选项卡中制作多个片段堆栈
https://tausiq.wordpress.com/2014/06/06/android-multiple-fragments-stack-in-each-viewpager-tab/
我有一个创建 instagram-like 导航的任务,希望您可以在此处找到一些详细信息:
FragmentMetaData
class 对我来说看起来像:
public class FragmentMetaData {
public final String className;
public final Bundle fragmentBundle;
public FragmentMetaData(final String className, final Bundle fragmentBundle) {
this.className = className;
this.fragmentBundle = fragmentBundle;
}
}
希望对你有所帮助