125 lines
6.0 KiB
Diff
125 lines
6.0 KiB
Diff
|
diff --git a/backend/dnssd.c b/backend/dnssd.c
|
||
|
index 34781d5ce..7074f4294 100644
|
||
|
--- a/backend/dnssd.c
|
||
|
+++ b/backend/dnssd.c
|
||
|
@@ -1252,6 +1252,13 @@ query_callback(
|
||
|
strlcat(make_and_model, " ", sizeof(make_and_model));
|
||
|
strlcat(make_and_model, model, sizeof(make_and_model));
|
||
|
|
||
|
+ if (!_cups_strncasecmp(make_and_model, "EPSON EPSON ", 12))
|
||
|
+ _cups_strcpy(make_and_model, make_and_model + 6);
|
||
|
+ else if (!_cups_strncasecmp(make_and_model, "HP HP ", 6))
|
||
|
+ _cups_strcpy(make_and_model, make_and_model + 3);
|
||
|
+ else if (!_cups_strncasecmp(make_and_model, "Lexmark International Lexmark ", 30))
|
||
|
+ _cups_strcpy(make_and_model, make_and_model + 22);
|
||
|
+
|
||
|
device->make_and_model = strdup(make_and_model);
|
||
|
}
|
||
|
else
|
||
|
diff --git a/cgi-bin/admin.c b/cgi-bin/admin.c
|
||
|
index f788083fb..a3b5057b0 100644
|
||
|
--- a/cgi-bin/admin.c
|
||
|
+++ b/cgi-bin/admin.c
|
||
|
@@ -928,6 +929,8 @@ do_am_printer(http_t *http, /* I - HTTP connection */
|
||
|
else if (!file &&
|
||
|
(!cgiGetVariable("PPD_NAME") || cgiGetVariable("SELECT_MAKE")))
|
||
|
{
|
||
|
+ int ipp_everywhere = !strncmp(var, "ipp://", 6) || !strncmp(var, "ipps://", 7) || (!strncmp(var, "dnssd://", 8) && (strstr(var, "_ipp._tcp") || strstr(var, "_ipps._tcp")));
|
||
|
+
|
||
|
if (modify && !cgiGetVariable("SELECT_MAKE"))
|
||
|
{
|
||
|
/*
|
||
|
@@ -1076,6 +1079,8 @@ do_am_printer(http_t *http, /* I - HTTP connection */
|
||
|
if (!modify)
|
||
|
cgiSetVariable("CURRENT_MAKE_AND_MODEL",
|
||
|
cgiGetArray("PPD_MAKE_AND_MODEL", 0));
|
||
|
+ if (ipp_everywhere)
|
||
|
+ cgiSetVariable("SHOW_IPP_EVERYWHERE", "1");
|
||
|
cgiCopyTemplateLang("choose-model.tmpl");
|
||
|
cgiEndHTML();
|
||
|
}
|
||
|
diff --git a/templates/choose-model.tmpl b/templates/choose-model.tmpl
|
||
|
index ee9338cc5..d72534236 100644
|
||
|
--- a/templates/choose-model.tmpl
|
||
|
+++ b/templates/choose-model.tmpl
|
||
|
@@ -39,6 +39,7 @@
|
||
|
<TD>
|
||
|
<SELECT NAME="PPD_NAME" SIZE="10">
|
||
|
{op=add-printer?:<OPTION VALUE="__no_change__" SELECTED>Current Driver - {current_make_and_model}</OPTION>:}
|
||
|
+{show_ipp_everywhere?<OPTION VALUE="everywhere" SELECTED>IPP Everywhere ™</OPTION>:}
|
||
|
{[ppd_name]<OPTION VALUE="{ppd_name}" {op=modify-printer?:{?current_make_and_model={ppd_make_and_model}?SELECTED:}}>{ppd_make_and_model} ({ppd_natural_language})
|
||
|
}</SELECT>
|
||
|
</TD>
|
||
|
diff --git a/templates/de/choose-model.tmpl b/templates/de/choose-model.tmpl
|
||
|
index cb9b6f3bc..a08a8e3e0 100644
|
||
|
--- a/templates/de/choose-model.tmpl
|
||
|
+++ b/templates/de/choose-model.tmpl
|
||
|
@@ -39,6 +39,7 @@ Drucker {?printer_is_shared=?nicht:{?printer_is_shared=0?nicht:}} im Netzwerk fr
|
||
|
<TD>
|
||
|
<SELECT NAME="PPD_NAME" SIZE="10">
|
||
|
{op=add-printer?:<OPTION VALUE="__no_change__" SELECTED>Aktueller Treiber - {current_make_and_model}</OPTION>:}
|
||
|
+{show_ipp_everywhere?<OPTION VALUE="everywhere" SELECTED>IPP Everywhere ™</OPTION>:}
|
||
|
{[ppd_name]<OPTION VALUE="{ppd_name}" {op=modify-printer?:{?current_make_and_model={ppd_make_and_model}?SELECTED:}}>{ppd_make_and_model} ({ppd_natural_language})
|
||
|
}</SELECT>
|
||
|
</TD>
|
||
|
diff --git a/templates/es/choose-model.tmpl b/templates/es/choose-model.tmpl
|
||
|
index 8a5a4ba90..74f0a9bb9 100644
|
||
|
--- a/templates/es/choose-model.tmpl
|
||
|
+++ b/templates/es/choose-model.tmpl
|
||
|
@@ -39,6 +39,7 @@
|
||
|
<TD>
|
||
|
<SELECT NAME="PPD_NAME" SIZE="10">
|
||
|
{op=add-printer?:<OPTION VALUE="__no_change__" SELECTED>Controlador actual - {current_make_and_model}</OPTION>:}
|
||
|
+{show_ipp_everywhere?<OPTION VALUE="everywhere" SELECTED>IPP Everywhere ™</OPTION>:}
|
||
|
{[ppd_name]<OPTION VALUE="{ppd_name}" {op=modify-printer?:{?current_make_and_model={ppd_make_and_model}?SELECTED:}}>{ppd_make_and_model} ({ppd_natural_language})
|
||
|
}</SELECT>
|
||
|
</TD>
|
||
|
diff --git a/templates/fr/choose-model.tmpl b/templates/fr/choose-model.tmpl
|
||
|
index 1e154f18a..3038b3fe3 100644
|
||
|
--- a/templates/fr/choose-model.tmpl
|
||
|
+++ b/templates/fr/choose-model.tmpl
|
||
|
@@ -39,6 +39,7 @@
|
||
|
<TD>
|
||
|
<SELECT NAME="PPD_NAME" SIZE="10">
|
||
|
{op=add-printer?:<OPTION VALUE="__no_change__" SELECTED>Pilote actuel - {current_make_and_model}</OPTION>:}
|
||
|
+{show_ipp_everywhere?<OPTION VALUE="everywhere" SELECTED>IPP Everywhere ™</OPTION>:}
|
||
|
{[ppd_name]<OPTION VALUE="{ppd_name}" {op=modify-printer?:{?current_make_and_model={ppd_make_and_model}?SELECTED:}}>{ppd_make_and_model} ({ppd_natural_language})
|
||
|
}</SELECT>
|
||
|
</TD>
|
||
|
diff --git a/templates/ja/choose-model.tmpl b/templates/ja/choose-model.tmpl
|
||
|
index daf1375fd..b3c286b11 100644
|
||
|
--- a/templates/ja/choose-model.tmpl
|
||
|
+++ b/templates/ja/choose-model.tmpl
|
||
|
@@ -39,6 +39,7 @@
|
||
|
<TD>
|
||
|
<SELECT NAME="PPD_NAME" SIZE="10">
|
||
|
{op=add-printer?:<OPTION VALUE="__no_change__" SELECTED>現在のドライバー - {current_make_and_model}</OPTION>:}
|
||
|
+{show_ipp_everywhere?<OPTION VALUE="everywhere" SELECTED>IPP Everywhere ™</OPTION>:}
|
||
|
{[ppd_name]<OPTION VALUE="{ppd_name}" {op=modify-printer?:{?current_make_and_model={ppd_make_and_model}?SELECTED:}}>{ppd_make_and_model} ({ppd_natural_language})
|
||
|
}</SELECT>
|
||
|
</TD>
|
||
|
diff --git a/templates/pt_BR/choose-model.tmpl b/templates/pt_BR/choose-model.tmpl
|
||
|
index 55d8bd8d5..a5939ee9c 100644
|
||
|
--- a/templates/pt_BR/choose-model.tmpl
|
||
|
+++ b/templates/pt_BR/choose-model.tmpl
|
||
|
@@ -39,6 +39,7 @@
|
||
|
<TD>
|
||
|
<SELECT NAME="PPD_NAME" SIZE="10">
|
||
|
{op=add-printer?:<OPTION VALUE="__no_change__" SELECTED>Driver atual - {current_make_and_model}</OPTION>:}
|
||
|
+{show_ipp_everywhere?<OPTION VALUE="everywhere" SELECTED>IPP Everywhere ™</OPTION>:}
|
||
|
{[ppd_name]<OPTION VALUE="{ppd_name}" {op=modify-printer?:{?current_make_and_model={ppd_make_and_model}?SELECTED:}}>{ppd_make_and_model} ({ppd_natural_language})
|
||
|
}</SELECT>
|
||
|
</TD>
|
||
|
diff --git a/templates/ru/choose-model.tmpl b/templates/ru/choose-model.tmpl
|
||
|
index 2f0d6d9ba..86507814d 100644
|
||
|
--- a/templates/ru/choose-model.tmpl
|
||
|
+++ b/templates/ru/choose-model.tmpl
|
||
|
@@ -39,6 +39,7 @@
|
||
|
<TD>
|
||
|
<SELECT NAME="PPD_NAME" SIZE="10">
|
||
|
{op=add-printer?:<OPTION VALUE="__no_change__" SELECTED>Текущий драйвер - {current_make_and_model}</OPTION>:}
|
||
|
+{show_ipp_everywhere?<OPTION VALUE="everywhere" SELECTED>IPP Everywhere ™</OPTION>:}
|
||
|
{[ppd_name]<OPTION VALUE="{ppd_name}" {op=modify-printer?:{?current_make_and_model={ppd_make_and_model}?SELECTED:}}>{ppd_make_and_model} ({ppd_natural_language})
|
||
|
}</SELECT>
|
||
|
</TD>
|