Bug 1129267 - Fix by backing out patch for bug 1118615. r=mstange a=sledru
authorSteven Michaud <smichaud@pobox.com>
Mon, 09 Feb 2015 14:50:25 -0600
changeset 243734 1673712f9408
parent 243733 8600a7b2e3a6
child 243735 9579b9ab68ca
push id4455
push usersmichaud@pobox.com
push date2015-02-09 20:51 +0000
treeherdermozilla-beta@1673712f9408 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersmstange, sledru
bugs1129267, 1118615
milestone36.0
Bug 1129267 - Fix by backing out patch for bug 1118615. r=mstange a=sledru
dom/plugins/base/nsNPAPIPlugin.cpp
dom/plugins/ipc/PluginInstanceChild.cpp
dom/plugins/ipc/PluginModuleChild.cpp
dom/plugins/ipc/PluginModuleChild.h
--- a/dom/plugins/base/nsNPAPIPlugin.cpp
+++ b/dom/plugins/base/nsNPAPIPlugin.cpp
@@ -2155,29 +2155,16 @@ NPError
     *(NPBool*)result = true;
     return NPERR_NO_ERROR;
   }
 
   case NPNVcontentsScaleFactor: {
     nsNPAPIPluginInstance *inst =
       (nsNPAPIPluginInstance *) (npp ? npp->ndata : nullptr);
     double scaleFactor = inst ? inst->GetContentsScaleFactor() : 1.0;
-    // Work around a Flash ActionScript bug that causes long hangs if
-    // Flash thinks HiDPI support is available. Adobe is tracking this as
-    // ADBE 3921114. If this turns out to be Adobe's fault and they fix it,
-    // we'll no longer need this quirk. See QUIRK_FLASH_HIDE_HIDPI_SUPPORT
-    // in PluginModuleChild.h, and also bug 1118615.
-    if (inst) {
-      const char *mimeType;
-      inst->GetMIMEType(&mimeType);
-      NS_NAMED_LITERAL_CSTRING(flash, "application/x-shockwave-flash");
-      if (!PL_strncasecmp(mimeType, flash.get(), flash.Length())) {
-        scaleFactor = 1.0;
-      }
-    }
     *(double*)result = scaleFactor;
     return NPERR_NO_ERROR;
   }
 #endif
 
 #ifdef MOZ_WIDGET_ANDROID
     case kLogInterfaceV0_ANPGetValue: {
       LOG("get log interface");
--- a/dom/plugins/ipc/PluginInstanceChild.cpp
+++ b/dom/plugins/ipc/PluginInstanceChild.cpp
@@ -422,21 +422,17 @@ PluginInstanceChild::NPN_GetValue(NPNVar
 #ifndef NP_NO_QUICKDRAW
     case NPNVsupportsQuickDrawBool: {
         *((NPBool*)aValue) = false;
         return NPERR_NO_ERROR;
     }
 #endif /* NP_NO_QUICKDRAW */
 
     case NPNVcontentsScaleFactor: {
-        double scaleFactor = mContentsScaleFactor;
-        if (GetQuirks() & PluginModuleChild::QUIRK_FLASH_HIDE_HIDPI_SUPPORT) {
-          scaleFactor = 1.0;
-        }
-        *static_cast<double*>(aValue) = scaleFactor;
+        *static_cast<double*>(aValue) = mContentsScaleFactor;
         return NPERR_NO_ERROR;
     }
 #endif /* XP_MACOSX */
 
 #ifdef DEBUG
     case NPNVjavascriptEnabledBool:
     case NPNVasdEnabledBool:
     case NPNVisOfflineBool:
--- a/dom/plugins/ipc/PluginModuleChild.cpp
+++ b/dom/plugins/ipc/PluginModuleChild.cpp
@@ -2076,17 +2076,16 @@ PluginModuleChild::InitQuirksModes(const
 #endif
 
 #ifdef XP_MACOSX
     // Whitelist Flash and Quicktime to support offline renderer
     NS_NAMED_LITERAL_CSTRING(flash, "application/x-shockwave-flash");
     NS_NAMED_LITERAL_CSTRING(quicktime, "QuickTime Plugin.plugin");
     if (FindInReadable(flash, aMimeType)) {
       mQuirks |= QUIRK_FLASH_AVOID_CGMODE_CRASHES;
-      mQuirks |= QUIRK_FLASH_HIDE_HIDPI_SUPPORT;
     }
     if (FindInReadable(flash, aMimeType) ||
         FindInReadable(quicktime, mPluginFilename)) {
         mQuirks |= QUIRK_ALLOW_OFFLINE_RENDERER;
     }
 #endif
 }
 
--- a/dom/plugins/ipc/PluginModuleChild.h
+++ b/dom/plugins/ipc/PluginModuleChild.h
@@ -274,21 +274,16 @@ public:
         // Mac: Allow the plugin to use offline renderer mode.
         // Use this only if the plugin is certified the support the offline renderer.
         QUIRK_ALLOW_OFFLINE_RENDERER                    = 1 << 9,
         // Mac: Work around a Flash bug that can cause plugin process crashes
         // in CoreGraphics mode:  The Flash plugin sometimes accesses the
         // CGContextRef we pass to it in NPP_HandleEvent(NPCocoaEventDrawRect)
         // outside of that call.  See bug 804606.
         QUIRK_FLASH_AVOID_CGMODE_CRASHES                = 1 << 10,
-        // Mac: Work around a Flash ActionScript bug that causes long hangs if
-        // Flash thinks HiDPI support is available. Adobe is tracking this as
-        // ADBE 3921114. If this turns out to be Adobe's fault and they fix it,
-        // we'll no longer need this quirk. See bug 1118615.
-        QUIRK_FLASH_HIDE_HIDPI_SUPPORT                  = 1 << 11,
     };
 
     int GetQuirks() { return mQuirks; }
 
     const PluginSettings& Settings() const { return mCachedSettings; }
 
 private:
     void AddQuirk(PluginQuirks quirk) {