diff options
author | Vitaly Wool <vitaly.wool@konsulko.com> | 2019-03-03 23:00:06 +0100 |
---|---|---|
committer | Vitaly Wool <vitaly.wool@konsulko.com> | 2019-03-03 23:00:06 +0100 |
commit | 122bcc295d054a733585996e859dea870ba5ca88 (patch) | |
tree | 0fdd2137bc73be984e0e182a81cebfa7fc2b2ae4 /app/main.qml | |
parent | e5c3f28f53eeef478d19a39b32dc7405efa46ef9 (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.qml | 25 |
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 { |