1. 02 Dec, 2015 1 commit
    • James Lemieux's avatar
      Fix alarm query · 0b3f6a4e
      James Lemieux authored
      Bug: 25895834
      
      ag/811037 left a bug in place that this change addresses.
      
      Specifically, if a one-time alarm is missed, an entry is left in
      the alarm_instances table with a state of MISSED. The query's
      join clause would not return a row for the alarm in this case.
      
      A subselect is now used to return the alarm_instances row with
      the smallest state value. This means:
      
       - SILENT instances are preferred over MISSED instances
       (the only case where 2 instances exist for the same alarm).
       - MISSED instances are returned if they are the only instance for
       an alarm (the above case)
      
      Change-Id: I31de6d8b2d2bf7719f6b027a2401b1da1a09f247
      0b3f6a4e
  2. 01 Dec, 2015 4 commits
  3. 30 Nov, 2015 1 commit
  4. 26 Nov, 2015 1 commit
  5. 25 Nov, 2015 5 commits
  6. 24 Nov, 2015 2 commits
  7. 23 Nov, 2015 4 commits
  8. 21 Nov, 2015 1 commit
    • James Lemieux's avatar
      Update test cases to verify time-change scenario · 8f436750
      James Lemieux authored
      Bug: 25302368
      
      The bug was already fixed as part of b/19651361 but I wanted to
      add the reported use case to the corpus for better regression
      testing.
      
      Change-Id: I51f80cfbbae01681b018d249de56d0d39b4122d2
      8f436750
  9. 20 Nov, 2015 2 commits
  10. 19 Nov, 2015 3 commits
    • James Lemieux's avatar
      Fix fab disappearing on rotation when no timers exist · 739e1ed7
      James Lemieux authored
      Bug: 25779786
      
      The issue here is that TimerSetupView actually customizes the fab.
      These customizations include setting it invisible. It was a poor design
      to share the fab with this view. So, the fix is that the view now holds
      its own fab-like button that it is free to manipulate without fear of
      altering the app-wide fab state unintentionally.
      
      Change-Id: Ie83b03c98db4f77e0be912b122b6f74c2c7e6c8a
      739e1ed7
    • James Lemieux's avatar
      ad9d3e6d
    • James Lemieux's avatar
      Miscellaneous fixes · 6468db45
      James Lemieux authored
      - add precision to some wording for translators
      - update widget provider XML layout
      
      Change-Id: I78d7d29b2ed2ea4768c0e36d125b38df971c1484
      6468db45
  11. 18 Nov, 2015 2 commits
  12. 17 Nov, 2015 2 commits
    • James Lemieux's avatar
      Avoid jank in the tabs from a cold open · 84006e23
      James Lemieux authored
      Bug: 24977472
      
      By default, the menu is inflated after the first draw. A proactive
      call to Toolbar.inflate(...) during creation defeats this default
      behavior.
      
      A second problem is that the menu that is inflated by default for
      DeskClock contains the search menu item which is briefly shown.
      By defaulting that menu item to be invisible and only making it
      visible when its corresponding controller exists, the
      dancing/flashing effect is avoided.
      
      Change-Id: I933ab9a59b471abe26e1cf07385e4a4c128d1808
      84006e23
    • Justin Klaassen's avatar
      Load TimeZone list in PrefsFragment#onCreate · 557573da
      Justin Klaassen authored
      Bug: 25706729
      Change-Id: Idf41102e733c5056f98ac4873a5b1dde442ffefe
      557573da
  13. 16 Nov, 2015 1 commit
  14. 14 Nov, 2015 1 commit
  15. 13 Nov, 2015 2 commits
  16. 12 Nov, 2015 3 commits
    • James Lemieux's avatar
      Simplify HandleDeskClockApiCalls, TimerService and StopwatchService · 437da3b0
      James Lemieux authored
      HandleDeskClockApiCalls used to pass through all timer and stopwatch
      mutations to the corresponding Service to complete. This complicated
      the logging of the corresponding event unnecessarily.
      
      After this change:
      
      - StopwatchService is only invoked from stopwatch notifications and may
      now assume the event label
      
      - TimerService is only invoked from timer notifications and AlarmManager
      and may now assume the event label
      
      - HandleDeskClockApiCalls.EXTRA_FROM_NOTIFICATION has been replaced
      with HandleDeskClockApiCalls.EXTRA_EVENT_LABEL which explicitly
      identifies the label of the event
      
      Change-Id: Ic9796c43e826f82138ee431d3abb02524c0146ba
      437da3b0
    • Justin Klaassen's avatar
      Fallback to internal alarm ringtone if necessary · cbb9333b
      Justin Klaassen authored
      Bug: 25177293
      
      If the default system alarm ringtone is invalid or malformed then
      RingtoneManager will return a null Ringtone. In which case we now
      fallback to playing our own internal alarm ringtone.
      
      Change-Id: I1beeec0fc8998ad684e67062ffc0fd0d03f66f68
      cbb9333b
    • James Lemieux's avatar
      Fix mandatory timer creation screen · e100e102
      James Lemieux authored
      Change-Id: Ibe429ba988a8842715c8732b4524eefb2655f7e4
      e100e102
  17. 11 Nov, 2015 4 commits
    • James Lemieux's avatar
      Fix Alarm query · e2b8d1cb
      James Lemieux authored
      Bug: 25630846
      
      Change-Id: I3a7566f6ef2c20ceb487e864fde0f0d12582f8cc
      e2b8d1cb
    • James Lemieux's avatar
    • James Lemieux's avatar
      Refactor Timers to use new unified DataModel · 6d603b7c
      James Lemieux authored
      Bug: 24816218
      Bug: 25494722
      
      This refactoring introduces a Timer domain object. Instances of these
      domain objects are fetched via a DataModel class that is the single point
      of reference for all timer data. This allows the data to be shared across
      the entire application. In particular, the timer notifications, TimerFragment
      and ExpiredTimersActivity all draw upon the same model to determine
      what the state of the timers are.
      
      IMPORTANT: The public intent com.android.deskclock.action.STOP_TIMER
      has been renamed to com.android.deskclock.action.PAUSE_TIMER to be
      more accurate.
      
      Change-Id: Ib904e80a25c6de1861de2b395bec27db16ff0e66
      6d603b7c
    • James Lemieux's avatar
      Shorten clock tab animation · c61f219a
      James Lemieux authored
      Bug: 25631044
      
      The clock tab animation was noticeably longer than the other
      tab animations. Some rotations were removed to shorten its
      duration. Also, animated vectors are v22+, so the resource files
      were moved into /animator-v22 to fix some lint warnings.
      
      Change-Id: I90b116df2a3cc7a30bdd69b8e478207dd3f016fb
      c61f219a
  18. 10 Nov, 2015 1 commit
    • James Lemieux's avatar
      Avoid displaying two copies of the same alarm · bb0e88de
      James Lemieux authored
      Bug: 17903090
      
      When an alarm is missed the alarm_instances table actually contains two
      entries for the same alarm.
      
      - one represents the missed alarm
      - one represents the next upcoming alarm
      
      The query that joins alarm_templates to alarm_instances would return
      two rows for the same alarm in this case. Since the alarm_instance data
      is used offer a predismiss button in the UI, it is fine to ignore the
      missed alarm in this join.
      
      Change-Id: I720e48c9274b42d3cda9d57d3eef099c5dcd3902
      bb0e88de