aboutsummaryrefslogtreecommitdiffstats
path: root/src/imports/controls/qtquickcontrols2plugin.cpp
Commit message (Collapse)AuthorAgeFilesLines
* Refactor QQuickStyleSelectorJ-P Nurmi2018-03-131-1/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Instead of trying to determine a single base URL based on the import URI of the plugin, and whether built in static mode, provide a list of paths where to lookup styles, in priority order: - requested style path (-style /path/to/style) - QT_QUICK_CONTROLS_STYLE_PATH environment variable - QT_INSTALL_QML/QtQuick/Controls.2/ - qrc://qt-project.org/imports/QtQuick/Controls.2/ Furthermore, provide the requested style name and the fallback style name as a simple list of selectors. The lookup order is: 1) requested style 2) fallback style 3) default style As a result, QQuickStyleSelector implementation is a lot simpler, completely independent of QQuickStyle, and the style lookup works regardless of whether the files are in QRC or on the file system. This allows us to utilize QRC and the Qt Quick Compiler in the future. Note: two data rows in tst_QQuickStyleSelector::select_data() had to be fixed. Not sure how the expected values ended up like that, but as the comments say, "Label.qml exists in the default and fallback styles" and "Button.qml exists in all styles", so it makes no sense to expect that Label.qml or Button.qml is selected from the FallbackStyle when a valid "data" folder is specified. Change-Id: I18dea9fddf8f079e0140b51b567814da0df2802c Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
* Merge remote-tracking branch 'origin/5.11' into devJ-P Nurmi2018-02-211-0/+7
|\ | | | | | | Change-Id: I6cc3095673bb459acef93e3da8a67c3819b70d3a
| * Reset QQuickStyle when the QtQuick.Controls 2 plugin is unloadedJ-P Nurmi2018-02-201-0/+7
| | | | | | | | | | | | | | | | | | Cleanup global static data in QQuickStyle when the controls plugin is unloaded (qmlClearTypeRegistrations()). This ensures that the style is resolved as appropriate when the controls plugin is reloaded. Change-Id: Icebb835e057e6063e4fc0ca035c6836560bc7c14 Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
* | Merge remote-tracking branch 'origin/5.11' into devJ-P Nurmi2018-02-151-22/+10
|\| | | | | | | Change-Id: Id3333e9bb67ced4c6dbae5845512fe1927a7b858
| * Fix memory leak in QQC2Simon Hausmann2018-02-071-22/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When repeatedly creating a QQuickView, loading a QML file that imports QQC2 and deleting the view again, we would leak memory that was allocated as a consequence of QML type registration in initializeEngine() callbacks that were called on every iteration. After the limitation of namespacing in the registerTypes() callback of QML module plugins has been lifted, we can move the type registrations into registerTypes() where they belong and which is called only once. Change-Id: I7e314663a69fd8c8529195b56c128b61392c0042 Reviewed-by: J-P Nurmi <jpnurmi@qt.io> Reviewed-by: Mitch Curtis <mitch.curtis@qt.io> Reviewed-by: Michael Winkelmann <michael.winkelmann@qt.io>
* | Read :/qtquickcontrols2.conf in QQuickStylePluginJ-P Nurmi2018-02-151-3/+3
|/ | | | | | | | | | | | | | | | | QQuickTheme is going to be promoted from libQQC2 to libQQT2 so that it can provide dark and light palettes (and later, icons). The first step is to refactor out the :/qtquickcontrols2.conf reading code, which cannot be in style-agnostic libQQT2. Read the conf file in QQuickStyle Plugin instead. The additional benefit is that we don't need duplicate name() methods for styles and their themes. Even though QQuickStyle Plugin's name handling is case-insensitive, QSetting is case-sensitive. Therefore all QQuickStylePlugin::name() overrides have been updated to use capital first letter. This name is used to lookup the correct section in :/qtquickcontrols2.conf. Task-number: QTBUG-63331 Change-Id: I07b1269d9dbc2c9568e6f22f2da75951fde7b669 Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
* Merge remote-tracking branch 'origin/5.9' into 5.10J-P Nurmi2018-01-101-1/+11
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: src/imports/controls/BusyIndicator.qml src/imports/controls/CheckBox.qml src/imports/controls/CheckDelegate.qml src/imports/controls/ComboBox.qml src/imports/controls/DelayButton.qml src/imports/controls/Dial.qml src/imports/controls/ItemDelegate.qml src/imports/controls/MenuItem.qml src/imports/controls/RadioButton.qml src/imports/controls/RadioDelegate.qml src/imports/controls/SwipeDelegate.qml src/imports/controls/Switch.qml src/imports/controls/SwitchDelegate.qml src/imports/controls/doc/src/qtquickcontrols2-configuration.qdoc src/imports/controls/material/CheckDelegate.qml src/imports/controls/material/ItemDelegate.qml src/imports/controls/material/MenuItem.qml src/imports/controls/material/RadioDelegate.qml src/imports/controls/material/SwipeDelegate.qml src/imports/controls/material/SwitchDelegate.qml src/imports/controls/qquickdefaultbusyindicator.cpp src/imports/controls/qquickdefaultbusyindicator_p.h src/imports/controls/qtquickcontrols2plugin.cpp src/imports/controls/universal/CheckDelegate.qml src/imports/controls/universal/ItemDelegate.qml src/imports/controls/universal/MenuItem.qml src/imports/controls/universal/RadioDelegate.qml src/imports/controls/universal/SwipeDelegate.qml src/imports/controls/universal/SwitchDelegate.qml src/quickcontrols2/quickcontrols2.pri src/quicktemplates2/qquickcontrol.cpp src/quicktemplates2/qquickmenu.cpp src/quicktemplates2/qquickpopup_p.h Change-Id: Ib25c8b4a7fe018b7c0ade9b02bfaaa6980118c15
| * Default: eliminate internal IDs in DelayButtonJ-P Nurmi2017-12-211-0/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | An ID in the internal Text element prevented deferred execution for the whole content item. The ID was used for two reasons. First of all, it was used to propagate implicit size from the Text element to the root of the content item. Secondly, it was used to calculate clip areas to provide the same text in two different colors. This patch provides two internal C++ helpers, ItemGroup and ClippedText, that provide these functionalities without the need of using IDs in QML. At the same time we got rid of two wrapper Items and simplified some QML bindings, which results to a nice boost (18->22) in qmlbench on TX1. Task-number: QTBUG-65341 Change-Id: Icf9c09356cf5c0ed641bde537bee7291bd260057 Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
| * Make QtQuick.Controls::ButtonGroup a composite typeJ-P Nurmi2017-06-081-4/+1
| | | | | | | | | | | | | | | | | | | | | | This is a backport (only the ButtonGroup part) of 1af7f8a59, which was already pushed to dev. The main motivator for the original patch was to cleanup the registration code, but this fixes also an issue with auto- completion in Qt Creator. Task-number: QTCREATORBUG-18321 Change-Id: I5e8e8122cb94c74f78445cce1a89f604634149b1 Reviewed-by: Marco Benelli <marco.benelli@qt.io>
* | Visualize mnemonicsJ-P Nurmi2017-11-021-0/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Unfortunately this comes a bit late in the 5.10 cycle, but this should be released together with the rest of the mnemonics stuff going out in 5.10, because it affects the value of AbstractButton/Menu(Bar)Item::text. As the removed TODO comments and altered tests indicate, previously the ampersand was blatantly stripped out. It would be worse to change it later once people have already started using mnemonics and rely on the behavior in custom styles. The necessary modifications to QQuickText were added in qtdeclarative commit 65ef4ba. Task-number: QTBUG-61422 Change-Id: Iaa73da8c012e9a6019743cf98f5bdc02527064e5 Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
* | Default: merge SwitchIndicator back to Switch & SwitchDelegateJ-P Nurmi2017-11-021-1/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | See the previous commit (CheckIndicator) for more details. Before: running: /home/jpnurmi/Projects/qmlbench/benchmarks/auto/creation/quick.controls2/delegates_switch.qml [...] Average: 87.8 frames; using samples; MedianAll=87; StdDev=2.16795, CoV=0.0246919 After: running: qmlbench/benchmarks/auto/creation/quick.controls2/delegates_switch.qml [...] Average: 92.6 frames; using samples; MedianAll=92; StdDev=2.19089, CoV=0.0236597 Change-Id: Iea9e88e4e771ac27d336c2c87232704d33a226ec Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
* | Default: merge RadioIndicator back to RadioButton & RadioDelegateJ-P Nurmi2017-11-021-1/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | See the previous commit (CheckIndicator) for more details. Before: running: qmlbench/benchmarks/auto/creation/quick.controls2/delegates_radiobutton.qml [...] Average: 91.6 frames; using samples; MedianAll=91; StdDev=1.51658, CoV=0.0165565 After: running: qmlbench/benchmarks/auto/creation/quick.controls2/delegates_radiobutton.qml [...] Average: 95.8 frames; using samples; MedianAll=96; StdDev=2.04939, CoV=0.0213924 Change-Id: Ic185241767d0b9422e86919356e3155e00803e56 Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
* | Default: merge CheckIndicator back to CheckBox & CheckDelegateJ-P Nurmi2017-11-021-1/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The internal CheckIndicator helper was introduced together with CheckDelegate in 1acb34a, because we naturally wanted to share the indicator instead of duplicating it. This change is controversial, because it leads to duplicate code, but keeping the indicator definitions inline is clearly faster. This is not seen as a huge problem for the Default style, because the indicator is not too complicated. Basically, this fixes a ~5% performance regression introduced by 1acb34a. Before: running: qmlbench/benchmarks/auto/creation/quick.controls2/delegates_checkbox.qml [...] Average: 72.8 frames; using samples; MedianAll=73; StdDev=1.48324, CoV=0.0203742 After: running: qmlbench/benchmarks/auto/creation/quick.controls2/delegates_checkbox.qml [...] Average: 77 frames; using samples; MedianAll=77; StdDev=1.41421, CoV=0.0183664 Change-Id: Ibee0e29e83a64ee4a6a772a90b1784a9c8c715bb Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
* | Optimize CheckBox, Switch, and RadioButtonJ-P Nurmi2017-11-021-0/+3
| | | | | | | | | | | | | | | | | | | | Add an internal CheckLabel helper that simply initializes a few QQuickText properties with defaults that are suitable for CheckBox, Switch, and RadioButton. This gives a 10% boost on desktop in debug mode, and a 5% boost on a TX1 in release mode. Change-Id: I82fead9ca22b6aa74f24924d240c924b2a42a912 Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
* | Introduce MenuBarJ-P Nurmi2017-07-261-0/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | MenuBar is an ordinary Item. It can be located basically anywhere, but the idea is to introduce a new ApplicationWindow::menuBar property in a follow-up commit. Currently the example snippets are using the header property. [ChangeLog][Controls][MenuBar] Introduced a MenuBar control. Task-number: QTBUG-60350 Change-Id: Ie66dc457a3d8edbe8362fab2a591dc49442c95e2 Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org> Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
* | Add Overlay attached properties and signalsJ-P Nurmi2017-06-261-0/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | [ChangeLog][Controls][ApplicationWindow] Deprecated the overlay grouped property in favor of the newly introduced Overlay attached properties. [ChangeLog][Controls][Overlay] Introduced Overlay attached properties and signals that supersede the overlay grouped property in Application Window. The Overlay attached type allows providing background dimming for popups without requiring an ApplicationWindow instance. Task-number: QTBUG-61336 Change-Id: I9df11bcb167e7725014d5f058fe24d70da4a10b3 Reviewed-by: Topi Reiniƶ <topi.reinio@qt.io> Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
* | Expose PaddedRectangle in QtQuick.Controls.impl 2.0J-P Nurmi2017-06-121-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | PaddedRectangle was moved from QtQuick.Controls.Material.impl 2.0 to QtQuick.Controls.impl 2.3 in 8290b876b. It seems that the qhours app is using the PaddedRectangle for a custom SpinBox. Importing 2.3 would make Qt 5.10 a hard requirement, so registering PaddedRectangle to QtQuick.Controls.impl 2.0 allows us to fix qhours so that it still works with Qt 5.9 and earlier. It's an internal type, and technically it already was there since 2.0, so this shouldn't matter much. Change-Id: Ie959dc150356fd5624e899eac9e52ca5a183ffe5 Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
* | Add .qml files for the non-visual typesJ-P Nurmi2017-06-021-11/+3
| | | | | | | | | | | | | | | | | | | | | | This makes the registration code in qtquickcontrols2plugin.cpp clean, consistent, and a bit less error-prone. I can't think of anything style specific in Action, ActionGroup, or ButtonGroup, but in theory, this mechanism would allow styles to even specify their own default values for certain properties if they wanted. Change-Id: I57e1c256d442f2383146808d0fe77355717b0ff2 Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
* | Add QQuickDefaultThemeJ-P Nurmi2017-05-291-1/+15
| | | | | | | | | | | | | | | | | | The Default style will be changed to use palettes, and it will be also possible to define the default fonts and palettes for any style in the qqc2.conf file, so the Default style needs its own proxy theme. Change-Id: I0262f7a1f783daa62ca4afbdf3c8fe29d989ca36 Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
* | Plugins: add missing override keywordsJ-P Nurmi2017-05-161-2/+2
| | | | | | | | | | Change-Id: Ic43604fdb601769e93618cac30d839cc524f1394 Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
* | Give all styles access to PaddedRectangleJ-P Nurmi2017-05-121-0/+2
| | | | | | | | | | | | | | Promote it from QtQuick.Controls.Material.impl to QtQuick.Controls.impl. Change-Id: I8260ee85b633544f9e76f6419f8aa26b03c500c6 Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
* | Default: rename QQuickDialRing to QQuickDefaultDialJ-P Nurmi2017-05-121-2/+2
| | | | | | | | | | | | | | | | This is consistent with the other existing internal Default style visuals QQuickDefaultBusyIndicator and QQuickDefaultProgressBar. Change-Id: I3a84edfdd6fb8bbd8a040c633c5b6411dd5350d8 Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
* | Make QQuickIcon a value typeJ-P Nurmi2017-05-101-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | QQuickIcon no longer inherits QObject, but becomes a light-weight implicitly shared Q_GADGET-type, that is passed by value the same way fonts and colors are. Before: SUB: OS: Fedora 25 (Workstation Edition) SUB: QPA: xcb SUB: GL_VENDOR: Intel Open Source Technology Center SUB: GL_RENDERER: Mesa DRI Intel(R) Haswell Desktop SUB: GL_VERSION: 3.0 Mesa 13.0.4 SUB: running: benchmarks/auto/creation/controls/delegates_buttoncontrol2.qml SUB: 110 frames SUB: 109 frames SUB: 109 frames SUB: 109 frames SUB: 109 frames SUB: Average: SUB: 109.2 frames; using samples; MedianAll=109; StdDev=0.447214, CoV=0.00409536 After: [...] SUB: running: benchmarks/auto/creation/controls/delegates_buttoncontrol2.qml SUB: 123 frames SUB: 124 frames SUB: 124 frames SUB: 122 frames SUB: 125 frames SUB: Average: SUB: 123.6 frames; using samples; MedianAll=124; StdDev=1.14018, CoV=0.00922472 Change-Id: I604532204fb94fc0726d0c9b8b6097f9ebc265e8 Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
* | Add ButtonGroup::exclusiveJ-P Nurmi2017-04-281-0/+1
| | | | | | | | | | | | | | | | [ChangeLog][Controls][ButtonGroup] Added exclusive property to allow creating non-exclusive button groups. Change-Id: Ic2f3f4bac852f03e5c25f9010993d62234a71e0b Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
* | Add ActionGroupJ-P Nurmi2017-04-191-0/+2
| | | | | | | | | | | | | | | | | | [ChangeLog][Controls][ActionGroup] Introduced ActionGroup, a non-visual group of actions that is mutually exclusive by default. Task-number: QTBUG-50705 Change-Id: Ia33103173441ca8980341b7c94aba0db3264284d Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
* | Replace QQuickColorImageProvider with QQuickColorImageJ-P Nurmi2017-04-181-4/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Now that QQuickImage is exported, we can colorize images using a simple QQuickImage subclass instead of using an image provider. The main issue with QQuickColorImageProvider was that it was based on QGuiApplication::devicePixelRatio(). Now each QQuickColorImage handles its device pixel ratio correctly depending on which screen it is on. Even though we now have to use two bindings (color and source) instead of encoding the color to the source, at the same time we can remove the sourceSize bindings that were added as image provider specific high DPI workarounds (ca87ab8). Task-number: QTBUG-58925 Change-Id: Iba14d2afe3bda540189682ba5be7c58d907d88f7 Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
* | Add ActionJ-P Nurmi2017-04-101-0/+2
| | | | | | | | | | | | | | | | | | [ChangeLog][Controls][Action] Introduced Action, an abstract user interface action that can have shortcuts and be assigned to buttons. Task-number: QTBUG-50705 Change-Id: I1986cc7ed13cdf428d51ae38cd196a20493fde8b Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
* | Rename QQuickDisplayLayout to QQuickIconLabelMitch Curtis2017-04-071-2/+2
| | | | | | | | | | | | | | | | There are some performance improvements planned that require changes to the class, resulting in it no longer being a layout "container". Change-Id: Ie29f2f95eebb64b3b018746f93763fdbe79625f0 Reviewed-by: J-P Nurmi <jpnurmi@qt.io>
* | AbstractButton: add support for iconsMitch Curtis2017-03-241-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch adds the following properties to AbstractButton: - icon.name - icon.source - icon.width - icon.height - icon.color Derived types implement the behavior behind these properties using the new private IconImage type. [ChangeLog][Controls][AbstractButton] Added support for icons. The following properties are now available for derived types to use: icon.name, icon.source, icon.width, icon.height, icon.color. Task-number: QTBUG-49820 Change-Id: I3b5e4eaac390543deef60883e13539646a6bb060 Reviewed-by: J-P Nurmi <jpnurmi@qt.io>
* | Add QQuickDisplayLayoutMitch Curtis2017-03-171-0/+2
| | | | | | | | | | | | | | | | | | This class lays out an icon and text in various configurations, depending on the display property. Task-number: QTBUG-49820 Change-Id: I2ace443e6cb134a1032b0b79378abd2179916133 Reviewed-by: J-P Nurmi <jpnurmi@qt.io>
* | Add private Color singletonMitch Curtis2017-03-161-1/+9
| | | | | | | | | | | | | | This will be used by various styles. Change-Id: I50b22c1fab04e7fd8fb1fe0b74630c721b6f8c6f Reviewed-by: J-P Nurmi <jpnurmi@qt.io>
* | Add IconImageJ-P Nurmi2017-03-081-0/+4
| | | | | | | | | | | | | | | | This adds an internal helper item that will be used for showing icons on various controls (in follow-up commits). Change-Id: I792b423737023ba663211371f82fedb2b92857bb Reviewed-by: J-P Nurmi <jpnurmi@qt.io>
* | Merge remote-tracking branch 'origin/5.9' into devLiang Qi2017-03-011-0/+6
|\| | | | | | | Change-Id: Ia4c692552e6573b33b2e0f6b43b2a482a78ad970
| * Tumbler requires ListView and PathViewJ-P Nurmi2017-02-021-0/+6
| | | | | | | | | | Change-Id: Ieb40f536cc5d68fdf13075df2c9b3e09d5077de3 Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
* | Add QQuickIconMitch Curtis2017-02-091-0/+4
|/ | | | | | | | | | This adds the initial API needed to add support for setting icons on buttons, etc., and is also necessary for action support. Follow up commits will add the actual support for icons. Change-Id: I9ab892aa4fe43210e7b18bed3e0ebcec2edb9c91 Reviewed-by: J-P Nurmi <jpnurmi@qt.io>
* Add ScrollViewJ-P Nurmi2017-01-271-0/+1
| | | | | | | | [ChangeLog][Controls][ScrollView] Added ScrollView. Change-Id: I5d68799f0246e04b519bf6a0ec7bc7e5625f50e7 Reviewed-by: Mitch Curtis <mitch.curtis@qt.io> Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
* Merge remote-tracking branch 'origin/5.8' into devJ-P Nurmi2017-01-111-1/+1
|\ | | | | | | Change-Id: If797ac58344b20e8de4379343131c097247ba2f2
| * Welcome to 2017J-P Nurmi2017-01-091-1/+1
| | | | | | | | | | Change-Id: If68cff4efacc7dc5719c8b8e61937e85e9076870 Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
* | Editors: fix placeholder text alignmentJ-P Nurmi2017-01-101-0/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The internal QQuickPlaceholderText creates an "implicit binding" to the editor's horizontalAlignment, meaning that the placeholder respects the editor's horizontal alignment when explicitly set, and otherwise determines the alignment from the placeholder text's visual direction. [ChangeLog][Controls][TextField] Fixed the horizontal alignment of the placeholder text in right-to-left UIs. [ChangeLog][Controls][TextArea] Fixed the horizontal alignment of the placeholder text in right-to-left UIs. Task-number: QTBUG-55999 Change-Id: If1a8596c35c1920874996277520f1c54430c5f69 Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
* | Add DelayButtonJ-P Nurmi2017-01-021-0/+1
| | | | | | | | | | | | | | [ChangeLog][Controls][DelayButton] Added DelayButton. Change-Id: I94820dfb41ba9b90f0a29cda01ac476b54cf3de8 Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
* | qtquickcontrols2plugin.cpp: cleanup the template header includesJ-P Nurmi2016-11-231-5/+1
| | | | | | | | | | | | | | These are no longer needed. Change-Id: If77c09430781b3d71dbf4dfffc2236d120b5ecfc Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
* | Sort out and clarify QML type registrationJ-P Nurmi2016-11-231-7/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | We cannot call qmlRegisterRevision() for our own types, because that will register an unnamed type. In practice, the empty type name occurs as a missing type name in qmlInfo() warnings. I've clarified the type registration comments a bit, about what needs to be registered and where: - templates: new types _and_ new revisions for existing types - controls: _only_ new types For controls, the revisions is determined by the import version in the .qml file, so those must be kept up to date in new releases. Change-Id: I7c76a9d80185fa7e922c419b4ee7361be45c61f5 Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
* | Make sure the appropriate import versions are always availableJ-P Nurmi2016-11-231-1/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | Utilize the newly introduced qmlRegisterModule() to automatically register the import version that matches the Qt version that is used to build the module. Now we can remove the artificial qmlRegisterRevision() calls, which were added just to make certain import versions available, even if there was no such revision. Change-Id: Ic3887c221c69b6cd299853d8d5869b8af7a314ec Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
* | Default: rewrite the indeterminate progress bar animationJ-P Nurmi2016-10-191-3/+2
| | | | | | | | | | | | | | | | Use a simple animated node instead of using the private animator API. Task-number: QTBUG-56601 Change-Id: Id8deb1e6ae48554bfa7b26b333247bf08c27aa09 Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
* | Default: rewrite the busy indicator animationJ-P Nurmi2016-10-181-3/+2
| | | | | | | | | | | | | | | | Use a simple animated node instead of using the private animator API. Task-number: QTBUG-56601 Change-Id: Id420ef6faae0ddfc3a571e9b12be59c0d263fc38 Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
* | Merge remote-tracking branch 'origin/5.8' into devJ-P Nurmi2016-10-061-5/+3
|\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: src/imports/controls/Dial.qml src/imports/controls/RangeSlider.qml src/imports/controls/Slider.qml src/imports/controls/Tumbler.qml src/imports/controls/material/Dial.qml src/imports/controls/material/RangeSlider.qml src/imports/controls/material/Slider.qml src/imports/controls/material/Tumbler.qml src/imports/controls/qtquickcontrols2plugin.cpp src/imports/controls/universal/Dial.qml src/imports/controls/universal/RangeSlider.qml src/imports/controls/universal/Slider.qml src/imports/controls/universal/Tumbler.qml Change-Id: I02b433e66109d90c63fcb9d0e5e304dc9375ea44
| * Remove wrong Container revision registrationJ-P Nurmi2016-10-051-2/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | We register Container.qml for QtQuick.Controls 2.0, so it is important to not override the registration with plain QQuickContainer template revision 1 for QtQuick.Controls 2.1, or else the behavior of Container will be different depending on whether the user imports QtQuick Controls 2.0 or 2.1. The auto test started failing when the import version was bumped from 2.0 to 2.1. This revealed that "Container" was pointing to Container.qml in 2.0, and to QQuickContainer in 2.1. Change-Id: I80b8de3bf556c57e4ae853b116d387431dfa02c7 Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
| * Improve the type registration version commentsJ-P Nurmi2016-10-041-3/+3
| | | | | | | | | | Change-Id: I6a5f42e341f213676146bc2a9540c63d3435ffa3 Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
* | Add QQuickDial::liveJ-P Nurmi2016-10-061-0/+2
| | | | | | | | | | | | | | | | | | [ChangeLog][Controls][Dial] Added a live-property that determines whether the dial provides live updates for the value-property while the handle is dragged. Change-Id: I8da1190df1e9093f81271a8e11f2cea55759573f Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
* | Add QQuickRangeSlider::liveJ-P Nurmi2016-10-061-0/+2
| | | | | | | | | | | | | | | | | | [ChangeLog][Controls][RangeSlider] Added a live-property that determines whether the range slider provides live updates for the first.value and second.value properties while the respective handle is dragged. Change-Id: I44d1924078969a5e22aca55625967dd8b5a4abac Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>