2012-02-16 Carlos Garcia Campos [GTK] Page content is incorrectly translated whenh rendering pages for printing in WebKit2 https://bugs.webkit.org/show_bug.cgi?id=78712 Reviewed by Martin Robinson. * WebProcess/WebPage/gtk/WebPrintOperationGtk.cpp: (WebKit::WebPrintOperationGtk::enumeratePrintersFunction): Simplify the code to select the printer. (WebKit::WebPrintOperationGtk::renderPage): Call cairo_save() before rendering the page and cairo_restore() when page has been rendered. 2012-02-16 Carlos Garcia Campos [GTK] Add WebKitPrintOperation to WebKit2 GTK+ API https://bugs.webkit.org/show_bug.cgi?id=76448 Reviewed by Martin Robinson. * GNUmakefile.am: Add new files to compilation. * UIProcess/API/gtk/WebKitDefines.h: * UIProcess/API/gtk/WebKitPrintOperation.cpp: Added. (webViewDestroyed): Delete the print operation when the view widget associated is destroyed. (webkitPrintOperationConstructed): Connect to destroy signal of associated web view. (webkitPrintOperationGetProperty): (webkitPrintOperationSetProperty): (webkit_print_operation_init): (webkit_print_operation_class_init): (webkitPrintOperationRunDialogUnix): Use GtkPrintUnixDialog to show the printing dialog in UNIX platforms. (webkitPrintOperationRunDialogWin32): Empty, not implemented yet. (drawPagesForPrintingCompleted): Callback called when printing operation has finished in the web process. (webkitPrintOperationRunDialogForFrame): Run the printing dialog and start printing the given frame. (webkit_print_operation_new): Create a new print operation for the given web view. (webkit_print_operation_get_print_settings): (webkit_print_operation_set_print_settings): (webkit_print_operation_get_page_setup): (webkit_print_operation_set_page_setup): (webkit_print_operation_run_dialog): Run the print dialog to print the web view main frame. * UIProcess/API/gtk/WebKitPrintOperation.h: Added. * UIProcess/API/gtk/WebKitPrintOperationPrivate.h: Added. * UIProcess/API/gtk/WebKitUIClient.cpp: (printFrame): Call webkitWebViewPrintFrame. (attachUIClientToView): Add implementation for printFrame callback. * UIProcess/API/gtk/WebKitWebView.cpp: (webkit_web_view_class_init): Add WebKitWebView::print-requested signal. (webkitWebViewPrintFrame): Emit print-requested and show the print dialog to print the frame when not signal is not handled by user. * UIProcess/API/gtk/WebKitWebView.h: * UIProcess/API/gtk/WebKitWebViewPrivate.h: * UIProcess/API/gtk/docs/webkit2gtk-docs.sgml: Add new section for WebKitPrintOperation. * UIProcess/API/gtk/docs/webkit2gtk-sections.txt: Add new symbols. * UIProcess/API/gtk/tests/GNUmakefile.am: * UIProcess/API/gtk/tests/TestPrinting.cpp: Added. (testPrintOperationPrintSettings): (webViewPrintRequestedCallback): (testWebViewPrintRequested): (beforeAll): (afterAll): * UIProcess/API/gtk/webkit2.h: Include WebKitPrintOperation.h. 2012-02-16 Simon Hausmann [Gtk][Efl][Qt] Move OpenGLShims out of cairo/ subdirectory https://bugs.webkit.org/show_bug.cgi?id=78800 Reviewed by Kenneth Rohde Christiansen. * UIProcess/qt/LayerTreeHostProxyQt.cpp: Adjust to changed OpenGLShims.h location - no more cairo prefix needed. 2012-02-16 No'am Rosenthal [Qt][WK2] Allow opaque tiles https://bugs.webkit.org/show_bug.cgi?id=78809 Set the supportsAlpha flag for TiledBackingStore when the layer has contentsOpaque enabled. Use the flag for ShareableBitmaps created by TiledBackingStore. For now this will not have impact on performance/memory, because we allocate the same type of buffers for opaque and transparent tiles. Reviewed by Kenneth Rohde Christiansen. * WebProcess/WebCoreSupport/WebGraphicsLayer.cpp: (WebCore::WebGraphicsLayer::setContentsOpaque): (WebCore::WebGraphicsLayer::setContentsScale): (WebCore::WebGraphicsLayer::createBackingStore): (WebCore): (WebCore::WebGraphicsLayer::updateContentBuffers): * WebProcess/WebCoreSupport/WebGraphicsLayer.h: (WebGraphicsLayer): * WebProcess/WebPage/TiledBackingStoreRemoteTile.cpp: (WebKit::TiledBackingStoreRemoteTile::updateBackBuffer): 2012-02-16 Sergio Villar Senin [soup] Move important SoupSession feature initialization to WebCore https://bugs.webkit.org/show_bug.cgi?id=68602 Reviewed by Martin Robinson. Moved content sniffer and decoder initialization from the WebProcess to WebCore because network stuff will not work as expected without them. No new tests required as we're just moving stuff from the WebProcess to WebCore. * WebProcess/gtk/WebProcessMainGtk.cpp: (WebKit::WebProcessMainGtk): 2012-02-16 Adenilson Cavalcanti [Qt][WK2] Split QWebPermissionRequest into QWebSecurityOrigin https://bugs.webkit.org/show_bug.cgi?id=73215 Reviewed by Kenneth Rohde Christiansen. Introducing a new class to expose security origin information (port/scheme/etc), useful for inspecting the origin of permission requests. * Target.pri: * UIProcess/API/qt/qtwebsecurityorigin.cpp: Added. (QtWebSecurityOrigin::QtWebSecurityOrigin): (QtWebSecurityOrigin::~QtWebSecurityOrigin): (QtWebSecurityOrigin::host): (QtWebSecurityOrigin::scheme): (QtWebSecurityOrigin::path): (QtWebSecurityOrigin::port): (QtWebSecurityOrigin::setHost): (QtWebSecurityOrigin::setScheme): (QtWebSecurityOrigin::setPath): (QtWebSecurityOrigin::setPort): * UIProcess/API/qt/qtwebsecurityorigin_p.h: Added. * UIProcess/API/qt/tests/qmltests/WebView/tst_origin.qml: Added. * UIProcess/API/qt/qwebpermissionrequest.cpp: (QWebPermissionRequestPrivate::QWebPermissionRequestPrivate): (QWebPermissionRequest::securityOrigin): * UIProcess/API/qt/qwebpermissionrequest_p.h: * UIProcess/API/qt/tests/qmltests/qmltests.pro: 2012-02-16 Patrick Gansterer [CMake] Add missing include directories. * CMakeLists.txt: 2012-02-16 Carlos Garcia Campos [GTK] Document that local paths in html loaded with loadHTML might cause the web process to terminate https://bugs.webkit.org/show_bug.cgi?id=78719 Reviewed by Martin Robinson. * UIProcess/API/gtk/WebKitWebView.cpp: 2012-02-15 Anders Carlsson Add TiledCoreAnimationDrawingArea::forceRepaint https://bugs.webkit.org/show_bug.cgi?id=78749 Reviewed by Sam Weinig. * WebProcess/WebPage/mac/TiledCoreAnimationDrawingArea.h: * WebProcess/WebPage/mac/TiledCoreAnimationDrawingArea.mm: (WebKit::TiledCoreAnimationDrawingArea::forceRepaint): Force a repaint and synchronize the layer tree to the UI process. 2012-02-15 Enrica Casucci Refactor ClipboardMac class to use PlatformStrategies. https://bugs.webkit.org/show_bug.cgi?id=78554 Reviewed by Anders Carlsson. * WebProcess/WebCoreSupport/WebDragClient.h: Changed method signature to reference the pasteboard by name. * WebProcess/WebCoreSupport/WebPlatformStrategies.cpp: Added new methods. (WebKit::WebPlatformStrategies::changeCount): (WebKit::WebPlatformStrategies::uniqueName): * WebProcess/WebCoreSupport/WebPlatformStrategies.h: Ditto. * WebProcess/WebCoreSupport/mac/WebDragClientMac.mm: (WebKit::WebDragClient::declareAndWriteDragImage): Changed method signature to reference the pasteboard by name. 2012-02-15 Sadrul Habib Chowdhury Notify ChromeClient when touch-event handlers are installed/removed. https://bugs.webkit.org/show_bug.cgi?id=77440 Reviewed by Darin Fisher and Ryosuke Niwa. * UIProcess/WebPageProxy.h: (WebKit::WebPageProxy::numTouchEventHandlersChanged): * WebProcess/WebCoreSupport/WebChromeClient.h: 2012-02-15 Patrick Gansterer [CMake] Move RunLoop to WebCore/platform https://bugs.webkit.org/show_bug.cgi?id=78504 Reviewed by Adam Roben. * CMakeLists.txt: Remove RunLoop.cpp from list of souces. 2012-02-14 Simon Hausmann [Qt] Eliminate first set of QtWidgets dependencies from WebCore https://bugs.webkit.org/show_bug.cgi?id=78611 Reviewed by Kenneth Rohde Christiansen. * UIProcess/qt/QtWebPageEventHandler.cpp: Add missing QCursor include to fix compilation. 2012-02-15 Roland Steiner