diff options
author | Ken Moore <ken@ixsystems.com> | 2018-01-30 16:57:34 -0500 |
---|---|---|
committer | Ken Moore <ken@ixsystems.com> | 2018-01-30 16:57:34 -0500 |
commit | ff713a8605f39d95ce2d3cfd2c17f892539d0f5a (patch) | |
tree | 5c975420277adc2d2a20d8407f47adf4ebbeb381 /src-qt5/core/lumina-desktop-unified/src-desktop/src-qml | |
parent | Merge branch 'master' of https://github.com/trueos/lumina (diff) | |
download | lumina-ff713a8605f39d95ce2d3cfd2c17f892539d0f5a.tar.gz lumina-ff713a8605f39d95ce2d3cfd2c17f892539d0f5a.tar.bz2 lumina-ff713a8605f39d95ce2d3cfd2c17f892539d0f5a.zip |
Get the Battery notification button put together.
Diffstat (limited to 'src-qt5/core/lumina-desktop-unified/src-desktop/src-qml')
-rw-r--r-- | src-qt5/core/lumina-desktop-unified/src-desktop/src-qml/plugins/StatusTray.qml | 3 | ||||
-rw-r--r-- | src-qt5/core/lumina-desktop-unified/src-desktop/src-qml/plugins/status_tray/BatteryButton.qml | 14 |
2 files changed, 12 insertions, 5 deletions
diff --git a/src-qt5/core/lumina-desktop-unified/src-desktop/src-qml/plugins/StatusTray.qml b/src-qt5/core/lumina-desktop-unified/src-desktop/src-qml/plugins/StatusTray.qml index 4552ea39..8f2239b9 100644 --- a/src-qt5/core/lumina-desktop-unified/src-desktop/src-qml/plugins/StatusTray.qml +++ b/src-qt5/core/lumina-desktop-unified/src-desktop/src-qml/plugins/StatusTray.qml @@ -15,7 +15,7 @@ import "./status_tray" as QML Rectangle { property int prefsize: (parent.width < parent.height) ? parent.width : parent.height id: "status_tray" - //color: "transparent" + color: "transparent" Layout.fillHeight: true Layout.fillWidth: true @@ -38,7 +38,6 @@ Rectangle { } //Battery Status QML.BatteryButton{ - id: "batButton" Layout.preferredHeight: status_tray.prefsize Layout.preferredWidth: status_tray.prefsize } diff --git a/src-qt5/core/lumina-desktop-unified/src-desktop/src-qml/plugins/status_tray/BatteryButton.qml b/src-qt5/core/lumina-desktop-unified/src-desktop/src-qml/plugins/status_tray/BatteryButton.qml index 0963165d..8ceec2d4 100644 --- a/src-qt5/core/lumina-desktop-unified/src-desktop/src-qml/plugins/status_tray/BatteryButton.qml +++ b/src-qt5/core/lumina-desktop-unified/src-desktop/src-qml/plugins/status_tray/BatteryButton.qml @@ -5,8 +5,16 @@ // See the LICENSE file for full details //=========================================== import QtQuick 2.2 -import QtQuick.Controls 2 +import QtQuick.Controls 1 -Rectangle{ - color: "red" +import Lumina.Backend.RootDesktopObject 2.0 +import Lumina.Backend.OSInterface 2.0 + +ToolButton{ + property OSInterface os: RootObject.os_interface() + id: "batButton" + iconName: os.icon + tooltip: os.batteryCharge+"%: "+os.batteryRemaining + visible: os.batteryAvailable() + enabled: false } |