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


C# Bundle.GetBoolean方法代码示例

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


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

示例1: OnCreateView

		public override View OnCreateView (LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState)
		{
			//	  set View
			var rootView = inflater.Inflate (Resource.Layout.DiemThi_HK, container, false);
			isfirst=true;
			listViewDT = rootView.FindViewById<ListView> (Resource.Id.listDT_HK);
			lbl_HK = rootView.FindViewById<TextView> (Resource.Id.lbl_HK_DT);
			lbl_NH = rootView.FindViewById<TextView> (Resource.Id.lbl_NH_DT);
			progress=rootView.FindViewById<ProgressBar>(Resource.Id.progressDTHK);
			 txtNotify = rootView.FindViewById<TextView> (Resource.Id.txtNotify_DT_HK);
			linear = rootView.FindViewById<LinearLayout> (Resource.Id.linear_HK_DT);
			 linearDT = rootView.FindViewById<LinearLayout> (Resource.Id.linearDT_HK);
			//button 
			 btnHKTruoc = rootView.FindViewById<Button> (Resource.Id.btnHK_Truoc_DT);
			btnHKKe = rootView.FindViewById<Button> (Resource.Id.btnHK_Ke_DT);
			//bundle
			bundle=this.Arguments;
			check = bundle.GetBoolean ("Remind");
			autoupdate = bundle.GetBoolean ("AutoUpdateData");
			//load data
			LoadData ("0", "0");

			//button event
			btnHKTruoc.Click += new EventHandler (btnHK_Truoc_Click);
			btnHKKe.Click += new EventHandler (btnHK_Ke_Click);	


			return rootView;
		}
开发者ID:tienbui123,项目名称:Mobile-VS2,代码行数:29,代码来源:DiemThiHKFragment.cs

示例2: OnCreate

		protected override void OnCreate (Bundle savedInstanceState)
		{
			base.OnCreate (savedInstanceState);
			SetContentView (Resource.Layout.activity_main);

			if (savedInstanceState != null) {
				mIsResolving = savedInstanceState.GetBoolean (KEY_IS_RESOLVING);
				mShouldResolve = savedInstanceState.GetBoolean (KEY_SHOULD_RESOLVE);
			}

			FindViewById (Resource.Id.sign_in_button).SetOnClickListener (this);
			FindViewById (Resource.Id.sign_out_button).SetOnClickListener (this);
			FindViewById (Resource.Id.disconnect_button).SetOnClickListener (this);

			FindViewById<SignInButton> (Resource.Id.sign_in_button).SetSize (SignInButton.SizeWide);
			FindViewById (Resource.Id.sign_in_button).Enabled = false;

			mStatus = FindViewById<TextView> (Resource.Id.status);

			mGoogleApiClient = new GoogleApiClientBuilder (this)
				.AddConnectionCallbacks (this)
				.AddOnConnectionFailedListener (this)
				.AddApi (PlusClass.API)
				.AddScope (new Scope (Scopes.Profile))
				.Build ();
		}
开发者ID:nick30935n,项目名称:monodroid-samples,代码行数:26,代码来源:MainActivity.cs

示例3: OnCreateView

		public override View OnCreateView (LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState)
		{
			// Use this to return your custom view for this Fragment
			// return inflater.Inflate(Resource.Layout.YourFragment, container, false);

			//	  Lich hoc theo HK
			var rootView = inflater.Inflate (Resource.Layout.LichHoc_HK, container, false);
			isfirst = true;
			listView_HK = rootView.FindViewById<ListView> (Resource.Id.listLH);
			lbl_HK = rootView.FindViewById<TextView> (Resource.Id.lbl_HK_LH);
			lbl_NH = rootView.FindViewById<TextView> (Resource.Id.lbl_NH_LH);
			progress = rootView.FindViewById<ProgressBar> (Resource.Id.progressLH);
			linear = rootView.FindViewById<LinearLayout>(Resource.Id.linear_HK_LH);
			linearLH = rootView.FindViewById<LinearLayout>(Resource.Id.linearLH);
			txtNotify = rootView.FindViewById<TextView>(Resource.Id.txtNotify_LT_HK);
		//	radioGroup = rootView.FindViewById<RadioGroup>(Resource.Id.radioGroup1);
		    bundle=this.Arguments;
			check = bundle.GetBoolean ("Remind");
			autoupdate = bundle.GetBoolean ("AutoUpdateData");

			//load data

			LoadData_HK ();
		
			// row click
			listView_HK.ItemLongClick += listView_ItemClick;
						

			return rootView;
		}
开发者ID:tienbui123,项目名称:Mobile-VS2,代码行数:30,代码来源:LichHocHKFragment.cs

