AI2 Component  (Version nb184)
com.google.appinventor.components.runtime.util.theme.IceCreamSandwichThemeHelper Class Reference
Inheritance diagram for com.google.appinventor.components.runtime.util.theme.IceCreamSandwichThemeHelper:
com.google.appinventor.components.runtime.util.theme.ThemeHelper

Public Member Functions

 IceCreamSandwichThemeHelper (AppInventorCompatActivity activity)
 
void requestActionBar ()
 
boolean setActionBarVisible (boolean visible)
 
boolean hasActionBar ()
 
void setTitle (String title)
 
void setActionBarAnimation (boolean enabled)
 
void setTitle (String title, boolean black)
 

Detailed Description

Definition at line 17 of file IceCreamSandwichThemeHelper.java.

Constructor & Destructor Documentation

◆ IceCreamSandwichThemeHelper()

com.google.appinventor.components.runtime.util.theme.IceCreamSandwichThemeHelper.IceCreamSandwichThemeHelper ( AppInventorCompatActivity  activity)

Definition at line 21 of file IceCreamSandwichThemeHelper.java.

Member Function Documentation

◆ hasActionBar()

boolean com.google.appinventor.components.runtime.util.theme.IceCreamSandwichThemeHelper.hasActionBar ( )

Tests whether the theme supports ActionBar.

Returns
true if ActionBar is supported in the current theme, otherwise false.

Implements com.google.appinventor.components.runtime.util.theme.ThemeHelper.

Definition at line 47 of file IceCreamSandwichThemeHelper.java.

◆ requestActionBar()

void com.google.appinventor.components.runtime.util.theme.IceCreamSandwichThemeHelper.requestActionBar ( )

Request the ActionBar functionality fot the platform, if available.

Implements com.google.appinventor.components.runtime.util.theme.ThemeHelper.

Definition at line 26 of file IceCreamSandwichThemeHelper.java.

◆ setActionBarAnimation()

void com.google.appinventor.components.runtime.util.theme.IceCreamSandwichThemeHelper.setActionBarAnimation ( boolean  enabled)

Sets whether the ActionBar appear/disappear animation is shown (AppCompat mode only).

Parameters
enabledtrue if the animation should be used when visibility of the ActionBar is toggled, otherwise false.

Implements com.google.appinventor.components.runtime.util.theme.ThemeHelper.

Definition at line 60 of file IceCreamSandwichThemeHelper.java.

◆ setActionBarVisible()

boolean com.google.appinventor.components.runtime.util.theme.IceCreamSandwichThemeHelper.setActionBarVisible ( boolean  visible)

Change the ActionBar visibility

Parameters
visibletrue if the ActionBar should be made visible, otherwise false.
Returns
true if the ActionBar is available. If false is returned, no future requests for the ActionBar will be honored (usually due to being in Classic theme mode).

Implements com.google.appinventor.components.runtime.util.theme.ThemeHelper.

Definition at line 31 of file IceCreamSandwichThemeHelper.java.

◆ setTitle() [1/2]

void com.google.appinventor.components.runtime.util.theme.IceCreamSandwichThemeHelper.setTitle ( String  title)

Sets the title of the activity in the ActionBar.

Parameters
titleNew title text for the ActionBar

Implements com.google.appinventor.components.runtime.util.theme.ThemeHelper.

Definition at line 52 of file IceCreamSandwichThemeHelper.java.

◆ setTitle() [2/2]

void com.google.appinventor.components.runtime.util.theme.IceCreamSandwichThemeHelper.setTitle ( String  title,
boolean  black 
)

Sets the title of the ActionBar and its color. If

black

is true, the helper should attempt to make the text black. Otherwise, the text will be white.

Parameters
titlethe new title for the ActionBar
blacktrue if black text is desired, false if white text is desired

Implements com.google.appinventor.components.runtime.util.theme.ThemeHelper.

Definition at line 68 of file IceCreamSandwichThemeHelper.java.


The documentation for this class was generated from the following file: