Adnan Begovic | d5fdee9 | 2015-11-13 15:28:21 -0800 | [diff] [blame] | 1 | /** |
| 2 | * Copyright (c) 2015, The CyanogenMod Project |
Bruno Martins | 6cd6665 | 2019-11-04 12:06:30 +0000 | [diff] [blame] | 3 | * Copyright (C) 2019 The LineageOS Project |
Adnan Begovic | d5fdee9 | 2015-11-13 15:28:21 -0800 | [diff] [blame] | 4 | * |
| 5 | * Licensed under the Apache License, Version 2.0 (the "License"); |
| 6 | * you may not use this file except in compliance with the License. |
| 7 | * You may obtain a copy of the License at |
| 8 | * |
| 9 | * http://www.apache.org/licenses/LICENSE-2.0 |
| 10 | * |
| 11 | * Unless required by applicable law or agreed to in writing, software |
| 12 | * distributed under the License is distributed on an "AS IS" BASIS, |
| 13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 14 | * See the License for the specific language governing permissions and |
| 15 | * limitations under the License. |
| 16 | */ |
| 17 | |
| 18 | import java.util.Arrays; |
| 19 | |
| 20 | /** |
Sam Mortimer | 542742b | 2017-09-18 19:44:11 -0700 | [diff] [blame] | 21 | * LineageSettings contains Lineage specific preferences in System, Secure, and Global. |
Adnan Begovic | d5fdee9 | 2015-11-13 15:28:21 -0800 | [diff] [blame] | 22 | */ |
Sam Mortimer | 542742b | 2017-09-18 19:44:11 -0700 | [diff] [blame] | 23 | public final class LineageSettings { |
| 24 | public static final String AUTHORITY = "lineagesettings"; |
Adnan Begovic | d5fdee9 | 2015-11-13 15:28:21 -0800 | [diff] [blame] | 25 | |
| 26 | /** |
Sam Mortimer | 542742b | 2017-09-18 19:44:11 -0700 | [diff] [blame] | 27 | * System settings, containing miscellaneous Lineage system preferences. This table holds simple |
Adnan Begovic | d5fdee9 | 2015-11-13 15:28:21 -0800 | [diff] [blame] | 28 | * name/value pairs. There are convenience functions for accessing individual settings entries. |
| 29 | */ |
| 30 | public static final class System { |
| 31 | // region System Settings |
| 32 | |
| 33 | /** |
| 34 | * Quick Settings Quick Pulldown |
| 35 | * 0 = off, 1 = right, 2 = left |
| 36 | * @hide |
| 37 | */ |
| 38 | public static final String QS_QUICK_PULLDOWN = "qs_quick_pulldown"; |
| 39 | |
| 40 | /** |
| 41 | * Whether to attach a queue to media notifications. |
| 42 | * 0 = 0ff, 1 = on |
| 43 | * @hide |
| 44 | */ |
| 45 | public static final String NOTIFICATION_PLAY_QUEUE = "notification_play_queue"; |
| 46 | |
| 47 | /** |
| 48 | * Whether the HighTouchSensitivity is activated or not. |
| 49 | * 0 = off, 1 = on |
| 50 | * @hide |
| 51 | */ |
| 52 | public static final String HIGH_TOUCH_SENSITIVITY_ENABLE = |
| 53 | "high_touch_sensitivity_enable"; |
| 54 | |
| 55 | /** |
| 56 | * Show the pending notification counts as overlays on the status bar |
| 57 | * @hide |
| 58 | */ |
| 59 | public static final String SYSTEM_PROFILES_ENABLED = "system_profiles_enabled"; |
| 60 | |
| 61 | /** |
Hendrik Hagendorn | 5bb06dc | 2016-12-13 18:32:16 +0100 | [diff] [blame] | 62 | * Whether to show the clock in the right or left position or show it in the center |
| 63 | * 0: show the clock in the right position (LTR) |
| 64 | * 1: show the clock in the center |
| 65 | * 2: show the clock in the left position (LTR) |
| 66 | * default: 0 |
Adnan Begovic | d5fdee9 | 2015-11-13 15:28:21 -0800 | [diff] [blame] | 67 | * @hide |
| 68 | */ |
| 69 | public static final String STATUS_BAR_CLOCK = "status_bar_clock"; |
| 70 | |
| 71 | /** |
| 72 | * Display style of AM/PM next to clock in status bar |
| 73 | * 0: Normal display (Eclair stock) |
| 74 | * 1: Small display (Froyo stock) |
| 75 | * 2: No display (Gingerbread/ICS stock) |
| 76 | * default: 2 |
| 77 | * @hide |
| 78 | */ |
| 79 | public static final String STATUS_BAR_AM_PM = "status_bar_am_pm"; |
| 80 | |
| 81 | /** |
| 82 | * Display style of the status bar battery information |
| 83 | * 0: Display the battery an icon in portrait mode |
Hendrik Hagendorn | 5ded0fc | 2017-01-15 08:45:51 +0100 | [diff] [blame] | 84 | * 1: Display the battery as a circle |
| 85 | * 2: Display the battery as plain text |
Adnan Begovic | d5fdee9 | 2015-11-13 15:28:21 -0800 | [diff] [blame] | 86 | * default: 0 |
| 87 | * @hide |
| 88 | */ |
| 89 | public static final String STATUS_BAR_BATTERY_STYLE = "status_bar_battery_style"; |
| 90 | |
| 91 | /** |
| 92 | * Status bar battery % |
| 93 | * 0: Hide the battery percentage |
| 94 | * 1: Display the battery percentage inside the icon |
| 95 | * 2: Display the battery percentage next to the icon |
| 96 | * @hide |
| 97 | */ |
| 98 | public static final String STATUS_BAR_SHOW_BATTERY_PERCENT = "status_bar_show_battery_percent"; |
| 99 | // endregion |
| 100 | |
| 101 | /** |
| 102 | * Whether the phone ringtone should be played in an increasing manner |
| 103 | * @hide |
| 104 | */ |
| 105 | public static final String INCREASING_RING = "increasing_ring"; |
| 106 | |
| 107 | /** |
| 108 | * Start volume fraction for increasing ring volume |
| 109 | * @hide |
| 110 | */ |
| 111 | public static final String INCREASING_RING_START_VOLUME = "increasing_ring_start_vol"; |
| 112 | |
| 113 | /** |
| 114 | * Ramp up time (seconds) for increasing ring |
| 115 | * @hide |
| 116 | */ |
| 117 | public static final String INCREASING_RING_RAMP_UP_TIME = "increasing_ring_ramp_up_time"; |
| 118 | |
| 119 | /** |
| 120 | * Volume Adjust Sounds Enable, This is the noise made when using volume hard buttons |
| 121 | * Defaults to 1 - sounds enabled |
| 122 | * @hide |
| 123 | */ |
| 124 | public static final String VOLUME_ADJUST_SOUNDS_ENABLED = "volume_adjust_sounds_enabled"; |
| 125 | |
| 126 | /** |
| 127 | * Navigation controls to Use |
| 128 | * @hide |
| 129 | */ |
| 130 | public static final String NAV_BUTTONS = "nav_buttons"; |
| 131 | |
| 132 | /** |
Adnan Begovic | d5fdee9 | 2015-11-13 15:28:21 -0800 | [diff] [blame] | 133 | * boolean value. toggles using arrow key locations on nav bar |
| 134 | * as left and right dpad keys |
| 135 | * @hide |
| 136 | */ |
| 137 | public static final String NAVIGATION_BAR_MENU_ARROW_KEYS = "navigation_bar_menu_arrow_keys"; |
| 138 | |
| 139 | /** |
| 140 | * Action to perform when the home key is long-pressed. |
| 141 | * (Default can be configured via config_longPressOnHomeBehavior) |
| 142 | * 0 - Nothing |
| 143 | * 1 - Menu |
| 144 | * 2 - App-switch |
| 145 | * 3 - Search |
| 146 | * 4 - Voice search |
| 147 | * 5 - In-app search |
| 148 | * 6 - Launch Camera |
| 149 | * 7 - Action Sleep |
| 150 | * 8 - Last app |
| 151 | * @hide |
| 152 | */ |
| 153 | public static final String KEY_HOME_LONG_PRESS_ACTION = "key_home_long_press_action"; |
| 154 | |
| 155 | /** |
| 156 | * Action to perform when the home key is double-tapped. |
| 157 | * (Default can be configured via config_doubleTapOnHomeBehavior) |
| 158 | * (See KEY_HOME_LONG_PRESS_ACTION for valid values) |
| 159 | * @hide |
| 160 | */ |
| 161 | public static final String KEY_HOME_DOUBLE_TAP_ACTION = "key_home_double_tap_action"; |
| 162 | |
| 163 | /** |
| 164 | * Whether to wake the screen with the back key, the value is boolean. |
| 165 | * @hide |
| 166 | */ |
| 167 | public static final String BACK_WAKE_SCREEN = "back_wake_screen"; |
| 168 | |
| 169 | /** |
| 170 | * Whether to wake the screen with the menu key, the value is boolean. |
| 171 | * @hide |
| 172 | */ |
| 173 | public static final String MENU_WAKE_SCREEN = "menu_wake_screen"; |
| 174 | |
| 175 | /** |
| 176 | * Whether to wake the screen with the volume keys, the value is boolean. |
| 177 | * @hide |
| 178 | */ |
| 179 | public static final String VOLUME_WAKE_SCREEN = "volume_wake_screen"; |
| 180 | |
| 181 | /** |
| 182 | * Action to perform when the menu key is pressed. (Default is 1) |
| 183 | * (See KEY_HOME_LONG_PRESS_ACTION for valid values) |
| 184 | * @hide |
| 185 | */ |
| 186 | public static final String KEY_MENU_ACTION = "key_menu_action"; |
| 187 | |
| 188 | /** |
| 189 | * Action to perform when the menu key is long-pressed. |
| 190 | * (Default is 0 on devices with a search key, 3 on devices without) |
| 191 | * (See KEY_HOME_LONG_PRESS_ACTION for valid values) |
| 192 | * @hide |
| 193 | */ |
| 194 | public static final String KEY_MENU_LONG_PRESS_ACTION = "key_menu_long_press_action"; |
| 195 | |
| 196 | /** |
| 197 | * Action to perform when the assistant (search) key is pressed. (Default is 3) |
| 198 | * (See KEY_HOME_LONG_PRESS_ACTION for valid values) |
| 199 | * @hide |
| 200 | */ |
| 201 | public static final String KEY_ASSIST_ACTION = "key_assist_action"; |
| 202 | |
| 203 | /** |
| 204 | * Action to perform when the assistant (search) key is long-pressed. (Default is 4) |
| 205 | * (See KEY_HOME_LONG_PRESS_ACTION for valid values) |
| 206 | * @hide |
| 207 | */ |
| 208 | public static final String KEY_ASSIST_LONG_PRESS_ACTION = "key_assist_long_press_action"; |
| 209 | |
| 210 | /** |
| 211 | * Action to perform when the app switch key is pressed. (Default is 2) |
| 212 | * (See KEY_HOME_LONG_PRESS_ACTION for valid values) |
| 213 | * @hide |
| 214 | */ |
| 215 | public static final String KEY_APP_SWITCH_ACTION = "key_app_switch_action"; |
| 216 | |
| 217 | /** |
| 218 | * Action to perform when the app switch key is long-pressed. (Default is 0) |
| 219 | * (See KEY_HOME_LONG_PRESS_ACTION for valid values) |
| 220 | * @hide |
| 221 | */ |
| 222 | public static final String KEY_APP_SWITCH_LONG_PRESS_ACTION = "key_app_switch_long_press_action"; |
| 223 | |
| 224 | /** |
| 225 | * Whether to wake the screen with the home key, the value is boolean. |
| 226 | * @hide |
| 227 | */ |
| 228 | public static final String HOME_WAKE_SCREEN = "home_wake_screen"; |
| 229 | |
| 230 | /** |
| 231 | * Whether to wake the screen with the assist key, the value is boolean. |
| 232 | * @hide |
| 233 | */ |
| 234 | public static final String ASSIST_WAKE_SCREEN = "assist_wake_screen"; |
| 235 | |
| 236 | /** |
| 237 | * Whether to wake the screen with the app switch key, the value is boolean. |
| 238 | * @hide |
| 239 | */ |
| 240 | public static final String APP_SWITCH_WAKE_SCREEN = "app_switch_wake_screen"; |
| 241 | |
| 242 | /** |
| 243 | * Whether to wake the screen with the camera key half-press. |
| 244 | * @hide |
| 245 | */ |
| 246 | public static final String CAMERA_WAKE_SCREEN = "camera_wake_screen"; |
| 247 | |
| 248 | /** |
| 249 | * Whether or not to send device back to sleep if Camera button is released ("Peek") |
| 250 | * @hide |
| 251 | */ |
| 252 | public static final String CAMERA_SLEEP_ON_RELEASE = "camera_sleep_on_release"; |
| 253 | |
| 254 | /** |
| 255 | * Whether to launch secure camera app when key is longpressed |
| 256 | * @hide |
| 257 | */ |
| 258 | public static final String CAMERA_LAUNCH = "camera_launch"; |
| 259 | |
| 260 | /** |
Zhao Wei Liew | 33fc2d4 | 2016-10-09 09:43:44 +0800 | [diff] [blame] | 261 | * Show icon when stylus is used |
| 262 | * The value is boolean (1 or 0). |
| 263 | * @hide |
| 264 | */ |
| 265 | public static final String STYLUS_ICON_ENABLED = "stylus_icon_enabled"; |
| 266 | |
| 267 | /** |
Adnan Begovic | d5fdee9 | 2015-11-13 15:28:21 -0800 | [diff] [blame] | 268 | * Swap volume buttons when the screen is rotated |
| 269 | * 0 - Disabled |
| 270 | * 1 - Enabled (screen is rotated by 90 or 180 degrees: phone, hybrid) |
| 271 | * 2 - Enabled (screen is rotated by 180 or 270 degrees: tablet) |
| 272 | * @hide |
| 273 | */ |
| 274 | public static final String SWAP_VOLUME_KEYS_ON_ROTATION = "swap_volume_keys_on_rotation"; |
| 275 | |
| 276 | /** |
| 277 | * Whether the battery light should be enabled (if hardware supports it) |
| 278 | * The value is boolean (1 or 0). |
| 279 | * @hide |
| 280 | */ |
| 281 | public static final String BATTERY_LIGHT_ENABLED = "battery_light_enabled"; |
| 282 | |
| 283 | /** |
| 284 | * Whether the battery LED should repeatedly flash when the battery is low |
| 285 | * on charge. The value is boolean (1 or 0). |
| 286 | * @hide |
| 287 | */ |
| 288 | public static final String BATTERY_LIGHT_PULSE = "battery_light_pulse"; |
| 289 | |
| 290 | /** |
| 291 | * What color to use for the battery LED while charging - low |
| 292 | * @hide |
| 293 | */ |
| 294 | public static final String BATTERY_LIGHT_LOW_COLOR = "battery_light_low_color"; |
| 295 | |
| 296 | /** |
| 297 | * What color to use for the battery LED while charging - medium |
| 298 | * @hide |
| 299 | */ |
| 300 | public static final String BATTERY_LIGHT_MEDIUM_COLOR = "battery_light_medium_color"; |
| 301 | |
| 302 | /** |
| 303 | * What color to use for the battery LED while charging - full |
| 304 | * @hide |
| 305 | */ |
| 306 | public static final String BATTERY_LIGHT_FULL_COLOR = "battery_light_full_color"; |
| 307 | |
| 308 | /** |
| 309 | * Sprint MWI Quirk: Show message wait indicator notifications |
| 310 | * @hide |
| 311 | */ |
| 312 | public static final String ENABLE_MWI_NOTIFICATION = "enable_mwi_notification"; |
| 313 | |
| 314 | /** |
| 315 | * Check the proximity sensor during wakeup |
| 316 | * @hide |
| 317 | */ |
| 318 | public static final String PROXIMITY_ON_WAKE = "proximity_on_wake"; |
| 319 | |
| 320 | /** |
| 321 | * Enable looking up of phone numbers of nearby places |
| 322 | * |
| 323 | * @hide |
| 324 | */ |
| 325 | public static final String ENABLE_FORWARD_LOOKUP = "enable_forward_lookup"; |
| 326 | |
| 327 | /** |
| 328 | * Enable looking up of phone numbers of people |
| 329 | * |
| 330 | * @hide |
| 331 | */ |
| 332 | public static final String ENABLE_PEOPLE_LOOKUP = "enable_people_lookup"; |
| 333 | |
| 334 | /** |
| 335 | * Enable looking up of information of phone numbers not in the contacts |
| 336 | * |
| 337 | * @hide |
| 338 | */ |
| 339 | public static final String ENABLE_REVERSE_LOOKUP = "enable_reverse_lookup"; |
| 340 | |
| 341 | /** |
| 342 | * The forward lookup provider |
| 343 | * |
| 344 | * @hide |
| 345 | */ |
| 346 | public static final String FORWARD_LOOKUP_PROVIDER = "forward_lookup_provider"; |
| 347 | |
| 348 | /** |
| 349 | * The people lookup provider |
| 350 | * |
| 351 | * @hide |
| 352 | */ |
| 353 | public static final String PEOPLE_LOOKUP_PROVIDER = "people_lookup_provider"; |
| 354 | |
| 355 | /** |
| 356 | * The reverse lookup provider |
| 357 | * |
| 358 | * @hide |
| 359 | */ |
| 360 | public static final String REVERSE_LOOKUP_PROVIDER = "reverse_lookup_provider"; |
| 361 | |
| 362 | /** |
| 363 | * The OpenCNAM paid account ID |
| 364 | * |
| 365 | * @hide |
| 366 | */ |
| 367 | public static final String DIALER_OPENCNAM_ACCOUNT_SID = "dialer_opencnam_account_sid"; |
| 368 | |
| 369 | /** |
| 370 | * The OpenCNAM authentication token |
| 371 | * |
| 372 | * @hide |
| 373 | */ |
| 374 | public static final String DIALER_OPENCNAM_AUTH_TOKEN = "dialer_opencnam_auth_token"; |
| 375 | |
| 376 | /** |
| 377 | * Whether wifi settings will connect to access point automatically |
| 378 | * 0 = automatically |
| 379 | * 1 = manually |
| 380 | * @hide |
| 381 | */ |
| 382 | public static final String WIFI_AUTO_CONNECT_TYPE = "wifi_auto_connect_type"; |
| 383 | |
| 384 | /** |
| 385 | * Color temperature of the display during the day |
| 386 | * @hide |
| 387 | */ |
| 388 | public static final String DISPLAY_TEMPERATURE_DAY = "display_temperature_day"; |
| 389 | |
| 390 | /** |
| 391 | * Color temperature of the display at night |
| 392 | * @hide |
| 393 | */ |
| 394 | public static final String DISPLAY_TEMPERATURE_NIGHT = "display_temperature_night"; |
| 395 | |
| 396 | /** |
| 397 | * Display color temperature adjustment mode, one of DAY (default), NIGHT, or AUTO. |
| 398 | * @hide |
| 399 | */ |
| 400 | public static final String DISPLAY_TEMPERATURE_MODE = "display_temperature_mode"; |
| 401 | |
| 402 | /** |
| 403 | * Automatic outdoor mode |
| 404 | * @hide |
| 405 | */ |
| 406 | public static final String DISPLAY_AUTO_OUTDOOR_MODE = "display_auto_outdoor_mode"; |
| 407 | |
| 408 | /** |
| 409 | * Use display power saving features such as CABC or CABL |
| 410 | * @hide |
| 411 | */ |
| 412 | public static final String DISPLAY_LOW_POWER = "display_low_power"; |
| 413 | |
| 414 | /** |
| 415 | * Use color enhancement feature of display |
| 416 | * @hide |
| 417 | */ |
| 418 | public static final String DISPLAY_COLOR_ENHANCE = "display_color_enhance"; |
| 419 | |
| 420 | /** |
| 421 | * Manual display color adjustments (RGB values as floats, separated by spaces) |
| 422 | * @hide |
| 423 | */ |
| 424 | public static final String DISPLAY_COLOR_ADJUSTMENT = "display_color_adjustment"; |
| 425 | |
| 426 | /** |
| 427 | * Did we tell about how they can stop breaking their eyes? |
| 428 | * @hide |
| 429 | */ |
| 430 | public static final String LIVE_DISPLAY_HINTED = "live_display_hinted"; |
| 431 | |
| 432 | /** |
| 433 | * Enable statusbar double tap gesture on to put device to sleep |
| 434 | * @hide |
| 435 | */ |
| 436 | public static final String DOUBLE_TAP_SLEEP_GESTURE = "double_tap_sleep_gesture"; |
| 437 | |
| 438 | /** |
| 439 | * Boolean value on whether to show weather in the statusbar |
| 440 | * @hide |
| 441 | */ |
| 442 | public static final String STATUS_BAR_SHOW_WEATHER = "status_bar_show_weather"; |
| 443 | |
| 444 | /** |
| 445 | * Show search bar in recents |
| 446 | * @hide |
| 447 | */ |
| 448 | public static final String RECENTS_SHOW_SEARCH_BAR = "recents_show_search_bar"; |
| 449 | |
| 450 | /** |
| 451 | * Whether navigation bar is placed on the left side in landscape mode |
| 452 | * @hide |
| 453 | */ |
| 454 | public static final String NAVBAR_LEFT_IN_LANDSCAPE = "navigation_bar_left"; |
| 455 | |
| 456 | /** |
| 457 | * Locale for secondary overlay on dialer for t9 search input |
| 458 | * @hide |
| 459 | */ |
| 460 | public static final String T9_SEARCH_INPUT_LOCALE = "t9_search_input_locale"; |
| 461 | |
| 462 | /** |
| 463 | * If all file types can be accepted over Bluetooth OBEX. |
| 464 | * @hide |
| 465 | */ |
| 466 | public static final String BLUETOOTH_ACCEPT_ALL_FILES = |
| 467 | "bluetooth_accept_all_files"; |
| 468 | |
| 469 | /** |
| 470 | * Whether to scramble a pin unlock layout |
| 471 | * @hide |
| 472 | */ |
| 473 | public static final String LOCKSCREEN_PIN_SCRAMBLE_LAYOUT = |
| 474 | "lockscreen_scramble_pin_layout"; |
| 475 | |
| 476 | /** |
Dan Pasanen | c4becbb | 2016-05-11 10:20:57 -0500 | [diff] [blame] | 477 | * Whether keyguard will rotate to landscape mode |
| 478 | * @hide |
| 479 | */ |
| 480 | public static final String LOCKSCREEN_ROTATION = "lockscreen_rotation"; |
| 481 | |
| 482 | /** |
Adnan Begovic | d5fdee9 | 2015-11-13 15:28:21 -0800 | [diff] [blame] | 483 | * @hide |
| 484 | */ |
| 485 | public static final String SHOW_ALARM_ICON = "show_alarm_icon"; |
| 486 | |
| 487 | /** |
| 488 | * Whether to show the IME switcher in the status bar |
| 489 | * @hide |
| 490 | */ |
| 491 | public static final String STATUS_BAR_IME_SWITCHER = "status_bar_ime_switcher"; |
| 492 | |
| 493 | /** Whether to allow one finger quick settings expansion on the right side of the statusbar. |
| 494 | * |
| 495 | * @hide |
| 496 | */ |
| 497 | public static final String STATUS_BAR_QUICK_QS_PULLDOWN = "status_bar_quick_qs_pulldown"; |
| 498 | |
| 499 | /** Whether to show the brightness slider in quick settings panel. |
| 500 | * |
| 501 | * @hide |
| 502 | */ |
| 503 | public static final String QS_SHOW_BRIGHTNESS_SLIDER = "qs_show_brightness_slider"; |
| 504 | |
| 505 | /** |
| 506 | * Whether to control brightness from status bar |
| 507 | * |
| 508 | * @hide |
| 509 | */ |
| 510 | public static final String STATUS_BAR_BRIGHTNESS_CONTROL = "status_bar_brightness_control"; |
| 511 | |
| 512 | /** |
| 513 | * Whether or not volume button music controls should be enabled to seek media tracks |
| 514 | * @hide |
| 515 | */ |
| 516 | public static final String VOLBTN_MUSIC_CONTROLS = "volbtn_music_controls"; |
| 517 | |
| 518 | /** |
| 519 | * Use EdgeGesture Service for system gestures in PhoneWindowManager |
| 520 | * @hide |
| 521 | */ |
| 522 | public static final String USE_EDGE_SERVICE_FOR_GESTURES = "edge_service_for_gestures"; |
| 523 | |
| 524 | /** |
| 525 | * Show the pending notification counts as overlays on the status bar |
| 526 | * @hide |
| 527 | */ |
| 528 | public static final String STATUS_BAR_NOTIF_COUNT = "status_bar_notif_count"; |
| 529 | |
| 530 | /** |
| 531 | * Call recording format value |
| 532 | * 0: AMR_WB |
| 533 | * 1: MPEG_4 |
| 534 | * Default: 0 |
| 535 | * @hide |
| 536 | */ |
| 537 | public static final String CALL_RECORDING_FORMAT = "call_recording_format"; |
| 538 | |
| 539 | /** |
| 540 | * Contains the notifications light maximum brightness to use. |
| 541 | * @hide |
| 542 | */ |
| 543 | public static final String NOTIFICATION_LIGHT_BRIGHTNESS_LEVEL = |
| 544 | "notification_light_brightness_level"; |
| 545 | |
| 546 | /** |
Adnan Begovic | d5fdee9 | 2015-11-13 15:28:21 -0800 | [diff] [blame] | 547 | * Whether to allow notifications with the screen on or DayDreams. |
| 548 | * The value is boolean (1 or 0). Default will always be false. |
| 549 | * @hide |
| 550 | */ |
| 551 | public static final String NOTIFICATION_LIGHT_SCREEN_ON = |
| 552 | "notification_light_screen_on_enable"; |
| 553 | |
| 554 | /** |
| 555 | * What color to use for the notification LED by default |
| 556 | * @hide |
| 557 | */ |
| 558 | public static final String NOTIFICATION_LIGHT_PULSE_DEFAULT_COLOR = |
| 559 | "notification_light_pulse_default_color"; |
| 560 | |
| 561 | /** |
| 562 | * How long to flash the notification LED by default |
| 563 | * @hide |
| 564 | */ |
| 565 | public static final String NOTIFICATION_LIGHT_PULSE_DEFAULT_LED_ON = |
| 566 | "notification_light_pulse_default_led_on"; |
| 567 | |
| 568 | /** |
| 569 | * How long to wait between flashes for the notification LED by default |
| 570 | * @hide |
| 571 | */ |
| 572 | public static final String NOTIFICATION_LIGHT_PULSE_DEFAULT_LED_OFF = |
| 573 | "notification_light_pulse_default_led_off"; |
| 574 | |
| 575 | /** |
| 576 | * What color to use for the missed call notification LED |
| 577 | * @hide |
| 578 | */ |
| 579 | public static final String NOTIFICATION_LIGHT_PULSE_CALL_COLOR = |
| 580 | "notification_light_pulse_call_color"; |
| 581 | |
| 582 | /** |
| 583 | * How long to flash the missed call notification LED |
| 584 | * @hide |
| 585 | */ |
| 586 | public static final String NOTIFICATION_LIGHT_PULSE_CALL_LED_ON = |
| 587 | "notification_light_pulse_call_led_on"; |
| 588 | |
| 589 | /** |
| 590 | * How long to wait between flashes for the missed call notification LED |
| 591 | * @hide |
| 592 | */ |
| 593 | public static final String NOTIFICATION_LIGHT_PULSE_CALL_LED_OFF = |
| 594 | "notification_light_pulse_call_led_off"; |
| 595 | /** |
| 596 | * What color to use for the voicemail notification LED |
| 597 | * @hide |
| 598 | */ |
| 599 | public static final String NOTIFICATION_LIGHT_PULSE_VMAIL_COLOR = |
| 600 | "notification_light_pulse_vmail_color"; |
| 601 | |
| 602 | /** |
| 603 | * How long to flash the voicemail notification LED |
| 604 | * @hide |
| 605 | */ |
| 606 | public static final String NOTIFICATION_LIGHT_PULSE_VMAIL_LED_ON = |
| 607 | "notification_light_pulse_vmail_led_on"; |
| 608 | |
| 609 | /** |
| 610 | * How long to wait between flashes for the voicemail notification LED |
| 611 | * @hide |
| 612 | */ |
| 613 | public static final String NOTIFICATION_LIGHT_PULSE_VMAIL_LED_OFF = |
| 614 | "notification_light_pulse_vmail_led_off"; |
| 615 | |
| 616 | /** |
| 617 | * Whether to use the custom LED values for the notification pulse LED. |
| 618 | * @hide |
| 619 | */ |
| 620 | public static final String NOTIFICATION_LIGHT_PULSE_CUSTOM_ENABLE = |
| 621 | "notification_light_pulse_custom_enable"; |
| 622 | |
| 623 | /** |
| 624 | * Which custom LED values to use for the notification pulse LED. |
| 625 | * @hide |
| 626 | */ |
| 627 | public static final String NOTIFICATION_LIGHT_PULSE_CUSTOM_VALUES = |
| 628 | "notification_light_pulse_custom_values"; |
| 629 | |
| 630 | /** |
| 631 | * @hide |
| 632 | */ |
| 633 | public static final String[] LEGACY_SYSTEM_SETTINGS = new String[]{ |
Sam Mortimer | 542742b | 2017-09-18 19:44:11 -0700 | [diff] [blame] | 634 | LineageSettings.System.QS_QUICK_PULLDOWN, |
| 635 | LineageSettings.System.NAV_BUTTONS, |
| 636 | LineageSettings.System.KEY_HOME_LONG_PRESS_ACTION, |
| 637 | LineageSettings.System.KEY_HOME_DOUBLE_TAP_ACTION, |
| 638 | LineageSettings.System.BACK_WAKE_SCREEN, |
| 639 | LineageSettings.System.MENU_WAKE_SCREEN, |
| 640 | LineageSettings.System.VOLUME_WAKE_SCREEN, |
| 641 | LineageSettings.System.KEY_MENU_ACTION, |
| 642 | LineageSettings.System.KEY_MENU_LONG_PRESS_ACTION, |
| 643 | LineageSettings.System.KEY_ASSIST_ACTION, |
| 644 | LineageSettings.System.KEY_ASSIST_LONG_PRESS_ACTION, |
| 645 | LineageSettings.System.KEY_APP_SWITCH_ACTION, |
| 646 | LineageSettings.System.KEY_APP_SWITCH_LONG_PRESS_ACTION, |
| 647 | LineageSettings.System.HOME_WAKE_SCREEN, |
| 648 | LineageSettings.System.ASSIST_WAKE_SCREEN, |
| 649 | LineageSettings.System.APP_SWITCH_WAKE_SCREEN, |
| 650 | LineageSettings.System.CAMERA_WAKE_SCREEN, |
| 651 | LineageSettings.System.CAMERA_SLEEP_ON_RELEASE, |
| 652 | LineageSettings.System.CAMERA_LAUNCH, |
| 653 | LineageSettings.System.STYLUS_ICON_ENABLED, |
| 654 | LineageSettings.System.SWAP_VOLUME_KEYS_ON_ROTATION, |
| 655 | LineageSettings.System.BATTERY_LIGHT_ENABLED, |
| 656 | LineageSettings.System.BATTERY_LIGHT_PULSE, |
| 657 | LineageSettings.System.BATTERY_LIGHT_LOW_COLOR, |
| 658 | LineageSettings.System.BATTERY_LIGHT_MEDIUM_COLOR, |
| 659 | LineageSettings.System.BATTERY_LIGHT_FULL_COLOR, |
| 660 | LineageSettings.System.ENABLE_MWI_NOTIFICATION, |
| 661 | LineageSettings.System.PROXIMITY_ON_WAKE, |
| 662 | LineageSettings.System.ENABLE_FORWARD_LOOKUP, |
| 663 | LineageSettings.System.ENABLE_PEOPLE_LOOKUP, |
| 664 | LineageSettings.System.ENABLE_REVERSE_LOOKUP, |
| 665 | LineageSettings.System.FORWARD_LOOKUP_PROVIDER, |
| 666 | LineageSettings.System.PEOPLE_LOOKUP_PROVIDER, |
| 667 | LineageSettings.System.REVERSE_LOOKUP_PROVIDER, |
| 668 | LineageSettings.System.DIALER_OPENCNAM_ACCOUNT_SID, |
| 669 | LineageSettings.System.DIALER_OPENCNAM_AUTH_TOKEN, |
| 670 | LineageSettings.System.DISPLAY_TEMPERATURE_DAY, |
| 671 | LineageSettings.System.DISPLAY_TEMPERATURE_NIGHT, |
| 672 | LineageSettings.System.DISPLAY_TEMPERATURE_MODE, |
| 673 | LineageSettings.System.DISPLAY_AUTO_OUTDOOR_MODE, |
| 674 | LineageSettings.System.DISPLAY_LOW_POWER, |
| 675 | LineageSettings.System.DISPLAY_COLOR_ENHANCE, |
| 676 | LineageSettings.System.DISPLAY_COLOR_ADJUSTMENT, |
| 677 | LineageSettings.System.LIVE_DISPLAY_HINTED, |
| 678 | LineageSettings.System.DOUBLE_TAP_SLEEP_GESTURE, |
| 679 | LineageSettings.System.STATUS_BAR_SHOW_WEATHER, |
| 680 | LineageSettings.System.RECENTS_SHOW_SEARCH_BAR, |
| 681 | LineageSettings.System.NAVBAR_LEFT_IN_LANDSCAPE, |
| 682 | LineageSettings.System.T9_SEARCH_INPUT_LOCALE, |
| 683 | LineageSettings.System.BLUETOOTH_ACCEPT_ALL_FILES, |
| 684 | LineageSettings.System.LOCKSCREEN_PIN_SCRAMBLE_LAYOUT, |
| 685 | LineageSettings.System.LOCKSCREEN_ROTATION, |
| 686 | LineageSettings.System.SHOW_ALARM_ICON, |
| 687 | LineageSettings.System.STATUS_BAR_IME_SWITCHER, |
| 688 | LineageSettings.System.QS_SHOW_BRIGHTNESS_SLIDER, |
| 689 | LineageSettings.System.STATUS_BAR_BRIGHTNESS_CONTROL, |
| 690 | LineageSettings.System.VOLBTN_MUSIC_CONTROLS, |
| 691 | LineageSettings.System.SWAP_VOLUME_KEYS_ON_ROTATION, |
| 692 | LineageSettings.System.USE_EDGE_SERVICE_FOR_GESTURES, |
| 693 | LineageSettings.System.STATUS_BAR_NOTIF_COUNT, |
| 694 | LineageSettings.System.CALL_RECORDING_FORMAT, |
| 695 | LineageSettings.System.NOTIFICATION_LIGHT_BRIGHTNESS_LEVEL, |
Sam Mortimer | 542742b | 2017-09-18 19:44:11 -0700 | [diff] [blame] | 696 | LineageSettings.System.NOTIFICATION_LIGHT_SCREEN_ON, |
| 697 | LineageSettings.System.NOTIFICATION_LIGHT_PULSE_DEFAULT_COLOR, |
| 698 | LineageSettings.System.NOTIFICATION_LIGHT_PULSE_DEFAULT_LED_ON, |
| 699 | LineageSettings.System.NOTIFICATION_LIGHT_PULSE_DEFAULT_LED_OFF, |
| 700 | LineageSettings.System.NOTIFICATION_LIGHT_PULSE_CALL_COLOR, |
| 701 | LineageSettings.System.NOTIFICATION_LIGHT_PULSE_CALL_LED_ON, |
| 702 | LineageSettings.System.NOTIFICATION_LIGHT_PULSE_CALL_LED_OFF, |
| 703 | LineageSettings.System.NOTIFICATION_LIGHT_PULSE_VMAIL_COLOR, |
| 704 | LineageSettings.System.NOTIFICATION_LIGHT_PULSE_VMAIL_LED_ON, |
| 705 | LineageSettings.System.NOTIFICATION_LIGHT_PULSE_VMAIL_LED_OFF, |
| 706 | LineageSettings.System.NOTIFICATION_LIGHT_PULSE_CUSTOM_ENABLE, |
| 707 | LineageSettings.System.NOTIFICATION_LIGHT_PULSE_CUSTOM_VALUES, |
| 708 | LineageSettings.System.STATUS_BAR_QUICK_QS_PULLDOWN, |
| 709 | LineageSettings.System.VOLUME_ADJUST_SOUNDS_ENABLED, |
| 710 | LineageSettings.System.SYSTEM_PROFILES_ENABLED, |
| 711 | LineageSettings.System.INCREASING_RING, |
| 712 | LineageSettings.System.INCREASING_RING_START_VOLUME, |
| 713 | LineageSettings.System.INCREASING_RING_RAMP_UP_TIME, |
| 714 | LineageSettings.System.STATUS_BAR_CLOCK, |
| 715 | LineageSettings.System.STATUS_BAR_AM_PM, |
| 716 | LineageSettings.System.STATUS_BAR_BATTERY_STYLE, |
| 717 | LineageSettings.System.STATUS_BAR_SHOW_BATTERY_PERCENT, |
Sam Mortimer | 542742b | 2017-09-18 19:44:11 -0700 | [diff] [blame] | 718 | LineageSettings.System.NAVIGATION_BAR_MENU_ARROW_KEYS, |
Adnan Begovic | d5fdee9 | 2015-11-13 15:28:21 -0800 | [diff] [blame] | 719 | }; |
| 720 | |
| 721 | /** |
| 722 | * @hide |
| 723 | */ |
| 724 | public static boolean isLegacySetting(String key) { |
| 725 | return Arrays.asList(LEGACY_SYSTEM_SETTINGS).contains(key); |
| 726 | } |
| 727 | } |
| 728 | |
| 729 | /** |
Sam Mortimer | 542742b | 2017-09-18 19:44:11 -0700 | [diff] [blame] | 730 | * Secure settings, containing miscellaneous Lineage secure preferences. This |
Adnan Begovic | d5fdee9 | 2015-11-13 15:28:21 -0800 | [diff] [blame] | 731 | * table holds simple name/value pairs. There are convenience |
| 732 | * functions for accessing individual settings entries. |
| 733 | */ |
| 734 | public static final class Secure { |
| 735 | |
| 736 | // region Secure Settings |
| 737 | |
| 738 | /** |
| 739 | * Whether to enable "advanced mode" for the current user. |
| 740 | * Boolean setting. 0 = no, 1 = yes. |
| 741 | * @hide |
| 742 | */ |
| 743 | public static final String ADVANCED_MODE = "advanced_mode"; |
| 744 | |
| 745 | /** |
| 746 | * The time in ms to keep the button backlight on after pressing a button. |
| 747 | * A value of 0 will keep the buttons on for as long as the screen is on. |
| 748 | * @hide |
| 749 | */ |
| 750 | public static final String BUTTON_BACKLIGHT_TIMEOUT = "button_backlight_timeout"; |
| 751 | |
| 752 | /** |
| 753 | * The button brightness to be used while the screen is on or after a button press, |
| 754 | * depending on the value of {@link BUTTON_BACKLIGHT_TIMEOUT}. |
| 755 | * Valid value range is between 0 and {@link PowerManager#getMaximumButtonBrightness()} |
| 756 | * @hide |
| 757 | */ |
| 758 | public static final String BUTTON_BRIGHTNESS = "button_brightness"; |
| 759 | |
| 760 | /** |
Adnan Begovic | d5fdee9 | 2015-11-13 15:28:21 -0800 | [diff] [blame] | 761 | * Developer options - Navigation Bar show switch |
| 762 | * @hide |
| 763 | */ |
| 764 | public static final String DEV_FORCE_SHOW_NAVBAR = "dev_force_show_navbar"; |
| 765 | |
| 766 | /** |
| 767 | * The keyboard brightness to be used while the screen is on. |
| 768 | * Valid value range is between 0 and {@link PowerManager#getMaximumKeyboardBrightness()} |
| 769 | * @hide |
| 770 | */ |
| 771 | public static final String KEYBOARD_BRIGHTNESS = "keyboard_brightness"; |
| 772 | |
| 773 | /** |
Adnan Begovic | d5fdee9 | 2015-11-13 15:28:21 -0800 | [diff] [blame] | 774 | * Custom navring actions |
| 775 | * @hide |
| 776 | */ |
| 777 | public static final String[] NAVIGATION_RING_TARGETS = new String[] { |
| 778 | "navigation_ring_targets_0", |
| 779 | "navigation_ring_targets_1", |
| 780 | "navigation_ring_targets_2", |
| 781 | }; |
| 782 | |
| 783 | /** |
| 784 | * String to contain power menu actions |
LuK1337 | d8742f0 | 2020-11-06 20:04:03 +0100 | [diff] [blame] | 785 | * @deprecated |
Adnan Begovic | d5fdee9 | 2015-11-13 15:28:21 -0800 | [diff] [blame] | 786 | * @hide |
| 787 | */ |
LuK1337 | d8742f0 | 2020-11-06 20:04:03 +0100 | [diff] [blame] | 788 | @Deprecated |
Adnan Begovic | d5fdee9 | 2015-11-13 15:28:21 -0800 | [diff] [blame] | 789 | public static final String POWER_MENU_ACTIONS = "power_menu_actions"; |
| 790 | |
| 791 | /** |
| 792 | * Whether to show the brightness slider in quick settings panel. |
| 793 | * @hide |
| 794 | */ |
| 795 | public static final String QS_SHOW_BRIGHTNESS_SLIDER = "qs_show_brightness_slider"; |
| 796 | |
| 797 | /** |
| 798 | * List of QS tile names |
| 799 | * @hide |
| 800 | */ |
| 801 | public static final String QS_TILES = "sysui_qs_tiles"; |
| 802 | |
| 803 | /** |
| 804 | * Use "main" tiles on the first row of the quick settings panel |
| 805 | * 0 = no, 1 = yes |
| 806 | * @hide |
| 807 | */ |
| 808 | public static final String QS_USE_MAIN_TILES = "sysui_qs_main_tiles"; |
| 809 | |
| 810 | /** |
| 811 | * Global stats collection |
| 812 | * @hide |
| 813 | */ |
| 814 | public static final String STATS_COLLECTION = "stats_collection"; |
| 815 | |
| 816 | /** |
| 817 | * Boolean value whether to link ringtone and notification volume |
| 818 | * |
| 819 | * @hide |
| 820 | */ |
| 821 | public static final String VOLUME_LINK_NOTIFICATION = "volume_link_notification"; |
| 822 | |
| 823 | /** |
| 824 | * Whether newly installed apps should run with privacy guard by default |
Bruno Martins | 6cd6665 | 2019-11-04 12:06:30 +0000 | [diff] [blame] | 825 | * @deprecated |
Adnan Begovic | d5fdee9 | 2015-11-13 15:28:21 -0800 | [diff] [blame] | 826 | * @hide |
| 827 | */ |
Bruno Martins | 6cd6665 | 2019-11-04 12:06:30 +0000 | [diff] [blame] | 828 | @Deprecated |
Adnan Begovic | d5fdee9 | 2015-11-13 15:28:21 -0800 | [diff] [blame] | 829 | public static final String PRIVACY_GUARD_DEFAULT = "privacy_guard_default"; |
| 830 | |
| 831 | /** |
| 832 | * The global recents long press activity chosen by the user. |
| 833 | * This setting is stored as a flattened component name as |
| 834 | * per {@link ComponentName#flattenToString()}. |
| 835 | * |
| 836 | * @hide |
| 837 | */ |
| 838 | public static final String RECENTS_LONG_PRESS_ACTIVITY = "recents_long_press_activity"; |
| 839 | |
| 840 | /** |
| 841 | * What happens when the user presses the Home button when the |
| 842 | * phone is ringing.<br/> |
| 843 | * <b>Values:</b><br/> |
| 844 | * 1 - Nothing happens. (Default behavior)<br/> |
| 845 | * 2 - The Home button answer the current call.<br/> |
| 846 | * |
| 847 | * @hide |
| 848 | */ |
| 849 | public static final String RING_HOME_BUTTON_BEHAVIOR = "ring_home_button_behavior"; |
| 850 | |
| 851 | /** |
| 852 | * RING_HOME_BUTTON_BEHAVIOR value for "do nothing". |
| 853 | * @hide |
| 854 | */ |
| 855 | public static final int RING_HOME_BUTTON_BEHAVIOR_DO_NOTHING = 0x1; |
| 856 | |
| 857 | /** |
| 858 | * RING_HOME_BUTTON_BEHAVIOR value for "answer". |
| 859 | * @hide |
| 860 | */ |
| 861 | public static final int RING_HOME_BUTTON_BEHAVIOR_ANSWER = 0x2; |
| 862 | |
| 863 | /** |
| 864 | * RING_HOME_BUTTON_BEHAVIOR default value. |
| 865 | * @hide |
| 866 | */ |
| 867 | public static final int RING_HOME_BUTTON_BEHAVIOR_DEFAULT = |
| 868 | RING_HOME_BUTTON_BEHAVIOR_DO_NOTHING; |
| 869 | |
| 870 | /** |
| 871 | * When the user has enable the option to have a "bug report" command |
| 872 | * in the power menu. |
| 873 | * @deprecated Use {@link android.provider.Settings.Global#BUGREPORT_IN_POWER_MENU} instead |
| 874 | * @hide |
| 875 | */ |
| 876 | @Deprecated |
| 877 | public static final String BUGREPORT_IN_POWER_MENU = "bugreport_in_power_menu"; |
| 878 | |
| 879 | /** |
| 880 | * Performance profile |
| 881 | * @hide |
| 882 | */ |
| 883 | public static final String PERFORMANCE_PROFILE = "performance_profile"; |
| 884 | |
| 885 | /** |
| 886 | * App-based performance profile selection |
| 887 | * @hide |
| 888 | */ |
| 889 | public static final String APP_PERFORMANCE_PROFILES_ENABLED = "app_perf_profiles_enabled"; |
| 890 | |
| 891 | /** |
| 892 | * Launch actions for left/right lockscreen targets |
| 893 | * @hide |
| 894 | */ |
| 895 | public static final String LOCKSCREEN_TARGETS = "lockscreen_target_actions"; |
| 896 | |
| 897 | /** |
| 898 | * Whether to display a menu containing 'Wipe data', 'Force close' and other options |
| 899 | * in the notification area and in the recent app list |
| 900 | * @hide |
| 901 | */ |
| 902 | public static final String DEVELOPMENT_SHORTCUT = "development_shortcut"; |
| 903 | |
| 904 | /** |
| 905 | * What happens when the user presses the Power button while in-call |
| 906 | * and the screen is on.<br/> |
| 907 | * <b>Values:</b><br/> |
| 908 | * 1 - The Power button turns off the screen and locks the device. (Default behavior)<br/> |
| 909 | * 2 - The Power button hangs up the current call.<br/> |
| 910 | * |
| 911 | * @hide |
| 912 | */ |
| 913 | public static final String INCALL_POWER_BUTTON_BEHAVIOR = "incall_power_button_behavior"; |
| 914 | |
| 915 | /** |
| 916 | * INCALL_POWER_BUTTON_BEHAVIOR value for "turn off screen". |
| 917 | * @hide |
| 918 | */ |
| 919 | public static final int INCALL_POWER_BUTTON_BEHAVIOR_SCREEN_OFF = 0x1; |
| 920 | |
| 921 | /** |
| 922 | * INCALL_POWER_BUTTON_BEHAVIOR value for "hang up". |
| 923 | * @hide |
| 924 | */ |
| 925 | public static final int INCALL_POWER_BUTTON_BEHAVIOR_HANGUP = 0x2; |
| 926 | |
| 927 | /** |
| 928 | * INCALL_POWER_BUTTON_BEHAVIOR default value. |
| 929 | * @hide |
| 930 | */ |
| 931 | public static final int INCALL_POWER_BUTTON_BEHAVIOR_DEFAULT = |
| 932 | INCALL_POWER_BUTTON_BEHAVIOR_SCREEN_OFF; |
| 933 | |
| 934 | /** |
| 935 | * Whether to display the ADB notification. |
Bruno Martins | af3c06c | 2020-10-08 20:42:01 +0100 | [diff] [blame] | 936 | * @deprecated |
Adnan Begovic | d5fdee9 | 2015-11-13 15:28:21 -0800 | [diff] [blame] | 937 | * @hide |
| 938 | */ |
Bruno Martins | af3c06c | 2020-10-08 20:42:01 +0100 | [diff] [blame] | 939 | @Deprecated |
Adnan Begovic | d5fdee9 | 2015-11-13 15:28:21 -0800 | [diff] [blame] | 940 | public static final String ADB_NOTIFY = "adb_notify"; |
| 941 | |
| 942 | /** |
| 943 | * The TCP/IP port to run ADB on, or -1 for USB |
Bruno Martins | af3c06c | 2020-10-08 20:42:01 +0100 | [diff] [blame] | 944 | * @deprecated |
Adnan Begovic | d5fdee9 | 2015-11-13 15:28:21 -0800 | [diff] [blame] | 945 | * @hide |
| 946 | */ |
Bruno Martins | af3c06c | 2020-10-08 20:42:01 +0100 | [diff] [blame] | 947 | @Deprecated |
Adnan Begovic | d5fdee9 | 2015-11-13 15:28:21 -0800 | [diff] [blame] | 948 | public static final String ADB_PORT = "adb_port"; |
| 949 | |
| 950 | /** |
| 951 | * The hostname for this device |
| 952 | * @hide |
| 953 | */ |
| 954 | public static final String DEVICE_HOSTNAME = "device_hostname"; |
| 955 | |
| 956 | /** |
| 957 | * Whether to allow killing of the foreground app by long-pressing the Back button |
Bruno Martins | 9eca902 | 2020-10-08 20:26:25 +0100 | [diff] [blame] | 958 | * @deprecated |
Adnan Begovic | d5fdee9 | 2015-11-13 15:28:21 -0800 | [diff] [blame] | 959 | * @hide |
| 960 | */ |
Bruno Martins | 9eca902 | 2020-10-08 20:26:25 +0100 | [diff] [blame] | 961 | @Deprecated |
Adnan Begovic | d5fdee9 | 2015-11-13 15:28:21 -0800 | [diff] [blame] | 962 | public static final String KILL_APP_LONGPRESS_BACK = "kill_app_longpress_back"; |
| 963 | |
| 964 | /** Protected Components |
| 965 | * @hide |
| 966 | */ |
| 967 | public static final String PROTECTED_COMPONENTS = "protected_components"; |
| 968 | |
| 969 | /** |
| 970 | * Stored color matrix for LiveDisplay. This is used to allow co-existence with |
| 971 | * display tuning done by DisplayAdjustmentUtils when hardware support isn't |
| 972 | * available. |
| 973 | * @hide |
| 974 | */ |
| 975 | public static final String LIVE_DISPLAY_COLOR_MATRIX = "live_display_color_matrix"; |
| 976 | |
| 977 | /** |
| 978 | * Whether to include options in power menu for rebooting into recovery or bootloader |
| 979 | * @hide |
| 980 | */ |
| 981 | public static final String ADVANCED_REBOOT = "advanced_reboot"; |
Adnan Begovic | d5fdee9 | 2015-11-13 15:28:21 -0800 | [diff] [blame] | 982 | // endregion |
| 983 | |
| 984 | /** |
| 985 | * @hide |
| 986 | */ |
| 987 | public static final String[] LEGACY_SECURE_SETTINGS = new String[]{ |
Sam Mortimer | 542742b | 2017-09-18 19:44:11 -0700 | [diff] [blame] | 988 | LineageSettings.Secure.ADVANCED_MODE, |
| 989 | LineageSettings.Secure.BUTTON_BACKLIGHT_TIMEOUT, |
| 990 | LineageSettings.Secure.BUTTON_BRIGHTNESS, |
Sam Mortimer | 542742b | 2017-09-18 19:44:11 -0700 | [diff] [blame] | 991 | LineageSettings.Secure.DEV_FORCE_SHOW_NAVBAR, |
| 992 | LineageSettings.Secure.KEYBOARD_BRIGHTNESS, |
| 993 | LineageSettings.Secure.POWER_MENU_ACTIONS, |
| 994 | LineageSettings.Secure.STATS_COLLECTION, |
| 995 | LineageSettings.Secure.QS_SHOW_BRIGHTNESS_SLIDER, |
| 996 | LineageSettings.Secure.QS_TILES, |
| 997 | LineageSettings.Secure.QS_USE_MAIN_TILES, |
| 998 | LineageSettings.Secure.VOLUME_LINK_NOTIFICATION, |
| 999 | LineageSettings.Secure.NAVIGATION_RING_TARGETS[0], |
| 1000 | LineageSettings.Secure.NAVIGATION_RING_TARGETS[1], |
| 1001 | LineageSettings.Secure.NAVIGATION_RING_TARGETS[2], |
| 1002 | LineageSettings.Secure.RECENTS_LONG_PRESS_ACTIVITY, |
| 1003 | LineageSettings.Secure.ADB_NOTIFY, |
| 1004 | LineageSettings.Secure.ADB_PORT, |
| 1005 | LineageSettings.Secure.DEVICE_HOSTNAME, |
| 1006 | LineageSettings.Secure.KILL_APP_LONGPRESS_BACK, |
| 1007 | LineageSettings.Secure.PROTECTED_COMPONENTS, |
| 1008 | LineageSettings.Secure.LIVE_DISPLAY_COLOR_MATRIX, |
| 1009 | LineageSettings.Secure.ADVANCED_REBOOT, |
Sam Mortimer | 542742b | 2017-09-18 19:44:11 -0700 | [diff] [blame] | 1010 | LineageSettings.Secure.LOCKSCREEN_TARGETS, |
| 1011 | LineageSettings.Secure.RING_HOME_BUTTON_BEHAVIOR, |
| 1012 | LineageSettings.Secure.PRIVACY_GUARD_DEFAULT, |
| 1013 | LineageSettings.Secure.DEVELOPMENT_SHORTCUT, |
| 1014 | LineageSettings.Secure.PERFORMANCE_PROFILE, |
| 1015 | LineageSettings.Secure.APP_PERFORMANCE_PROFILES_ENABLED}; |
Adnan Begovic | d5fdee9 | 2015-11-13 15:28:21 -0800 | [diff] [blame] | 1016 | |
| 1017 | /** |
| 1018 | * @hide |
| 1019 | */ |
| 1020 | public static boolean isLegacySetting(String key) { |
| 1021 | return Arrays.asList(LEGACY_SECURE_SETTINGS).contains(key); |
| 1022 | } |
| 1023 | } |
| 1024 | |
| 1025 | /** |
Sam Mortimer | 542742b | 2017-09-18 19:44:11 -0700 | [diff] [blame] | 1026 | * Global settings, containing miscellaneous Lineage global preferences. This |
Adnan Begovic | d5fdee9 | 2015-11-13 15:28:21 -0800 | [diff] [blame] | 1027 | * table holds simple name/value pairs. There are convenience |
| 1028 | * functions for accessing individual settings entries. |
| 1029 | */ |
| 1030 | public static final class Global { |
| 1031 | // region Global Settings |
| 1032 | /** |
| 1033 | * Whether to wake the display when plugging or unplugging the charger |
| 1034 | * |
| 1035 | * @hide |
| 1036 | */ |
| 1037 | public static final String WAKE_WHEN_PLUGGED_OR_UNPLUGGED = |
| 1038 | "wake_when_plugged_or_unplugged"; |
| 1039 | |
| 1040 | /** {@hide} */ |
| 1041 | public static final String |
| 1042 | BLUETOOTH_A2DP_SRC_PRIORITY_PREFIX = "bluetooth_a2dp_src_priority_"; |
| 1043 | |
| 1044 | /** |
| 1045 | * Whether to sound when charger power is connected/disconnected |
| 1046 | * @hide |
| 1047 | */ |
| 1048 | public static final String POWER_NOTIFICATIONS_ENABLED = "power_notifications_enabled"; |
| 1049 | |
| 1050 | /** |
| 1051 | * Whether to vibrate when charger power is connected/disconnected |
| 1052 | * @hide |
| 1053 | */ |
| 1054 | public static final String POWER_NOTIFICATIONS_VIBRATE = "power_notifications_vibrate"; |
| 1055 | |
| 1056 | /** |
| 1057 | * URI for power notification sounds |
| 1058 | * @hide |
| 1059 | */ |
| 1060 | public static final String POWER_NOTIFICATIONS_RINGTONE = "power_notifications_ringtone"; |
| 1061 | |
| 1062 | /** |
| 1063 | * @hide |
| 1064 | */ |
| 1065 | public static final String ZEN_DISABLE_DUCKING_DURING_MEDIA_PLAYBACK = |
| 1066 | "zen_disable_ducking_during_media_playback"; |
| 1067 | |
| 1068 | /** |
| 1069 | * Whether the system auto-configure the priority of the wifi ap's or use |
| 1070 | * the manual settings established by the user. |
| 1071 | * <> 0 to autoconfigure, 0 to manual settings. Default is <> 0. |
| 1072 | * @hide |
| 1073 | */ |
| 1074 | public static final String WIFI_AUTO_PRIORITIES_CONFIGURATION = "wifi_auto_priority"; |
| 1075 | // endregion |
| 1076 | |
| 1077 | /** |
| 1078 | * @hide |
| 1079 | */ |
| 1080 | public static final String[] LEGACY_GLOBAL_SETTINGS = new String[]{ |
Sam Mortimer | 542742b | 2017-09-18 19:44:11 -0700 | [diff] [blame] | 1081 | LineageSettings.Global.WAKE_WHEN_PLUGGED_OR_UNPLUGGED, |
| 1082 | LineageSettings.Global.POWER_NOTIFICATIONS_ENABLED, |
| 1083 | LineageSettings.Global.POWER_NOTIFICATIONS_VIBRATE, |
| 1084 | LineageSettings.Global.POWER_NOTIFICATIONS_RINGTONE, |
| 1085 | LineageSettings.Global.ZEN_DISABLE_DUCKING_DURING_MEDIA_PLAYBACK, |
| 1086 | LineageSettings.Global.WIFI_AUTO_PRIORITIES_CONFIGURATION}; |
Adnan Begovic | d5fdee9 | 2015-11-13 15:28:21 -0800 | [diff] [blame] | 1087 | |
| 1088 | /** |
| 1089 | * @hide |
| 1090 | */ |
| 1091 | public static boolean isLegacySetting(String key) { |
| 1092 | return Arrays.asList(LEGACY_GLOBAL_SETTINGS).contains(key); |
| 1093 | } |
| 1094 | } |
| 1095 | } |