示例4: OnCreateView

		public override View OnCreateView (LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState)
		{

			//Theo Tuan

			var rootView = inflater.Inflate (Resource.Layout.LichHoc_Tuan, container, false);
			listView_Tuan = rootView.FindViewById<ExpandableListView> (Resource.Id.listLH_Tuan);
			listView_Tuan.GroupClick += (sender, e) => {
				listView_ItemClick(sender,e);
			};
			isfirst = true;
			progress = rootView.FindViewById<ProgressBar> (Resource.Id.progressLHTuan);
			lbl_TuNgay = rootView.FindViewById<TextView> (Resource.Id.lbl_TuNgay);
			lbl_DenNgay = rootView.FindViewById<TextView> (Resource.Id.lbl_DenNgay);
			lbl_HK = rootView.FindViewById<TextView> (Resource.Id.lbl_HK_Tuan);
			LinearLayout linear_ThoiGian= rootView.FindViewById<LinearLayout> (Resource.Id.linear_LH_Tuan_ThoiGian);
			TextView txtNotify = rootView.FindViewById<TextView> (Resource.Id.txtNotify_LH_Tuan);
			//RadioGroup radioGroup = rootView.FindViewById<RadioGroup>(Resource.Id.radioGroup2);
			//button 
			 btnTuanTruoc = rootView.FindViewById<Button> (Resource.Id.btnTuanTruoc);
			 btnTuanKe = rootView.FindViewById<Button> (Resource.Id.btnTuanKe);
			//bundle
			bundle=this.Arguments;
			check = bundle.GetBoolean ("Remind");
			autoupdate = bundle.GetBoolean ("AutoUpdateData");

			LichHoc lh = BLichHoc.GetLast (SQLite_Android.GetConnection ());
			if (lh != null) {
				btnTuanTruoc.Enabled = true;
				btnTuanKe.Enabled = true;
				btnTuanTruoc.SetBackgroundResource(Android.Resource.Color.HoloBlueDark);
				btnTuanKe.SetBackgroundResource(Android.Resource.Color.HoloBlueDark);
			//	radioGroup.Visibility = ViewStates.Visible;
				linear_ThoiGian.Visibility = ViewStates.Visible;
				txtNotify.Visibility = ViewStates.Gone;
				LoadData_Tuan (DateTime.Today);
			}
			else {
				progress.Visibility = ViewStates.Gone;
				btnTuanTruoc.Enabled = false;
				btnTuanKe.Enabled = false;
				btnTuanTruoc.SetBackgroundResource(Android.Resource.Color.DarkerGray);
				btnTuanKe.SetBackgroundResource(Android.Resource.Color.DarkerGray);
			//	radioGroup.Visibility = ViewStates.Gone;
				linear_ThoiGian.Visibility = ViewStates.Gone;
				txtNotify.Visibility = ViewStates.Visible;
				txtNotify.Text = "Hiện tại lịch học chưa có dữ liệu. Xin vui lòng thử lại sau!!!";
			}

			// button event
			btnTuanTruoc.Click += new EventHandler (btnTuanTruoc_Click);
			btnTuanKe.Click += new EventHandler (btnTuanKe_Click);



			return rootView;
		}
开发者ID:tienbui123,项目名称:Mobile-VS2,代码行数:57,代码来源:LichHocTuanFragment.cs

示例5: OnCreate

        protected override async void OnCreate(Bundle savedInstanceState)
        {
            base.OnCreate(savedInstanceState);

            _stateMemory = new StateMemory();
            //positionInEpisodeTabList = 0;

            LayoutInflater.Inflate(Resource.Layout.shows_overview_activity, _BaseFrameLayout);

            _myShow = await PopulateSeasons(Intent.GetStringExtra("TMDBID"));

            SetTitle("Description for show " + _myShow.Name);
            if (savedInstanceState != null)
            {
                _stateMemory._isAfterAnimation = savedInstanceState.GetBoolean(KEY_ISAFTERANIMATION, false);
                //positionInEpisodeTabList = savedInstanceState.GetInt("position", 0);
            }
            else
            {
                _stateMemory._isAfterAnimation = false;
            }

            SetUpBeforeFragment();

        }
开发者ID:patrickpetropoulos,项目名称:TrakkerApp,代码行数:25,代码来源:ShowOverviewActivity.cs

