Add a default for make-and-model
This commit is contained in:
parent
3564b083e8
commit
34e09abd50
10 changed files with 42 additions and 2 deletions
|
@ -33,7 +33,7 @@ Page {
|
|||
}
|
||||
|
||||
Label {
|
||||
text: printer.attrs["printer-make-and-model"].value
|
||||
text: Utils.unknownForEmptyString(printer.attrs["printer-make-and-model"].value)
|
||||
}
|
||||
|
||||
SectionHeader {
|
||||
|
|
|
@ -242,7 +242,7 @@ Page {
|
|||
id: mm_label
|
||||
color: canPrint || selectedFile == "" ? Theme.primaryColor : Theme.secondaryColor
|
||||
font.pixelSize: Theme.fontSizeExtraSmall
|
||||
text: printer.attrs["printer-make-and-model"].value
|
||||
text: Utils.unknownForEmptyString(printer.attrs["printer-make-and-model"].value)
|
||||
}
|
||||
|
||||
Label {
|
||||
|
|
|
@ -336,6 +336,18 @@ function isWaringState(printer)
|
|||
return false;
|
||||
}
|
||||
|
||||
function unknownForEmptyString(s)
|
||||
{
|
||||
if(s === "")
|
||||
{
|
||||
return qsTr("Unknown");
|
||||
}
|
||||
else
|
||||
{
|
||||
return s;
|
||||
}
|
||||
}
|
||||
|
||||
var media =
|
||||
{"asme_f_28x40in": "28 x 40″",
|
||||
"choice_iso_a4_210x297mm_na_letter_8.5x11in": "A4 or US Letter",
|
||||
|
|
|
@ -710,5 +710,9 @@
|
|||
<source>single document (new sheet)</source>
|
||||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>Unknown</source>
|
||||
<translation type="unfinished">Unbekannt</translation>
|
||||
</message>
|
||||
</context>
|
||||
</TS>
|
||||
|
|
|
@ -710,5 +710,9 @@
|
|||
<source>single document (new sheet)</source>
|
||||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>Unknown</source>
|
||||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
</context>
|
||||
</TS>
|
||||
|
|
|
@ -710,5 +710,9 @@
|
|||
<source>single document (new sheet)</source>
|
||||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>Unknown</source>
|
||||
<translation type="unfinished">Inconnu</translation>
|
||||
</message>
|
||||
</context>
|
||||
</TS>
|
||||
|
|
|
@ -710,5 +710,9 @@
|
|||
<source>single document (new sheet)</source>
|
||||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>Unknown</source>
|
||||
<translation type="unfinished">Onbekend</translation>
|
||||
</message>
|
||||
</context>
|
||||
</TS>
|
||||
|
|
|
@ -710,5 +710,9 @@
|
|||
<source>single document (new sheet)</source>
|
||||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>Unknown</source>
|
||||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
</context>
|
||||
</TS>
|
||||
|
|
|
@ -710,5 +710,9 @@
|
|||
<source>single document (new sheet)</source>
|
||||
<translation>一份文件(新纸张)</translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>Unknown</source>
|
||||
<translation type="unfinished">未知</translation>
|
||||
</message>
|
||||
</context>
|
||||
</TS>
|
||||
|
|
|
@ -710,5 +710,9 @@
|
|||
<source>single document (new sheet)</source>
|
||||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>Unknown</source>
|
||||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
</context>
|
||||
</TS>
|
||||
|
|
Loading…
Reference in a new issue