Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(467)

Unified Diff: chromeos/printing/printer_translator.cc

Issue 2956173002: Introduce the field make_and_model for synced printers. (Closed)
Patch Set: done Created 3 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « chromeos/printing/printer_configuration.h ('k') | chromeos/printing/printer_translator_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chromeos/printing/printer_translator.cc
diff --git a/chromeos/printing/printer_translator.cc b/chromeos/printing/printer_translator.cc
index c723664611528dc0ea0ec28c5914574844072c16..7f7499abc41376ba6c5633bd9a1fe9bf94252c4e 100644
--- a/chromeos/printing/printer_translator.cc
+++ b/chromeos/printing/printer_translator.cc
@@ -65,6 +65,12 @@ bool DictionaryToPrinter(const DictionaryValue& value, Printer* printer) {
if (value.GetString(kModel, &model))
printer->set_model(model);
+ std::string make_and_model = manufacturer;
+ if (!manufacturer.empty() && !model.empty())
+ make_and_model.append(" ");
+ make_and_model.append(model);
+ printer->set_make_and_model(make_and_model);
+
std::string uuid;
if (value.GetString(kUUID, &uuid))
printer->set_uuid(uuid);
« no previous file with comments | « chromeos/printing/printer_configuration.h ('k') | chromeos/printing/printer_translator_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698