[Qt] Replace use of QApplication with QGuiApplication
authorhausmann@webkit.org <hausmann@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Wed, 9 Nov 2011 08:42:44 +0000 (08:42 +0000)
committerhausmann@webkit.org <hausmann@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Wed, 9 Nov 2011 08:42:44 +0000 (08:42 +0000)
commit3bed68e12d7e531d497c679c447f4b1bc5107881
treee40a6fa11e1034b75dc4daac820f6245b61d6fee
parentc070e5be7824085b0fbc3fd47db35679f8024656
[Qt] Replace use of QApplication with QGuiApplication
https://bugs.webkit.org/show_bug.cgi?id=71794

Reviewed by Andreas Kling.

Source/JavaScriptCore:

Add compat headers for use when building with Qt 4: QGuiApplication
is typedef'ed to QApplication.

* wtf/qt/compat/QGuiApplication: Added.
* wtf/qt/compat/qguiapplication.h: Added.

Source/WebCore:

* Target.pri: Add compat include dir when compiling with Qt 4.
* platform/graphics/gstreamer/PlatformVideoWindowQt.cpp:
(FullScreenVideoWindow::closeEvent): Replace use of QApplication with QGuiApplication.
(FullScreenVideoWindow::hideCursor): Ditto.
(FullScreenVideoWindow::showCursor): Ditto.
* platform/graphics/qt/TileQt.cpp: Remove unnecessary inclusion of QApplication.
* platform/qt/ClipboardQt.cpp: Replace use of QApplication with QGuiApplication.
(WebCore::ClipboardQt::ClipboardQt):
(WebCore::ClipboardQt::clearData):
(WebCore::ClipboardQt::clearAllData):
(WebCore::ClipboardQt::setData):
(WebCore::ClipboardQt::declareAndWriteDragImage):
(WebCore::ClipboardQt::writeURL):
(WebCore::ClipboardQt::writeRange):
(WebCore::ClipboardQt::writePlainText):
* platform/qt/PasteboardQt.cpp: Ditto.
(WebCore::Pasteboard::writeSelection):
(WebCore::Pasteboard::canSmartReplace):
(WebCore::Pasteboard::plainText):
(WebCore::Pasteboard::documentFragment):
(WebCore::Pasteboard::writePlainText):
(WebCore::Pasteboard::writeURL):
(WebCore::Pasteboard::writeImage):

Source/WebKit/qt:

* WebCoreSupport/QtWebComboBox.cpp:
(WebCore::QtWebComboBox::showPopupAtCursorPosition): Replace use of QApplication
with QCoreApplication.

Source/WebKit2:

* Platform/CoreIPC/unix/ConnectionUnix.cpp: Remove unnecessary QApplication inclusion.
* Platform/qt/RunLoopQt.cpp: Replace QApplication include with QCoreApplication.
* UIProcess/Launcher/qt/ProcessLauncherQt.cpp: Ditto.
* UIProcess/Launcher/qt/ThreadLauncherQt.cpp: Remove unnecessary QApplication inclusion.
* UIProcess/qt/QtWebPageProxy.cpp:
(QtWebPageProxy::handleMousePressEvent): Replace QApplication usage with QStyleHints.
(QtWebPageProxy::handleMouseDoubleClickEvent): Ditto.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@99664 268f45cc-cd09-0410-ab3c-d52691b4dbfc
17 files changed:
Source/JavaScriptCore/ChangeLog
Source/JavaScriptCore/wtf/qt/compat/QGuiApplication [new file with mode: 0644]
Source/JavaScriptCore/wtf/qt/compat/qguiapplication.h [new file with mode: 0644]
Source/WebCore/ChangeLog
Source/WebCore/Target.pri
Source/WebCore/platform/graphics/gstreamer/PlatformVideoWindowQt.cpp
Source/WebCore/platform/graphics/qt/TileQt.cpp
Source/WebCore/platform/qt/ClipboardQt.cpp
Source/WebCore/platform/qt/PasteboardQt.cpp
Source/WebKit/qt/ChangeLog
Source/WebKit/qt/WebCoreSupport/QtWebComboBox.cpp
Source/WebKit2/ChangeLog
Source/WebKit2/Platform/CoreIPC/unix/ConnectionUnix.cpp
Source/WebKit2/Platform/qt/RunLoopQt.cpp
Source/WebKit2/UIProcess/Launcher/qt/ProcessLauncherQt.cpp
Source/WebKit2/UIProcess/Launcher/qt/ThreadLauncherQt.cpp
Source/WebKit2/UIProcess/qt/QtWebPageProxy.cpp