Skip to content
Browse files

Stopwatch & Countdown

Stopwatch and Countdown applications on Deskclock activity, request in issue 5936.
The DeskClock is now a ViewPager, with StopWatch <-> DeskClock <-> CountDown fragments, allowing
swiping between pages.

Patch 2: Clean up
Patch 3: BigTextStyle notifications, TimerHelper and extract titlebar color
Patch 4: PowerManagement improvements:
           * CPU WakeLock in TimerClockService
           * New flags on startActivity on TimerClockService for determine if is necessary force turn on the screen
             (force to use onCreate instead of onNewIntent to avoid that screen not turning on when user pressed the
             power button previously)
           * Dim on StopWatch and CountDown after 30 seconds
         Correct a bug that not restart the UI thread when the both timers are running and a countdown is reached
Patch 5: Improve layouts for big screens
Patch 6: Use stat_notify_timer drawable for large icon notification
         ViewPager indicator (Trebuchet like)
Patch 7: Brief tutorial of hidden options at first use (Trebuchet like)
         Remove WIP
Patch 8: Use device density for resolve status bar height
Patch 9: Improved layouts: now are based on screen width, not clock width
         Autoresize DigitalTimerClock to fit the parent view
         Fixed bugs
Patch 10: Fix milliseconds overflow on big numbers
          Set DeskClock fragment as the first page. StopWatch and CountDown are now at the right of DeskClock. Updated
             tutorial to reflect the change.
          Change scrollbar indicator fade to 650 millis, like Trebuchet
          Fix more bugs
Patch 11: The milliseconds of the clock were not adjusted because of a typo in the for loop
Patch 12: If a timer in resume state exists, reset button doesn't reset the partial timer (thanks Sam Mortimer)
          Add a refresh ratio, and separate refresh ratios of portrait (50L) and landscape (100L). Portrait
          performs better
          Clean up
Patch 13: Add overflow menu button to devices with no hardware menu key
          Forces to show deskclock fragment where the device is inserted in the dock.
          Use SparseArray instead of HashMap, as Google Lint suggest for better performance
Patch 14: Clean up (code style, debug information)
Patch 15: Clean up strings to match Android conventions
Status: Ready for merged

  Khas Patch Set 2: Remove unknown symbols

Signed-off-by: KhasMek <Boushh@gmail.com>
Change-Id: I4ab08b6594fe8150a70e64a24b83e52152dbc99b
  • Loading branch information...
1 parent 650c4cd commit 602d4808951782f96183569869a538b88e28b622 @jruesga jruesga committed with Gerrit Code Review Aug 25, 2012
Showing with 10,702 additions and 509 deletions.
  1. +4 −2 Android.mk
  2. +33 −4 AndroidManifest.xml
  3. +3 −0 proguard.cfg
  4. BIN res/drawable-hdpi/bg_cling1.png
  5. BIN res/drawable-hdpi/cling.png
  6. BIN res/drawable-hdpi/ic_menu_moreoverflow.png
  7. BIN res/drawable-hdpi/ic_menu_moreoverflow_focused_holo_dark.png
  8. BIN res/drawable-hdpi/ic_menu_moreoverflow_normal_holo_dark.png
  9. BIN res/drawable-hdpi/ic_next.png
  10. BIN res/drawable-hdpi/ic_previous.png
  11. BIN res/drawable-hdpi/stat_notify_timer.png
  12. BIN res/drawable-land-hdpi/bg_cling1.png
  13. BIN res/drawable-land-mdpi/bg_cling1.png
  14. BIN res/drawable-land-xhdpi/bg_cling1.png
  15. BIN res/drawable-mdpi/bg_cling1.png
  16. BIN res/drawable-mdpi/cling.png
  17. BIN res/drawable-mdpi/ic_menu_moreoverflow.png
  18. BIN res/drawable-mdpi/ic_menu_moreoverflow_focused_holo_dark.png
  19. BIN res/drawable-mdpi/ic_menu_moreoverflow_normal_holo_dark.png
  20. BIN res/drawable-mdpi/ic_next.png
  21. BIN res/drawable-mdpi/ic_previous.png
  22. BIN res/drawable-mdpi/stat_notify_timer.png
  23. BIN res/drawable-xhdpi/bg_cling1.png
  24. BIN res/drawable-xhdpi/cling.png
  25. BIN res/drawable-xhdpi/ic_menu_moreoverflow.png
  26. BIN res/drawable-xhdpi/ic_menu_moreoverflow_focused_holo_dark.png
  27. BIN res/drawable-xhdpi/ic_menu_moreoverflow_normal_holo_dark.png
  28. BIN res/drawable-xhdpi/ic_next.png
  29. BIN res/drawable-xhdpi/ic_previous.png
  30. BIN res/drawable-xhdpi/stat_notify_timer.png
  31. +25 −0 res/drawable/holo_background.xml
  32. +29 −0 res/drawable/holo_selector.xml
  33. +18 −0 res/drawable/ic_menu_moreoverflow_holo_dark.xml
  34. +139 −0 res/layout-land/countdown_fragment.xml
  35. +146 −0 res/layout-land/stopwatch_fragment.xml
  36. +7 −0 res/layout-sw600dp/desk_clock.xml
  37. +72 −0 res/layout/cling_countdown.xml
  38. +62 −0 res/layout/cling_deskclock.xml
  39. +71 −0 res/layout/cling_stopwatch.xml
  40. +132 −0 res/layout/countdown_fragment.xml
  41. +40 −0 res/layout/countdown_timers.xml
  42. +45 −0 res/layout/countdown_timers_item.xml
  43. +7 −0 res/layout/desk_clock.xml
  44. +23 −0 res/layout/desk_clock_fragment.xml
  45. +33 −0 res/layout/desk_clock_pager.xml
  46. +69 −0 res/layout/fragment_titlebar.xml
  47. +40 −0 res/layout/sector_picker_dialog.xml
  48. +138 −0 res/layout/stopwatch_fragment.xml
  49. +49 −0 res/layout/stopwatch_info_panel.xml
  50. +48 −0 res/layout/stopwatch_panel.xml
  51. +43 −0 res/layout/stopwatch_panel_item.xml
  52. +36 −0 res/layout/viewpager_indicator.xml
  53. +32 −3 res/menu/desk_clock_menu.xml
  54. BIN res/mipmap-hdpi/ic_launcher_timer.png
  55. BIN res/mipmap-mdpi/ic_launcher_timer.png
  56. BIN res/mipmap-xhdpi/ic_launcher_timer.png
  57. +13 −8 res/values-land/dimens.xml
  58. +17 −0 res/values-large-hdpi/dimen.xml
  59. +17 −0 res/values-large-land-hdpi/dimen.xml
  60. +23 −8 res/values-sw600dp-land/dimens.xml
  61. +23 −8 res/values-sw600dp/dimens.xml
  62. +17 −0 res/values-sw720dp-land/dimen.xml
  63. +17 −0 res/values-sw720dp/dimen.xml
  64. +48 −15 res/values/arrays.xml
  65. +49 −0 res/values/attrs.xml
  66. +11 −0 res/values/colors.xml
  67. +49 −8 res/values/dimens.xml
  68. +217 −2 res/values/strings.xml
  69. +26 −0 res/xml/countdown_preferences_headers.xml
  70. +82 −0 res/xml/countdown_preferences_notifications.xml
  71. +26 −0 res/xml/stopwatch_preferences_headers.xml
  72. +37 −0 res/xml/stopwatch_preferences_laps_sectors.xml
  73. +919 −0 src/com/android/deskclock/AbstractTimerFragment.java
  74. +702 −0 src/com/android/deskclock/CountDownFragment.java
  75. +210 −0 src/com/android/deskclock/CountDownTimer.java
  76. +51 −0 src/com/android/deskclock/CountDownTimerClock.java
  77. +320 −451 src/com/android/deskclock/DeskClock.java
  78. +678 −0 src/com/android/deskclock/DeskClockFragment.java
  79. +202 −0 src/com/android/deskclock/DeskClockPagerAdapter.java
  80. +750 −0 src/com/android/deskclock/DigitalTimerClock.java
  81. +151 −0 src/com/android/deskclock/FragmentTitle.java
  82. +68 −0 src/com/android/deskclock/ITimerClockService.aidl
  83. +380 −0 src/com/android/deskclock/SavedCountDownTimers.java
  84. +896 −0 src/com/android/deskclock/StopWatchFragment.java
  85. +172 −0 src/com/android/deskclock/StopWatchInfoPanel.java
  86. +273 −0 src/com/android/deskclock/StopWatchLap.java
  87. +315 −0 src/com/android/deskclock/StopWatchLapItems.java
  88. +132 −0 src/com/android/deskclock/StopWatchPanel.java
  89. +58 −0 src/com/android/deskclock/StopWatchTimerClock.java
  90. +960 −0 src/com/android/deskclock/TimerClockService.java
  91. +72 −0 src/com/android/deskclock/TimerDatabaseHelper.java
  92. +100 −0 src/com/android/deskclock/TimerHelper.java
  93. +206 −0 src/com/android/deskclock/TimersProvider.java
  94. +251 −0 src/com/android/deskclock/ViewPagerIndicator.java
  95. +159 −0 src/com/android/deskclock/preferences/CountDownNotificationsPreference.java
  96. +142 −0 src/com/android/deskclock/preferences/CountDownPreferences.java
  97. +282 −0 src/com/android/deskclock/preferences/SectorsDialogPreference.java
  98. +117 −0 src/com/android/deskclock/preferences/StopWatchLapsSectorsPreference.java
  99. +120 −0 src/com/android/deskclock/preferences/StopWatchPreferences.java
