Bug 747990 part 2: make use of UAName attribute to have the web app runtime use the associated application's UA string, r=myk
authorGavin Sharp <gavin@gavinsharp.com>
Tue, 01 May 2012 00:24:38 -0400
changeset 93895 f597b823f6e4be3d465a83ff6994948e6fcd975c
parent 93894 6fcc82582c2e29f7a2c0764bcfa350fe467500a2
child 93896 c0be912b90b4c917f6043c01ef309bb5efcd70c9
push idunknown
push userunknown
push dateunknown
reviewersmyk
bugs747990
milestone15.0a1
Bug 747990 part 2: make use of UAName attribute to have the web app runtime use the associated application's UA string, r=myk
webapprt/Makefile.in
webapprt/application.ini.in
webapprt/prefs.js
--- a/webapprt/Makefile.in
+++ b/webapprt/Makefile.in
@@ -43,17 +43,20 @@ libs::
 	$(PYTHON) $(MOZILLA_DIR)/config/buildlist.py $(FINAL_TARGET)/chrome.manifest "resource webapprt ./"
 
 libs:: prefs.js
 	$(NSINSTALL) -D $(FINAL_TARGET)/defaults/preferences
 	$(INSTALL) $^ $(FINAL_TARGET)/defaults/preferences
 
 GRE_MILESTONE := $(shell tail -n 1 $(topsrcdir)/config/milestone.txt 2>/dev/null || tail -1 $(topsrcdir)/config/milestone.txt)
 GRE_BUILDID := $(shell cat $(DEPTH)/config/buildid)
-DEFINES += -DGRE_MILESTONE=$(GRE_MILESTONE) -DGRE_BUILDID=$(GRE_BUILDID)
+DEFINES += -DGRE_MILESTONE=$(GRE_MILESTONE) \
+           -DGRE_BUILDID=$(GRE_BUILDID) \
+           -DMOZ_APP_BASENAME=$(MOZ_APP_BASENAME) \
+           $(NULL)
 
 webapprt.ini: application.ini.in $(DEPTH)/config/buildid $(topsrcdir)/config/milestone.txt
 	$(PYTHON) $(topsrcdir)/config/Preprocessor.py $(DEFINES) $< > $@
 
 libs:: webapprt.ini
 	$(INSTALL) webapprt.ini $(FINAL_TARGET)
 
 GARBAGE += webapprt.ini
--- a/webapprt/application.ini.in
+++ b/webapprt/application.ini.in
@@ -7,12 +7,13 @@
 #filter substitution
 
 [App]
 ID=webapprt@mozilla.org
 Vendor=Mozilla
 Name=Webapp Runtime
 Version=@GRE_MILESTONE@
 BuildID=@GRE_BUILDID@
+UAName=@MOZ_APP_BASENAME@
 
 [Gecko]
 MinVersion=@GRE_MILESTONE@
 MaxVersion=@GRE_MILESTONE@
--- a/webapprt/prefs.js
+++ b/webapprt/prefs.js
@@ -1,7 +1,6 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * License, v. 2.0. If a copy of the MPL was not distributed with this file,
  * You can obtain one at http://mozilla.org/MPL/2.0/. */
 
 pref("browser.chromeURL", "chrome://webapprt/content/webapp.xul");
 pref("browser.download.folderList", 1);
-pref("general.useragent.compatMode.firefox", true);