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

Unified Diff: chrome/browser/importer/firefox_importer_utils.h

Issue 10830098: Get the Firefox branding name dynamically (Closed) Base URL: http://src.chromium.org/svn/trunk/src/
Patch Set: Created 8 years, 5 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
Index: chrome/browser/importer/firefox_importer_utils.h
===================================================================
--- chrome/browser/importer/firefox_importer_utils.h (revision 148898)
+++ chrome/browser/importer/firefox_importer_utils.h (working copy)
@@ -96,4 +96,22 @@
std::string GetPrefsJsValue(const std::string& prefs,
const std::string& pref_key);
+// Returns the Firefox branding name stored in the application.ini file.
+// This is useful to differentiate between Firefox and Iceweasel.
+// A sample application.ini file is the following:
+// [App]
+// Vendor=Mozilla
+// Name=Iceweasel
+// Profile=mozilla/firefox
+// Version=3.5.16
+// BuildID=20120421070307
+// Copyright=Copyright (c) 1998 - 2010 mozilla.org
+// ID={ec8030f7-c20a-464f-9b0e-13a3a9e97384}
+// .........................................
+// For this example the function would return "Iceweasel".
+// The application.ini file is stored in the Firefox application directory.
+// If anything goes wrong while trying to obtain the branding name,
+// the function returns an empty string.
Ilya Sherman 2012/08/03 23:12:29 Optional nit: This comment is very nice and detail
cristian.patrasciuc 2012/08/07 15:46:49 Done.
+std::string GetFirefoxBrandingName(const FilePath& app_path);
+
#endif // CHROME_BROWSER_IMPORTER_FIREFOX_IMPORTER_UTILS_H_

Powered by Google App Engine
This is Rietveld 408576698