md toolbar button ripples should appear on spacebar down |
||||||
Issue descriptionIn pre-md, when you pressed space, the button would look pressed, and when you released space, it would activate. Assuming we want to keep this general behavior, we should show a ripple on space down in MD (currently there's no visible feedback until you release the spacebar).
,
May 4 2016
,
May 4 2016
When do toolbar buttons get focus in order to actually get keyboard events? I found this comment in custom_button.h: // A button with custom rendering. The base of ImageButton and LabelButton. // Note that this type of button is not focusable by default and will not be // part of the focus chain. Call SetFocusBehavior(FocusBehavior::ALWAYS) to // make it part of the focus chain.
,
May 4 2016
Pressing <alt> + <shift> + 't' will focus the Toolbar buttons.
,
May 13 2016
This appears to be working now. I'm seeing the ripple feedback in MD mode on pressing the spacebar.
,
May 13 2016
you're seeing a ripple before release the space key?
,
May 13 2016
It's odd. I see the ripples on the button to the right of the omnibar, but not the refresh button... so it's not consistent or universal to all of the buttons.
,
May 13 2016
Upon further examination, the ripples do appear on release.. if the timing is right. Also, the ripples are much larger for the back/forward/refresh buttons than the app/extension/menu buttons on the right.
,
May 13 2016
The navigation button actions are triggered on space-release whereas the extension button actions are triggered on space-down. I believe the ACTION_TRIGGERED ripple animation is triggered when the button action is triggered, thus you will see the ripple on space-down for extension buttons but not for the navigation buttons. This issue is tracking the work to show the ripple on space-down for space-up triggered buttons.
,
May 13 2016
Ok, that's why I didn't initially notice it. I assumed (yeah, I know ;-), that the extension buttons shared the same implementation as the navigation buttons. To make this work then, the ripple trigger will need to be tied to a specific action applied to the button and not the resulting event trigger.
,
May 13 2016
with regards to the discrepancy between nav and extension buttons, see also https://codereview.chromium.org/1886943002 https://codereview.chromium.org/1947533003 Note in particular my comment "We'd also need to update browser action buttons to key up, but that can be a TODO." > This issue is tracking the work to show the ripple on space-down for space-up triggered buttons. correct
,
May 14 2016
Marking to started for kylixrd@. Review: https://codereview.chromium.org/1977793006/
,
May 16 2016
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/bc4847d61fd0da6cd297f60311d9d7c58f391c75 commit bc4847d61fd0da6cd297f60311d9d7c58f391c75 Author: kylixrd <kylixrd@chromium.org> Date: Mon May 16 19:50:40 2016 In MD mode, pressing spacebar on toolbar buttons triggers the ripple effect. It will remain in that state unti the key is released BUG= 608996 Review-Url: https://codereview.chromium.org/1977793006 Cr-Commit-Position: refs/heads/master@{#393907} [modify] https://crrev.com/bc4847d61fd0da6cd297f60311d9d7c58f391c75/ui/views/animation/button_ink_drop_delegate.cc [modify] https://crrev.com/bc4847d61fd0da6cd297f60311d9d7c58f391c75/ui/views/animation/button_ink_drop_delegate.h [modify] https://crrev.com/bc4847d61fd0da6cd297f60311d9d7c58f391c75/ui/views/animation/ink_drop_delegate.h [modify] https://crrev.com/bc4847d61fd0da6cd297f60311d9d7c58f391c75/ui/views/animation/test/test_ink_drop_delegate.cc [modify] https://crrev.com/bc4847d61fd0da6cd297f60311d9d7c58f391c75/ui/views/animation/test/test_ink_drop_delegate.h [modify] https://crrev.com/bc4847d61fd0da6cd297f60311d9d7c58f391c75/ui/views/controls/button/custom_button.cc [modify] https://crrev.com/bc4847d61fd0da6cd297f60311d9d7c58f391c75/ui/views/controls/button/custom_button_unittest.cc [modify] https://crrev.com/bc4847d61fd0da6cd297f60311d9d7c58f391c75/ui/views/controls/button/menu_button_unittest.cc
,
May 16 2016
,
Jun 3 2016
|
||||||
►
Sign in to add a comment |
||||||
Comment 1 by pkasting@chromium.org
, May 4 2016Labels: -Pri-2 Pri-3