simonpoole / OpeningHoursFragment

Android UI element for displaying and editing an opening hours value
MIT License
9 stars 2 forks source link

Show time picker on click #36

Closed simonpoole closed 5 years ago

simonpoole commented 5 years ago

Showing the time picker on clicking the bar should make it faster for people that don't want to, or can't use the bar directly.

simonpoole commented 5 years ago

@ltog this should interest you too, see https://twitter.com/vespucci_editor/status/1126452377907863552

ltog commented 5 years ago

@simonpoole : Here's some feedback:

  1. Thank you for implementing my feature request from https://github.com/simonpoole/OpeningHoursFragment/issues/34 . I saw it only just now.

  2. Also in https://github.com/simonpoole/OpeningHoursFragment/issues/34 I suggested to have a method to still allow for small minute values if that should be necessary. Since that doesn't seem to be implemented yet, I tried the following: Putting the cursor in the raw data field (while still being in the opening hours GUI) and editing the opening hours by hand. That didn't work well: After deleting a character the cursor jumps to the right-hand side of the raw value. Therefore you can't change e.g. a "17.30" to a "17.35" by deleting the 0 and inserting the 5, since after deleting 0, the cursor jumps.

  3. I was able to provoke a crash: Choose "Weekdays with lunch break and late ..." --> In rule 1 change time by clicking on the timebar that goes from 9 to 12 (timepicker will open) --> change end date to 47:00 -> drag the "upside down drop" icon showing "23:00" to the right-hand side, so that it will show "24:00". Swipe downwards (maybe multiple times) as you would do in order to see the top of the page (although in fact it's already on top) --> Boom! (Sidenote: Even if this was fixed, there is still an inconsistency: Using the "upside down drop" icon allows to choose a value of 24/48 hours, while using the time picker GUI only allows to choose 23/47 hours. It seems to be quite a corner case but I'm sure the opening hours specification is explicit about what is allowed here. Both methods should behave identical on what is possible.

simonpoole commented 5 years ago

WRT

2) you can switch the tick granularity in the menu, just as for the time bar, changing it in the menu is a bit messy, but I might add that.

3) that is the time picker crashing (no need to swipe) because it doesn't expect 48 hours plus, the specification is not quite clear on what the max. extended time is, is it 48:00 or 48:59. The evaluator from ypid stops at 48:00.