1 /* 2 * Copyright 2018 The Android Open Source Project 3 * 4 * Licensed under the Apache License, Version 2.0 (the "License"); 5 * you may not use this file except in compliance with the License. 6 * You may obtain a copy of the License at 7 * 8 * http://www.apache.org/licenses/LICENSE-2.0 9 * 10 * Unless required by applicable law or agreed to in writing, software 11 * distributed under the License is distributed on an "AS IS" BASIS, 12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 * See the License for the specific language governing permissions and 14 * limitations under the License. 15 */ 16 17 package com.google.android.setupcompat.partnerconfig; 18 19 // TODO: optimize the enum 20 /** Resources that can be customized by partner overlay APK. */ 21 public enum PartnerConfig { 22 23 // Status bar background color or illustration. 24 CONFIG_STATUS_BAR_BACKGROUND(PartnerConfigKey.KEY_STATUS_BAR_BACKGROUND, ResourceType.DRAWABLE), 25 26 // The same as "WindowLightStatusBar". If set true, the status bar icons will be drawn such 27 // that it is compatible with a light status bar background 28 CONFIG_LIGHT_STATUS_BAR(PartnerConfigKey.KEY_LIGHT_STATUS_BAR, ResourceType.BOOL), 29 30 // Navigation bar background color 31 CONFIG_NAVIGATION_BAR_BG_COLOR(PartnerConfigKey.KEY_NAVIGATION_BAR_BG_COLOR, ResourceType.COLOR), 32 33 // Navigation bar divider color 34 CONFIG_NAVIGATION_BAR_DIVIDER_COLOR( 35 PartnerConfigKey.KEY_NAVIGATION_BAR_DIVIDER_COLOR, ResourceType.COLOR), 36 37 // Background color of the footer bar. 38 CONFIG_FOOTER_BAR_BG_COLOR(PartnerConfigKey.KEY_FOOTER_BAR_BG_COLOR, ResourceType.COLOR), 39 40 // The min height of the footer buttons 41 CONFIG_FOOTER_BAR_MIN_HEIGHT(PartnerConfigKey.KEY_FOOTER_BAR_MIN_HEIGHT, ResourceType.DIMENSION), 42 43 // The padding start of the footer bar 44 CONFIG_FOOTER_BAR_PADDING_START( 45 PartnerConfigKey.KEY_FOOTER_BAR_PADDING_START, ResourceType.DIMENSION), 46 47 // The padding end of the footer bar 48 CONFIG_FOOTER_BAR_PADDING_END( 49 PartnerConfigKey.KEY_FOOTER_BAR_PADDING_END, ResourceType.DIMENSION), 50 51 // The same as "windowLightNavigationBar". If set true, the navigation bar icons will be drawn 52 // such that it is compatible with a light navigation bar background. 53 CONFIG_LIGHT_NAVIGATION_BAR(PartnerConfigKey.KEY_LIGHT_NAVIGATION_BAR, ResourceType.BOOL), 54 55 // The font face used in footer buttons. This must be a string reference to a font that is 56 // available in the system. Font references (@font or @xml) are not allowed. 57 CONFIG_FOOTER_BUTTON_FONT_FAMILY( 58 PartnerConfigKey.KEY_FOOTER_BUTTON_FONT_FAMILY, ResourceType.STRING), 59 60 // The font weight used in footer buttons. 61 CONFIG_FOOTER_BUTTON_FONT_WEIGHT( 62 PartnerConfigKey.KEY_FOOTER_BUTTON_FONT_WEIGHT, ResourceType.INTEGER), 63 64 // The icon for "add another" action. Can be "@null" for no icon. 65 CONFIG_FOOTER_BUTTON_ICON_ADD_ANOTHER( 66 PartnerConfigKey.KEY_FOOTER_BUTTON_ICON_ADD_ANOTHER, ResourceType.DRAWABLE), 67 68 // The icon for "cancel" action. Can be "@null" for no icon. 69 CONFIG_FOOTER_BUTTON_ICON_CANCEL( 70 PartnerConfigKey.KEY_FOOTER_BUTTON_ICON_CANCEL, ResourceType.DRAWABLE), 71 72 // The icon for "clear" action. Can be "@null" for no icon. 73 CONFIG_FOOTER_BUTTON_ICON_CLEAR( 74 PartnerConfigKey.KEY_FOOTER_BUTTON_ICON_CLEAR, ResourceType.DRAWABLE), 75 76 // The icon for "done" action. Can be "@null" for no icon. 77 CONFIG_FOOTER_BUTTON_ICON_DONE( 78 PartnerConfigKey.KEY_FOOTER_BUTTON_ICON_DONE, ResourceType.DRAWABLE), 79 80 // The icon for "next" action. Can be "@null" for no icon. 81 CONFIG_FOOTER_BUTTON_ICON_NEXT( 82 PartnerConfigKey.KEY_FOOTER_BUTTON_ICON_NEXT, ResourceType.DRAWABLE), 83 84 // The icon for "opt-in" action. Can be "@null" for no icon. 85 CONFIG_FOOTER_BUTTON_ICON_OPT_IN( 86 PartnerConfigKey.KEY_FOOTER_BUTTON_ICON_OPT_IN, ResourceType.DRAWABLE), 87 88 // The icon for "skip" action. Can be "@null" for no icon. 89 CONFIG_FOOTER_BUTTON_ICON_SKIP( 90 PartnerConfigKey.KEY_FOOTER_BUTTON_ICON_SKIP, ResourceType.DRAWABLE), 91 92 // The icon for "stop" action. Can be "@null" for no icon. 93 CONFIG_FOOTER_BUTTON_ICON_STOP( 94 PartnerConfigKey.KEY_FOOTER_BUTTON_ICON_STOP, ResourceType.DRAWABLE), 95 96 // Top padding of the footer buttons 97 CONFIG_FOOTER_BUTTON_PADDING_TOP( 98 PartnerConfigKey.KEY_FOOTER_BUTTON_PADDING_TOP, ResourceType.DIMENSION), 99 100 // Bottom padding of the footer buttons 101 CONFIG_FOOTER_BUTTON_PADDING_BOTTOM( 102 PartnerConfigKey.KEY_FOOTER_BUTTON_PADDING_BOTTOM, ResourceType.DIMENSION), 103 104 // Corner radius of the footer buttons 105 CONFIG_FOOTER_BUTTON_RADIUS(PartnerConfigKey.KEY_FOOTER_BUTTON_RADIUS, ResourceType.DIMENSION), 106 107 // Ripple color alpha the footer buttons 108 CONFIG_FOOTER_BUTTON_RIPPLE_COLOR_ALPHA( 109 PartnerConfigKey.KEY_FOOTER_BUTTON_RIPPLE_ALPHA, ResourceType.FRACTION), 110 111 // Text size of the footer buttons 112 CONFIG_FOOTER_BUTTON_TEXT_SIZE( 113 PartnerConfigKey.KEY_FOOTER_BUTTON_TEXT_SIZE, ResourceType.DIMENSION), 114 115 // The text style of footer buttons {0 = NORMAL}, {1 = BOLD}, {2 = ITALIC}, {3 = BOLD_ITALIC} 116 CONFIG_FOOTER_BUTTON_TEXT_STYLE( 117 PartnerConfigKey.KEY_FOOTER_BUTTON_TEXT_STYLE, ResourceType.INTEGER), 118 119 // The min height of the footer buttons 120 CONFIG_FOOTER_BUTTON_MIN_HEIGHT( 121 PartnerConfigKey.KEY_FOOTER_BUTTON_MIN_HEIGHT, ResourceType.DIMENSION), 122 123 // Make the footer buttons all aligned the end 124 CONFIG_FOOTER_BUTTON_ALIGNED_END( 125 PartnerConfigKey.KEY_FOOTER_BUTTON_ALIGNED_END, ResourceType.BOOL), 126 127 // Disabled background alpha of the footer buttons 128 CONFIG_FOOTER_BUTTON_DISABLED_ALPHA( 129 PartnerConfigKey.KEY_FOOTER_BUTTON_DISABLED_ALPHA, ResourceType.FRACTION), 130 131 // Disabled background color of the footer buttons 132 CONFIG_FOOTER_BUTTON_DISABLED_BG_COLOR( 133 PartnerConfigKey.KEY_FOOTER_BUTTON_DISABLED_BG_COLOR, ResourceType.COLOR), 134 135 // Disabled text color of the primary footer button 136 CONFIG_FOOTER_PRIMARY_BUTTON_DISABLED_TEXT_COLOR( 137 PartnerConfigKey.KEY_PRIMARY_BUTTON_DISABLED_TEXT_COLOR, ResourceType.COLOR), 138 139 // Disabled text color of the secondary footer button 140 CONFIG_FOOTER_SECONDARY_BUTTON_DISABLED_TEXT_COLOR( 141 PartnerConfigKey.KEY_SECONDARY_BUTTON_DISABLED_TEXT_COLOR, ResourceType.COLOR), 142 143 // Background color of the primary footer button 144 CONFIG_FOOTER_PRIMARY_BUTTON_BG_COLOR( 145 PartnerConfigKey.KEY_FOOTER_PRIMARY_BUTTON_BG_COLOR, ResourceType.COLOR), 146 147 // Text color of the primary footer button 148 CONFIG_FOOTER_PRIMARY_BUTTON_TEXT_COLOR( 149 PartnerConfigKey.KEY_FOOTER_PRIMARY_BUTTON_TEXT_COLOR, ResourceType.COLOR), 150 151 // Margin start of the primary footer button 152 CONFIG_FOOTER_PRIMARY_BUTTON_MARGIN_START( 153 PartnerConfigKey.KEY_FOOTER_PRIMARY_BUTTON_MARGIN_START, ResourceType.DIMENSION), 154 155 // Background color of the secondary footer button 156 CONFIG_FOOTER_SECONDARY_BUTTON_BG_COLOR( 157 PartnerConfigKey.KEY_FOOTER_SECONDARY_BUTTON_BG_COLOR, ResourceType.COLOR), 158 159 // Text color of the secondary footer button 160 CONFIG_FOOTER_SECONDARY_BUTTON_TEXT_COLOR( 161 PartnerConfigKey.KEY_FOOTER_SECONDARY_BUTTON_TEXT_COLOR, ResourceType.COLOR), 162 163 // Margin start of the secondary footer button 164 CONFIG_FOOTER_SECONDARY_BUTTON_MARGIN_START( 165 PartnerConfigKey.KEY_FOOTER_SECONDARY_BUTTON_MARGIN_START, ResourceType.DIMENSION), 166 167 // Background color of layout 168 CONFIG_LAYOUT_BACKGROUND_COLOR(PartnerConfigKey.KEY_LAYOUT_BACKGROUND_COLOR, ResourceType.COLOR), 169 170 // Margin start of the layout 171 CONFIG_LAYOUT_MARGIN_START(PartnerConfigKey.KEY_LAYOUT_MARGIN_START, ResourceType.DIMENSION), 172 173 // Margin end of the layout 174 CONFIG_LAYOUT_MARGIN_END(PartnerConfigKey.KEY_LAYOUT_MARGIN_END, ResourceType.DIMENSION), 175 176 // Middle horizontal spacing of the landscape layout 177 CONFIG_LAND_MIDDLE_HORIZONTAL_SPACING( 178 PartnerConfigKey.KEY_LAND_MIDDLE_HORIZONTAL_SPACING, ResourceType.DIMENSION), 179 180 // Text color of the header 181 CONFIG_HEADER_TEXT_COLOR(PartnerConfigKey.KEY_HEADER_TEXT_COLOR, ResourceType.COLOR), 182 183 // Text size of the header 184 CONFIG_HEADER_TEXT_SIZE(PartnerConfigKey.KEY_HEADER_TEXT_SIZE, ResourceType.DIMENSION), 185 186 // Font family of the header 187 CONFIG_HEADER_FONT_FAMILY(PartnerConfigKey.KEY_HEADER_FONT_FAMILY, ResourceType.STRING), 188 189 // Font weight of the header 190 CONFIG_HEADER_FONT_WEIGHT(PartnerConfigKey.KEY_HEADER_FONT_WEIGHT, ResourceType.INTEGER), 191 192 // Margin top of the header text 193 CONFIG_HEADER_TEXT_MARGIN_TOP( 194 PartnerConfigKey.KEY_HEADER_TEXT_MARGIN_TOP, ResourceType.DIMENSION), 195 196 // Margin bottom of the header text 197 CONFIG_HEADER_TEXT_MARGIN_BOTTOM( 198 PartnerConfigKey.KEY_HEADER_TEXT_MARGIN_BOTTOM, ResourceType.DIMENSION), 199 200 // Gravity of the header, icon and description 201 CONFIG_LAYOUT_GRAVITY(PartnerConfigKey.KEY_LAYOUT_GRAVITY, ResourceType.STRING), 202 203 // Margin top of the icon 204 CONFIG_ICON_MARGIN_TOP(PartnerConfigKey.KEY_ICON_MARGIN_TOP, ResourceType.DIMENSION), 205 206 // Size of the icon 207 CONFIG_ICON_SIZE(PartnerConfigKey.KEY_ICON_SIZE, ResourceType.DIMENSION), 208 209 // Background color of the header area 210 CONFIG_HEADER_AREA_BACKGROUND_COLOR( 211 PartnerConfigKey.KEY_HEADER_AREA_BACKGROUND_COLOR, ResourceType.COLOR), 212 213 // Margin bottom of the header container 214 CONFIG_HEADER_CONTAINER_MARGIN_BOTTOM( 215 PartnerConfigKey.KEY_HEADER_CONTAINER_MARGIN_BOTTOM, ResourceType.DIMENSION), 216 217 // Auto text size enabled status 218 CONFIG_HEADER_AUTO_SIZE_ENABLED(PartnerConfigKey.KEY_HEADER_AUTO_SIZE_ENABLED, ResourceType.BOOL), 219 220 // Max text size of header when auto size enabled. Ignored if auto size is false. 221 CONFIG_HEADER_AUTO_SIZE_MAX_TEXT_SIZE( 222 PartnerConfigKey.KEY_HEADER_AUTO_SIZE_MAX_TEXT_SIZE, ResourceType.DIMENSION), 223 224 // Min text size of header when auto size enabled. Ignored if auto size is false. 225 CONFIG_HEADER_AUTO_SIZE_MIN_TEXT_SIZE( 226 PartnerConfigKey.KEY_HEADER_AUTO_SIZE_MIN_TEXT_SIZE, ResourceType.DIMENSION), 227 228 // The max lines of the max text size when auto size enabled. Ignored if auto size is false. 229 CONFIG_HEADER_AUTO_SIZE_MAX_LINE_OF_MAX_SIZE( 230 PartnerConfigKey.KEY_HEADER_AUTO_SIZE_MAX_LINE_OF_MAX_SIZE, ResourceType.INTEGER), 231 232 // Extra line spacing of header when auto size enabled. Ignored if auto size is false. 233 CONFIG_HEADER_AUTO_SIZE_LINE_SPACING_EXTRA( 234 PartnerConfigKey.KEY_HEADER_AUTO_SIZE_LINE_SPACING_EXTRA, ResourceType.DIMENSION), 235 236 // Text size of the description 237 CONFIG_DESCRIPTION_TEXT_SIZE(PartnerConfigKey.KEY_DESCRIPTION_TEXT_SIZE, ResourceType.DIMENSION), 238 239 // Text color of the description 240 CONFIG_DESCRIPTION_TEXT_COLOR(PartnerConfigKey.KEY_DESCRIPTION_TEXT_COLOR, ResourceType.COLOR), 241 242 // Link text color of the description 243 CONFIG_DESCRIPTION_LINK_TEXT_COLOR( 244 PartnerConfigKey.KEY_DESCRIPTION_LINK_TEXT_COLOR, ResourceType.COLOR), 245 246 // Font family of the description 247 CONFIG_DESCRIPTION_FONT_FAMILY(PartnerConfigKey.KEY_DESCRIPTION_FONT_FAMILY, ResourceType.STRING), 248 249 // Font weight of the description 250 CONFIG_DESCRIPTION_FONT_WEIGHT( 251 PartnerConfigKey.KEY_DESCRIPTION_FONT_WEIGHT, ResourceType.INTEGER), 252 253 // Font family of the link text 254 CONFIG_DESCRIPTION_LINK_FONT_FAMILY( 255 PartnerConfigKey.KEY_DESCRIPTION_LINK_FONT_FAMILY, ResourceType.STRING), 256 257 // Margin top of the description text 258 CONFIG_DESCRIPTION_TEXT_MARGIN_TOP( 259 PartnerConfigKey.KEY_DESCRIPTION_TEXT_MARGIN_TOP, ResourceType.DIMENSION), 260 261 // Margin bottom of the description text 262 CONFIG_DESCRIPTION_TEXT_MARGIN_BOTTOM( 263 PartnerConfigKey.KEY_DESCRIPTION_TEXT_MARGIN_BOTTOM, ResourceType.DIMENSION), 264 265 // Font size of the account name 266 CONFIG_ACCOUNT_NAME_TEXT_SIZE( 267 PartnerConfigKey.KEY_ACCOUNT_NAME_TEXT_SIZE, ResourceType.DIMENSION), 268 269 // Font family of the account name 270 CONFIG_ACCOUNT_NAME_FONT_FAMILY(PartnerConfigKey.KEY_ACCOUNT_NAME_FONT_FAMILY, ResourceType.STRING), 271 272 // Margin end of the account avatar 273 CONFIG_ACCOUNT_AVATAR_MARGIN_END( 274 PartnerConfigKey.KEY_ACCOUNT_AVATAR_MARGIN_END, ResourceType.DIMENSION), 275 276 // Size of account avatar 277 CONFIG_ACCOUNT_AVATAR_SIZE(PartnerConfigKey.KEY_ACCOUNT_AVATAR_MAX_SIZE, ResourceType.DIMENSION), 278 279 // Text size of the body content text 280 CONFIG_CONTENT_TEXT_SIZE(PartnerConfigKey.KEY_CONTENT_TEXT_SIZE, ResourceType.DIMENSION), 281 282 // Text color of the body content text 283 CONFIG_CONTENT_TEXT_COLOR(PartnerConfigKey.KEY_CONTENT_TEXT_COLOR, ResourceType.COLOR), 284 285 // Link text color of the body content text 286 CONFIG_CONTENT_LINK_TEXT_COLOR(PartnerConfigKey.KEY_CONTENT_LINK_TEXT_COLOR, ResourceType.COLOR), 287 288 // Font family of the body content text 289 CONFIG_CONTENT_FONT_FAMILY(PartnerConfigKey.KEY_CONTENT_FONT_FAMILY, ResourceType.STRING), 290 291 // Gravity of the body content text 292 CONFIG_CONTENT_LAYOUT_GRAVITY(PartnerConfigKey.KEY_CONTENT_LAYOUT_GRAVITY, ResourceType.STRING), 293 294 // The padding top of the content 295 CONFIG_CONTENT_PADDING_TOP(PartnerConfigKey.KEY_CONTENT_PADDING_TOP, ResourceType.DIMENSION), 296 297 // The text size of the content info. 298 CONFIG_CONTENT_INFO_TEXT_SIZE( 299 PartnerConfigKey.KEY_CONTENT_INFO_TEXT_SIZE, ResourceType.DIMENSION), 300 301 // The font family of the content info. 302 CONFIG_CONTENT_INFO_FONT_FAMILY( 303 PartnerConfigKey.KEY_CONTENT_INFO_FONT_FAMILY, ResourceType.STRING), 304 305 // The text line spacing extra of the content info. 306 CONFIG_CONTENT_INFO_LINE_SPACING_EXTRA( 307 PartnerConfigKey.KEY_CONTENT_INFO_LINE_SPACING_EXTRA, ResourceType.DIMENSION), 308 309 // The icon size of the content info. 310 CONFIG_CONTENT_INFO_ICON_SIZE( 311 PartnerConfigKey.KEY_CONTENT_INFO_ICON_SIZE, ResourceType.DIMENSION), 312 313 // The icon margin end of the content info. 314 CONFIG_CONTENT_INFO_ICON_MARGIN_END( 315 PartnerConfigKey.KEY_CONTENT_INFO_ICON_MARGIN_END, ResourceType.DIMENSION), 316 317 // The padding top of the content info. 318 CONFIG_CONTENT_INFO_PADDING_TOP( 319 PartnerConfigKey.KEY_CONTENT_INFO_PADDING_TOP, ResourceType.DIMENSION), 320 321 // The padding bottom of the content info. 322 CONFIG_CONTENT_INFO_PADDING_BOTTOM( 323 PartnerConfigKey.KEY_CONTENT_INFO_PADDING_BOTTOM, ResourceType.DIMENSION), 324 325 // The title text size of list items. 326 CONFIG_ITEMS_TITLE_TEXT_SIZE(PartnerConfigKey.KEY_ITEMS_TITLE_TEXT_SIZE, ResourceType.DIMENSION), 327 328 // The summary text size of list items. 329 CONFIG_ITEMS_SUMMARY_TEXT_SIZE( 330 PartnerConfigKey.KEY_ITEMS_SUMMARY_TEXT_SIZE, ResourceType.DIMENSION), 331 332 // The summary margin top of list items. 333 CONFIG_ITEMS_SUMMARY_MARGIN_TOP( 334 PartnerConfigKey.KEY_ITEMS_SUMMARY_MARGIN_TOP, ResourceType.DIMENSION), 335 336 // The title font family of list items. 337 CONFIG_ITEMS_TITLE_FONT_FAMILY(PartnerConfigKey.KEY_ITEMS_TITLE_FONT_FAMILY, ResourceType.STRING), 338 339 // The summary font family of list items. 340 CONFIG_ITEMS_SUMMARY_FONT_FAMILY( 341 PartnerConfigKey.KEY_ITEMS_SUMMARY_FONT_FAMILY, ResourceType.STRING), 342 343 // The padding top of list items. 344 CONFIG_ITEMS_PADDING_TOP(PartnerConfigKey.KEY_ITEMS_PADDING_TOP, ResourceType.DIMENSION), 345 346 // The padding bottom of list items. 347 CONFIG_ITEMS_PADDING_BOTTOM(PartnerConfigKey.KEY_ITEMS_PADDING_BOTTOM, ResourceType.DIMENSION), 348 349 // The minimum height of list items. 350 CONFIG_ITEMS_MIN_HEIGHT(PartnerConfigKey.KEY_ITEMS_MIN_HEIGHT, ResourceType.DIMENSION), 351 352 // The divider of list items are showing on the pages. 353 CONFIG_ITEMS_DIVIDER_SHOWN(PartnerConfigKey.KEY_ITEMS_DIVIDER_SHOWN, ResourceType.BOOL), 354 355 // The intrinsic width of the card view for foldable/tablet. 356 CONFIG_CARD_VIEW_INTRINSIC_WIDTH( 357 PartnerConfigKey.KEY_CARD_VIEW_INTRINSIC_WIDTH, ResourceType.DIMENSION), 358 359 // The intrinsic height of the card view for foldable/tablet. 360 CONFIG_CARD_VIEW_INTRINSIC_HEIGHT( 361 PartnerConfigKey.KEY_CARD_VIEW_INTRINSIC_HEIGHT, ResourceType.DIMENSION), 362 363 // The animation of loading screen used in those activities which is non of below type. 364 CONFIG_PROGRESS_ILLUSTRATION_DEFAULT( 365 PartnerConfigKey.KEY_PROGRESS_ILLUSTRATION_DEFAULT, ResourceType.ILLUSTRATION), 366 367 // The animation of loading screen used in those activity which is processing account info or 368 // related functions. 369 // For example:com.google.android.setupwizard.LOAD_ADD_ACCOUNT_INTENT 370 CONFIG_PROGRESS_ILLUSTRATION_ACCOUNT( 371 PartnerConfigKey.KEY_PROGRESS_ILLUSTRATION_ACCOUNT, ResourceType.ILLUSTRATION), 372 373 // The animation of loading screen used in those activity which is processing data connection. 374 // For example:com.android.setupwizard.CAPTIVE_PORTAL 375 CONFIG_PROGRESS_ILLUSTRATION_CONNECTION( 376 PartnerConfigKey.KEY_PROGRESS_ILLUSTRATION_CONNECTION, ResourceType.ILLUSTRATION), 377 378 // The animation of loading screen used in those activities which is updating device. 379 // For example:com.google.android.setupwizard.COMPAT_EARLY_UPDATE 380 CONFIG_PROGRESS_ILLUSTRATION_UPDATE( 381 PartnerConfigKey.KEY_PROGRESS_ILLUSTRATION_UPDATE, ResourceType.ILLUSTRATION), 382 383 // The animation of loading screen used in those activities which is finishing setup. 384 // For example:com.google.android.setupwizard.FINAL_HOLD 385 CONFIG_PROGRESS_ILLUSTRATION_FINAL_HOLD( 386 PartnerConfigKey.KEY_PROGRESS_ILLUSTRATION_FINAL_HOLD, ResourceType.ILLUSTRATION), 387 388 // The animation of loading screen to define how long showing on the pages. 389 CONFIG_PROGRESS_ILLUSTRATION_DISPLAY_MINIMUM_MS( 390 PartnerConfigKey.KEY_PROGRESS_ILLUSTRATION_DISPLAY_MINIMUM_MS, ResourceType.INTEGER), 391 392 // The animation for S+ devices used in those screens waiting for non of below type. 393 CONFIG_LOADING_LOTTIE_DEFAULT( 394 PartnerConfigKey.KEY_LOADING_LOTTIE_DEFAULT, ResourceType.ILLUSTRATION), 395 396 // The animation for S+ devices used in those screens which is processing account info or related 397 // functions. 398 // For example:com.google.android.setupwizard.LOAD_ADD_ACCOUNT_INTENT 399 CONFIG_LOADING_LOTTIE_ACCOUNT( 400 PartnerConfigKey.KEY_LOADING_LOTTIE_ACCOUNT, ResourceType.ILLUSTRATION), 401 402 // The animation for S+ devices used in those screens which is processing data connection. 403 // For example:com.android.setupwizard.CAPTIVE_PORTAL 404 CONFIG_LOADING_LOTTIE_CONNECTION( 405 PartnerConfigKey.KEY_LOADING_LOTTIE_CONNECTION, ResourceType.ILLUSTRATION), 406 407 // The animation for S+ devices used in those screens which is updating devices. 408 // For example:com.google.android.setupwizard.COMPAT_EARLY_UPDATE 409 CONFIG_LOADING_LOTTIE_UPDATE( 410 PartnerConfigKey.KEY_LOADING_LOTTIE_UPDATE, ResourceType.ILLUSTRATION), 411 412 // The animation for S+ devices used in those screens which is updating devices. 413 // For example:com.google.android.setupwizard.COMPAT_EARLY_UPDATE 414 CONFIG_LOADING_LOTTIE_FINAL_HOLD( 415 PartnerConfigKey.KEY_LOADING_LOTTIE_FINAL_HOLD, ResourceType.ILLUSTRATION), 416 417 // The transition type to decide the transition between activities or fragments. 418 CONFIG_TRANSITION_TYPE(PartnerConfigKey.KEY_TRANSITION_TYPE, ResourceType.INTEGER), 419 420 // The list of keypath and color map, applied to default animation when light theme. 421 CONFIG_LOTTIE_LIGHT_THEME_CUSTOMIZATION_DEFAULT( 422 PartnerConfigKey.KEY_LOADING_LIGHT_THEME_CUSTOMIZATION_DEFAULT, ResourceType.STRING_ARRAY), 423 424 // The list of keypath and color map, applied to account animation when light theme. 425 CONFIG_LOTTIE_LIGHT_THEME_CUSTOMIZATION_ACCOUNT( 426 PartnerConfigKey.KEY_LOADING_LIGHT_THEME_CUSTOMIZATION_ACCOUNT, ResourceType.STRING_ARRAY), 427 428 // The list of keypath and color map, applied to connection animation when light theme. 429 CONFIG_LOTTIE_LIGHT_THEME_CUSTOMIZATION_CONNECTION( 430 PartnerConfigKey.KEY_LOADING_LIGHT_THEME_CUSTOMIZATION_CONNECTION, ResourceType.STRING_ARRAY), 431 432 // The list of keypath and color map, applied to update animation when light theme. 433 CONFIG_LOTTIE_LIGHT_THEME_CUSTOMIZATION_UPDATE( 434 PartnerConfigKey.KEY_LOADING_LIGHT_THEME_CUSTOMIZATION_UPDATE, ResourceType.STRING_ARRAY), 435 436 // The list of keypath and color map, applied to update animation when light theme. 437 CONFIG_LOTTIE_LIGHT_THEME_CUSTOMIZATION_FINAL_HOLD( 438 PartnerConfigKey.KEY_LOADING_LIGHT_THEME_CUSTOMIZATION_FINAL_HOLD, ResourceType.STRING_ARRAY), 439 440 // The list of keypath and color map, applied to default animation when dark theme. 441 CONFIG_LOTTIE_DARK_THEME_CUSTOMIZATION_DEFAULT( 442 PartnerConfigKey.KEY_LOADING_DARK_THEME_CUSTOMIZATION_DEFAULT, ResourceType.STRING_ARRAY), 443 444 // The list of keypath and color map, applied to account animation when dark theme. 445 CONFIG_LOTTIE_DARK_THEME_CUSTOMIZATION_ACCOUNT( 446 PartnerConfigKey.KEY_LOADING_DARK_THEME_CUSTOMIZATION_ACCOUNT, ResourceType.STRING_ARRAY), 447 448 // The list of keypath and color map, applied to connection animation when dark theme. 449 CONFIG_LOTTIE_DARK_THEME_CUSTOMIZATION_CONNECTION( 450 PartnerConfigKey.KEY_LOADING_DARK_THEME_CUSTOMIZATION_CONNECTION, ResourceType.STRING_ARRAY), 451 452 // The list of keypath and color map, applied to update animation when dark theme. 453 CONFIG_LOTTIE_DARK_THEME_CUSTOMIZATION_UPDATE( 454 PartnerConfigKey.KEY_LOADING_DARK_THEME_CUSTOMIZATION_UPDATE, ResourceType.STRING_ARRAY), 455 456 // The list of keypath and color map, applied to final hold animation when dark theme. 457 CONFIG_LOTTIE_DARK_THEME_CUSTOMIZATION_FINAL_HOLD( 458 PartnerConfigKey.KEY_LOADING_DARK_THEME_CUSTOMIZATION_FINAL_HOLD, ResourceType.STRING_ARRAY), 459 460 // The padding top of the content frame of loading layout. 461 CONFIG_LOADING_LAYOUT_PADDING_TOP( 462 PartnerConfigKey.KEY_LOADING_LAYOUT_CONTENT_PADDING_TOP, ResourceType.DIMENSION), 463 464 // The padding start of the content frame of loading layout. 465 CONFIG_LOADING_LAYOUT_PADDING_START( 466 PartnerConfigKey.KEY_LOADING_LAYOUT_CONTENT_PADDING_START, ResourceType.DIMENSION), 467 468 // The padding end of the content frame of loading layout. 469 CONFIG_LOADING_LAYOUT_PADDING_END( 470 PartnerConfigKey.KEY_LOADING_LAYOUT_CONTENT_PADDING_END, ResourceType.DIMENSION), 471 472 // The padding bottom of the content frame of loading layout. 473 CONFIG_LOADING_LAYOUT_PADDING_BOTTOM( 474 PartnerConfigKey.KEY_LOADING_LAYOUT_CONTENT_PADDING_BOTTOM, ResourceType.DIMENSION), 475 476 // The height of the header of the loading layout. 477 CONFIG_LOADING_LAYOUT_HEADER_HEIGHT( 478 PartnerConfigKey.KEY_LOADING_LAYOUT_HEADER_HEIGHT, ResourceType.DIMENSION), 479 480 // Use the fullscreen style lottie animation. 481 CONFIG_LOADING_LAYOUT_FULL_SCREEN_ILLUSTRATION_ENABLED( 482 PartnerConfigKey.KEY_LOADING_LAYOUT_FULL_SCREEN_ILLUSTRATION_ENABLED, ResourceType.BOOL), 483 484 // Waiting for the animation finished before process to the next page/action. 485 CONFIG_LOADING_LAYOUT_WAIT_FOR_ANIMATION_FINISHED( 486 PartnerConfigKey.KEY_LOADING_LAYOUT_WAIT_FOR_ANIMATION_FINISHED, ResourceType.BOOL), 487 488 // The margin top of progress bar. 489 CONFIG_PROGRESS_BAR_MARGIN_TOP( 490 PartnerConfigKey.KEY_PROGRESS_BAR_MARGIN_TOP, ResourceType.DIMENSION), 491 492 // The margin bottom of progress bar. 493 CONFIG_PROGRESS_BAR_MARGIN_BOTTOM( 494 PartnerConfigKey.KEY_PROGRESS_BAR_MARGIN_BOTTOM, ResourceType.DIMENSION); 495 496 /** Resource type of the partner resources type. */ 497 public enum ResourceType { 498 INTEGER, 499 BOOL, 500 COLOR, 501 DRAWABLE, 502 STRING, 503 DIMENSION, 504 FRACTION, 505 ILLUSTRATION, 506 STRING_ARRAY 507 } 508 509 private final String resourceName; 510 private final ResourceType resourceType; 511 getResourceType()512 public ResourceType getResourceType() { 513 return resourceType; 514 } 515 getResourceName()516 public String getResourceName() { 517 return resourceName; 518 } 519 PartnerConfig(@artnerConfigKey String resourceName, ResourceType type)520 PartnerConfig(@PartnerConfigKey String resourceName, ResourceType type) { 521 this.resourceName = resourceName; 522 this.resourceType = type; 523 } 524 } 525