diff options
| author | Adam Powell <adamp@google.com> | 2010-04-20 10:01:14 -0700 |
|---|---|---|
| committer | Adam Powell <adamp@google.com> | 2010-05-13 01:27:59 -0700 |
| commit | 33b974393b6fadcefc896ec4a0f9b66724f61e9f (patch) | |
| tree | 5c90001e5931a2cf09e9900c58d6d815d3dfa46b /core/java/android/view/Window.java | |
| parent | 5d8636dbada23bd40c80dbf43702d538b2997ac4 (diff) | |
ActionBar added to framework, integrated with Activity and styles.
Added onClick attribute support to menus in MenuInflater.
Change-Id: I739771b4f249d87a0d8b15969f3d526b099067a1
Diffstat (limited to 'core/java/android/view/Window.java')
| -rw-r--r-- | core/java/android/view/Window.java | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/core/java/android/view/Window.java b/core/java/android/view/Window.java index 7dd5085f1075..e1ff4e86b725 100644 --- a/core/java/android/view/Window.java +++ b/core/java/android/view/Window.java @@ -61,6 +61,13 @@ public abstract class Window { @hide */ public static final int FEATURE_OPENGL = 8; + /** + * Flag for enabling the Action Bar. + * This is enabled by default for some devices. The Action Bar + * replaces the title bar and provides an alternate location + * for an on-screen menu button on some devices. + */ + public static final int FEATURE_ACTION_BAR = 9; /** Flag for setting the progress bar's visibility to VISIBLE */ public static final int PROGRESS_VISIBILITY_ON = -1; /** Flag for setting the progress bar's visibility to GONE */ @@ -981,6 +988,16 @@ public abstract class Window { { return mFeatures; } + + /** + * Query for the availability of a certain feature. + * + * @param feature The feature ID to check + * @return true if the feature is enabled, false otherwise. + */ + public boolean hasFeature(int feature) { + return (getFeatures() & (1 << feature)) != 0; + } /** * Return the feature bits that are being implemented by this Window. |
