Skip to content

Commit

Permalink
Development - TRDS 5.0 [4/5]
Browse files Browse the repository at this point in the history
Change-Id: If98625636951eaebb611f6553e97d4d7c3c325a5
Signed-off-by: STELIX <[email protected]>
  • Loading branch information
kufikugel authored and STELIX committed Oct 6, 2015
1 parent 6ddd064 commit b17e947
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,7 @@ public void onCreate(Bundle icicle) {
+ "orientation=" + c.orientation + "\n"
+ "screenLayout=0x" + Integer.toHexString(c.screenLayout) + "\n"
+ "touchscreen=" + c.touchscreen + "\n"
+ "uiThemeMode=" + Integer.toHexString(c.uiThemeMode) + "\n"
+ "uiMode=0x" + Integer.toHexString(c.uiMode) + "\n"
+ "\n"
+ "DisplayMetrics\n"
Expand Down
16 changes: 16 additions & 0 deletions ndk/platforms/android-9/include/android/configuration.h
Original file line number Diff line number Diff line change
Expand Up @@ -73,6 +73,11 @@ enum {
ACONFIGURATION_SCREENLONG_NO = 0x1,
ACONFIGURATION_SCREENLONG_YES = 0x2,

ACONFIGURATION_UI_THEME_MODE_ANY = 0x0000,
ACONFIGURATION_UI_THEME_MODE_NORMAL = 0x0001,
ACONFIGURATION_UI_THEME_MODE_HOLO_DARK = 0x0002,
ACONFIGURATION_UI_THEME_MODE_HOLO_LIGHT = 0x0003,

ACONFIGURATION_UI_MODE_TYPE_ANY = 0x00,
ACONFIGURATION_UI_MODE_TYPE_NORMAL = 0x01,
ACONFIGURATION_UI_MODE_TYPE_DESK = 0x02,
Expand All @@ -94,6 +99,7 @@ enum {
ACONFIGURATION_SCREEN_SIZE = 0x0200,
ACONFIGURATION_VERSION = 0x0400,
ACONFIGURATION_SCREEN_LAYOUT = 0x0800,
ACONFIGURATION_UI_THEME_MODE = 0x0900,
ACONFIGURATION_UI_MODE = 0x1000,
};

Expand Down Expand Up @@ -265,6 +271,16 @@ int32_t AConfiguration_getScreenLong(AConfiguration* config);
*/
void AConfiguration_setScreenLong(AConfiguration* config, int32_t screenLong);

/**
* Return the current ACONFIGURATION_UI_THEME_MODE_* set in the configuration.
*/
int32_t AConfiguration_getUiThemeMode(AConfiguration* config);

/**
* Set the current theme UI mode in the configuration.
*/
void AConfiguration_setUiThemeMode(AConfiguration* config, int32_t uiThemeMode);

/**
* Return the current ACONFIGURATION_UI_MODE_TYPE_* set in the configuration.
*/
Expand Down

0 comments on commit b17e947

Please sign in to comment.