aboutsummaryrefslogtreecommitdiffstats
path: root/app/main.qml
diff options
context:
space:
mode:
authorVitaly Wool <vitaly.wool@konsulko.com>2019-03-03 23:00:06 +0100
committerVitaly Wool <vitaly.wool@konsulko.com>2019-03-03 23:00:06 +0100
commit122bcc295d054a733585996e859dea870ba5ca88 (patch)
tree0fdd2137bc73be984e0e182a81cebfa7fc2b2ae4 /app/main.qml
parente5c3f28f53eeef478d19a39b32dc7405efa46ef9 (diff)
Add extraInfo processing
Implement processing of user request for extra info for a selected process and show a pop-up with the information returned by the back-end. Change-Id: Ief4e18d561e83877d57f984d8db3163c1cd314ac Signed-off-by: Vitaly Wool <vitaly.wool@konsulko.com>
Diffstat (limited to 'app/main.qml')
-rw-r--r--app/main.qml25
1 files changed, 25 insertions, 0 deletions
diff --git a/app/main.qml b/app/main.qml
index 58f63a6..a76aaa8 100644
--- a/app/main.qml
+++ b/app/main.qml
@@ -1,6 +1,7 @@
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
@@ -40,6 +41,10 @@ Window {
Component.onCompleted: {
taskmgr.open(bindingAddress);
}
+
+ onShowProcessInfo: {
+ infoPopup.infoText = info_;
+ }
}
ListModel {
@@ -60,10 +65,30 @@ Window {
id: buttonRowLayout
spacing: 6
+ NewControls.Popup {
+ id: infoPopup
+ x: 200
+ y: 200
+ width: 300
+ height: 200
+ modal: true
+ focus: true
+ closePolicy: NewControls.Popup.CloseOnPressOutsideParent
+ property var infoText: "Getting extra information for process"
+ function doOpen(tid) {
+ taskmgr.getExtraInfo(tid)
+ infoPopup.open()
+ }
+ contentItem: Text {
+ text: infoPopup.infoText
+ }
+ }
+
Button {
id: infoButton
text: "Info"
enabled: tableView.currentRow != -1
+ onClicked: infoPopup.doOpen(libraryModel.get(tableView.currentRow).tid)
}
Button {