Changeset 85867 in webkit


Ignore:
Timestamp:
May 5, 2011 12:05:02 PM (13 years ago)
Author:
commit-queue@webkit.org
Message:

2011-05-05 Chang Shu <cshu@webkit.org>

Reviewed by Andreas Kling.

[Qt][WK2] Support PageGroup in QGraphicsWKView/QWKPage constructors
https://bugs.webkit.org/show_bug.cgi?id=59638

Unskip passed tests.

  • platform/qt-wk2/Skipped:

2011-05-05 Chang Shu <cshu@webkit.org>

Reviewed by Andreas Kling.

[Qt][WK2] Support PageGroup in QGraphicsWKView/QWKPage constructors
https://bugs.webkit.org/show_bug.cgi?id=59638

Added private constructors for class QGraphicsWKView and QWKPage to support
WKPageGroupRef.

  • UIProcess/API/qt/qgraphicswkview.cpp: (QGraphicsWKView::QGraphicsWKView): (QGraphicsWKView::~QGraphicsWKView): (QGraphicsWKView::init):
  • UIProcess/API/qt/qgraphicswkview.h:
  • UIProcess/API/qt/qwkpage.cpp: (QWKPagePrivate::QWKPagePrivate): (QWKPage::QWKPage): (QWKPage::~QWKPage): (QWKPage::init):
  • UIProcess/API/qt/qwkpage.h:
  • UIProcess/API/qt/qwkpage_p.h:

2011-05-05 Chang Shu <cshu@webkit.org>

Reviewed by Andreas Kling.

[Qt][WK2] Support PageGroup in QGraphicsWKView/QWKPage constructors
https://bugs.webkit.org/show_bug.cgi?id=59638

  1. Call QGraphicsWKView constructor with pageGroupRef.
  2. Disable setFontFamily calls as it breaks Qt test fonts.
  • WebKitTestRunner/TestController.cpp: (WTR::TestController::resetStateToConsistentValues):
  • WebKitTestRunner/qt/PlatformWebViewQt.cpp: (WTR::WebView::WebView): (WTR::PlatformWebView::PlatformWebView):
Location:
trunk
Files:
11 edited

Legend:

Unmodified
Added
Removed
  • trunk/LayoutTests/ChangeLog

    r85852 r85867  
     12011-05-05  Chang Shu  <cshu@webkit.org>
     2
     3        Reviewed by Andreas Kling.
     4
     5        [Qt][WK2] Support PageGroup in QGraphicsWKView/QWKPage constructors
     6        https://bugs.webkit.org/show_bug.cgi?id=59638
     7
     8        Unskip passed tests.
     9
     10        * platform/qt-wk2/Skipped:
     11
    1122011-05-05  Andrey Kosyakov  <caseq@chromium.org>
    213
  • trunk/LayoutTests/platform/qt-wk2/Skipped

    r85686 r85867  
    34443444fast/dom/shadow/gc-shadow.html
    34453445
    3446 # [Qt][WK2] Support PageGroup in QGraphicsWKView/QWKPage constructors
    3447 # https://bugs.webkit.org/show_bug.cgi?id=59638
    3448 fast/dom/Document/early-document-access.html
    3449 fast/dom/Window/closure-access-after-navigation-window.html
    3450 fast/dom/Window/dom-access-from-closure-window.html
    3451 fast/dom/Window/window-early-properties.html
    3452 fast/frames/iframe-reparenting-new-page.html
    3453 fast/frames/sandboxed-iframe-close-top-noclose.html
    3454 fast/frames/sandboxed-iframe-close-top.html
    3455 fast/history/history-subframe-with-name.html
    3456 fast/loader/ping-error.html
    3457 fast/loader/stateobjects/replacestate-in-iframe.html
    3458 storage/domstorage/localstorage/window-open.html
    3459 storage/domstorage/sessionstorage/window-open.html
    3460 
    34613446# [Qt][WK2] Incorrect line number dumping
    34623447# https://bugs.webkit.org/show_bug.cgi?id=60074
  • trunk/Source/WebKit2/ChangeLog

    r85863 r85867  
     12011-05-05  Chang Shu  <cshu@webkit.org>
     2
     3        Reviewed by Andreas Kling.
     4
     5        [Qt][WK2] Support PageGroup in QGraphicsWKView/QWKPage constructors
     6        https://bugs.webkit.org/show_bug.cgi?id=59638
     7
     8        Added private constructors for class QGraphicsWKView and QWKPage to support
     9        WKPageGroupRef.
     10
     11        * UIProcess/API/qt/qgraphicswkview.cpp:
     12        (QGraphicsWKView::QGraphicsWKView):
     13        (QGraphicsWKView::~QGraphicsWKView):
     14        (QGraphicsWKView::init):
     15        * UIProcess/API/qt/qgraphicswkview.h:
     16        * UIProcess/API/qt/qwkpage.cpp:
     17        (QWKPagePrivate::QWKPagePrivate):
     18        (QWKPage::QWKPage):
     19        (QWKPage::~QWKPage):
     20        (QWKPage::init):
     21        * UIProcess/API/qt/qwkpage.h:
     22        * UIProcess/API/qt/qwkpage_p.h:
     23
    1242011-05-05  Brent Fulgham  <bfulgham@webkit.org>
    225
  • trunk/Source/WebKit2/UIProcess/API/qt/qgraphicswkview.cpp

    r84201 r85867  
    6666    , d(new QGraphicsWKViewPrivate(this))
    6767{
     68    d->page = new QWKPage(context);
     69    init(backingStoreType);
     70}
     71
     72QGraphicsWKView::QGraphicsWKView(QWKContext* context, WKPageGroupRef pageGroupRef, BackingStoreType backingStoreType, QGraphicsItem* parent)
     73    : QGraphicsWidget(parent)
     74    , d(new QGraphicsWKViewPrivate(this))
     75{
     76    d->page = new QWKPage(context, pageGroupRef);
     77    init(backingStoreType);
     78}
     79
     80void QGraphicsWKView::init(BackingStoreType backingStoreType)
     81{
    6882    setFocusPolicy(Qt::StrongFocus);
    6983    setAcceptHoverEvents(true);
    7084
    71 
    7285#if ENABLE(TILED_BACKING_STORE)
    7386    if (backingStoreType == Tiled)
     
    7588#endif
    7689
    77     d->page = new QWKPage(context);
    7890    d->page->d->init(this, backingStoreType);
    7991    connect(d->page, SIGNAL(titleChanged(QString)), this, SIGNAL(titleChanged(QString)));
  • trunk/Source/WebKit2/UIProcess/API/qt/qgraphicswkview.h

    r84613 r85867  
    1414class QWKContext;
    1515class QGraphicsWKViewPrivate;
     16namespace WTR {
     17class WebView;
     18};
    1619
    1720WKStringRef WKStringCreateWithQString(const QString& qString);
     
    9194
    9295private:
     96    QGraphicsWKView(QWKContext*, WKPageGroupRef, BackingStoreType = Simple, QGraphicsItem* parent = 0);
     97    void init(BackingStoreType);
     98
    9399    Q_PRIVATE_SLOT(d, void onScaleChanged())
    94100    Q_PRIVATE_SLOT(d, void onToolTipChanged(const QString&))
     
    97103    friend class QGraphicsWKViewPrivate;
    98104    friend class TiledDrawingAreaProxy;
     105    friend class WTR::WebView;
    99106};
    100107
  • trunk/Source/WebKit2/UIProcess/API/qt/qwkpage.cpp

    r85860 r85867  
    9090}
    9191
    92 QWKPagePrivate::QWKPagePrivate(QWKPage* qq, QWKContext* c)
     92QWKPagePrivate::QWKPagePrivate(QWKPage* qq, QWKContext* c, WKPageGroupRef pageGroupRef)
    9393    : q(qq)
    9494    , view(0)
     
    100100{
    101101    memset(actions, 0, sizeof(actions));
    102     page = context->d->context->createWebPage(this, 0);
     102    page = context->d->context->createWebPage(this, toImpl(pageGroupRef));
    103103    history = QWKHistoryPrivate::createHistory(page->backForwardList());
    104104}
     
    428428}
    429429
     430QWKPage::QWKPage(QWKContext* context, WKPageGroupRef pageGroupRef)
     431    : d(new QWKPagePrivate(this, context, pageGroupRef))
     432{
     433    init();
     434}
     435
    430436QWKPage::QWKPage(QWKContext* context)
    431437    : d(new QWKPagePrivate(this, context))
     438{
     439    init();
     440}
     441
     442void QWKPage::init()
    432443{
    433444    WKPageLoaderClient loadClient = {
  • trunk/Source/WebKit2/UIProcess/API/qt/qwkpage.h

    r84201 r85867  
    144144
    145145private:
     146    QWKPage(QWKContext*, WKPageGroupRef);
     147    void init();
    146148#ifndef QT_NO_ACTION
    147149    Q_PRIVATE_SLOT(d, void _q_webActionTriggered(bool checked));
  • trunk/Source/WebKit2/UIProcess/API/qt/qwkpage_p.h

    r84082 r85867  
    4141class QWKPagePrivate : WebKit::PageClient {
    4242public:
    43     QWKPagePrivate(QWKPage*, QWKContext*);
     43    QWKPagePrivate(QWKPage*, QWKContext*, WKPageGroupRef = 0);
    4444    ~QWKPagePrivate();
    4545
  • trunk/Tools/ChangeLog

    r85861 r85867  
     12011-05-05  Chang Shu  <cshu@webkit.org>
     2
     3        Reviewed by Andreas Kling.
     4
     5        [Qt][WK2] Support PageGroup in QGraphicsWKView/QWKPage constructors
     6        https://bugs.webkit.org/show_bug.cgi?id=59638
     7
     8        1. Call QGraphicsWKView constructor with pageGroupRef.
     9        2. Disable setFontFamily calls as it breaks Qt test fonts.
     10
     11        * WebKitTestRunner/TestController.cpp:
     12        (WTR::TestController::resetStateToConsistentValues):
     13        * WebKitTestRunner/qt/PlatformWebViewQt.cpp:
     14        (WTR::WebView::WebView):
     15        (WTR::PlatformWebView::PlatformWebView):
     16
    1172011-05-05  Joseph Pecoraro  <joepeck@webkit.org>
    218
  • trunk/Tools/WebKitTestRunner/TestController.cpp

    r85860 r85867  
    386386#endif
    387387
     388#if !PLATFORM(QT)
    388389    static WKStringRef standardFontFamily = WKStringCreateWithUTF8CString("Times");
    389390    static WKStringRef cursiveFontFamily = WKStringCreateWithUTF8CString("Apple Chancery");
     
    399400    WKPreferencesSetSansSerifFontFamily(preferences, sansSerifFontFamily);
    400401    WKPreferencesSetSerifFontFamily(preferences, serifFontFamily);
     402#endif
    401403
    402404    m_mainWebView->focus();
  • trunk/Tools/WebKitTestRunner/qt/PlatformWebViewQt.cpp

    r81135 r85867  
    3636class WebView : public QGraphicsView {
    3737public:
    38     WebView(WKContextRef);
     38    WebView(WKContextRef, WKPageGroupRef);
    3939
    4040    QGraphicsWKView* wkView() const { return m_item; }
     
    4646};
    4747
    48 WebView::WebView(WKContextRef contextRef)
     48WebView::WebView(WKContextRef contextRef, WKPageGroupRef pageGroupRef)
    4949    : QGraphicsView()
    50     , m_item(new QGraphicsWKView(new QWKContext(contextRef, this)))
     50    , m_item(new QGraphicsWKView(new QWKContext(contextRef, this), pageGroupRef))
    5151{
    5252    setScene(new QGraphicsScene(this));
     
    5454}
    5555
    56 PlatformWebView::PlatformWebView(WKContextRef contextRef, WKPageGroupRef)
    57     : m_view(new WebView(contextRef))
     56PlatformWebView::PlatformWebView(WKContextRef contextRef, WKPageGroupRef pageGroupRef)
     57    : m_view(new WebView(contextRef, pageGroupRef))
    5858    , m_window(new QMainWindow())
    5959{
Note: See TracChangeset for help on using the changeset viewer.