From 96000dbbfb24df181b87e284ae27a8eea8d40fb8 Mon Sep 17 00:00:00 2001 From: Daniel Hillenbrand Date: Sun, 9 Jun 2013 11:51:32 +0200 Subject: i9300: move advanced settings to common Change-Id: Icce502a25b33a13448de371c09eb80b7ce2c447c --- DeviceSettings/Android.mk | 15 -- DeviceSettings/AndroidManifest.xml | 31 --- .../res/drawable/ic_launcher_cmdevicesettings.png | Bin 8207 -> 0 bytes .../layout/preference_dialog_vibrator_tuning.xml | 59 ------ DeviceSettings/res/layout/top.xml | 5 - DeviceSettings/res/values-de/arrays.xml | 48 ----- DeviceSettings/res/values-de/strings.xml | 44 ----- DeviceSettings/res/values-es/arrays.xml | 41 ---- DeviceSettings/res/values-es/strings.xml | 33 ---- DeviceSettings/res/values-fr/arrays.xml | 56 ------ DeviceSettings/res/values-fr/strings.xml | 47 ----- DeviceSettings/res/values-hu/arrays.xml | 48 ----- DeviceSettings/res/values-hu/strings.xml | 34 ---- DeviceSettings/res/values-pl/arrays.xml | 48 ----- DeviceSettings/res/values-pl/strings.xml | 34 ---- DeviceSettings/res/values-pt-rBR/arrays.xml | 48 ----- DeviceSettings/res/values-pt-rBR/strings.xml | 33 ---- DeviceSettings/res/values-ru/arrays.xml | 46 ----- DeviceSettings/res/values-ru/strings.xml | 42 ---- DeviceSettings/res/values-zh-rCN/arrays.xml | 64 ------ DeviceSettings/res/values-zh-rCN/strings.xml | 48 ----- DeviceSettings/res/values/arrays.xml | 93 --------- DeviceSettings/res/values/config.xml | 29 --- DeviceSettings/res/values/strings.xml | 56 ------ DeviceSettings/res/xml/dock_preferences.xml | 26 --- DeviceSettings/res/xml/haptic_preferences.xml | 10 - DeviceSettings/res/xml/radio_preferences.xml | 12 -- DeviceSettings/res/xml/screen_preferences.xml | 74 ------- .../src/com/cyanogenmod/settings/device/CABC.java | 58 ------ .../settings/device/DeviceSettings.java | 169 ---------------- .../settings/device/DockFragmentActivity.java | 72 ------- .../settings/device/HapticFragmentActivity.java | 72 ------- .../src/com/cyanogenmod/settings/device/Hspa.java | 67 ------- .../com/cyanogenmod/settings/device/LedFade.java | 59 ------ .../settings/device/RadioFragmentActivity.java | 66 ------- .../settings/device/ScreenFragmentActivity.java | 106 ---------- .../com/cyanogenmod/settings/device/Startup.java | 40 ---- .../settings/device/TouchkeyTimeout.java | 59 ------ .../src/com/cyanogenmod/settings/device/Utils.java | 163 --------------- .../settings/device/VibratorTuningPreference.java | 219 --------------------- .../com/cyanogenmod/settings/device/mDNIeMode.java | 59 ------ .../cyanogenmod/settings/device/mDNIeNegative.java | 59 ------ .../cyanogenmod/settings/device/mDNIeScenario.java | 59 ------ 43 files changed, 2451 deletions(-) delete mode 100644 DeviceSettings/Android.mk delete mode 100644 DeviceSettings/AndroidManifest.xml delete mode 100755 DeviceSettings/res/drawable/ic_launcher_cmdevicesettings.png delete mode 100644 DeviceSettings/res/layout/preference_dialog_vibrator_tuning.xml delete mode 100755 DeviceSettings/res/layout/top.xml delete mode 100644 DeviceSettings/res/values-de/arrays.xml delete mode 100644 DeviceSettings/res/values-de/strings.xml delete mode 100644 DeviceSettings/res/values-es/arrays.xml delete mode 100644 DeviceSettings/res/values-es/strings.xml delete mode 100644 DeviceSettings/res/values-fr/arrays.xml delete mode 100644 DeviceSettings/res/values-fr/strings.xml delete mode 100644 DeviceSettings/res/values-hu/arrays.xml delete mode 100644 DeviceSettings/res/values-hu/strings.xml delete mode 100644 DeviceSettings/res/values-pl/arrays.xml delete mode 100644 DeviceSettings/res/values-pl/strings.xml delete mode 100644 DeviceSettings/res/values-pt-rBR/arrays.xml delete mode 100644 DeviceSettings/res/values-pt-rBR/strings.xml delete mode 100644 DeviceSettings/res/values-ru/arrays.xml delete mode 100644 DeviceSettings/res/values-ru/strings.xml delete mode 100644 DeviceSettings/res/values-zh-rCN/arrays.xml delete mode 100644 DeviceSettings/res/values-zh-rCN/strings.xml delete mode 100644 DeviceSettings/res/values/arrays.xml delete mode 100644 DeviceSettings/res/values/config.xml delete mode 100644 DeviceSettings/res/values/strings.xml delete mode 100644 DeviceSettings/res/xml/dock_preferences.xml delete mode 100644 DeviceSettings/res/xml/haptic_preferences.xml delete mode 100644 DeviceSettings/res/xml/radio_preferences.xml delete mode 100644 DeviceSettings/res/xml/screen_preferences.xml delete mode 100644 DeviceSettings/src/com/cyanogenmod/settings/device/CABC.java delete mode 100644 DeviceSettings/src/com/cyanogenmod/settings/device/DeviceSettings.java delete mode 100644 DeviceSettings/src/com/cyanogenmod/settings/device/DockFragmentActivity.java delete mode 100644 DeviceSettings/src/com/cyanogenmod/settings/device/HapticFragmentActivity.java delete mode 100644 DeviceSettings/src/com/cyanogenmod/settings/device/Hspa.java delete mode 100644 DeviceSettings/src/com/cyanogenmod/settings/device/LedFade.java delete mode 100644 DeviceSettings/src/com/cyanogenmod/settings/device/RadioFragmentActivity.java delete mode 100644 DeviceSettings/src/com/cyanogenmod/settings/device/ScreenFragmentActivity.java delete mode 100644 DeviceSettings/src/com/cyanogenmod/settings/device/Startup.java delete mode 100644 DeviceSettings/src/com/cyanogenmod/settings/device/TouchkeyTimeout.java delete mode 100644 DeviceSettings/src/com/cyanogenmod/settings/device/Utils.java delete mode 100644 DeviceSettings/src/com/cyanogenmod/settings/device/VibratorTuningPreference.java delete mode 100644 DeviceSettings/src/com/cyanogenmod/settings/device/mDNIeMode.java delete mode 100644 DeviceSettings/src/com/cyanogenmod/settings/device/mDNIeNegative.java delete mode 100644 DeviceSettings/src/com/cyanogenmod/settings/device/mDNIeScenario.java diff --git a/DeviceSettings/Android.mk b/DeviceSettings/Android.mk deleted file mode 100644 index 6605185..0000000 --- a/DeviceSettings/Android.mk +++ /dev/null @@ -1,15 +0,0 @@ -LOCAL_PATH:= $(call my-dir) -include $(CLEAR_VARS) - -LOCAL_MODULE_TAGS := optional - -LOCAL_STATIC_JAVA_LIBRARIES := android-support-v13 - -LOCAL_SRC_FILES := $(call all-java-files-under, src) - -LOCAL_PACKAGE_NAME := DeviceSettings -LOCAL_CERTIFICATE := platform - -include $(BUILD_PACKAGE) - -include $(call all-makefiles-under,$(LOCAL_PATH)) diff --git a/DeviceSettings/AndroidManifest.xml b/DeviceSettings/AndroidManifest.xml deleted file mode 100644 index d373ded..0000000 --- a/DeviceSettings/AndroidManifest.xml +++ /dev/null @@ -1,31 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/DeviceSettings/res/drawable/ic_launcher_cmdevicesettings.png b/DeviceSettings/res/drawable/ic_launcher_cmdevicesettings.png deleted file mode 100755 index 66de9c3..0000000 Binary files a/DeviceSettings/res/drawable/ic_launcher_cmdevicesettings.png and /dev/null differ diff --git a/DeviceSettings/res/layout/preference_dialog_vibrator_tuning.xml b/DeviceSettings/res/layout/preference_dialog_vibrator_tuning.xml deleted file mode 100644 index 1cf116b..0000000 --- a/DeviceSettings/res/layout/preference_dialog_vibrator_tuning.xml +++ /dev/null @@ -1,59 +0,0 @@ - - - - - - - - - - - - - - diff --git a/DeviceSettings/res/layout/top.xml b/DeviceSettings/res/layout/top.xml deleted file mode 100755 index 744b568..0000000 --- a/DeviceSettings/res/layout/top.xml +++ /dev/null @@ -1,5 +0,0 @@ - - diff --git a/DeviceSettings/res/values-de/arrays.xml b/DeviceSettings/res/values-de/arrays.xml deleted file mode 100644 index 04b2538..0000000 --- a/DeviceSettings/res/values-de/arrays.xml +++ /dev/null @@ -1,48 +0,0 @@ - - - - CyanogenMod (Standard) - UI - Video - Video warm - Video kalt - Kamera - Navigation - Gallerie - VT - - - - Dynamisch (Standard) - Standard - Natürlich - Film - - - - Normal - Invertiert - - - - Blinken - Verblassen - - - - Niemals - 1 Sekunde - 2 Sekunden - 3 Sekunden (Standard) - 4 Sekunden - 5 Sekunden - 6 Sekunden - - - - Nur UMTS - Nur HSDPA - HSDPA + HSUPA - - - diff --git a/DeviceSettings/res/values-de/strings.xml b/DeviceSettings/res/values-de/strings.xml deleted file mode 100644 index 65ce91e..0000000 --- a/DeviceSettings/res/values-de/strings.xml +++ /dev/null @@ -1,44 +0,0 @@ - - - Erweiterte Einstellungen - - Zurücksetzen - - Display - Farben - Szenario - Wähle das mDNIe Szenario - Modus - Wähle den mDNIe Modus - Negativ Modus - Invertiere Farben - - Benachrichtigungslicht - Modus - Wähle zwischen sanftem Verblassen und Blinken - - Touchkeys - Beleuchtung - Aktiviere Beleuchtung - Deaktiviere Beleuchtung - Zeitabschaltung der Beleuchtung - Setze Zeit für automatische Abschaltung - - - Haptik - - - Vibrator - Vibrationsstärke - Stärke des Vibrationseffektes einstellen - Vorsicht: Höhere Werte als %1$d werden nicht empfohlen - - Mobilfunk - HSPA - Aktiviere HSDPA/HSUPA - - Dock - Audio - USB-Dock Audio - Passive Audio-Ausgabe des USB-Docks verwenden - diff --git a/DeviceSettings/res/values-es/arrays.xml b/DeviceSettings/res/values-es/arrays.xml deleted file mode 100644 index c7d02c5..0000000 --- a/DeviceSettings/res/values-es/arrays.xml +++ /dev/null @@ -1,41 +0,0 @@ - - - Sólo UMTS - Sólo HSDPA - HSDPA + HSUPA - - - CyanogenMod (por defecto) - UI - Vídeo - Vídeo cálido - Vídeo frío - Camara - Navegación - Galería - VT - - - Estándar (por defecto) - Dinámico - Natural - Película - - - Normal - Invertido - - - Parpadeo - Fundido - - - Nunca - 1 segundo - 2 segundos - 3 segundos (por defecto) - 4 segundos - 5 segundos - 6 segundos - - diff --git a/DeviceSettings/res/values-es/strings.xml b/DeviceSettings/res/values-es/strings.xml deleted file mode 100644 index f615d4b..0000000 --- a/DeviceSettings/res/values-es/strings.xml +++ /dev/null @@ -1,33 +0,0 @@ - - - Ajustes avanzados - Base - Sonido - Usar sonido USB - Utilizar la salida de audio de la base - Háptica - Vibración - Intensidad de vibración - Establecer la intensidad de vibración - No son recomendables valores mayores de %1$d - Radio - HSPA - Habilitar HSDPA/HSUPA - Pantalla - Colores - Escenario - Establecer escenario mDNIe - Modo - Establecer modo mDNIe - Modo Negativo - Habilitar/deshabilitar colores invertidos - Notificación LED - Fundido LED - Habilitar fundido suave en vez de parpadeo intenso - Teclas táctiles - Retroiluminación - Habilitar retroiluminación - Deshabilitar retroiluminación - Tiempo de espera de retroiluminación - Tiempo tras pulsar una tecla antes de apagar la retroiluminación - diff --git a/DeviceSettings/res/values-fr/arrays.xml b/DeviceSettings/res/values-fr/arrays.xml deleted file mode 100644 index 11b706d..0000000 --- a/DeviceSettings/res/values-fr/arrays.xml +++ /dev/null @@ -1,56 +0,0 @@ - - - - - UMTS seulement - HSDPA seulement - HSDPA + HSUPA - - - CyanogenMod (Défaut) - UI - Vidéo - Vidéo chaude - Vidéo froide - Caméra - Navigation - Galerie - VT - - - Dynamique (Défaut) - Standard - Naturel - Vidéo - - - Normal - Inversé - - - Clignotante - Progressive - - - Désactivé - 1 seconde - 2 secondes - 3 secondes (Défaut) - 4 secondes - 5 secondes - 6 secondes - - diff --git a/DeviceSettings/res/values-fr/strings.xml b/DeviceSettings/res/values-fr/strings.xml deleted file mode 100644 index 5556d24..0000000 --- a/DeviceSettings/res/values-fr/strings.xml +++ /dev/null @@ -1,47 +0,0 @@ - - - - Paramètres avancés - Station d\'accueil - Audio - Sortie audio - Utiliser la sortie audio de la station d\'accueil - Haptique - Vibreur - Intensité du vibreur - Définir l\'intensité du vibreur - Les valeurs supérieurs à %1$d ne sont pas recommandées - Radio - HSPA - Activer HSDPA/HSUPA - Écran - Couleurs - Scénario - Définir le scénario mDNIe - Mode - Définir le mode mDNIe - Mode négatif - Activer/désactiver les couleurs inversées - LED de notification - LED progressive - Préférer l\'éclairage progressif au clignotement - Touches tactiles - Rétroéclairage - Activer le rétroéclairage des touches tactiles lorsque l\'écran est activé - Désactiver le rétroéclairage des touches tactiles lorsque l\'écran est activé - Délai avant extinction - Définir le délai avant l\'extinction des touches - diff --git a/DeviceSettings/res/values-hu/arrays.xml b/DeviceSettings/res/values-hu/arrays.xml deleted file mode 100644 index 82074a2..0000000 --- a/DeviceSettings/res/values-hu/arrays.xml +++ /dev/null @@ -1,48 +0,0 @@ - - - - UMTS - HSDPA - HSDPA + HSUPA - - - - CyanogenMod (Alapbeállítás) - Felhasználói felület - Videó - Videó (Meleg árnyalat) - Videó (Hideg árnyalat) - Kamera - Navigáció - Galéria - VT - - - - Dinamikus (Alapbeállítás) - Hagyományos - Természetes - Film - - - - Normál - Fordított - - - - Villogás - Elhalványulás - - - - Soha - 1 másodperc - 2 másodperc - 3 másodperc (Alapbeállítás) - 4 másodperc - 5 másodperc - 6 másodperc - - - diff --git a/DeviceSettings/res/values-hu/strings.xml b/DeviceSettings/res/values-hu/strings.xml deleted file mode 100644 index f5f1411..0000000 --- a/DeviceSettings/res/values-hu/strings.xml +++ /dev/null @@ -1,34 +0,0 @@ - - - Advanced settings - - Dokkoló - Dokkoló hangszórók - Dokkoló hangszóróinak használata - Használja a dokkoló passzív hangkimenetét - - GSM Rádió - HSPA - HSDPA/HSUPA engedélyezése - - Kijelző - Színek - Megjelenítés - mDNIe megjelenítési beállítások - Üzemmód - mDNIe üzemmódok - Negatív üzemmód - Fordított színek ki/be - - LED értesítés - LED halványítás - LED elhalványítása villogtatás helyett - - Érintőgombok - Háttérvilágítás - Háttérvilágítás engedélyezése - Háttérvilágítás tiltása - Háttérvilágítás időkorlátja - Háttérvilágítás késleltetése - - diff --git a/DeviceSettings/res/values-pl/arrays.xml b/DeviceSettings/res/values-pl/arrays.xml deleted file mode 100644 index f9de456..0000000 --- a/DeviceSettings/res/values-pl/arrays.xml +++ /dev/null @@ -1,48 +0,0 @@ - - - - Tylko UMTS - Tylko HSDPA - HSDPA + HSUPA - - - - CyanogenMod (domyślnie) - UI - Wideo - Ciepły film - Zimny film - Kamera - Nawigacja - Galeria - VT - - - - Dynamicznie (domyślnie) - Standardowo - Naturalnie - Film - - - - Normalnie - Odwrócony - - - - Miganie - Zanikanie - - - - Nigdy - 1 sekunda - 2 sekundy - 3 sekundy (domyślnie) - 4 sekundy - 5 sekund - 6 sekund - - - diff --git a/DeviceSettings/res/values-pl/strings.xml b/DeviceSettings/res/values-pl/strings.xml deleted file mode 100644 index 20da92d..0000000 --- a/DeviceSettings/res/values-pl/strings.xml +++ /dev/null @@ -1,34 +0,0 @@ - - - Advanced settings - - Stacja dokująca - Dźwięk w stacji dokującej - Użyj stacji dokującej - Użyj pasywnego wyjścia audio w stacji dokującej - - Radio - HSPA - Aktywuj HSDPA/HSUPA - - Ekran - Kolory - Technologia mDNIe - Ustaw scenariusz mDNIe - Tryb - Ustaw tryb mDNIe - Tryb negatywu - Włącz/wyłącz odwrócone kolory - - Lampka LED - Zanikanie lampki LED - Aktywuj delikatne zanikanie lampki LED zamiast migania. - - Przyciski dotykowe - Podświetlenie - Włącz podświetlenie - Wyłącz podświetlenie - Opóźnienie podświetlenia - Ustaw opóźnienie dla podświetlenia - - diff --git a/DeviceSettings/res/values-pt-rBR/arrays.xml b/DeviceSettings/res/values-pt-rBR/arrays.xml deleted file mode 100644 index 983e35a..0000000 --- a/DeviceSettings/res/values-pt-rBR/arrays.xml +++ /dev/null @@ -1,48 +0,0 @@ - - - - - Somente UMTS - Somente HSDPA - HSDPA + HSUPA - - - - CyanogenMod (Padrão) - IU - Vídeo - Vídeo Quente - Vídeo Frio - Câmera - Navegação - Galeria - VT - - - - Padrão - Dinâmico - Natural - Filme - - - - Normal - Invertido - - - - Piscando - Desvanecimento - - - - Nunca - 1 segundo - 2 segundos - 3 segundos (Padrão) - 4 segundos - 5 segundos - 6 segundos - - diff --git a/DeviceSettings/res/values-pt-rBR/strings.xml b/DeviceSettings/res/values-pt-rBR/strings.xml deleted file mode 100644 index 5813d7e..0000000 --- a/DeviceSettings/res/values-pt-rBR/strings.xml +++ /dev/null @@ -1,33 +0,0 @@ - - - Configurações avançadas - Resposta tátil - Vibração - Intensidade da vibração - Ajusar a intensidade da resposta por vibração - Valores maiores que %1$d não são recomendados - Rádio - Ativar HSDPA/HSUPA - Tela - Cores - Cenário - Define o Cenário mDNIe - Modo - Define o Modo mDNIe - Modo Negativo - Ativar/Desativar cores invertidas - Notificação com LED - Desvanecimento LED - Ativar desvanecimento suave do LED em vez de piscar. - Teclas sensíveis ao toque - Luz de fundo - Ativar luz de fundo - Desativar luz de fundo - Tempo limite da luz de fundo - Define o tempo limite para a luz de fundo - HSPA - Dock - Áudio do dock - Usar áudio USB do dock - Usar a saída de áudio passiva no dock - \ No newline at end of file diff --git a/DeviceSettings/res/values-ru/arrays.xml b/DeviceSettings/res/values-ru/arrays.xml deleted file mode 100644 index a83b7b4..0000000 --- a/DeviceSettings/res/values-ru/arrays.xml +++ /dev/null @@ -1,46 +0,0 @@ - - - - Только UMTS - Только HSDPA - HSDPA + HSUPA - - - - CyanogenMod (По умолч.) - Видео - Видео (тёпл.) - Видео (хол.) - Камера - Навигация - Галерея - VT - - - - Динамический (По умолч.) - Стандартный - Натуральный - Кино - - - - Нормально - Инверсия - - - - Мигание - Затухание - - - - Никогда - 1 секунда - 2 секунды - 3 секунды (По умолч.) - 4 секунды - 5 секунд - 6 секунд - - diff --git a/DeviceSettings/res/values-ru/strings.xml b/DeviceSettings/res/values-ru/strings.xml deleted file mode 100644 index c7b287a..0000000 --- a/DeviceSettings/res/values-ru/strings.xml +++ /dev/null @@ -1,42 +0,0 @@ - - - Advanced settings - - Экран - Цвета - Сценарий - Установка сценария mDNIe - Режим - Установка режима mDNIe - Негатив - Вкл./выкл. инверсии цветов - - Индикатор событий - Режим - Плавное затухание или резкое мигание - - Сенсорные клавиши - Подсветка - Подсветка включена - Подсветка выключена - Тайм-аут подсветки - Установка тайм-аута подсветки - - - Отклик - - - Вибрация - Интенсивность вибрации - Установка интенсивности вибрации - Не рекомендуется установка значения выше %1$d - - Модем - HSPA - Включить HSDPA/HSUPA - - Док-станция - Аудио - USB аудио док-станция - Использовать пассивный режим аудио док-станции - diff --git a/DeviceSettings/res/values-zh-rCN/arrays.xml b/DeviceSettings/res/values-zh-rCN/arrays.xml deleted file mode 100644 index 373d649..0000000 --- a/DeviceSettings/res/values-zh-rCN/arrays.xml +++ /dev/null @@ -1,64 +0,0 @@ - - - - - - 仅使用 UMTS - 仅使用 HSDPA - 使用 HSDPA + HSUPA - - - - CyanogenMod (默认) - 界面 - 影片 - 影片 (温) - 影片 (冷) - 相机 - 导航 - 图库 - VT - - - - 动态 (默认) - 标准 - 自然 - 电影 - - - - 正常 - 反色 - - - - 闪烁 - 淡出 - - - - 从不 - 1 秒 - 2 秒 - 3 秒 (默认) - 4 秒 - 5 秒 - 6 秒 - - - diff --git a/DeviceSettings/res/values-zh-rCN/strings.xml b/DeviceSettings/res/values-zh-rCN/strings.xml deleted file mode 100644 index f4158b9..0000000 --- a/DeviceSettings/res/values-zh-rCN/strings.xml +++ /dev/null @@ -1,48 +0,0 @@ - - - - 高级设置 - - 无线电 - HSPA - 启用 HSDPA/HSUPA - - 屏幕 - 颜色 - 场景 - 设置 mDNIe 场景 - 模式 - 设置 mDNIe 模式 - 负极模式 - 启用/禁用反色 - - LED 指示灯 - LED 淡出 - 启用后 LED 指示灯将会产生淡出效果而替代闪烁效果。 - - 触摸键 - 背光灯 - 启用背光灯 - 禁用背光灯 - 背光灯超时 - 设置背光灯超时时间 - - 基座 - 音频 - 使用基座的 USB 音频 - 使用基座上的被动音频输出 - diff --git a/DeviceSettings/res/values/arrays.xml b/DeviceSettings/res/values/arrays.xml deleted file mode 100644 index 8e99c95..0000000 --- a/DeviceSettings/res/values/arrays.xml +++ /dev/null @@ -1,93 +0,0 @@ - - - - CyanogenMod (Default) - UI - Video - Video Warm - Video Cold - Camera - Navigation - Gallery - VT - - - - 0 - 1 - 2 - 3 - 4 - 5 - 6 - 7 - 8 - - - - Dynamic (Default) - Standard - Natural - Movie - - - - 0 - 1 - 2 - 3 - - - - Normal - Inverted - - - - 0 - 1 - - - - Never - 1 second - 2 seconds - 3 seconds (Default) - 4 seconds - 5 seconds - 6 seconds - - - - 0 - 1 - 2 - 3 - 4 - 5 - 6 - - - - Blinking - Fading - - - - 0 - 1 - - - - UMTS Only - HSDPA Only - HSDPA + HSUPA - - - - 21 - 22 - 23 - - - diff --git a/DeviceSettings/res/values/config.xml b/DeviceSettings/res/values/config.xml deleted file mode 100644 index 5667f97..0000000 --- a/DeviceSettings/res/values/config.xml +++ /dev/null @@ -1,29 +0,0 @@ - - - - - - - - true - "/sys/vibrator/pwm_val" - 100 - 75 - 50 - 0 - - diff --git a/DeviceSettings/res/values/strings.xml b/DeviceSettings/res/values/strings.xml deleted file mode 100644 index 155e9c2..0000000 --- a/DeviceSettings/res/values/strings.xml +++ /dev/null @@ -1,56 +0,0 @@ - - - Advanced settings - - Reset to default - - - Screen - Colors - - - CABC - Enable content adaptive backlight control - - - Scenario - Set the mDNIe Scenario - Mode - Set the mDNIe Mode - Negative Mode - Enable/Disable inverted colors - - - Notification LED - LED Fading - Enable LED smooth fading instead of sharp blinking. - - - Touchkeys - Backlight - Enable backlight - Disable backlight - Backlight timeout - Set timeout for the backlight - - - Haptic - - - Vibrator - Vibration strength - Adjust the strength of the vibration feedback - Values higher than %1$d are not recommended - - - Radio - HSPA - Enable HSDPA/HSUPA - - - Dock - Audio - Use Dock USB Audio - Use the passive audio out on the dock - - diff --git a/DeviceSettings/res/xml/dock_preferences.xml b/DeviceSettings/res/xml/dock_preferences.xml deleted file mode 100644 index 62c962c..0000000 --- a/DeviceSettings/res/xml/dock_preferences.xml +++ /dev/null @@ -1,26 +0,0 @@ - - - - - - - - diff --git a/DeviceSettings/res/xml/haptic_preferences.xml b/DeviceSettings/res/xml/haptic_preferences.xml deleted file mode 100644 index 31070ed..0000000 --- a/DeviceSettings/res/xml/haptic_preferences.xml +++ /dev/null @@ -1,10 +0,0 @@ - - - - - - diff --git a/DeviceSettings/res/xml/radio_preferences.xml b/DeviceSettings/res/xml/radio_preferences.xml deleted file mode 100644 index c173db7..0000000 --- a/DeviceSettings/res/xml/radio_preferences.xml +++ /dev/null @@ -1,12 +0,0 @@ - - - - - - diff --git a/DeviceSettings/res/xml/screen_preferences.xml b/DeviceSettings/res/xml/screen_preferences.xml deleted file mode 100644 index 57d1761..0000000 --- a/DeviceSettings/res/xml/screen_preferences.xml +++ /dev/null @@ -1,74 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/DeviceSettings/src/com/cyanogenmod/settings/device/CABC.java b/DeviceSettings/src/com/cyanogenmod/settings/device/CABC.java deleted file mode 100644 index af247d8..0000000 --- a/DeviceSettings/src/com/cyanogenmod/settings/device/CABC.java +++ /dev/null @@ -1,58 +0,0 @@ -/* - * Copyright (C) 2013 The CyanogenMod Project - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package com.cyanogenmod.settings.device; - -import android.content.Context; -import android.content.SharedPreferences; -import android.preference.CheckBoxPreference; -import android.preference.Preference; -import android.preference.Preference.OnPreferenceChangeListener; -import android.preference.PreferenceManager; -import android.util.AttributeSet; - -public class CABC extends CheckBoxPreference implements OnPreferenceChangeListener { - - public CABC(Context context, AttributeSet attrs) { - super(context, attrs); - this.setOnPreferenceChangeListener(this); - } - - private static final String FILE = "/sys/class/lcd/panel/power_reduce"; - - public static boolean isSupported() { - return Utils.fileExists(FILE); - } - - /** - * Restore cabc setting from SharedPreferences. (Write to kernel.) - * @param context The context to read the SharedPreferences from - */ - public static void restore(Context context) { - if (!isSupported()) { - return; - } - - SharedPreferences sharedPrefs = PreferenceManager.getDefaultSharedPreferences(context); - Utils.writeValue(FILE, sharedPrefs.getBoolean(DeviceSettings.KEY_CABC, true) ? "1" : "0"); - } - - public boolean onPreferenceChange(Preference preference, Object newValue) { - Utils.writeValue(FILE, (Boolean)newValue ? "1" : "0"); - return true; - } - -} diff --git a/DeviceSettings/src/com/cyanogenmod/settings/device/DeviceSettings.java b/DeviceSettings/src/com/cyanogenmod/settings/device/DeviceSettings.java deleted file mode 100644 index 486fe79..0000000 --- a/DeviceSettings/src/com/cyanogenmod/settings/device/DeviceSettings.java +++ /dev/null @@ -1,169 +0,0 @@ -/* - * Copyright (C) 2012 The CyanogenMod Project - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package com.cyanogenmod.settings.device; - -import android.app.ActionBar; -import android.app.ActionBar.Tab; -import android.app.Activity; -import android.app.Fragment; -import android.app.FragmentTransaction; -import android.content.Context; -import android.os.Bundle; -import android.support.v4.app.FragmentActivity; -import android.support.v13.app.FragmentPagerAdapter; -import android.support.v4.view.ViewPager; -import android.view.MenuItem; - -import com.cyanogenmod.settings.device.R; - -import java.util.ArrayList; - -public class DeviceSettings extends FragmentActivity { - - public static final String SHARED_PREFERENCES_BASENAME = "com.cyanogenmod.settings.device"; - public static final String ACTION_UPDATE_PREFERENCES = "com.cyanogenmod.settings.device.UPDATE"; - public static final String KEY_CABC = "cabc"; - public static final String KEY_MDNIE_SCENARIO = "mdnie_scenario"; - public static final String KEY_MDNIE_MODE = "mdnie_mode"; - public static final String KEY_MDNIE_NEGATIVE = "mdnie_negative"; - public static final String KEY_LED_FADE = "led_fade"; - public static final String KEY_TOUCHKEY_LIGHT = "touchkey_light"; - public static final String KEY_TOUCHKEY_TIMEOUT = "touchkey_timeout"; - public static final String KEY_HSPA = "hspa"; - public static final String KEY_VIBRATOR_INTENSITY = "vibrator_intensity"; - public static final String KEY_USE_DOCK_AUDIO = "dock_audio"; - - ViewPager mViewPager; - TabsAdapter mTabsAdapter; - - @Override - protected void onCreate(Bundle savedInstanceState) { - super.onCreate(savedInstanceState); - - mViewPager = new ViewPager(this); - mViewPager.setId(R.id.viewPager); - setContentView(mViewPager); - - final ActionBar bar = getActionBar(); - bar.setNavigationMode(ActionBar.NAVIGATION_MODE_TABS); - bar.setDisplayOptions(ActionBar.DISPLAY_SHOW_TITLE, ActionBar.DISPLAY_SHOW_TITLE); - bar.setTitle(R.string.app_name); - bar.setDisplayHomeAsUpEnabled(true); - - mTabsAdapter = new TabsAdapter(this, mViewPager); - mTabsAdapter.addTab(bar.newTab().setText(R.string.category_radio_title), - RadioFragmentActivity.class, null); - mTabsAdapter.addTab(bar.newTab().setText(R.string.category_screen_title), - ScreenFragmentActivity.class, null); - mTabsAdapter.addTab(bar.newTab().setText(R.string.category_haptic_title), - HapticFragmentActivity.class, null); - mTabsAdapter.addTab(bar.newTab().setText(R.string.category_dock_title), - DockFragmentActivity.class, null); - - if (savedInstanceState != null) { - bar.setSelectedNavigationItem(savedInstanceState.getInt("tab", 0)); - } - } - - @Override - protected void onSaveInstanceState(Bundle outState) { - super.onSaveInstanceState(outState); - outState.putInt("tab", getActionBar().getSelectedNavigationIndex()); - } - - public static class TabsAdapter extends FragmentPagerAdapter - implements ActionBar.TabListener, ViewPager.OnPageChangeListener { - private final Context mContext; - private final ActionBar mActionBar; - private final ViewPager mViewPager; - private final ArrayList mTabs = new ArrayList(); - - static final class TabInfo { - private final Class clss; - private final Bundle args; - - TabInfo(Class _class, Bundle _args) { - clss = _class; - args = _args; - } - } - - public TabsAdapter(Activity activity, ViewPager pager) { - super(activity.getFragmentManager()); - mContext = activity; - mActionBar = activity.getActionBar(); - mViewPager = pager; - mViewPager.setAdapter(this); - mViewPager.setOnPageChangeListener(this); - } - - public void addTab(ActionBar.Tab tab, Class clss, Bundle args) { - TabInfo info = new TabInfo(clss, args); - tab.setTag(info); - tab.setTabListener(this); - mTabs.add(info); - mActionBar.addTab(tab); - notifyDataSetChanged(); - } - - @Override - public int getCount() { - return mTabs.size(); - } - - @Override - public Fragment getItem(int position) { - TabInfo info = mTabs.get(position); - return Fragment.instantiate(mContext, info.clss.getName(), info.args); - } - - public void onPageScrolled(int position, float positionOffset, int positionOffsetPixels) { - } - - public void onPageSelected(int position) { - mActionBar.setSelectedNavigationItem(position); - } - - public void onPageScrollStateChanged(int state) { - } - - public void onTabSelected(Tab tab, FragmentTransaction ft) { - Object tag = tab.getTag(); - for (int i=0; i= strengthToPercent(WARNING_THRESHOLD); - if (mProgressDrawable != null) { - mProgressDrawable.setColorFilter(shouldWarn ? mRedFilter : null); - } - if (mProgressThumb != null) { - mProgressThumb.setColorFilter(shouldWarn ? mRedFilter : null); - } - Utils.writeValue(FILE_PATH, String.valueOf(percentToStrength(progress))); - mValue.setText(String.format("%d%%", progress)); - } - - @Override - public void onStartTrackingTouch(SeekBar seekBar) { - // Do nothing - } - - @Override - public void onStopTrackingTouch(SeekBar seekBar) { - Vibrator vib = (Vibrator) getContext().getSystemService(Context.VIBRATOR_SERVICE); - vib.vibrate(200); - } - - /** - * Convert vibrator strength to percent - */ - public static int strengthToPercent(int strength) { - double maxValue = MAX_VALUE; - double minValue = MIN_VALUE; - - double percent = (strength - minValue) * (100 / (maxValue - minValue)); - - if (percent > 100) - percent = 100; - else if (percent < 0) - percent = 0; - - return (int) percent; - } - - /** - * Convert percent to vibrator strength - */ - public static int percentToStrength(int percent) { - int strength = Math.round((((MAX_VALUE - MIN_VALUE) * percent) / 100) + MIN_VALUE); - - if (strength > MAX_VALUE) - strength = MAX_VALUE; - else if (strength < MIN_VALUE) - strength = MIN_VALUE; - - return strength; - } -} diff --git a/DeviceSettings/src/com/cyanogenmod/settings/device/mDNIeMode.java b/DeviceSettings/src/com/cyanogenmod/settings/device/mDNIeMode.java deleted file mode 100644 index 7969637..0000000 --- a/DeviceSettings/src/com/cyanogenmod/settings/device/mDNIeMode.java +++ /dev/null @@ -1,59 +0,0 @@ -/* - * Copyright (C) 2012 The CyanogenMod Project - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package com.cyanogenmod.settings.device; - -import android.content.Context; - -import android.content.SharedPreferences; -import android.util.AttributeSet; -import android.preference.Preference; -import android.preference.ListPreference; -import android.preference.Preference.OnPreferenceChangeListener; -import android.preference.PreferenceManager; - -public class mDNIeMode extends ListPreference implements OnPreferenceChangeListener { - - public mDNIeMode(Context context, AttributeSet attrs) { - super(context, attrs); - this.setOnPreferenceChangeListener(this); - } - - private static final String FILE = "/sys/class/mdnie/mdnie/mode"; - - public static boolean isSupported() { - return Utils.fileExists(FILE); - } - - /** - * Restore mdnie user mode setting from SharedPreferences. (Write to kernel.) - * @param context The context to read the SharedPreferences from - */ - public static void restore(Context context) { - if (!isSupported()) { - return; - } - - SharedPreferences sharedPrefs = PreferenceManager.getDefaultSharedPreferences(context); - Utils.writeValue(FILE, sharedPrefs.getString(DeviceSettings.KEY_MDNIE_MODE, "0")); - } - - public boolean onPreferenceChange(Preference preference, Object newValue) { - Utils.writeValue(FILE, (String) newValue); - return true; - } - -} diff --git a/DeviceSettings/src/com/cyanogenmod/settings/device/mDNIeNegative.java b/DeviceSettings/src/com/cyanogenmod/settings/device/mDNIeNegative.java deleted file mode 100644 index c2ccc7b..0000000 --- a/DeviceSettings/src/com/cyanogenmod/settings/device/mDNIeNegative.java +++ /dev/null @@ -1,59 +0,0 @@ -/* - * Copyright (C) 2012 The CyanogenMod Project - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package com.cyanogenmod.settings.device; - -import java.io.IOException; -import android.content.Context; -import android.util.AttributeSet; -import android.content.SharedPreferences; -import android.preference.Preference; -import android.preference.ListPreference; -import android.preference.Preference.OnPreferenceChangeListener; -import android.preference.PreferenceManager; - -public class mDNIeNegative extends ListPreference implements OnPreferenceChangeListener { - - public mDNIeNegative(Context context, AttributeSet attrs) { - super(context, attrs); - this.setOnPreferenceChangeListener(this); - } - - private static final String FILE = "/sys/class/mdnie/mdnie/negative"; - - public static boolean isSupported() { - return Utils.fileExists(FILE); - } - - /** - * Restore mdnie user mode setting from SharedPreferences. (Write to kernel.) - * @param context The context to read the SharedPreferences from - */ - public static void restore(Context context) { - if (!isSupported()) { - return; - } - - SharedPreferences sharedPrefs = PreferenceManager.getDefaultSharedPreferences(context); - Utils.writeValue(FILE, sharedPrefs.getString(DeviceSettings.KEY_MDNIE_NEGATIVE, "0")); - } - - public boolean onPreferenceChange(Preference preference, Object newValue) { - Utils.writeValue(FILE, (String) newValue); - return true; - } - -} diff --git a/DeviceSettings/src/com/cyanogenmod/settings/device/mDNIeScenario.java b/DeviceSettings/src/com/cyanogenmod/settings/device/mDNIeScenario.java deleted file mode 100644 index a9c935a..0000000 --- a/DeviceSettings/src/com/cyanogenmod/settings/device/mDNIeScenario.java +++ /dev/null @@ -1,59 +0,0 @@ -/* - * Copyright (C) 2012 The CyanogenMod Project - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package com.cyanogenmod.settings.device; - -import android.content.Context; - -import android.content.SharedPreferences; -import android.util.AttributeSet; -import android.preference.Preference; -import android.preference.ListPreference; -import android.preference.Preference.OnPreferenceChangeListener; -import android.preference.PreferenceManager; - -public class mDNIeScenario extends ListPreference implements OnPreferenceChangeListener { - - public mDNIeScenario(Context context, AttributeSet attrs) { - super(context,attrs); - this.setOnPreferenceChangeListener(this); - } - - private static final String FILE = "/sys/class/mdnie/mdnie/scenario"; - - public static boolean isSupported() { - return Utils.fileExists(FILE); - } - - /** - * Restore mdnie "camera" setting from SharedPreferences. (Write to kernel.) - * @param context The context to read the SharedPreferences from - */ - public static void restore(Context context) { - if (!isSupported()) { - return; - } - - SharedPreferences sharedPrefs = PreferenceManager.getDefaultSharedPreferences(context); - Utils.writeValue(FILE, sharedPrefs.getString(DeviceSettings.KEY_MDNIE_SCENARIO, "0")); - } - - public boolean onPreferenceChange(Preference preference, Object newValue) { - Utils.writeValue(FILE, (String) newValue); - return true; - } - -} -- cgit v1.1