Exemplo n.º 1
0
        protected override void OnCreate(Bundle savedInstanceState)
        {
            base.OnCreate(savedInstanceState);
            AppUtil.InitLocale(this);
            binding = MainActivityBinding.SetContentView(this, Resource.Layout.activity_main);
            MainApplication.GetComponent(this).Inject(this);

            Subscription.Add(BrokerProvider.Get().Observe().Subscribe(page =>
            {
                ToggleToolbarElevation(page.ShouldToggleToolbar());
                ChangePage(page.GetTitleResId(), page.CreateFragment());
                binding.navView.SetCheckedItem(page.GetMenuId());
            }));
            InitView();

            ReplaceFragment(SessionsFragment.NewInstance());
        }
Exemplo n.º 2
0
        protected override void OnCreate(Bundle savedInstanceState)
        {
            base.OnCreate(savedInstanceState);
            AppUtil.InitLocale(this);
            binding = MainActivityBinding.SetContentView(this, Resource.Layout.activity_main);
            MainApplication.GetComponent(this).Inject(this);

            Subscription.Add(BrokerProvider.Get().Observe().Subscribe(page =>
                {
                    ToggleToolbarElevation(page.ShouldToggleToolbar());
                    ChangePage(page.GetTitleResId(), page.CreateFragment());
                    binding.navView.SetCheckedItem(page.GetMenuId());
                }));
            InitView();

            ReplaceFragment(SessionsFragment.NewInstance());
        }