示例6: OnCreate

        protected override void OnCreate (Bundle savedInstanceState) 
        {
            base.OnCreate (savedInstanceState);
            SetContentView (Resource.Layout.person_list_activity);

            var options = new PlusClass.PlusOptions.Builder ().AddActivityTypes (MomentUtil.ACTIONS).Build ();
            mGoogleApiClient = new GoogleApiClientBuilder (this)
                .AddConnectionCallbacks (this)
                .AddOnConnectionFailedListener (this)
                .AddApi (PlusClass.API, options)
                .AddScope (PlusClass.ScopePlusLogin)
                .Build ();

            mListItems = new List<string>();
            mListAdapter = new ArrayAdapter<string> (this,
                Android.Resource.Layout.SimpleListItem1, mListItems);
            mPersonListView = FindViewById<ListView> (Resource.Id.person_list);
            mResolvingError = savedInstanceState != null
                && savedInstanceState.GetBoolean (STATE_RESOLVING_ERROR, false);

            var available = GooglePlayServicesUtil.IsGooglePlayServicesAvailable (this);
            if (available != CommonStatusCodes.Success)
                ShowDialog (DIALOG_GET_GOOGLE_PLAY_SERVICES);

            if (Build.VERSION.SdkInt >= BuildVersionCodes.Honeycomb) {
                this.ActionBar.SetDisplayHomeAsUpEnabled (true);
            }
        }
开发者ID:ravensorb,项目名称:AdMobBuddy,代码行数:28,代码来源:ListVisiblePeopleActivity.cs

示例7: OnCreate

        protected override void OnCreate(Bundle savedInstanceState)
        {
            base.OnCreate(savedInstanceState);
            SetContentView(Resource.Layout.activity_cheat);

            if (Build.VERSION.SdkInt >= BuildVersionCodes.Honeycomb) {
                ActionBar.SetSubtitle(Resource.String.test_subject);
            }

            // Create your application here
            mAnswerIsTrue = Intent.GetBooleanExtra(EXTRA_ANSWER_IS_TRUE, false);

            mAnswerTextView = (TextView)FindViewById(Resource.Id.answerTextView);
            mVersionTextView = (TextView)FindViewById(Resource.Id.apiVersion);
            mVersionTextView.SetText(String.Format("API Level {0} {1}", Build.VERSION.Sdk, Build.VERSION.SdkInt.ToString()), TextView.BufferType.Normal);

            // Answer will not be shown until the user presses the button
            mWasAnswerShown = false;
            SetAnswerShownResult(mWasAnswerShown);

            mShowAnswer = (Button)FindViewById(Resource.Id.showAnswerButton);
            mShowAnswer.Click += (object sender, EventArgs e) => {
                ShowAnswer();
            };

            if (savedInstanceState != null) {
                mWasAnswerShown = savedInstanceState.GetBoolean(KEY_ANSWER_SHOWN, false);
                ShowAnswer();
            }
        }
开发者ID:yingfangdu,项目名称:BNR,代码行数:30,代码来源:CheatActivity.cs

示例8: OnCreate

		protected override void OnCreate(Bundle savedInstanceState)
		{
			base.OnCreate(savedInstanceState);

			SetContentView(Resource.Layout.Main);

			if (savedInstanceState != null)
			{
				isStarted = savedInstanceState.GetBoolean(SERVICE_STARTED_KEY, false);
			}

			serviceToStart = new Intent(this, typeof(TimestampService));

			stopServiceButton = FindViewById<Button>(Resource.Id.stop_timestamp_service_button);
			startServiceButton = FindViewById<Button>(Resource.Id.start_timestamp_service_button);

			if (isStarted)
			{
				stopServiceButton.Click += StopServiceButton_Click;
				stopServiceButton.Enabled = true;
				startServiceButton.Enabled = false;
			}
			else 
			{
				startServiceButton.Click += StartServiceButton_Click;
				startServiceButton.Enabled = true;
				stopServiceButton.Enabled = false;
			}
		}
开发者ID:xamarin,项目名称:monodroid-samples,代码行数:29,代码来源:MainActivity.cs

示例9: OnCreate

        protected override void OnCreate(Bundle savedInstanceState)
        {
            base.OnCreate(savedInstanceState);

            // Set our view from the "main" layout resource
            SetContentView(Resource.Layout.Main);

            var layout = FindViewById<SlidingUpPanelLayout>(Resource.Id.sliding_layout);
            FindViewById<TextView>(Resource.Id.more_info).MovementMethod = new LinkMovementMethod();

            layout.ShadowDrawable = Resources.GetDrawable(Resource.Drawable.above_shadow);
            layout.AnchorPoint = 0.3f;
            layout.PanelExpanded += (s, e) => Log.Info(Tag, "PanelExpanded");
            layout.PanelCollapsed += (s, e) => Log.Info(Tag, "PanelCollapsed");
            layout.PanelAnchored += (s, e) => Log.Info(Tag, "PanelAnchored");
            layout.PanelSlide += (s, e) =>
            {
                if (e.SlideOffset < 0.2)
                {
                    if (SupportActionBar.IsShowing)
                        SupportActionBar.Hide();
                }
                else
                {
                    if (!SupportActionBar.IsShowing)
                        SupportActionBar.Show();
                }
            };

            var actionBarHidden = savedInstanceState != null &&
                                  savedInstanceState.GetBoolean(SavedStateActionBarHidden, false);
            if (actionBarHidden)
                SupportActionBar.Hide();
        }
