Пример #1
0
 private void init(android.view.View decor)
 {
     mContext    = decor.getContext();
     mActionView = ([email protected])decor.findViewById([email protected]
                                                                              .id.action_bar);
     mContextView = ([email protected])decor.findViewById(
         [email protected]_context_bar);
     mContainerView = ([email protected])decor.findViewById(
         [email protected]_bar_container);
     mSplitView = ([email protected])decor.findViewById([email protected]
                                                                                  .id.split_action_bar);
     if (mActionView == null || mContextView == null || mContainerView == null)
     {
         throw new System.InvalidOperationException(GetType().Name + " can only be used "
                                                    + "with a compatible window decor layout");
     }
     mActionView.setContextView(mContextView);
     mContextDisplayMode = mActionView.isSplitActionBar() ? CONTEXT_DISPLAY_SPLIT : CONTEXT_DISPLAY_NORMAL;
     // Older apps get the home button interaction enabled by default.
     // Newer apps need to enable it explicitly.
     setHomeButtonEnabled(mContext.getApplicationInfo().targetSdkVersion < android.os.Build
                          .VERSION_CODES.ICE_CREAM_SANDWICH);
     setHasEmbeddedTabs(mContext.getResources().getBoolean([email protected][email protected]_bar_embed_tabs
                                                           ));
 }
Пример #2
0
		protected internal override void onFinishInflate()
		{
			base.onFinishInflate();
			mActionBarView = ([email protected])findViewById([email protected]
				.id.action_bar);
		}
Пример #3
0
 protected internal override void onFinishInflate()
 {
     base.onFinishInflate();
     mActionBarView = ([email protected])findViewById([email protected]
                                                                           .id.action_bar);
 }
Пример #4
0
		private void init(android.view.View decor)
		{
			mContext = decor.getContext();
			mActionView = ([email protected])decor.findViewById([email protected]
				.id.action_bar);
			mContextView = ([email protected])decor.findViewById(
				[email protected]_context_bar);
			mContainerView = ([email protected])decor.findViewById(
				[email protected]_bar_container);
			mSplitView = ([email protected])decor.findViewById([email protected]
				.id.split_action_bar);
			if (mActionView == null || mContextView == null || mContainerView == null)
			{
				throw new System.InvalidOperationException(GetType().Name + " can only be used " 
					+ "with a compatible window decor layout");
			}
			mActionView.setContextView(mContextView);
			mContextDisplayMode = mActionView.isSplitActionBar() ? CONTEXT_DISPLAY_SPLIT : CONTEXT_DISPLAY_NORMAL;
			// Older apps get the home button interaction enabled by default.
			// Newer apps need to enable it explicitly.
			setHomeButtonEnabled(mContext.getApplicationInfo().targetSdkVersion < android.os.Build
				.VERSION_CODES.ICE_CREAM_SANDWICH);
			setHasEmbeddedTabs(mContext.getResources().getBoolean([email protected][email protected]_bar_embed_tabs
				));
		}