From a326ebdabf980a6b43264cf7dfa42d6a4f238686 Mon Sep 17 00:00:00 2001 From: Evgeniy Alekseev Date: Sat, 1 Oct 2016 12:42:05 +0300 Subject: [PATCH] replace buttons in dataengine page --- .../package/contents/ui/dataengine.qml | 72 ++++--------------- 1 file changed, 12 insertions(+), 60 deletions(-) diff --git a/sources/awesome-widget/package/contents/ui/dataengine.qml b/sources/awesome-widget/package/contents/ui/dataengine.qml index b507ef4..d5379b5 100644 --- a/sources/awesome-widget/package/contents/ui/dataengine.qml +++ b/sources/awesome-widget/package/contents/ui/dataengine.qml @@ -215,72 +215,24 @@ Item { Column { height: implicitHeight width: parent.width - Row { - height: implicitHeight - width: parent.width - QtControls.Label { - height: parent.height - width: parent.width * 2 / 5 - horizontalAlignment: Text.AlignRight - verticalAlignment: Text.AlignVCenter - text: i18n("Custom scripts") - } - QtControls.Button { - width: parent.width * 3 / 5 - text: i18n("Edit scripts") - onClicked: awKeys.editItem("extscript") - } + ButtonSelector { + value: i18n("Custom scripts") + onButtonActivated: awKeys.editItem("extscript") } - Row { - height: implicitHeight - width: parent.width - QtControls.Label { - height: parent.height - width: parent.width * 2 / 5 - horizontalAlignment: Text.AlignRight - verticalAlignment: Text.AlignVCenter - text: i18n("Quotes monitor") - } - QtControls.Button { - width: parent.width * 3 / 5 - text: i18n("Edit tickers") - onClicked: awKeys.editItem("extquotes") - } + ButtonSelector { + value: i18n("Quotes monitor") + onButtonActivated: awKeys.editItem("extquotes") } - Row { - height: implicitHeight - width: parent.width - QtControls.Label { - height: parent.height - width: parent.width * 2 / 5 - horizontalAlignment: Text.AlignRight - verticalAlignment: Text.AlignVCenter - text: i18n("Package manager") - } - QtControls.Button { - width: parent.width * 3 / 5 - text: i18n("Edit command") - onClicked: awKeys.editItem("extupgrade") - } + ButtonSelector { + value: i18n("Package manager") + onButtonActivated: awKeys.editItem("extupgrade") } - Row { - height: implicitHeight - width: parent.width - QtControls.Label { - height: parent.height - width: parent.width * 2 / 5 - horizontalAlignment: Text.AlignRight - verticalAlignment: Text.AlignVCenter - text: i18n("Weather") - } - QtControls.Button { - width: parent.width * 3 / 5 - text: i18n("Edit weather") - onClicked: awKeys.editItem("extweather") - } + ButtonSelector { + value: i18n("Weather") + onButtonActivated: awKeys.editItem("extweather") } } }