diff --git a/qml/pages/DetailsPage.qml b/qml/pages/DetailsPage.qml
index b7a8d82..cef676e 100644
--- a/qml/pages/DetailsPage.qml
+++ b/qml/pages/DetailsPage.qml
@@ -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 {
diff --git a/qml/pages/FirstPage.qml b/qml/pages/FirstPage.qml
index 54c6883..3551657 100644
--- a/qml/pages/FirstPage.qml
+++ b/qml/pages/FirstPage.qml
@@ -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 {
diff --git a/qml/pages/utils.js b/qml/pages/utils.js
index 8612c53..bfdbd4a 100644
--- a/qml/pages/utils.js
+++ b/qml/pages/utils.js
@@ -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",
diff --git a/translations/harbour-seaprint-de.ts b/translations/harbour-seaprint-de.ts
index ba161e6..dabc171 100644
--- a/translations/harbour-seaprint-de.ts
+++ b/translations/harbour-seaprint-de.ts
@@ -710,5 +710,9 @@
+
+
+ Unbekannt
+
diff --git a/translations/harbour-seaprint-es.ts b/translations/harbour-seaprint-es.ts
index 3203ead..3233a34 100644
--- a/translations/harbour-seaprint-es.ts
+++ b/translations/harbour-seaprint-es.ts
@@ -710,5 +710,9 @@
+
+
+
+
diff --git a/translations/harbour-seaprint-fr.ts b/translations/harbour-seaprint-fr.ts
index d06c6d1..3e185a1 100644
--- a/translations/harbour-seaprint-fr.ts
+++ b/translations/harbour-seaprint-fr.ts
@@ -710,5 +710,9 @@
+
+
+ Inconnu
+
diff --git a/translations/harbour-seaprint-nl.ts b/translations/harbour-seaprint-nl.ts
index 45c20e3..d890652 100644
--- a/translations/harbour-seaprint-nl.ts
+++ b/translations/harbour-seaprint-nl.ts
@@ -710,5 +710,9 @@
+
+
+ Onbekend
+
diff --git a/translations/harbour-seaprint-pl.ts b/translations/harbour-seaprint-pl.ts
index 29ce1f1..8ab1d5a 100644
--- a/translations/harbour-seaprint-pl.ts
+++ b/translations/harbour-seaprint-pl.ts
@@ -710,5 +710,9 @@
+
+
+
+
diff --git a/translations/harbour-seaprint-zh_CN.ts b/translations/harbour-seaprint-zh_CN.ts
index aef16cf..d0446c6 100644
--- a/translations/harbour-seaprint-zh_CN.ts
+++ b/translations/harbour-seaprint-zh_CN.ts
@@ -710,5 +710,9 @@
一份文件(新纸张)
+
+
+ 未知
+
diff --git a/translations/harbour-seaprint.ts b/translations/harbour-seaprint.ts
index a14e92b..c3b902f 100644
--- a/translations/harbour-seaprint.ts
+++ b/translations/harbour-seaprint.ts
@@ -710,5 +710,9 @@
+
+
+
+