开发者ID:Cheesebaron,项目名称:SlidingUpPanel,代码行数:34,代码来源:DemoActivity.cs

示例10: CanSayHello

		// Returns the current status of the restriction
		private bool CanSayHello(Bundle restrictions)
		{
			bool defaultValue = false;
			bool canSayHello = restrictions == null ? defaultValue :
				restrictions.GetBoolean("can_say_hello", defaultValue);
			Log.Debug (TAG, "canSayHello: " + canSayHello);
			return canSayHello;
		}
开发者ID:WalterVale,项目名称:monodroid-samples,代码行数:9,代码来源:AppRestrictionSchemaFragment.cs

示例11: OnCreateView

		public override View OnCreateView (LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState)
		{

			var rootView = inflater.Inflate(Resource.Layout.DiemThi, container, false);
			bundle = this.Arguments;
			check = bundle.GetBoolean ("Remind");
			autoupdate = bundle.GetBoolean ("AutoUpdateData");

			listView = rootView.FindViewById<ListView>(Resource.Id.listDT);
			progress=rootView.FindViewById<ProgressBar>(Resource.Id.progressDT);
			linear = rootView.FindViewById<LinearLayout>(Resource.Id.linear11);
			txtNotify = rootView.FindViewById<TextView>(Resource.Id.txtNotify_DT);
			txtHocKyDT = rootView.FindViewById<TextView> (Resource.Id.txtHocKyDT);
			LoadData ();

			return rootView;
		}
开发者ID:tienbui123,项目名称:Mobile-VS2,代码行数:17,代码来源:DiemThiFragment.cs

示例12: OnCreate

        protected override void OnCreate(Bundle bundle)
        {
            base.OnCreate(bundle);

            if (bundle != null)
            {
                _authInProgress = bundle.GetBoolean(AUTH_IN_PROGRESS_STATE, false);
            }
        }
开发者ID:ChristopheDaVinci,项目名称:gplus-quickstart-xamarin.android,代码行数:9,代码来源:AccountPickerExample.cs

示例13: OnPostCreate

        /**
         * Further SlidingMenu initialization. Should be called within the activitiy's onPostCreate()
         *
         * @param savedInstanceState the saved instance state (unused)
         */
        public void OnPostCreate(Bundle savedInstanceState)
        {
            if (mViewBehind == null || mViewAbove == null)
            {
                throw new Java.Lang.IllegalStateException("Both setBehindContentView must be called " +
                        "in onCreate in addition to setContentView.");
            }

            mOnPostCreateCalled = true;

            mSlidingMenu.attachToActivity(mActivity,
                    mEnableSlide ? SlidingMenu.SLIDING_WINDOW : SlidingMenu.SLIDING_CONTENT);

            bool open;
            bool secondary;
            if (savedInstanceState != null)
            {
                open = savedInstanceState.GetBoolean("SlidingActivityHelper.open");
                secondary = savedInstanceState.GetBoolean("SlidingActivityHelper.secondary");
            }
            else
            {
                open = false;
                secondary = false;
            }
            
            //new Handler().post(new Runnable() {
            //    public void run() {
            //        if (open) {
            //            if (secondary) {
            //                mSlidingMenu.showSecondaryMenu(false);
            //            } else {
            //                mSlidingMenu.showMenu(false);
            //            }
            //        } else {
            //            mSlidingMenu.showContent(false);					
            //        }
            //    }
            //});

             
            new Handler().Post(new runclass(open, secondary, mSlidingMenu));
        }
开发者ID:skywolf888,项目名称:SlidingMenu.Net,代码行数:48,代码来源:SlidingActivityHelper.cs

示例14: OnRestoreInstanceState

        protected override void OnRestoreInstanceState(Bundle savedInstanceState)
        {
            this.wasClicked = savedInstanceState.GetBoolean ("clicked");
            if (this.wasClicked)
            {
                HandleClick (this, null);
            }

            base.OnRestoreInstanceState (savedInstanceState);
        }
开发者ID:paul33868,项目名称:SimplyMobile,代码行数:10,代码来源:Activity1.cs

示例15: OnCreate

        protected override void OnCreate(Bundle bundle)
        {
            base.OnCreate (bundle);
            SetContentView (Resource.Layout.Main);

            // extract authInProgress from bundle if it's in there
            if (bundle != null && bundle.ContainsKey ("authInProgress")) {
                authInProgress = bundle.GetBoolean ("authInProgress");
            }

            BuildApiClient ();
        }
开发者ID:sl-android,项目名称:android-fit-xamarin,代码行数:12,代码来源:MainActivity.cs


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