本文整理了Java中android.app.Activity.onPreparePanel()
方法的一些代码示例,展示了Activity.onPreparePanel()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Activity.onPreparePanel()
方法的具体详情如下:
包路径:android.app.Activity
类名称:Activity
方法名:onPreparePanel
暂无
代码示例来源:origin: kingargyle/adt-leanback-support
/**
* @hide
*/
protected boolean onPrepareOptionsPanel(View view, Menu menu) {
return super.onPreparePanel(Window.FEATURE_OPTIONS_PANEL, view, menu);
}
代码示例来源:origin: iqiyi/Neptune
@Override
public boolean onPreparePanel(int int0, android.view.View view1, android.view.Menu menu2) {
return mOriginActivity.onPreparePanel(int0, view1, menu2);
}
代码示例来源:origin: com.uphyca/android-junit4-robolectric
/**
* @param featureId
* @param view
* @param menu
* @return
* @see android.app.Activity#onPreparePanel(int, android.view.View,
* android.view.Menu)
*/
public boolean onPreparePanel(int featureId,
View view,
Menu menu) {
return mActivity.onPreparePanel(featureId, view, menu);
}
代码示例来源:origin: shazam/android-aspects
@Override
public boolean onPreparePanel(int featureId, View view, Menu menu) {
return super.onPreparePanel(featureId, view, menu) || dispatcher.dispatchOnPreparePanel(this, featureId, view, menu);
}
代码示例来源:origin: com.google.android/support-v4
/**
* Dispatch onPrepareOptionsMenu() to fragments.
*/
@Override
public boolean onPreparePanel(int featureId, View view, Menu menu) {
if (featureId == Window.FEATURE_OPTIONS_PANEL && menu != null) {
if (mOptionsMenuInvalidated) {
mOptionsMenuInvalidated = false;
menu.clear();
onCreatePanelMenu(featureId, menu);
}
boolean goforit = super.onPreparePanel(featureId, view, menu);
goforit |= mFragments.dispatchPrepareOptionsMenu(menu);
return goforit && menu.hasVisibleItems();
}
return super.onPreparePanel(featureId, view, menu);
}
代码示例来源:origin: kingargyle/adt-leanback-support
/**
* Dispatch onPrepareOptionsMenu() to fragments.
*/
@Override
public boolean onPreparePanel(int featureId, View view, Menu menu) {
if (featureId == Window.FEATURE_OPTIONS_PANEL && menu != null) {
if (mOptionsMenuInvalidated) {
mOptionsMenuInvalidated = false;
menu.clear();
onCreatePanelMenu(featureId, menu);
}
boolean goforit = onPrepareOptionsPanel(view, menu);
goforit |= mFragments.dispatchPrepareOptionsMenu(menu);
return goforit;
}
return super.onPreparePanel(featureId, view, menu);
}
代码示例来源:origin: ELynx/pokemon-go-xposed-mitm
public boolean onPreparePanel(int featureId, android.view.View view, android.view.Menu menu) {
if (ScriptLoader.isCalledFromJRuby()) return super.onPreparePanel(featureId, view, menu);
if (!JRubyAdapter.isInitialized()) {
Log.i("Method called before JRuby runtime was initialized: RubotoActivity#onPreparePanel");
return super.onPreparePanel(featureId, view, menu);
}
String rubyClassName = scriptInfo.getRubyClassName();
if (rubyClassName == null) return super.onPreparePanel(featureId, view, menu);
if ((Boolean)JRubyAdapter.runScriptlet(rubyClassName + ".instance_methods(false).any?{|m| m.to_sym == :onPreparePanel}")) {
return (Boolean) JRubyAdapter.runRubyMethod(Boolean.class, scriptInfo.getRubyInstance(), "onPreparePanel", new Object[]{featureId, view, menu});
} else {
if ((Boolean)JRubyAdapter.runScriptlet(rubyClassName + ".instance_methods(false).any?{|m| m.to_sym == :on_prepare_panel}")) {
return (Boolean) JRubyAdapter.runRubyMethod(Boolean.class, scriptInfo.getRubyInstance(), "on_prepare_panel", new Object[]{featureId, view, menu});
} else {
if ((Boolean)JRubyAdapter.runScriptlet(rubyClassName + ".instance_methods(true).any?{|m| m.to_sym == :on_prepare_panel}")) {
return (Boolean) JRubyAdapter.runRubyMethod(Boolean.class, scriptInfo.getRubyInstance(), "on_prepare_panel", new Object[]{featureId, view, menu});
} else {
return (Boolean) JRubyAdapter.runRubyMethod(Boolean.class, scriptInfo.getRubyInstance(), "onPreparePanel", new Object[]{featureId, view, menu});
}
}
}
}
内容来源于网络,如有侵权,请联系作者删除!