From 36b2ee162ffd57c70d21c27ff25801f894886569 Mon Sep 17 00:00:00 2001 From: Christian Mollekopf Date: Mon, 31 Jul 2017 16:29:01 -0600 Subject: Use a regular Label with a SelectableItem in the logview This allows to copy all labels within the layout. Maybe a bit too magic atm. --- components/kube/contents/ui/LogView.qml | 20 ++++++++++++++------ 1 file changed, 14 insertions(+), 6 deletions(-) (limited to 'components') diff --git a/components/kube/contents/ui/LogView.qml b/components/kube/contents/ui/LogView.qml index 299c8e67..e085e449 100644 --- a/components/kube/contents/ui/LogView.qml +++ b/components/kube/contents/ui/LogView.qml @@ -125,13 +125,17 @@ Controls.SplitView { } color: Kube.Colors.viewBackgroundColor GridLayout { - anchors.fill: parent + id: gridLayout + anchors { + top: parent.top + left: parent.left + } columns: 2 Kube.Label { text: qsTr("Account:") visible: details.accountName } - Kube.SelectableLabel { + Kube.Label { text: details.accountName visible: details.accountName } @@ -139,7 +143,7 @@ Controls.SplitView { text: qsTr("Account Id:") visible: details.accountId } - Kube.SelectableLabel { + Kube.Label { text: details.accountId visible: details.accountId } @@ -147,20 +151,20 @@ Controls.SplitView { text: qsTr("Resource Id:") visible: details.resourceId } - Kube.SelectableLabel { + Kube.Label { text: details.resourceId visible: details.resourceId } Kube.Label { text: qsTr("Timestamp:") } - Kube.SelectableLabel { + Kube.Label { text: Qt.formatDateTime(details.timestamp, " hh:mm:ss dd MMM yyyy") } Kube.Label { text: qsTr("Message:") } - Kube.SelectableLabel { + Kube.Label { text: details.message wrapMode: Text.Wrap Layout.fillWidth: true @@ -171,6 +175,10 @@ Controls.SplitView { } //TODO offer a possible explanation for known errors and a path to resolution. } + + Kube.SelectableItem { + layout: gridLayout + } } } } -- cgit v1.2.3