From 966a053e7689f41807d8994a93d5fd3952e09932 Mon Sep 17 00:00:00 2001 From: Marco Martin Date: Thu, 6 Aug 2015 14:03:59 +0200 Subject: Allow for styles to provide own EditMenu Allow for styles to define their own EditMenu component, to provide cut/copy/paste actions with the platform style. In order to be able to provide mobile-optimized controls on Linux systems, use the boolean env var QT_MOBILE_PLATFORM in this case. This allows on a plain Linux system to offer controls with the touch friendly text selection handles and the little inline cut/copy/paste menu Change-Id: Id9013b4386423938735390325a003fcccdcfd598 Reviewed-by: Richard Moe Gustavsen --- src/controls/Styles/Base/TextAreaStyle.qml | 6 ++++++ src/controls/Styles/Base/TextFieldStyle.qml | 6 ++++++ 2 files changed, 12 insertions(+) (limited to 'src/controls/Styles/Base') diff --git a/src/controls/Styles/Base/TextAreaStyle.qml b/src/controls/Styles/Base/TextAreaStyle.qml index 678d365d..1da52227 100644 --- a/src/controls/Styles/Base/TextAreaStyle.qml +++ b/src/controls/Styles/Base/TextAreaStyle.qml @@ -146,4 +146,10 @@ ScrollViewStyle { \since QtQuick.Controls.Styles 1.3 */ property Component __cursorDelegate + + /*! \internal + The delegate for the cut/copy/paste menu. + \since QtQuick.Controls.Styles 1.4 + */ + property Component __editMenu } diff --git a/src/controls/Styles/Base/TextFieldStyle.qml b/src/controls/Styles/Base/TextFieldStyle.qml index e9247416..b5e024b4 100644 --- a/src/controls/Styles/Base/TextFieldStyle.qml +++ b/src/controls/Styles/Base/TextFieldStyle.qml @@ -209,4 +209,10 @@ Style { \since QtQuick.Controls.Styles 1.3 */ property Component __cursorDelegate + + /*! \internal + The delegate for the cut/copy/paste menu. + \since QtQuick.Controls.Styles 1.4 + */ + property Component __editMenu } -- cgit v1.2.1