Add missing translation markers

This commit is contained in:
Arjen Hiemstra 2015-05-07 16:33:37 +02:00
parent ef62725cc1
commit acf5120cff
13 changed files with 76 additions and 40 deletions

View file

@ -9,27 +9,19 @@ Item
{
width: 250
height: 250
/*Rectangle
{
color: "blue"
width: 250
height:250
}*/
Slider
{
width: 10
height: 250
anchors.right : parent.right
//anchors.fill: parent
//Layout.preferredHeight: UM.Theme.sizes.section.height;
orientation: Qt.Vertical
minimumValue: 0;
maximumValue: 100;
value: 50;
value: 100;
onValueChanged: UM.ActiveView.triggerAction("setLayer", value)
style: UM.Theme.styles.slider;
//Component.onCompleted: {console.log(UM.Theme.styles.slider)}
}
}
}

View file

@ -1,6 +1,7 @@
import QtQuick 2.1
import QtQuick.Controls 1.1
import QtQuick.Layouts 1.1
Rectangle
{
width: 300; height: 100
@ -10,11 +11,13 @@ Rectangle
{
Text
{
text: "extruder temperature " + manager.extruderTemperature
//: USB Printing dialog label, %1 is head temperature
text: qsTr("Extruder Temperature %1").arg(manager.extruderTemperature)
}
Text
{
text: "bed temperature " + manager.bedTemperature
//: USB Printing dialog label, %1 is bed temperature
text: qsTr("Bed Temperature %1").arg(manager.bedTemperature)
}
Text
{
@ -26,13 +29,15 @@ Rectangle
{
Button
{
text: "Print"
//: USB Printing dialog start print button
text: qsTr("Print");
onClicked: { manager.startPrint() }
enabled: manager.progress == 0 ? true : false
}
Button
{
text: "Cancel"
//: USB Printing dialog cancel print button
text: qsTr("Cancel");
onClicked: { manager.cancelPrint() }
enabled: manager.progress == 0 ? false: true
}
@ -52,4 +57,4 @@ Rectangle
height: 25
}
}
}
}

View file

@ -9,7 +9,22 @@ Rectangle
Text
{
text: manager.progress == 0 ? "Starting firmware update, may take a while.": manager.progress > 99 ? "Firmware update completed.": "Updating firmware."
text: {
if (manager.progress == 0)
{
//: Firmware update status label
return qsTr("Starting firmware update, this may take a while.")
}
else if (manager.progress > 99)
{
//: Firmware update status label
return qsTr("Firmware update completed.")
}
else
{
//: Firmware update status label
return qsTr("Updating firmware.")
}
}
ProgressBar
{
@ -26,4 +41,4 @@ Rectangle
height: 25
}
}
}
}

View file

@ -16,8 +16,7 @@ from PyQt5.QtQuick import QQuickView
from PyQt5.QtCore import QUrl, QObject, pyqtSlot, pyqtProperty, pyqtSignal
from UM.i18n import i18nCatalog
i18n_catalog = i18nCatalog("plugins")
i18n_catalog = i18nCatalog("uranium")
class USBPrinterManager(QObject, SignalEmitter, Extension):
@ -38,7 +37,7 @@ class USBPrinterManager(QObject, SignalEmitter, Extension):
self._error_message = ""
## Add menu item to top menu of the application.
self.addMenuItem(i18n_catalog.i18n("Update firmware"), self.updateAllFirmware)
self.addMenuItem(i18n_catalog.i18n("Update Firmware"), self.updateAllFirmware)
pyqtError = pyqtSignal(str, arguments = ["amount"])
processingProgress = pyqtSignal(float, arguments = ["amount"])