Add home controls complication type in settingslib.

Bug: 240707969
Test: manually on device
Change-Id: I568d9323b8f552da8adb9c033b772846bb947abf
This commit is contained in:
Darrell Shi
2022-07-29 22:15:46 +00:00
parent 3f2c081a30
commit 9b7a7182a7
2 changed files with 8 additions and 1 deletions

View File

@@ -1608,6 +1608,8 @@
<string name="dream_complication_title_aqi">Air Quality</string>
<!-- Screensaver overlay which displays cast info. [CHAR LIMIT=20] -->
<string name="dream_complication_title_cast_info">Cast Info</string>
<!-- Screensaver overlay which displays home controls. [CHAR LIMIT=20] -->
<string name="dream_complication_title_home_controls">Home Controls</string>
<!-- Title for a screen allowing the user to choose a profile picture. [CHAR LIMIT=NONE] -->
<string name="avatar_picker_title">Choose a profile picture</string>

View File

@@ -91,7 +91,8 @@ public class DreamBackend {
COMPLICATION_TYPE_DATE,
COMPLICATION_TYPE_WEATHER,
COMPLICATION_TYPE_AIR_QUALITY,
COMPLICATION_TYPE_CAST_INFO
COMPLICATION_TYPE_CAST_INFO,
COMPLICATION_TYPE_HOME_CONTROLS
})
@Retention(RetentionPolicy.SOURCE)
public @interface ComplicationType {}
@@ -101,6 +102,7 @@ public class DreamBackend {
public static final int COMPLICATION_TYPE_WEATHER = 3;
public static final int COMPLICATION_TYPE_AIR_QUALITY = 4;
public static final int COMPLICATION_TYPE_CAST_INFO = 5;
public static final int COMPLICATION_TYPE_HOME_CONTROLS = 6;
private final Context mContext;
private final IDreamManager mDreamManager;
@@ -346,6 +348,9 @@ public class DreamBackend {
case COMPLICATION_TYPE_CAST_INFO:
res = R.string.dream_complication_title_cast_info;
break;
case COMPLICATION_TYPE_HOME_CONTROLS:
res = R.string.dream_complication_title_home_controls;
break;
default:
return null;
}