Bug 728620 - Followup: Add a FIXME comment. DONTBUILD
authorAli Juma <ajuma@mozilla.com>
Tue, 21 Feb 2012 10:30:57 -0500
changeset 89198 a442ffe3c5cb459fd11d6e561f6da70bc6245093
parent 89197 d644bee235512829194d6d2766001752c5f9e87f
child 89199 ad16a4fbcdc5980a2b3d357cff8f2e15df52fcc3
push id22242
push userkgupta@mozilla.com
push dateWed, 14 Mar 2012 15:19:09 +0000
treeherdermozilla-central@936ef50fa498 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
bugs728620
milestone13.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 728620 - Followup: Add a FIXME comment. DONTBUILD
mobile/android/chrome/content/browser.js
--- a/mobile/android/chrome/content/browser.js
+++ b/mobile/android/chrome/content/browser.js
@@ -2088,16 +2088,23 @@ Tab.prototype = {
   observe: function(aSubject, aTopic, aData) {
     switch (aTopic) {
       case "document-shown":
         // Is it on the top level?
         let contentDocument = aSubject;
         if (contentDocument == this.browser.contentDocument) {
           ViewportHandler.updateMetadata(this);
           this.documentIdForCurrentViewport = ViewportHandler.getIdForDocument(contentDocument);
+          // FIXME: This is a workaround for the fact that we suppress draw events.
+          // This means we need to retrigger a draw event here since we might
+          // have suppressed a draw event before documentIdForCurrentViewport
+          // got updated. The real fix is to get rid of suppressing draw events
+          // based on the value of documentIdForCurrentViewport, which we
+          // can do once the docshell and the browser element are aware 
+          // of the existence of <meta viewport>. 
           sendMessageToJava({ gecko: { type: "Viewport:UpdateAndDraw" } });
         }
         break;
     }
   },
 
   QueryInterface: XPCOMUtils.generateQI([
     Ci.nsIWebProgressListener,