mirror of
https://github.com/Ultimaker/Cura.git
synced 2025-08-06 21:44:01 -06:00
Added status icon
This commit is contained in:
parent
6abbe7381a
commit
a02486e85a
3 changed files with 50 additions and 19 deletions
27
resources/qml/Menus/PrinterStatusIcon.qml
Normal file
27
resources/qml/Menus/PrinterStatusIcon.qml
Normal file
|
@ -0,0 +1,27 @@
|
|||
// Copyright (c) 2017 Ultimaker B.V.
|
||||
// Cura is released under the terms of the LGPLv3 or higher.
|
||||
|
||||
import QtQuick 2.2
|
||||
import QtQuick.Controls 1.1
|
||||
import QtQuick.Controls.Styles 1.1
|
||||
import QtQuick.Layouts 1.1
|
||||
|
||||
import UM 1.2 as UM
|
||||
import Cura 1.0 as Cura
|
||||
|
||||
Item {
|
||||
property bool printerConnected: Cura.MachineManager.printerOutputDevices.length != 0
|
||||
width: childrenRect.width
|
||||
height: childrenRect.height
|
||||
Image {
|
||||
id: statusIcon
|
||||
width: UM.Theme.getSize("status_icon").width
|
||||
height: UM.Theme.getSize("status_icon").height
|
||||
sourceSize.width: width
|
||||
sourceSize.height: width
|
||||
source: printerConnected ? UM.Theme.getIcon("tab_status_connected") : UM.Theme.getIcon("tab_status_busy")
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
Loading…
Add table
Add a link
Reference in a new issue