Commit f9c88735 authored by hausmann@webkit.org's avatar hausmann@webkit.org
Browse files

2008-11-05 Simon Hausmann <hausmann@webkit.org>

        Reviewed by Tor Arne Vestbø

        Fix loading of Flash 10 in the Qt port by faking the toolkit to be Gtk.

        Otherwise Flash refuses to load and function :(

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@38124 268f45cc-cd09-0410-ab3c-d52691b4dbfc
parent 49f97660
2008-11-05 Simon Hausmann <hausmann@webkit.org>
Reviewed by Tor Arne Vestbø
Fix loading of Flash 10 in the Qt port by faking the toolkit to be Gtk.
Otherwise Flash refuses to load and function :(
* plugins/PluginPackage.cpp:
(WebCore::PluginPackage::determineQuirks):
* plugins/PluginQuirkSet.h:
(WebCore::):
* plugins/qt/PluginViewQt.cpp:
(WebCore::PluginView::getValue):
2008-11-05 Simon Hausmann <hausmann@webkit.org> 2008-11-05 Simon Hausmann <hausmann@webkit.org>
   
Reviewed by Tor Arne Vestbø Reviewed by Tor Arne Vestbø
......
...@@ -172,6 +172,9 @@ void PluginPackage::determineQuirks(const String& mimeType) ...@@ -172,6 +172,9 @@ void PluginPackage::determineQuirks(const String& mimeType)
if (compareFileVersion(flashTenVersion) >= 0) { if (compareFileVersion(flashTenVersion) >= 0) {
// Flash 10.0 b218 doesn't like having a NULL window handle // Flash 10.0 b218 doesn't like having a NULL window handle
m_quirks.add(PluginQuirkDontSetNullWindowHandleOnDestroy); m_quirks.add(PluginQuirkDontSetNullWindowHandleOnDestroy);
#if PLATFORM(QT)
m_quirks.add(PluginQuirkRequiresGtkToolKit);
#endif
} else { } else {
// Flash 9 and older requests windowless plugins if we return a mozilla user agent // Flash 9 and older requests windowless plugins if we return a mozilla user agent
m_quirks.add(PluginQuirkWantsMozillaUserAgent); m_quirks.add(PluginQuirkWantsMozillaUserAgent);
......
...@@ -45,6 +45,7 @@ namespace WebCore { ...@@ -45,6 +45,7 @@ namespace WebCore {
PluginQuirkDontClipToZeroRectWhenScrolling = 1 << 9, PluginQuirkDontClipToZeroRectWhenScrolling = 1 << 9,
PluginQuirkDontSetNullWindowHandleOnDestroy = 1 << 10, PluginQuirkDontSetNullWindowHandleOnDestroy = 1 << 10,
PluginQuirkDontAllowMultipleInstances = 1 << 11, PluginQuirkDontAllowMultipleInstances = 1 << 11,
PluginQuirkRequiresGtkToolKit = 1 << 12,
}; };
class PluginQuirkSet { class PluginQuirkSet {
......
...@@ -373,8 +373,14 @@ NPError PluginView::getValue(NPNVariable variable, void* value) ...@@ -373,8 +373,14 @@ NPError PluginView::getValue(NPNVariable variable, void* value)
return NPERR_NO_ERROR; return NPERR_NO_ERROR;
} }
case NPNVToolkit:
if (m_plugin->quirks().contains(PluginQuirkRequiresGtkToolKit)) {
*((uint32 *)value) = 2;
return NPERR_NO_ERROR;
}
// fall through
default: default:
return getValueStatic(variable, value); return getValueStatic(variable, value);
} }
} }
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment