[Development] Proposal: change QML Flickable's flickableDirection default value to AutoFlickIfNeeded in 5.8
Andrea Bernabei
and.bernabei at gmail.com
Tue Jul 26 16:12:08 CEST 2016
Hello everyone,
I'd like to propose changing the default value of QML Flickable's
flickableDirection in Qt 5.8.
The current default value is Flickable.AutoFlickDirection
The description is: it "allows flicking vertically if the *contentHeight*
is not equal to the *height* of the Flickable. Allows flicking horizontally
if the *contentWidth* is not equal to the *width* of the Flickable."
It seems to me like the current default was chosen to make it so that the
surface is always draggable except for things like vertical ListViews
(where contentWidth==width, or the same for height in the case of
horizontal lists).
I propose we should change the default value to Flickable.AutoFlickIfNeeded
(added by Shawn, Flickable's maintainer, in 5.7
https://codereview.qt-project.org/#/c/150388/ ).
I'll try using bullet points to avoid a wall of text.
Proposal:
Change default Flickable's flickableDirection to AutoFlickIfNeeded in
Qt5.8, and only available when importing QtQuick >= 2.8
Why:
The current behaviour is a bit confusing. If we only take the horizontal
dimension into account:
- content narrower than Flickable --> content IS draggable (why?)
- content same size as Flickable --> content NOT draggable
- content wider than Flickable --> content IS draggable
While with the proposed change:
- content narrower than Flickable --> content NOT draggable
- content same size as Flickable --> content NOT draggable
- content wider than Flickable --> content IS draggable
I believe the new behaviour is better, the content is only draggable when
dragging "makes sense", i.e. when dragging would reveal additional content
that would otherwise be hidden.
What do you guys think?
Cheers,
Andrea (faenil)
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.qt-project.org/pipermail/development/attachments/20160726/891b7c4d/attachment.html>
More information about the Development
mailing list