mirror of
https://github.com/Ultimaker/Cura.git
synced 2025-08-05 21:13:58 -06:00
Fix the engine log window after changing it to use Window instead of Dialog
This commit is contained in:
parent
61de130880
commit
6d0e31aa8d
2 changed files with 36 additions and 14 deletions
|
@ -3,22 +3,52 @@ import QtQuick.Window 2.1
|
|||
import QtQuick.Controls 1.1
|
||||
import QtQuick.Layouts 1.1
|
||||
|
||||
import UM 1.0 as UM
|
||||
|
||||
Window {
|
||||
id: dialog
|
||||
|
||||
title: qsTr("Cura Engine Log");
|
||||
|
||||
modality: Qt.NonModal;
|
||||
flags: Qt.Dialog;
|
||||
|
||||
width: 640;
|
||||
height: 480;
|
||||
|
||||
TextArea {
|
||||
id: textArea
|
||||
Rectangle {
|
||||
anchors.fill: parent;
|
||||
color: UM.Theme.colors.system_window;
|
||||
|
||||
anchors.left: parent.left;
|
||||
anchors.right: parent.right;
|
||||
ColumnLayout {
|
||||
anchors.fill: parent;
|
||||
anchors.margins: UM.Theme.sizes.default_margin.width;
|
||||
|
||||
implicitHeight: 480;
|
||||
TextArea {
|
||||
id: textArea
|
||||
|
||||
Layout.fillWidth: true
|
||||
Layout.fillHeight: true
|
||||
}
|
||||
|
||||
Timer {
|
||||
id: updateTimer;
|
||||
interval: 1000;
|
||||
running: false;
|
||||
repeat: true;
|
||||
onTriggered: textArea.text = Printer.getEngineLog();
|
||||
}
|
||||
|
||||
RowLayout {
|
||||
Item {
|
||||
Layout.fillWidth: true;
|
||||
}
|
||||
Button {
|
||||
text: qsTr("Close");
|
||||
onClicked: dialog.visible = false;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
onVisibleChanged: {
|
||||
|
@ -29,12 +59,4 @@ Window {
|
|||
updateTimer.stop();
|
||||
}
|
||||
}
|
||||
|
||||
Timer {
|
||||
id: updateTimer;
|
||||
interval: 1000;
|
||||
running: false;
|
||||
repeat: true;
|
||||
onTriggered: textArea.text = Printer.getEngineLog();
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue