mirror of
https://github.com/arcan1s/awesome-widgets.git
synced 2025-12-15 01:23:42 +00:00
initial plasma6 support
This commit is contained in:
@ -15,32 +15,23 @@
|
||||
* along with awesome-widgets. If not, see http://www.gnu.org/licenses/ *
|
||||
***************************************************************************/
|
||||
|
||||
import QtQuick 2.0
|
||||
import QtQuick.Controls.Styles 1.3 as QtStyles
|
||||
import QtQuick.Dialogs 1.1 as QtDialogs
|
||||
import QtQuick 2.15
|
||||
import QtQuick.Dialogs
|
||||
|
||||
|
||||
Row {
|
||||
height: implicitHeight
|
||||
width: parent.width
|
||||
|
||||
property alias text: selector.text
|
||||
property alias value: selector.value
|
||||
|
||||
ButtonSelector {
|
||||
id: selector
|
||||
style: QtStyles.ButtonStyle {
|
||||
background: Rectangle {
|
||||
color: value
|
||||
}
|
||||
}
|
||||
onButtonActivated: colorDialog.visible = true
|
||||
ButtonSelector {
|
||||
background: Rectangle {
|
||||
implicitWidth: 100
|
||||
implicitHeight: 25
|
||||
color: value
|
||||
}
|
||||
|
||||
QtDialogs.ColorDialog {
|
||||
onButtonActivated: colorDialog.visible = true
|
||||
|
||||
ColorDialog {
|
||||
id: colorDialog
|
||||
title: i18n("Select a color")
|
||||
color: value
|
||||
onAccepted: value = colorDialog.color
|
||||
selectedColor: value
|
||||
onAccepted: value = selectedColor
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user