Handle empty printer name in more places
This commit is contained in:
parent
47fb9c8555
commit
a78e2c4449
12 changed files with 6 additions and 33 deletions
|
@ -1,5 +1,6 @@
|
|||
import QtQuick 2.6
|
||||
import Sailfish.Silica 1.0
|
||||
import "utils.js" as Utils
|
||||
|
||||
Page {
|
||||
|
||||
|
@ -17,7 +18,7 @@ Page {
|
|||
|
||||
PageHeader {
|
||||
id: header
|
||||
title: printer.attrs["printer-name"].value
|
||||
title: Utils.unknownForEmptyString(printer.attrs["printer-name"].value)
|
||||
}
|
||||
|
||||
TextArea {
|
||||
|
|
|
@ -19,7 +19,7 @@ Page {
|
|||
width: Math.min(Screen.width, detailsFlickable.width)-2*Theme.paddingLarge
|
||||
PageHeader {
|
||||
title: qsTr("Details")
|
||||
description: printer.attrs["printer-name"].value
|
||||
description: Utils.unknownForEmptyString(printer.attrs["printer-name"].value)
|
||||
}
|
||||
|
||||
// TODO:
|
||||
|
|
|
@ -146,7 +146,7 @@ Page {
|
|||
|
||||
visible: Object.keys(printer.attrs).length !== 0
|
||||
|
||||
property string name: printer.attrs["printer-name"].value != "" ? printer.attrs["printer-name"].value : qsTr("Unknown")
|
||||
property string name: Utils.unknownForEmptyString(printer.attrs["printer-name"].value)
|
||||
property var supported_formats: Utils.supported_formats(printer, considerAdditionalFormatsSetting.value)
|
||||
property bool canPrint: supported_formats.mimetypes.indexOf(selectedFileType) != -1
|
||||
|
||||
|
|
|
@ -51,7 +51,7 @@ Page {
|
|||
|
||||
header: PageHeader {
|
||||
id: pageHeader
|
||||
title: printer.attrs["printer-name"].value
|
||||
title: Utils.unknownForEmptyString(printer.attrs["printer-name"].value)
|
||||
description: printer.jobs.length==1 ? printer.jobs.length+" "+qsTr("job") : printer.jobs.length+" "+qsTr("jobs")
|
||||
}
|
||||
|
||||
|
|
|
@ -85,7 +85,7 @@ Page {
|
|||
|
||||
PageHeader {
|
||||
id: pageHeader
|
||||
title: printer.attrs["printer-name"].value
|
||||
title: Utils.unknownForEmptyString(printer.attrs["printer-name"].value)
|
||||
description: Utils.basename(selectedFile)
|
||||
}
|
||||
|
||||
|
|
|
@ -283,10 +283,6 @@
|
|||
<source>About SeaPrint</source>
|
||||
<translation>Über SeaPrint</translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>Unknown</source>
|
||||
<translation>Unbekannt</translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>No compatible formats supported</source>
|
||||
<translation>Keine kompatiblen Formate unterstützt</translation>
|
||||
|
|
|
@ -283,10 +283,6 @@
|
|||
<source>About SeaPrint</source>
|
||||
<translation>Acerca de SeaPrint</translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>Unknown</source>
|
||||
<translation>Desconocido</translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>No compatible formats supported</source>
|
||||
<translation>No admite formatos compatibles</translation>
|
||||
|
|
|
@ -283,10 +283,6 @@
|
|||
<source>About SeaPrint</source>
|
||||
<translation>À propos de SeaPrint</translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>Unknown</source>
|
||||
<translation>Inconnu</translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>No compatible formats supported</source>
|
||||
<translation>Aucun format compatible supporté</translation>
|
||||
|
|
|
@ -283,10 +283,6 @@
|
|||
<source>About SeaPrint</source>
|
||||
<translation>Over SeaPrint</translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>Unknown</source>
|
||||
<translation>Onbekend</translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>No compatible formats supported</source>
|
||||
<translation>Geen ondersteunde formaten beschikbaar</translation>
|
||||
|
|
|
@ -283,10 +283,6 @@
|
|||
<source>About SeaPrint</source>
|
||||
<translation>O SeaPrint</translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>Unknown</source>
|
||||
<translation>Nieznany</translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>No compatible formats supported</source>
|
||||
<translation>Brak obsługiwanych kompatybilnych formatów</translation>
|
||||
|
|
|
@ -283,10 +283,6 @@
|
|||
<source>About SeaPrint</source>
|
||||
<translation>关于 SeaPrint(海印)</translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>Unknown</source>
|
||||
<translation>未知</translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>No compatible formats supported</source>
|
||||
<translation>不支持相关格式</translation>
|
||||
|
|
|
@ -283,10 +283,6 @@
|
|||
<source>About SeaPrint</source>
|
||||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>Unknown</source>
|
||||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>No compatible formats supported</source>
|
||||
<translation type="unfinished"></translation>
|
||||
|
|
Loading…
Reference in a new issue