View
6 Android.mk
@@ -3,15 +3,17 @@ include $(CLEAR_VARS)
LOCAL_MODULE_TAGS := optional
-LOCAL_STATIC_JAVA_LIBRARIES := android-support-v13
+LOCAL_STATIC_JAVA_LIBRARIES := android-support-v4
-LOCAL_SRC_FILES := $(call all-java-files-under, src)
+LOCAL_SRC_FILES := src/com/android/deskclock/ITimerClockService.aidl
+LOCAL_SRC_FILES += $(call all-java-files-under, src)
LOCAL_PACKAGE_NAME := DeskClock
LOCAL_OVERRIDES_PACKAGES := AlarmClock
LOCAL_SDK_VERSION := current
+LOCAL_PROGUARD_FLAG_FILES := proguard.cfg
include $(BUILD_PACKAGE)
View
37 AndroidManifest.xml
@@ -27,7 +27,6 @@
android:icon="@mipmap/ic_launcher_alarmclock"
android:launchMode="singleInstance"
android:configChanges="orientation|keyboardHidden|keyboard|navigation">
- >
<intent-filter>
<action android:name="android.intent.action.MAIN" />
@@ -52,8 +51,7 @@
<activity android:name="SettingsActivity"
android:label="@string/settings"
android:taskAffinity=""
- android:excludeFromRecents="true"
- >
+ android:excludeFromRecents="true">
<intent-filter>
<action android:name="android.intent.action.MAIN" />
</intent-filter>
@@ -123,7 +121,7 @@
</receiver>
<receiver android:name="com.android.alarmclock.AnalogAppWidgetProvider" android:label="@string/analog_gadget"
- android:icon="@mipmap/ic_widget_analog_clock">
+ android:icon="@mipmap/ic_widget_analog_clock">
<intent-filter>
<action android:name="android.appwidget.action.APPWIDGET_UPDATE" />
</intent-filter>
@@ -169,7 +167,38 @@
<category android:name="android.intent.category.DREAM" />
</intent-filter>
</activity>
+
<service android:name=".DigitalAppWidgetService"></service>
+
+ <activity
+ android:name="com.android.deskclock.preferences.StopWatchPreferences"
+ android:icon="@mipmap/ic_launcher_timer"
+ android:exported="false">
+ <intent-filter>
+ <category android:name="android.intent.category.PREFERENCE" />
+ </intent-filter>
+ </activity>
+
+ <activity
+ android:name="com.android.deskclock.preferences.CountDownPreferences"
+ android:icon="@mipmap/ic_launcher_timer"
+ android:exported="false">
+ <intent-filter>
+ <category android:name="android.intent.category.PREFERENCE" />
+ </intent-filter>
+ </activity>
+
+ <!-- A service for holding timers clocks -->
+ <service android:name="com.android.deskclock.TimerClockService"
+ android:exported="false"
+ android:label="TimerClockService" />
+
+ <!-- The provider for timers database -->
+ <provider
+ android:name="com.android.deskclock.TimersProvider"
+ android:authorities="com.android.deskclock.timers"
+ android:exported="false" />
+
</application>
</manifest>
View
3 proguard.cfg
@@ -0,0 +1,3 @@
+-keep public class * extends android.preference.PreferenceFragment {
+ public <init>(...);
+}
View
BIN res/drawable-hdpi/bg_cling1.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
View
BIN res/drawable-hdpi/cling.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
View
BIN res/drawable-hdpi/ic_menu_moreoverflow.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
View
BIN res/drawable-hdpi/ic_menu_moreoverflow_focused_holo_dark.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
View
BIN res/drawable-hdpi/ic_menu_moreoverflow_normal_holo_dark.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
View
BIN res/drawable-hdpi/ic_next.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
View
BIN res/drawable-hdpi/ic_previous.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
View
BIN res/drawable-hdpi/stat_notify_timer.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
View
BIN res/drawable-land-hdpi/bg_cling1.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
View
BIN res/drawable-land-mdpi/bg_cling1.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
View
BIN res/drawable-land-xhdpi/bg_cling1.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
View
BIN res/drawable-mdpi/bg_cling1.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
View
BIN res/drawable-mdpi/cling.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
View
BIN res/drawable-mdpi/ic_menu_moreoverflow.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
View
BIN res/drawable-mdpi/ic_menu_moreoverflow_focused_holo_dark.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
View
BIN res/drawable-mdpi/ic_menu_moreoverflow_normal_holo_dark.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
View
BIN res/drawable-mdpi/ic_next.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
View
BIN res/drawable-mdpi/ic_previous.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
View
BIN res/drawable-mdpi/stat_notify_timer.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
View
BIN res/drawable-xhdpi/bg_cling1.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
View
BIN res/drawable-xhdpi/cling.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
View
BIN res/drawable-xhdpi/ic_menu_moreoverflow.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
View
BIN res/drawable-xhdpi/ic_menu_moreoverflow_focused_holo_dark.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
View
BIN res/drawable-xhdpi/ic_menu_moreoverflow_normal_holo_dark.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
View
BIN res/drawable-xhdpi/ic_next.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
View
BIN res/drawable-xhdpi/ic_previous.png
Diff not rendered.
View
BIN res/drawable-xhdpi/stat_notify_timer.png
Diff not rendered.
View
25 res/drawable/holo_background.xml
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ ** 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.
+
+-->
+<shape xmlns:android="http://schemas.android.com/apk/res/android"
+ android:shape="rectangle">
+ <gradient
+ android:angle="270"
+ android:startColor="#ff020202"
+ android:endColor="#ff272D33"
+ android:type="linear" />
+</shape>
View
29 res/drawable/holo_selector.xml
@@ -0,0 +1,29 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+ ** 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.
+-->
+<selector xmlns:android="http://schemas.android.com/apk/res/android" android:exitFadeDuration="@android:integer/config_shortAnimTime">
+
+ <item
+ android:drawable="@android:color/holo_blue_dark"
+ android:state_pressed="true"/>
+ <item
+ android:drawable="@android:color/holo_blue_dark"
+ android:state_enabled="true"
+ android:state_focused="true"/>
+ <item
+ android:drawable="@android:color/transparent"/>
+
+</selector>
View
18 res/drawable/ic_menu_moreoverflow_holo_dark.xml
@@ -0,0 +1,18 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (C) 2010 The Android Open Source 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.
+-->
+<selector xmlns:android="http://schemas.android.com/apk/res/android">
+ <item android:drawable="@drawable/ic_menu_moreoverflow_normal_holo_dark" />
+</selector>
View
139 res/layout-land/countdown_fragment.xml
@@ -0,0 +1,139 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+ ** 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.
+-->
+<RelativeLayout
+ xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:deskclock="http://schemas.android.com/apk/res/com.android.deskclock"
+ android:layout_width="match_parent"
+ android:layout_height="match_parent"
+ android:background="@drawable/holo_background"
+ android:cacheColorHint="#00000000">
+
+ <com.android.deskclock.FragmentTitle
+ android:id="@+id/fragment_title"
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content"
+ deskclock:icon="@mipmap/ic_launcher_timer"
+ deskclock:title="@string/countdown_title" />
+
+ <LinearLayout
+ android:layout_width="match_parent"
+ android:layout_height="match_parent"
+ android:orientation="horizontal"
+ android:layout_below="@id/fragment_title">
+
+ <RelativeLayout
+ android:layout_width="match_parent"
+ android:layout_height="match_parent"
+ android:layout_weight="1"
+ android:layout_gravity="top"
+ android:layout_margin="@dimen/timer_default_margin">
+
+ <com.android.deskclock.CountDownTimerClock
+ android:id="@+id/main_timer_clock"
+ android:layout_width="wrap_content"
+ android:layout_height="wrap_content"
+ android:paddingTop="@dimen/main_timer_clock_padding"
+ deskclock:size="@dimen/main_timer_clock_text_size"
+ deskclock:color="@color/main_timer_clock"
+ deskclock:autoresize="true"
+ deskclock:editable="true" />
+
+ <LinearLayout
+ android:id="@+id/vg_timer_control_layout"
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content"
+ android:layout_below="@id/main_timer_clock"
+ android:layout_marginTop="@dimen/timer_margin"
+ android:orientation="horizontal"
+ android:visibility="invisible">
+
+ <Button
+ android:id="@+id/bt_timer_reset"
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content"
+ android:layout_weight="1"
+ android:textSize="@dimen/main_button_text_size"
+ android:text="@string/countdown_actions_reset"
+ android:contentDescription="@string/countdown_actions_reset_cd" />
+
+ <Button
+ android:id="@+id/bt_timer_main"
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content"
+ android:layout_weight="1"
+ android:textSize="@dimen/main_button_text_size"
+ android:text="@string/countdown_actions_start"
+ android:contentDescription="@string/countdown_actions_start_cd" />
+
+ </LinearLayout>
+
+ <LinearLayout
+ android:id="@+id/vg_timer_edit_layout"
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content"
+ android:layout_below="@id/main_timer_clock"
+ android:layout_marginTop="@dimen/timer_margin"
+ android:orientation="horizontal"
+ android:visibility="invisible">
+
+ <Button
+ android:id="@+id/bt_timer_cancel"
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content"
+ android:layout_weight="1"
+ android:textSize="@dimen/main_button_text_size"
+ android:text="@string/countdown_actions_cancel"
+ android:contentDescription="@string/countdown_actions_cancel_cd" />
+
+ <Button
+ android:id="@+id/bt_timer_set"
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content"
+ android:layout_weight="1"
+ android:textSize="@dimen/main_button_text_size"
+ android:text="@string/countdown_actions_set"
+ android:contentDescription="@string/countdown_actions_set_cd" />
+
+ </LinearLayout>
+
+ </RelativeLayout>
+
+ <com.android.deskclock.SavedCountDownTimers
+ android:id="@+id/countdown_saved_timers_panel"
+ android:layout_width="match_parent"
+ android:layout_height="match_parent"
+ android:layout_margin="@dimen/countdown_saved_timers_panel_margin"
+ android:layout_weight="1" />
+
+ </LinearLayout>
+
+ <View android:id="@+id/window_tint"
+ android:layout_width="match_parent"
+ android:layout_height="match_parent"
+ android:background="#CC000000"
+ android:visibility="invisible"
+ android:clickable="false"
+ />
+
+ <include
+ layout="@layout/cling_countdown"
+ android:layout_width="match_parent"
+ android:layout_height="match_parent"
+ android:visibility="invisible"
+ android:clickable="false" />
+
+</RelativeLayout>
View
146 res/layout-land/stopwatch_fragment.xml
@@ -0,0 +1,146 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+ ** 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.
+-->
+<RelativeLayout
+ xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:deskclock="http://schemas.android.com/apk/res/com.android.deskclock"
+ android:layout_width="match_parent"
+ android:layout_height="match_parent"
+ android:background="@drawable/holo_background"
+ android:cacheColorHint="#00000000">
+
+ <com.android.deskclock.FragmentTitle
+ android:id="@+id/fragment_title"
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content"
+ deskclock:icon="@mipmap/ic_launcher_timer"
+ deskclock:title="@string/stopwatch_title" />
+
+ <LinearLayout
+ android:layout_width="match_parent"
+ android:layout_height="match_parent"
+ android:orientation="horizontal"
+ android:layout_below="@id/fragment_title">
+
+ <RelativeLayout
+ android:layout_width="match_parent"
+ android:layout_height="match_parent"
+ android:layout_weight="1"
+ android:layout_gravity="top"
+ android:layout_margin="@dimen/timer_default_margin">
+
+ <com.android.deskclock.StopWatchTimerClock
+ android:id="@+id/main_timer_clock"
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content"
+ android:paddingTop="@dimen/main_timer_clock_padding"
+ deskclock:size="@dimen/main_timer_clock_text_size"
+ deskclock:color="@color/main_timer_clock"
+ deskclock:autoresize="true" />
+
+ <LinearLayout
+ android:id="@+id/vg_small_clocks"
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content"
+ android:layout_below="@id/main_timer_clock"
+ android:layout_marginTop="@dimen/small_timer_margin"
+ android:paddingBottom="@dimen/timer_margin"
+ android:orientation="horizontal">
+
+ <com.android.deskclock.StopWatchTimerClock
+ android:id="@+id/diff_timer_clock"
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content"
+ android:layout_weight="1"
+ android:gravity="left|center_vertical"
+ deskclock:size="@dimen/small_timer_clock_text_size"
+ deskclock:show_sign="true"
+ deskclock:positive_color="@color/positive_timer_clock"
+ deskclock:negative_color="@color/negative_timer_clock" />
+
+ <com.android.deskclock.StopWatchTimerClock
+ android:id="@+id/partial_timer_clock"
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content"
+ android:layout_weight="1"
+ android:gravity="right|center_vertical"
+ deskclock:size="@dimen/small_timer_clock_text_size"
+ deskclock:color="@color/partial_timer_clock" />
+
+ </LinearLayout>
+
+ <LinearLayout
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content"
+ android:layout_below="@id/vg_small_clocks"
+ android:orientation="horizontal">
+
+ <Button
+ android:id="@+id/bt_timer_reset"
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content"
+ android:layout_weight="1"
+ android:textSize="@dimen/main_button_text_size"
+ android:text="@string/stopwatch_actions_reset"
+ android:contentDescription="@string/stopwatch_actions_reset_cd" />
+
+ <Button
+ android:id="@+id/bt_timer_main"
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content"
+ android:layout_weight="1"
+ android:textSize="@dimen/main_button_text_size"
+ android:text="@string/stopwatch_actions_start"
+ android:contentDescription="@string/stopwatch_actions_start_cd" />
+
+ <Button
+ android:id="@+id/bt_timer_partial"
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content"
+ android:layout_weight="1"
+ android:textSize="@dimen/main_button_text_size"
+ android:text="@string/stopwatch_actions_lap"
+ android:contentDescription="@string/stopwatch_actions_lap_cd" />
+
+ </LinearLayout>
+
+ </RelativeLayout>
+
+ <com.android.deskclock.StopWatchInfoPanel
+ android:id="@+id/stopwatch_info_panel"
+ android:layout_width="match_parent"
+ android:layout_height="match_parent"
+ android:layout_weight="1"
+ android:layout_margin="@dimen/stopwatch_info_panel_margin" />
+
+ </LinearLayout>
+
+ <View android:id="@+id/window_tint"
+ android:layout_width="match_parent"
+ android:layout_height="match_parent"
+ android:background="#CC000000"
+ android:visibility="invisible"
+ android:clickable="false"
+ />
+
+ <include
+ layout="@layout/cling_stopwatch"
+ android:layout_width="match_parent"
+ android:layout_height="match_parent"
+ android:visibility="invisible"
+ android:clickable="false" />
+
+</RelativeLayout>
View
7 res/layout-sw600dp/desk_clock.xml
@@ -65,4 +65,11 @@
android:clickable="false"
/>
+ <include
+ layout="@layout/cling_deskclock"
+ android:layout_width="match_parent"
+ android:layout_height="match_parent"
+ android:visibility="invisible"
+ android:clickable="false" />
+
</FrameLayout>
View
72 res/layout/cling_countdown.xml
@@ -0,0 +1,72 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+ ** 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.
+-->
+<RelativeLayout
+ xmlns:android="http://schemas.android.com/apk/res/android"
+ android:id="@+id/countdown_cling"
+ android:layout_width="match_parent"
+ android:layout_height="match_parent"
+ android:background="@drawable/bg_cling1">
+
+ <ImageView
+ android:id="@+id/cling_previous"
+ android:layout_width="wrap_content"
+ android:layout_height="wrap_content"
+ android:layout_marginLeft="@dimen/cling_margin_h"
+ android:layout_marginRight="@dimen/cling_margin_h"
+ android:layout_marginBottom="@dimen/cling_margin_v"
+ android:layout_alignParentLeft="true"
+ android:layout_alignParentBottom="true"
+ android:src="@drawable/ic_previous"
+ android:contentDescription="@null" />
+
+ <ImageView
+ android:id="@+id/cling_next"
+ android:layout_width="wrap_content"
+ android:layout_height="wrap_content"
+ android:layout_marginLeft="@dimen/cling_margin_h"
+ android:layout_marginRight="@dimen/cling_margin_h"
+ android:layout_marginBottom="@dimen/cling_margin_v"
+ android:layout_alignParentRight="true"
+ android:layout_alignParentBottom="true"
+ android:src="@drawable/ic_next"
+ android:visibility="invisible"
+ android:contentDescription="@null" />
+
+ <TextView
+ android:id="@+id/cling_text"
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content"
+ android:layout_toRightOf="@id/cling_previous"
+ android:layout_toLeftOf="@id/cling_next"
+ android:layout_marginBottom="@dimen/cling_margin_v"
+ android:layout_alignParentBottom="true"
+ android:layout_centerHorizontal="true"
+ android:gravity="center"
+ android:singleLine="false"
+ android:textColor="@color/cling_text"
+ android:text="@string/cling_countdown_desc" />
+
+ <ImageView
+ android:id="@+id/cling_image"
+ android:layout_width="248dip"
+ android:layout_height="248dip"
+ android:scaleType="fitCenter"
+ android:src="@drawable/cling"
+ android:visibility="invisible"
+ android:contentDescription="@null" />
+
+</RelativeLayout>
View
62 res/layout/cling_deskclock.xml
@@ -0,0 +1,62 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+ ** 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.
+-->
+<RelativeLayout
+ xmlns:android="http://schemas.android.com/apk/res/android"
+ android:id="@+id/deskclock_cling"
+ android:layout_width="match_parent"
+ android:layout_height="match_parent"
+ android:background="@drawable/bg_cling1">
+
+ <ImageView
+ android:id="@+id/cling_previous"
+ android:layout_width="wrap_content"
+ android:layout_height="wrap_content"
+ android:layout_marginLeft="@dimen/cling_margin_h"
+ android:layout_marginRight="@dimen/cling_margin_h"
+ android:layout_marginBottom="@dimen/cling_margin_v"
+ android:layout_alignParentLeft="true"
+ android:layout_alignParentBottom="true"
+ android:src="@drawable/ic_previous"
+ android:visibility="invisible"
+ android:contentDescription="@null" />
+
+ <ImageView
+ android:id="@+id/cling_next"
+ android:layout_width="wrap_content"
+ android:layout_height="wrap_content"
+ android:layout_marginLeft="@dimen/cling_margin_h"
+ android:layout_marginRight="@dimen/cling_margin_h"
+ android:layout_marginBottom="@dimen/cling_margin_v"
+ android:layout_alignParentRight="true"
+ android:layout_alignParentBottom="true"
+ android:src="@drawable/ic_next"
+ android:contentDescription="@null" />
+
+ <TextView
+ android:id="@+id/cling_text"
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content"
+ android:layout_toRightOf="@id/cling_previous"
+ android:layout_toLeftOf="@id/cling_next"
+ android:layout_marginBottom="@dimen/cling_margin_v"
+ android:layout_alignParentBottom="true"
+ android:gravity="center"
+ android:singleLine="false"
+ android:textColor="@color/cling_text"
+ android:text="@string/cling_deskclock_desc" />
+
+</RelativeLayout>
View
71 res/layout/cling_stopwatch.xml
@@ -0,0 +1,71 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+ ** 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.
+-->
+<RelativeLayout
+ xmlns:android="http://schemas.android.com/apk/res/android"
+ android:id="@+id/stopwatch_cling"
+ android:layout_width="match_parent"
+ android:layout_height="match_parent"
+ android:background="@drawable/bg_cling1">
+
+ <ImageView
+ android:id="@+id/cling_previous"
+ android:layout_width="wrap_content"
+ android:layout_height="wrap_content"
+ android:layout_marginLeft="@dimen/cling_margin_h"
+ android:layout_marginRight="@dimen/cling_margin_h"
+ android:layout_marginBottom="@dimen/cling_margin_v"
+ android:layout_alignParentLeft="true"
+ android:layout_alignParentBottom="true"
+ android:src="@drawable/ic_previous"
+ android:contentDescription="@null" />
+
+ <ImageView
+ android:id="@+id/cling_next"
+ android:layout_width="wrap_content"
+ android:layout_height="wrap_content"
+ android:layout_marginLeft="@dimen/cling_margin_h"
+ android:layout_marginRight="@dimen/cling_margin_h"
+ android:layout_marginBottom="@dimen/cling_margin_v"
+ android:layout_alignParentRight="true"
+ android:layout_alignParentBottom="true"
+ android:src="@drawable/ic_next"
+ android:contentDescription="@null" />
+
+ <TextView
+ android:id="@+id/cling_text"
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content"
+ android:layout_toRightOf="@id/cling_previous"
+ android:layout_toLeftOf="@id/cling_next"
+ android:layout_marginBottom="@dimen/cling_margin_v"
+ android:layout_alignParentBottom="true"
+ android:layout_centerHorizontal="true"
+ android:gravity="center"
+ android:singleLine="false"
+ android:textColor="@color/cling_text"
+ android:text="@string/cling_stopwatch_desc" />
+
+ <ImageView
+ android:id="@+id/cling_image"
+ android:layout_width="126dip"
+ android:layout_height="126dip"
+ android:scaleType="fitCenter"
+ android:src="@drawable/cling"
+ android:visibility="invisible"
+ android:contentDescription="@null" />
+
+</RelativeLayout>
View
132 res/layout/countdown_fragment.xml
@@ -0,0 +1,132 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+ ** 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.
+-->
+<RelativeLayout
+ xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:deskclock="http://schemas.android.com/apk/res/com.android.deskclock"
+ android:layout_width="match_parent"
+ android:layout_height="match_parent"
+ android:background="@drawable/holo_background"
+ android:cacheColorHint="#00000000">
+
+ <com.android.deskclock.FragmentTitle
+ android:id="@+id/fragment_title"
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content"
+ deskclock:icon="@mipmap/ic_launcher_timer"
+ deskclock:title="@string/countdown_title" />
+
+ <com.android.deskclock.CountDownTimerClock
+ android:id="@+id/main_timer_clock"
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content"
+ android:layout_centerHorizontal="true"
+ android:layout_below="@id/fragment_title"
+ android:layout_marginLeft="@dimen/timer_default_margin"
+ android:layout_marginRight="@dimen/timer_default_margin"
+ deskclock:padding="@dimen/main_timer_clock_padding"
+ deskclock:size="@dimen/main_timer_clock_text_size"
+ deskclock:color="@color/main_timer_clock"
+ deskclock:autoresize="true"
+ deskclock:editable="true" />
+
+ <LinearLayout
+ android:id="@+id/vg_timer_control_layout"
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content"
+ android:layout_below="@id/main_timer_clock"
+ android:layout_marginLeft="@dimen/timer_default_margin"
+ android:layout_marginRight="@dimen/timer_default_margin"
+ android:layout_marginTop="@dimen/timer_margin"
+ android:orientation="horizontal"
+ android:visibility="invisible">
+
+ <Button
+ android:id="@+id/bt_timer_reset"
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content"
+ android:layout_weight="1"
+ android:textSize="@dimen/main_button_text_size"
+ android:text="@string/countdown_actions_reset"
+ android:contentDescription="@string/countdown_actions_reset_cd" />
+
+ <Button
+ android:id="@+id/bt_timer_main"
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content"
+ android:layout_weight="1"
+ android:textSize="@dimen/main_button_text_size"
+ android:text="@string/countdown_actions_start"
+ android:contentDescription="@string/countdown_actions_start_cd" />
+
+ </LinearLayout>
+
+ <LinearLayout
+ android:id="@+id/vg_timer_edit_layout"
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content"
+ android:layout_below="@id/main_timer_clock"
+ android:layout_marginLeft="@dimen/timer_default_margin"
+ android:layout_marginRight="@dimen/timer_default_margin"
+ android:layout_marginTop="@dimen/timer_margin"
+ android:orientation="horizontal"
+ android:visibility="invisible">
+
+ <Button
+ android:id="@+id/bt_timer_cancel"
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content"
+ android:layout_weight="1"
+ android:textSize="@dimen/main_button_text_size"
+ android:text="@string/countdown_actions_cancel"
+ android:contentDescription="@string/countdown_actions_cancel_cd" />
+
+ <Button
+ android:id="@+id/bt_timer_set"
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content"
+ android:layout_weight="1"
+ android:textSize="@dimen/main_button_text_size"
+ android:text="@string/countdown_actions_set"
+ android:contentDescription="@string/countdown_actions_set_cd" />
+
+ </LinearLayout>
+
+ <com.android.deskclock.SavedCountDownTimers
+ android:id="@+id/countdown_saved_timers_panel"
+ android:layout_width="match_parent"
+ android:layout_height="match_parent"
+ android:layout_marginTop="@dimen/countdown_saved_timers_panel_margin"
+ android:layout_below="@id/vg_timer_control_layout"
+ android:layout_marginLeft="@dimen/timer_default_margin"
+ android:layout_marginRight="@dimen/timer_default_margin" />
+
+ <View android:id="@+id/window_tint"
+ android:layout_width="match_parent"
+ android:layout_height="match_parent"
+ android:background="#CC000000"
+ android:visibility="invisible"
+ android:clickable="false"
+ />
+
+ <include
+ layout="@layout/cling_countdown"
+ android:layout_width="match_parent"
+ android:layout_height="match_parent"
+ android:visibility="invisible"
+ android:clickable="false" />
+
+</RelativeLayout>
View
40 res/layout/countdown_timers.xml
@@ -0,0 +1,40 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+ ** 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.
+-->
+<RelativeLayout
+ xmlns:android="http://schemas.android.com/apk/res/android"
+ android:layout_width="match_parent"
+ android:layout_height="match_parent">
+ <TextView
+ android:id="@+id/countdown_panel_title"
+ android:layout_width="wrap_content"
+ android:layout_height="wrap_content"
+ android:textSize="@dimen/countdown_timers_panel_title_text_size"
+ android:textColor="@android:color/darker_gray"
+ android:text="@string/countdown_panel_title"
+ android:textAllCaps="true" />
+ <TextView
+ android:id="@+id/countdown_panel_separator"
+ android:layout_width="match_parent"
+ android:layout_height="@dimen/countdown_timers_panel_divider_size"
+ android:layout_below="@id/countdown_panel_title"
+ android:background="@android:color/darker_gray" />
+ <ListView
+ android:id="@+id/countdown_saved_timers_listview"
+ android:layout_width="match_parent"
+ android:layout_height="match_parent"
+ android:layout_below="@id/countdown_panel_separator" />
+</RelativeLayout>
View
45 res/layout/countdown_timers_item.xml
@@ -0,0 +1,45 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+ ** 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.
+-->
+<RelativeLayout
+ xmlns:android="http://schemas.android.com/apk/res/android"
+ android:layout_width="match_parent"
+ android:layout_height="@dimen/listview_row_height"
+ android:background="@drawable/holo_selector">
+ <TextView
+ android:id="@+id/countdown_saved_timer_text"
+ android:layout_width="match_parent"
+ android:layout_height="match_parent"
+ android:layout_alignParentLeft="true"
+ android:paddingLeft="@dimen/listview_row_padding"
+ android:gravity="left|center_vertical"
+ android:textSize="@dimen/listview_row_text_size"
+ android:textColor="@android:color/primary_text_dark"
+ android:clickable="true"
+ android:background="@drawable/holo_selector" />
+ <ImageButton
+ android:id="@+id/countdown_saved_timer_image"
+ android:layout_width="wrap_content"
+ android:layout_height="match_parent"
+ android:padding="@dimen/listview_row_image_padding"
+ android:focusable="false"
+ android:focusableInTouchMode="false"
+ android:layout_alignParentRight="true"
+ android:layout_centerVertical="true"
+ android:clickable="true"
+ android:contentDescription="@null"
+ android:background="@drawable/holo_selector"/>
+</RelativeLayout>
View
7 res/layout/desk_clock.xml
@@ -90,4 +90,11 @@
android:clickable="false"
/>
+ <include
+ layout="@layout/cling_deskclock"
+ android:layout_width="match_parent"
+ android:layout_height="match_parent"
+ android:visibility="invisible"
+ android:clickable="false" />
+
</FrameLayout>
View
23 res/layout/desk_clock_fragment.xml
@@ -0,0 +1,23 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ ** 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.
+-->
+<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
+ android:layout_width="match_parent"
+ android:layout_height="match_parent">
+
+<!-- This layouts for the fragment holds the original desk_clock.xml layout -->
+
+</LinearLayout>
View
33 res/layout/desk_clock_pager.xml
@@ -0,0 +1,33 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ ** 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.
+-->
+<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
+ android:layout_width="match_parent"
+ android:layout_height="match_parent" >
+
+ <android.support.v4.view.ViewPager
+ android:id="@+id/desk_clock_pager"
+ android:layout_width="match_parent"
+ android:layout_height="match_parent" />
+
+ <com.android.deskclock.ViewPagerIndicator
+ android:id="@+id/viewpager_indicator"
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content"
+ android:layout_alignParentBottom="true"
+ android:layout_margin="@dimen/viewpager_padding" />
+
+</RelativeLayout>
View
69 res/layout/fragment_titlebar.xml
@@ -0,0 +1,69 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ ** 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.
+
+-->
+<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
+ android:id="@+id/fragment_titlebar_layout"
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content">
+ <TextView
+ android:id="@+id/fragment_statusbar"
+ android:layout_width="match_parent"
+ android:layout_height="1dp">
+ </TextView>
+ <RelativeLayout
+ android:id="@+id/fragment_titlebar"
+ android:layout_width="match_parent"
+ android:layout_height="@dimen/fragment_titlebar_default_height"
+ android:layout_marginLeft="@dimen/fragment_titlebar_horizontal_padding"
+ android:gravity="center_vertical"
+ android:layout_below="@id/fragment_statusbar">
+ <ImageView
+ android:id="@+id/fragment_titlebar_icon"
+ android:layout_width="@dimen/fragment_titlebar_icon_size"
+ android:layout_height="match_parent"
+ android:layout_alignParentLeft="true"
+ android:gravity="center_horizontal|center_vertical"
+ android:contentDescription="@null" />
+ <ImageButton
+ android:id="@+id/fragment_titlebar_overflow"
+ android:layout_width="@dimen/fragment_titlebar_icon_size"
+ android:layout_height="match_parent"
+ android:layout_alignParentRight="true"
+ android:gravity="center_horizontal|center_vertical"
+ android:src="@drawable/ic_menu_moreoverflow_holo_dark"
+ android:background="?android:attr/actionBarItemBackground"
+ android:contentDescription="@string/overflow_button_cd"
+ android:visibility="invisible" />
+ <TextView
+ android:id="@+id/fragment_titlebar_title"
+ android:layout_width="match_parent"
+ android:layout_height="match_parent"
+ android:layout_toRightOf="@id/fragment_titlebar_icon"
+ android:layout_toLeftOf="@id/fragment_titlebar_overflow"
+ android:gravity="left|center_vertical"
+ android:textSize="@dimen/fragment_titlebar_title_text_size"
+ android:textColor="@android:color/primary_text_dark"
+ android:singleLine="true"
+ android:paddingLeft="@dimen/fragment_titlebar_title_left_padding" />
+ </RelativeLayout>
+ <TextView
+ android:id="@+id/fragment_separator"
+ android:background="@color/titlebar_separator"
+ android:layout_width="match_parent"
+ android:layout_height="2dp"
+ android:layout_below="@id/fragment_titlebar" />
+</RelativeLayout>
View
40 res/layout/sector_picker_dialog.xml
@@ -0,0 +1,40 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+ ** 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.
+-->
+<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
+ android:layout_width="wrap_content"
+ android:layout_height="wrap_content" >
+ <TextView
+ android:id="@+id/sector_enabled_txt"
+ android:layout_centerHorizontal="true"
+ android:layout_width="wrap_content"
+ android:layout_height="wrap_content"
+ android:layout_marginTop="16dip"
+ android:text="@string/sectors_dialog_enabled_text" />
+ <CheckBox
+ android:id="@+id/sector_enabled"
+ android:layout_width="wrap_content"
+ android:layout_height="wrap_content"
+ android:layout_toRightOf="@id/sector_enabled_txt"
+ android:layout_alignBaseline="@id/sector_enabled_txt" />
+ <NumberPicker
+ android:id="@+id/sector_picker"
+ android:layout_centerHorizontal="true"
+ android:layout_below="@+id/sector_enabled_txt"
+ android:layout_width="100dip"
+ android:layout_height="wrap_content" />
+</RelativeLayout>
+
View
138 res/layout/stopwatch_fragment.xml
@@ -0,0 +1,138 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+ ** 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.
+-->
+<RelativeLayout
+ xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:deskclock="http://schemas.android.com/apk/res/com.android.deskclock"
+ android:layout_width="match_parent"
+ android:layout_height="match_parent"
+ android:background="@drawable/holo_background"
+ android:cacheColorHint="#00000000">
+
+ <com.android.deskclock.FragmentTitle
+ android:id="@+id/fragment_title"
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content"
+ deskclock:icon="@mipmap/ic_launcher_timer"
+ deskclock:title="@string/stopwatch_title" />
+
+ <com.android.deskclock.StopWatchTimerClock
+ android:id="@+id/main_timer_clock"
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content"
+ android:layout_below="@id/fragment_title"
+ android:layout_marginLeft="@dimen/timer_default_margin"
+ android:layout_marginRight="@dimen/timer_default_margin"
+ deskclock:size="@dimen/main_timer_clock_text_size"
+ deskclock:color="@color/main_timer_clock"
+ deskclock:autoresize="true" />
+
+ <LinearLayout
+ android:id="@+id/vg_small_clocks"
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content"
+ android:layout_below="@id/main_timer_clock"
+ android:layout_marginLeft="@dimen/timer_default_margin"
+ android:layout_marginRight="@dimen/timer_default_margin"
+ android:layout_marginTop="@dimen/small_timer_margin"
+ android:paddingBottom="@dimen/timer_margin"
+ android:orientation="horizontal">
+
+ <com.android.deskclock.StopWatchTimerClock
+ android:id="@+id/diff_timer_clock"
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content"
+ android:layout_weight="1"
+ android:gravity="left|center_vertical"
+ deskclock:size="@dimen/small_timer_clock_text_size"
+ deskclock:show_sign="true"
+ deskclock:positive_color="@color/positive_timer_clock"
+ deskclock:negative_color="@color/negative_timer_clock" />
+
+ <com.android.deskclock.StopWatchTimerClock
+ android:id="@+id/partial_timer_clock"
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content"
+ android:layout_weight="1"
+ android:gravity="right|center_vertical"
+ deskclock:size="@dimen/small_timer_clock_text_size"
+ deskclock:color="@color/partial_timer_clock" />
+
+ </LinearLayout>
+
+ <LinearLayout
+ android:id="@+id/vg_buttons"
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content"
+ android:layout_below="@id/vg_small_clocks"
+ android:layout_marginLeft="@dimen/timer_default_margin"
+ android:layout_marginRight="@dimen/timer_default_margin"
+ android:orientation="horizontal">
+
+ <Button
+ android:id="@+id/bt_timer_reset"
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content"
+ android:layout_weight="1"
+ android:textSize="@dimen/main_button_text_size"
+ android:text="@string/stopwatch_actions_reset"
+ android:contentDescription="@string/stopwatch_actions_reset_cd" />
+
+ <Button
+ android:id="@+id/bt_timer_main"
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content"
+ android:layout_weight="1"
+ android:textSize="@dimen/main_button_text_size"
+ android:text="@string/stopwatch_actions_start"
+ android:contentDescription="@string/stopwatch_actions_start_cd" />
+
+ <Button
+ android:id="@+id/bt_timer_partial"
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content"
+ android:layout_weight="1"
+ android:textSize="@dimen/main_button_text_size"
+ android:text="@string/stopwatch_actions_lap"
+ android:contentDescription="@string/stopwatch_actions_lap_cd" />
+ </LinearLayout>
+
+ <com.android.deskclock.StopWatchInfoPanel
+ android:id="@+id/stopwatch_info_panel"
+ android:layout_width="match_parent"
+ android:layout_height="match_parent"
+ android:layout_below="@id/vg_buttons"
+ android:layout_marginLeft="@dimen/timer_default_margin"
+ android:layout_marginRight="@dimen/timer_default_margin"
+ android:layout_marginTop="@dimen/stopwatch_info_panel_margin"
+ android:layout_marginBottom="@dimen/stopwatch_info_panel_margin" />
+
+ <View android:id="@+id/window_tint"
+ android:layout_width="match_parent"
+ android:layout_height="match_parent"
+ android:background="#CC000000"
+ android:visibility="invisible"
+ android:clickable="false"
+ />
+
+ <include
+ layout="@layout/cling_stopwatch"
+ android:layout_width="match_parent"
+ android:layout_height="match_parent"
+ android:visibility="invisible"
+ android:clickable="false" />
+
+</RelativeLayout>
View
49 res/layout/stopwatch_info_panel.xml
@@ -0,0 +1,49 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+ ** 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.
+-->
+<ScrollView
+ xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:deskclock="http://schemas.android.com/apk/res/com.android.deskclock"
+ android:scrollbars="vertical">
+
+ <LinearLayout
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content"
+ android:orientation="vertical">
+ <!-- Last lap -->
+ <com.android.deskclock.StopWatchPanel
+ android:id="@+id/info_panel_last_lap"
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content"
+ android:layout_marginBottom="@dimen/stopwatch_info_panel_category_separator"
+ deskclock:panel_title="@string/stopwatch_info_panel_last_lap_title" />
+ <!-- Best lap -->
+ <com.android.deskclock.StopWatchPanel
+ android:id="@+id/info_panel_best_lap"
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content"
+ android:layout_marginBottom="@dimen/stopwatch_info_panel_category_separator"
+ deskclock:panel_title="@string/stopwatch_info_panel_best_lap_title" />
+ <!-- Laps -->
+ <com.android.deskclock.StopWatchPanel
+ android:id="@+id/info_panel_laps"
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content"
+ android:layout_marginBottom="@dimen/stopwatch_info_panel_category_separator"
+ deskclock:panel_title="@string/stopwatch_info_panel_laps_title" />
+ </LinearLayout>
+
+</ScrollView>
View
48 res/layout/stopwatch_panel.xml
@@ -0,0 +1,48 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+ ** 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.
+-->
+<RelativeLayout
+ xmlns:android="http://schemas.android.com/apk/res/android"
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content">
+ <TextView
+ android:id="@+id/stopwatch_panel_title"
+ android:layout_width="wrap_content"
+ android:layout_height="wrap_content"
+ android:textSize="@dimen/stopwatch_info_panel_title_text_size"
+ android:textColor="@android:color/darker_gray"
+ android:textAllCaps="true" />
+ <TextView
+ android:id="@+id/stopwatch_panel_title_separator"
+ android:layout_width="match_parent"
+ android:layout_height="@dimen/stopwatch_info_panel_divider_size"
+ android:layout_below="@id/stopwatch_panel_title"
+ android:background="@android:color/darker_gray" />
+ <com.android.deskclock.StopWatchLapItems
+ android:id="@+id/stopwatch_panel_items"
+ android:layout_width="match_parent"
+ android:layout_height="match_parent"
+ android:layout_below="@id/stopwatch_panel_title_separator" />
+ <TextView
+ android:id="@+id/stopwatch_panel_no_data"
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content"
+ android:layout_below="@id/stopwatch_panel_title_separator"
+ android:text="@string/stopwatch_info_panel_empty_data"
+ android:textColor="@android:color/primary_text_dark"
+ android:textSize="@dimen/stopwatch_info_panel_item_text_size"
+ android:gravity="center_horizontal" />
+</RelativeLayout>
View
43 res/layout/stopwatch_panel_item.xml
@@ -0,0 +1,43 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+ ** 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.
+-->
+<LinearLayout
+ xmlns:android="http://schemas.android.com/apk/res/android"
+ android:layout_width="match_parent"
+ android:layout_height="match_parent"
+ android:orientation="horizontal">
+ <TextView
+ android:id="@+id/info_panel_item_field1"
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content"
+ android:textSize="@dimen/stopwatch_info_panel_item_text_size"
+ android:layout_weight="1"
+ android:singleLine="true" />
+ <TextView
+ android:id="@+id/info_panel_item_field2"
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content"
+ android:textSize="@dimen/stopwatch_info_panel_item_text_size"
+ android:layout_weight="1"
+ android:singleLine="true" />
+ <TextView
+ android:id="@+id/info_panel_item_field3"
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content"
+ android:textSize="@dimen/stopwatch_info_panel_item_text_size"
+ android:layout_weight="1"
+ android:singleLine="true" />
+</LinearLayout>
View
36 res/layout/viewpager_indicator.xml
@@ -0,0 +1,36 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+ ** 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.
+-->
+<RelativeLayout
+ xmlns:android="http://schemas.android.com/apk/res/android"
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content">
+
+ <TextView
+ android:id="@+id/viewpager_indicator_bg"
+ android:layout_width="match_parent"
+ android:layout_height="2dip"
+ android:background="@color/bg_bar" />
+
+ <TextView
+ android:id="@+id/viewpager_indicator_fg"
+ android:layout_width="0dp"
+ android:layout_height="2dip"
+ android:layout_alignLeft="@id/viewpager_indicator_bg"
+ android:background="@color/fg_bar"
+ android:visibility="invisible" />
+
+</RelativeLayout>
View
35 res/menu/desk_clock_menu.xml
@@ -15,9 +15,38 @@
-->
<menu xmlns:android="http://schemas.android.com/apk/res/android">
- <item android:id="@+id/menu_item_dock_settings"
- android:title="@string/menu_item_dock_settings"
- android:icon="@android:drawable/ic_menu_preferences"/>
+ <!-- DeskClock -->
+ <group android:id="@+id/menu_group_deskclock">
+ <item android:id="@+id/menu_item_dock_settings"
+ android:title="@string/menu_item_dock_settings"
+ android:icon="@android:drawable/ic_menu_preferences"/>
+ </group>
+
+ <!-- StopWatch -->
+ <group android:id="@+id/menu_group_stopwatch">
+ <item android:id="@+id/menu_item_stopwatch_hide_last_lap"
+ android:title="@string/stopwatch_menu_hide_last_lap_panel"
+ android:checkable="true"
+ android:checked="false" />
+ <item android:id="@+id/menu_item_stopwatch_hide_best_lap"
+ android:title="@string/stopwatch_menu_hide_best_lap_panel"
+ android:checkable="true"
+ android:checked="false" />
+ <item android:id="@+id/menu_item_stopwatch_hide_laps"
+ android:title="@string/stopwatch_menu_hide_laps_panel"
+ android:checkable="true"
+ android:checked="false" />
+ <item android:id="@+id/menu_item_stopwatch_settings"
+ android:title="@string/stopwatch_menu_settings"/>
+ </group>
+
+ <!-- CountDown -->
+ <group android:id="@+id/menu_group_countdown">
+ <item android:id="@+id/menu_item_countdown_editor"
+ android:title="@string/countdown_menu_open_timer_editor"/>
+ <item android:id="@+id/menu_item_countdown_settings"
+ android:title="@string/countdown_menu_settings"/>
+ </group>
</menu>
View
BIN res/mipmap-hdpi/ic_launcher_timer.png
Diff not rendered.
View
BIN res/mipmap-mdpi/ic_launcher_timer.png
Diff not rendered.
View
BIN res/mipmap-xhdpi/ic_launcher_timer.png
Diff not rendered.
View
21 res/values-land/dimens.xml
@@ -3,16 +3,16 @@
/*
** Copyright 2011, The Android Open Source 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
+** 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
+** 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
+** 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.
*/
-->
@@ -30,4 +30,9 @@
<dimen name="ampm_margin_top">16dip</dimen>
<dimen name="font_margin_adjust">8dip</dimen>
<dimen name="next_alarm_margin_top">-5dip</dimen>
+
+ <!-- Timer Clock -->
+ <dimen name="main_timer_clock_text_size">36sp</dimen>
+ <dimen name="main_timer_clock_padding">10dip</dimen>
+ <dimen name="main_button_text_size">14sp</dimen>
</resources>
View
17 res/values-large-hdpi/dimen.xml
@@ -0,0 +1,17 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<resources xmlns:android="http://schemas.android.com/apk/res/android">
+ <!-- Timer Clock -->
+ <dimen name="main_timer_clock_text_size">100sp</dimen>
+ <dimen name="small_timer_clock_text_size">24sp</dimen>
+ <dimen name="main_button_text_size">20sp</dimen>
+
+ <!-- StopWatch Info Panel dimensions -->
+ <dimen name="stopwatch_info_panel_title_text_size">20sp</dimen>
+ <dimen name="stopwatch_info_panel_item_text_size">20sp</dimen>
+
+ <!-- CountDown Saved Timers Panel dimensions -->
+ <dimen name="countdown_timers_panel_title_text_size">20sp</dimen>
+
+ <!-- ListView general dimensions -->
+ <dimen name="listview_row_text_size">20sp</dimen>
+</resources>
View
17 res/values-large-land-hdpi/dimen.xml
@@ -0,0 +1,17 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<resources xmlns:android="http://schemas.android.com/apk/res/android">
+ <!-- Timer Clock -->
+ <dimen name="main_timer_clock_text_size">80sp</dimen>
+ <dimen name="small_timer_clock_text_size">24sp</dimen>
+ <dimen name="main_button_text_size">20sp</dimen>
+
+ <!-- StopWatch Info Panel dimensions -->
+ <dimen name="stopwatch_info_panel_title_text_size">20sp</dimen>
+ <dimen name="stopwatch_info_panel_item_text_size">20sp</dimen>
+
+ <!-- CountDown Saved Timers Panel dimensions -->
+ <dimen name="countdown_timers_panel_title_text_size">20sp</dimen>
+
+ <!-- ListView general dimensions -->
+ <dimen name="listview_row_text_size">20sp</dimen>
+</resources>
View
31 res/values-sw600dp-land/dimens.xml
@@ -3,16 +3,16 @@
/*
** Copyright 2011, The Android Open Source 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
+** 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
+** 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
+** 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.
*/
-->
@@ -30,4 +30,19 @@
<dimen name="ampm_margin_top">28dip</dimen>
<dimen name="font_margin_adjust">8dip</dimen>
<dimen name="next_alarm_margin_top">-5dip</dimen>
+
+ <!-- Timer Clock -->
+ <dimen name="main_timer_clock_text_size">100sp</dimen>
+ <dimen name="small_timer_clock_text_size">24sp</dimen>
+ <dimen name="main_button_text_size">20sp</dimen>
+
+ <!-- StopWatch Info Panel dimensions -->
+ <dimen name="stopwatch_info_panel_title_text_size">20sp</dimen>
+ <dimen name="stopwatch_info_panel_item_text_size">20sp</dimen>
+
+ <!-- CountDown Saved Timers Panel dimensions -->
+ <dimen name="countdown_timers_panel_title_text_size">20sp</dimen>
+
+ <!-- ListView general dimensions -->
+ <dimen name="listview_row_text_size">20sp</dimen>
</resources>
View
31 res/values-sw600dp/dimens.xml
@@ -3,16 +3,16 @@
/*
** Copyright 2011, The Android Open Source 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
+** 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
+** 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
+** 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.
*/
-->
@@ -31,4 +31,19 @@
<dimen name="font_margin_adjust">8dip</dimen>
<dimen name="next_alarm_margin_top">-5dip</dimen>
<dimen name="alarm_label_padding">64dip</dimen>
+
+ <!-- Timer Clock -->
+ <dimen name="main_timer_clock_text_size">120sp</dimen>
+ <dimen name="small_timer_clock_text_size">24sp</dimen>
+ <dimen name="main_button_text_size">20sp</dimen>
+
+ <!-- StopWatch Info Panel dimensions -->
+ <dimen name="stopwatch_info_panel_title_text_size">20sp</dimen>
+ <dimen name="stopwatch_info_panel_item_text_size">20sp</dimen>
+
+ <!-- CountDown Saved Timers Panel dimensions -->
+ <dimen name="countdown_timers_panel_title_text_size">20sp</dimen>
+
+ <!-- ListView general dimensions -->
+ <dimen name="listview_row_text_size">20sp</dimen>
</resources>
View
17 res/values-sw720dp-land/dimen.xml
@@ -0,0 +1,17 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<resources xmlns:android="http://schemas.android.com/apk/res/android">
+ <!-- Timer Clock -->
+ <dimen name="main_timer_clock_text_size">120sp</dimen>
+ <dimen name="small_timer_clock_text_size">30sp</dimen>
+ <dimen name="main_button_text_size">28sp</dimen>
+
+ <!-- StopWatch Info Panel dimensions -->
+ <dimen name="stopwatch_info_panel_title_text_size">26sp</dimen>
+ <dimen name="stopwatch_info_panel_item_text_size">26sp</dimen>
+
+ <!-- CountDown Saved Timers Panel dimensions -->
+ <dimen name="countdown_timers_panel_title_text_size">26sp</dimen>
+
+ <!-- ListView general dimensions -->
+ <dimen name="listview_row_text_size">26sp</dimen>
+</resources>
View
17 res/values-sw720dp/dimen.xml
@@ -0,0 +1,17 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<resources xmlns:android="http://schemas.android.com/apk/res/android">
+ <!-- Timer Clock -->
+ <dimen name="main_timer_clock_text_size">160sp</dimen>
+ <dimen name="small_timer_clock_text_size">32sp</dimen>
+ <dimen name="main_button_text_size">36sp</dimen>
+
+ <!-- StopWatch Info Panel dimensions -->
+ <dimen name="stopwatch_info_panel_title_text_size">26sp</dimen>
+ <dimen name="stopwatch_info_panel_item_text_size">26sp</dimen>
+
+ <!-- CountDown Saved Timers Panel dimensions -->
+ <dimen name="countdown_timers_panel_title_text_size">26sp</dimen>
+
+ <!-- ListView general dimensions -->
+ <dimen name="listview_row_text_size">26sp</dimen>
+</resources>
View
63 res/values/arrays.xml
@@ -1,15 +1,48 @@
-<?xml version="1.0" encoding="utf-8"?>
-<resources>
- <string-array name="aokp_clock_backgrounds_drawable" translatable="false">
- <item>appwidget_aokp_blue_clock_dial</item>
- <item>appwidget_aokp_pink_clock_dial</item>
- <item>appwidget_aokp_white_clock_dial</item>
- <item>appwidget_aokp_full_clock_dial</item>
- <item>appwidget_aokp_blue_light_clock_dial</item>
- <item>appwidget_aokp_letters_clock_dial</item>
- <item>appwidget_aokp_blue_letters_clock_dial</item>
- <item>appwidget_aokp_blue_letters2_clock_dial</item>
- <item>appwidget_aokp_big_blue_unicorn_clock_dial</item>
- <item>appwidget_aokp_jelly_clock_dial</item>
- </string-array>
-</resources>
+<?xml version="1.0" encoding="utf-8"?>
+<resources>