[Qt-interest] QtWebKit plugin issues
Paul Colby
qt at colby.id.au
Tue Oct 27 06:42:37 CET 2009
Hi Peter,
Below is the code for a really simple QtWebKit app I wrote as a test
case. It works fine in OSX and Windows, and should work fine in Linux
too. Why not give it a go... that way, you can reasonably determine
if the problem is in your Qt code vs your Qt / Flash installation.
#include <QApplication>
#include <QWebView>
int main(int argc, char *argv[]) {
QApplication app(argc, argv);
QWebView webView;
webView.settings()->setAttribute(QWebSettings::PluginsEnabled,true);
webView.setUrl(QUrl::fromEncoded("http://www.adobe.com/software/flash/about/"));
webView.show();
return app.exec();
}
Hope that helps narrow it down for you - even if only a little.
BTW, the Flash plugin crashes QtWebKit for Windows in Qt 4.6.1 beta 1
(https://bugs.webkit.org/show_bug.cgi?id=30375) just in case you were
thinking about trying that out :|
paul.
On Tue, Oct 27, 2009 at 4:26 PM, Peter <pgeorges at gmail.com> wrote:
> Anyone? There is no information other than "set QWebSettings::PluginsEnabled
> to true" to get flash working... why does it not work for me?
>
> On Sat, Oct 24, 2009 at 1:26 AM, Peter Georges <pgeorges at gmail.com> wrote:
>>
>> It does not work in 4.5 for me either in linux
>>
>> On 23/10/2009, at 7:38 PM, Andrew Stuart wrote:
>>
>> Flash is broken in 4.6 under Windows.
>> as
>> On 23/10/2009, at 7:19 PM, Peter wrote:
>> I have a few issues with QtWebKit under both osx 10.6 (using Qt 4.6.0beta1
>> w/cocoa) and linux (using Qt 4.5.2). Firstly, I cannot get flash working at
>> all (I use youtube as a test). I set the globalSettings() correct as
>> follows:
>>
>>
>> QWebSettings::globalSettings()->setAttribute(QWebSettings::PluginsEnabled,
>> true);
>>
>> QWebSettings::globalSettings()->setAttribute(QWebSettings::JavascriptEnabled,
>> true);
>>
>> then when I load the page I confirm that plugins and javascript are both
>> enabled:
>>
>> std::cout << "plugins enabled: " <<
>> webView->page()->settings()->testAttribute(QWebSettings::PluginsEnabled) <<
>> std::endl;
>> std::cout << "javascript enabled: " <<
>> webView->page()->settings()->testAttribute(QWebSettings::JavascriptEnabled)
>> << std::endl;
>> webView->load(QUrl(url));
>>
>> prints out:
>>
>> plugins enabled: 1
>> javascript enabled: 1
>>
>> I have flash10 installed on both linux and osx in the correct directories,
>> but it just tells me that I have no flash browser installed or my javascript
>> is not enabled...
>>
>> What am I doing wrong?
>>
>> Report this message as spam
>>
>> _______________________________________________
>> Qt-interest mailing list
>> Qt-interest at trolltech.com
>> http://lists.trolltech.com/mailman/listinfo/qt-interest
>>
>> _______________________________________________
>> Qt-interest mailing list
>> Qt-interest at trolltech.com
>> http://lists.trolltech.com/mailman/listinfo/qt-interest
>>
>
>
> _______________________________________________
> Qt-interest mailing list
> Qt-interest at trolltech.com
> http://lists.trolltech.com/mailman/listinfo/qt-interest
>
>
--
http://colby.id.au
More information about the Qt-interest-old
mailing list