diff options
author | J-P Nurmi <jpnurmi@qt.io> | 2018-04-06 15:45:23 +0200 |
---|---|---|
committer | J-P Nurmi <jpnurmi@qt.io> | 2018-04-06 15:46:16 +0200 |
commit | f447493bf9a8cf3490da0f5409d76e7f7fc98759 (patch) | |
tree | 3a7849bd636b820b211c24885e7cdb72334338c6 /src | |
parent | 4696c5609ae5741a841d2222c45c1e020c03db25 (diff) | |
parent | 4a8c2605c26acf575e181682f083e077b815ab4b (diff) |
Merge remote-tracking branch 'origin/5.11' into dev
Change-Id: I509cd2e02874d9a2fe0febf8cc667833b7072b23
Diffstat (limited to 'src')
-rw-r--r-- | src/imports/controls/doc/src/includes/qquickoverlay-popup-parent.qdocinc | 4 | ||||
-rw-r--r-- | src/imports/controls/plugins.qmltypes | 12 | ||||
-rw-r--r-- | src/imports/templates/plugins.qmltypes | 10 | ||||
-rw-r--r-- | src/imports/templates/qtquicktemplates2plugin.cpp | 1 | ||||
-rw-r--r-- | src/quicktemplates2/qquickrangeslider.cpp | 2 | ||||
-rw-r--r-- | src/quicktemplates2/qquickslider.cpp | 3 | ||||
-rw-r--r-- | src/quicktemplates2/qquicktextarea.cpp | 5 |
7 files changed, 32 insertions, 5 deletions
diff --git a/src/imports/controls/doc/src/includes/qquickoverlay-popup-parent.qdocinc b/src/imports/controls/doc/src/includes/qquickoverlay-popup-parent.qdocinc index 7ad8a003..5562f6a0 100644 --- a/src/imports/controls/doc/src/includes/qquickoverlay-popup-parent.qdocinc +++ b/src/imports/controls/doc/src/includes/qquickoverlay-popup-parent.qdocinc @@ -11,8 +11,8 @@ Button { parent: Overlay.overlay - x: (parent.width - width) / 2 - y: (parent.height - height) / 2 + x: Math.round((parent.width - width) / 2) + y: Math.round((parent.height - height) / 2) width: 100 height: 100 } diff --git a/src/imports/controls/plugins.qmltypes b/src/imports/controls/plugins.qmltypes index 8b2be4a1..5011365c 100644 --- a/src/imports/controls/plugins.qmltypes +++ b/src/imports/controls/plugins.qmltypes @@ -1208,6 +1208,16 @@ Module { Property { name: "title"; type: "string" } Property { name: "label"; type: "QQuickItem"; isPointer: true } } + + Component { + name: "QQuickIcon" + Property { name: "name"; type: "string" } + Property { name: "source"; type: "QUrl" } + Property { name: "width"; type: "int" } + Property { name: "height"; type: "int" } + Property { name: "color"; type: "QColor" } + } + Component { name: "QQuickItemDelegate" defaultProperty: "data" @@ -1903,7 +1913,7 @@ Module { Property { name: "busy"; type: "bool"; isReadonly: true } Property { name: "depth"; type: "int"; isReadonly: true } Property { name: "currentItem"; type: "QQuickItem"; isReadonly: true; isPointer: true } - Property { name: "initialItem"; type: "QVariant" } + Property { name: "initialItem"; type: "QJSValue" } Property { name: "popEnter"; type: "QQuickTransition"; isPointer: true } Property { name: "popExit"; type: "QQuickTransition"; isPointer: true } Property { name: "pushEnter"; type: "QQuickTransition"; isPointer: true } diff --git a/src/imports/templates/plugins.qmltypes b/src/imports/templates/plugins.qmltypes index ed609c1f..0283f50d 100644 --- a/src/imports/templates/plugins.qmltypes +++ b/src/imports/templates/plugins.qmltypes @@ -567,6 +567,14 @@ Module { Property { name: "label"; type: "QQuickItem"; isPointer: true } } Component { + name: "QQuickIcon" + Property { name: "name"; type: "string" } + Property { name: "source"; type: "QUrl" } + Property { name: "width"; type: "int" } + Property { name: "height"; type: "int" } + Property { name: "color"; type: "QColor" } + } + Component { name: "QQuickItemDelegate" defaultProperty: "data" prototype: "QQuickAbstractButton" @@ -1261,7 +1269,7 @@ Module { Property { name: "busy"; type: "bool"; isReadonly: true } Property { name: "depth"; type: "int"; isReadonly: true } Property { name: "currentItem"; type: "QQuickItem"; isReadonly: true; isPointer: true } - Property { name: "initialItem"; type: "QVariant" } + Property { name: "initialItem"; type: "QJSValue" } Property { name: "popEnter"; type: "QQuickTransition"; isPointer: true } Property { name: "popExit"; type: "QQuickTransition"; isPointer: true } Property { name: "pushEnter"; type: "QQuickTransition"; isPointer: true } diff --git a/src/imports/templates/qtquicktemplates2plugin.cpp b/src/imports/templates/qtquicktemplates2plugin.cpp index 81330447..ace2b316 100644 --- a/src/imports/templates/qtquicktemplates2plugin.cpp +++ b/src/imports/templates/qtquicktemplates2plugin.cpp @@ -299,6 +299,7 @@ void QtQuickTemplates2Plugin::registerTypes(const char *uri) qmlRegisterType<QQuickContainer, 3>(uri, 2, 3, "Container"); qmlRegisterType<QQuickDialog, 3>(uri, 2, 3, "Dialog"); qmlRegisterType<QQuickDialogButtonBox, 3>(uri, 2, 3, "DialogButtonBox"); + qmlRegisterType<QQuickIcon>(); qRegisterMetaType<QQuickIcon>(); qmlRegisterType<QQuickLabel, 3>(uri, 2, 3, "Label"); qmlRegisterType<QQuickMenu, 3>(uri, 2, 3, "Menu"); diff --git a/src/quicktemplates2/qquickrangeslider.cpp b/src/quicktemplates2/qquickrangeslider.cpp index 5b282f2c..49384fe4 100644 --- a/src/quicktemplates2/qquickrangeslider.cpp +++ b/src/quicktemplates2/qquickrangeslider.cpp @@ -86,6 +86,8 @@ QT_BEGIN_NAMESPACE RangeSlider. In the example above, \l {first.visualPosition} will be \c 0.24 in a left-to-right application, and \c 0.76 in a right-to-left application. + For a slider that allows the user to select a single value, see \l Slider. + \sa {Customizing RangeSlider}, {Input Controls}, {Focus Management in Qt Quick Controls 2} */ diff --git a/src/quicktemplates2/qquickslider.cpp b/src/quicktemplates2/qquickslider.cpp index 86e2445a..60667267 100644 --- a/src/quicktemplates2/qquickslider.cpp +++ b/src/quicktemplates2/qquickslider.cpp @@ -73,6 +73,9 @@ QT_BEGIN_NAMESPACE In the example above, \l visualPosition will be \c 0.24 in a left-to-right application, and \c 0.76 in a right-to-left application. + For a slider that allows the user to select a range by providing two + handles, see \l RangeSlider. + \sa {Customizing Slider}, {Input Controls} */ diff --git a/src/quicktemplates2/qquicktextarea.cpp b/src/quicktemplates2/qquicktextarea.cpp index a13213fd..45a084d2 100644 --- a/src/quicktemplates2/qquicktextarea.cpp +++ b/src/quicktemplates2/qquicktextarea.cpp @@ -529,7 +529,10 @@ void QQuickTextArea::setBackground(QQuickItem *background) delete d->background; d->background = background; if (background) { - background->setParentItem(this); + if (d->flickable) + background->setParentItem(d->flickable); + else + background->setParentItem(this); if (qFuzzyIsNull(background->z())) background->setZ(-1); if (isComponentComplete()) |