summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--src/maingui/printergui.cpp10
1 files changed, 2 insertions, 8 deletions
diff --git a/src/maingui/printergui.cpp b/src/maingui/printergui.cpp
index 528400e..8d094e3 100644
--- a/src/maingui/printergui.cpp
+++ b/src/maingui/printergui.cpp
@@ -233,14 +233,8 @@ static void enableOptionSelection(ppd_file_t *ppd, QStringList &nameList, QCombo
combo->setUpdatesEnabled(false);
combo->clear();
for (int i = 0; i < o->num_choices; ++i) {
- if (o->choices[i].choice == NULL)
- continue;
- if (o->choices[i].text == NULL) {
- combo->addItem(QString::fromUtf8(o->choices[i].choice), QString::fromLatin1(o->choices[i].choice));
- } else {
- combo->addItem(QString::fromUtf8(o->choices[i].text), QString::fromLatin1(o->choices[i].choice));
- }
- if (o->defchoice != NULL && strcmp(o->choices[i].choice, o->defchoice) == 0) {
+ combo->addItem(QString::fromUtf8(o->choices[i].text), QString::fromLatin1(o->choices[i].choice));
+ if (strcmp(o->choices[i].choice, o->defchoice) == 0) {
combo->setCurrentIndex(i);
}
}