on xenial help sign in
improves requested
commit1814087e972efca009d16739a522853d380be6d9 authorDiego Sarmentero <diego.sarmentero@gmail.com> dateTue 12 Aug 2014, 09:25 (12 years ago) parentfd1c34a
3 files changed+6−14
qml/Dash/Previews/PreviewPayments.qml+6−9 qml/Dash/Previews/PreviewWidget.qml−2 qml/Dash/Previews/PreviewWidgetFactory.qml−3
qml/Dash/Previews/PreviewPayments.qml+6−9
@@ -31,8 +31,6 @@ PreviewWidget {
3131 implicitHeight: paymentButton.implicitHeight
3232 implicitWidth: paymentButton.implicitWidth
3333
34− property bool processActive: false
35−
3634 Button {
3735 id: paymentButton
3836 objectName: "paymentButton"
@@ -43,11 +41,10 @@ PreviewWidget {
4341 paymentClient.start();
4442 root.processActive = true;
4543 }
46− enabled: !root.processActive
4744 anchors.right: parent.right
4845 width: (root.width - units.gu(1)) / 2
49− opacity: root.processActive ? 0 : 1
50− Behavior on opacity { PropertyAnimation {duration: UbuntuAnimation.SlowDuration}}
46+ visible: opacity == 0 ? false : true
47+ Behavior on opacity { PropertyAnimation {duration: UbuntuAnimation.FastDuration}}
5148
5249 Payments {
5350 id: paymentClient
@@ -69,10 +66,10 @@ PreviewWidget {
6966 ProgressBar {
7067 id: loadingBar
7168 indeterminate: true
72− anchors.right: parent.right
73− width: (root.width - units.gu(1)) / 2
74− opacity: root.processActive ? 1 : 0
69+ anchors.fill: paymentButton
70+ opacity: 1 - paymentsButton.opacity
71+ visible: opacity == 0 ? false : true
7572
76− Behavior on opacity { PropertyAnimation {duration: UbuntuAnimation.SlowDuration}}
73+ Behavior on opacity { PropertyAnimation {duration: UbuntuAnimation.FastDuration}}
7774 }
7875}
qml/Dash/Previews/PreviewWidget.qml−2
@@ -41,7 +41,5 @@ Item {
4141 */
4242 signal triggered(string widgetId, string actionId, var data)
4343
44− signal processing(bool active)
45−
4644 objectName: widgetId
4745}
qml/Dash/Previews/PreviewWidgetFactory.qml−3
@@ -43,8 +43,6 @@ Loader {
4343 //! Triggered signal forwarded from the widgets.
4444 signal triggered(string widgetId, string actionId, var data)
4545
46− signal processing(bool active)
47−
4846 source: widgetSource
4947
5048 //! \cond private
@@ -78,6 +76,5 @@ Loader {
7876 Connections {
7977 target: root.item
8078 onTriggered: root.triggered(widgetId, actionId, data)
81− onProcessing: root.processing(active)
8279 }
8380}