- From: Zachary “Gamer_Z.” Yaro <zmyaro@gmail.com>
- Date: Sat, 17 Nov 2012 14:57:34 -0500
- To: Wes Johnston <wjohnston@mozilla.com>
- Cc: www-style@w3.org
- Message-ID: <CANFzyvJUkuZ2HY+VEoTbcN8OZhbLYSuAuzykNo-EzwJ0YYJu-w@mail.gmail.com>
If I may ask, are there a lot of cases where this would be better than just having touch browsers display the :active state for touched elements? —Zachary “Gamer_Z.” Yaro On Nov 17, 2012 12:18 PM, "Wes Johnston" <wjohnston@mozilla.com> wrote: > It would be nice when interacting with web pages in touch or pen based > environments if there were easy ways to style objects based on whether they > are currently being touched or perhaps if they were touched in the last > touch session on the screen. I'd like to propose two potential selectors > for these situations: > > 1.) :touching for when an element is actively being touched on the screen. > Unlike targets in the touchevents spec, this should actively change as the > user moves their finger on the screen. As soon as a user lifts their finger > from the screen these selectors would no longer match. One potential use > case for this is something like an onscreen keyboard where you want the > keys to light up as the user drags their finger on the keyboard. This could > also be helpful as a means of providing quick feedback about what is being > touched on screen (i.e. tap highlights). > > 2.) :touched to match the elements that are actively being touched, or > elements that were being touched the last time a finger was on the screen. > The use case I want to address here are things like drop down menus, where > you would likely want them to remain visible on screen even after the users > finger has been lifted, but to disappear if the user touches outside the > menu. The selector should be removed as soon as another touch starts, ends > or moves on the document (i.e. if two fingers are on the screen and one is > lifted, the selector should match until the second finger moves or another > finger touches the document). > > In both cases, the selectors should stop matching if the system starts > performing any system actions on the page (such as scrolling). > > Apologies if I'm doing something incorrectly here. Its my first email to a > working group. > > Thoughts? > - Wes > >
Received on Saturday, 17 November 2012 19:58:02 UTC