diff options
author | Vitaly Wool <vitaly.wool@konsulko.com> | 2019-07-04 12:46:15 +0200 |
---|---|---|
committer | Vitaly Wool <vitaly.wool@konsulko.com> | 2019-07-04 12:46:15 +0200 |
commit | a402cc2ca741d9ca7a1bc5b90a7874e2c5abfd79 (patch) | |
tree | 913ba9830ae50692a1563a9b85ce39f4761d6780 | |
parent | 672937acb91fe7e680cb9dae88dcad411c3a3a60 (diff) |
Fix Taskmanager window layout
Fix Task Manager window layout so that it:
* does not have title bar
* occupies the full width of the screen
* is not anchored to the top of display (that makes it partially
invisible)
* scales with the screen resolution
Bug-AGL: SPEC-2585
Change-Id: I3b6bfbf5890dd67397790e93c0387e4cc7928d9a
Signed-off-by: Vitaly Wool <vitaly.wool@konsulko.com>
-rw-r--r-- | app/main.qml | 37 |
1 files changed, 22 insertions, 15 deletions
diff --git a/app/main.qml b/app/main.qml index 3ea844c..4c4d7a9 100644 --- a/app/main.qml +++ b/app/main.qml @@ -1,16 +1,16 @@ import QtQuick 2.6 -import QtQuick.Window 2.2 import QtQuick.Controls 1.4 import QtQuick.Controls 2.0 as NewControls import QtQuick.Layouts 1.1 import TaskManager 1.0 import QtCharts 2.2 -Window { +ApplicationWindow { id: root visible: true - width: 745 - height: 480 + width: container.width * container.scale + height: container.height * container.scale + flags: Qt.Window | Qt.FramelessWindowHint TaskManager { id: taskmgr @@ -60,6 +60,13 @@ Window { id: libraryModel } + Item { + id: container + anchors.centerIn: parent + width: 1080 + height: 1487 + scale: screenInfo.scale_factor() + TabView { id: mainTabview currentIndex: 0 @@ -69,6 +76,7 @@ Window { id: processesTab active: true anchors.fill: parent + title: "Processes" Rectangle { @@ -84,16 +92,14 @@ Window { Row { id: buttonRow width: parent.width - anchors.top: mainTabview.top RowLayout { id: buttonRowLayout - spacing: 6 NewControls.Popup { id: infoPopup - x: 200 - y: 200 + x: 400 * container.scale + y: 400 * container.scale width: 300 height: 200 modal: true @@ -139,37 +145,37 @@ Window { TableViewColumn { role: "cmd" title: "Process" - width: 150 + width: 200 * container.scale } TableViewColumn { role: "tid" title: "ID" - width: 80 + width: 100 * container.scale } TableViewColumn { role: "user" title: "User" - width: 80 + width: 120 * container.scale } TableViewColumn { role: "system_cpu" title: "System %" - width: 100 + width: 160 * container.scale } TableViewColumn { role: "user_cpu" title: "User %" - width: 100 + width: 160 * container.scale } TableViewColumn { role: "resident_memory" title: "Memory" - width: 100 + width: 160 * container.scale } TableViewColumn { role: "state" title: "State" - width: 90 + width: 80 * container.scale } model: libraryModel } @@ -320,4 +326,5 @@ Window { } } } + } } |