Changeset 91898 in webkit


Ignore:
Timestamp:
Jul 27, 2011, 9:08:40 PM (14 years ago)
Author:
commit-queue@webkit.org
Message:

[EFL] Drop WorkQueueItemEfl.h in favour of the general WorkQueueItem.h
https://bugs.webkit.org/show_bug.cgi?id=65269

Patch by Raphael Kubo da Costa <kubo@profusion.mobi> on 2011-07-27
Reviewed by Kent Tamura.

WorkQueueItemEfl.h was being included by efl's
LayoutTestControllerEfl.cpp, however the top-level
LayoutTestController still included WorkQueueItem.h, causing a lot of
type mismatches when running the WorkQueueItem code.

We can stick to the original WorkQueueItem header by making a few
changes to EFL's LayoutTestController.

This should make tests such as
fast/loader/non-deferred-substitute-load.html stop crashing.

  • DumpRenderTree/efl/LayoutTestControllerEfl.cpp:

(LayoutTestController::queueLoad):

  • DumpRenderTree/efl/WorkQueueItemEfl.cpp:

(LoadItem::invoke):
(LoadHTMLStringItem::invoke):
(ScriptItem::invoke):

  • DumpRenderTree/efl/WorkQueueItemEfl.h: Removed.
Location:
trunk/Tools
Files:
1 deleted
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/Tools/ChangeLog

    r91884 r91898  
     12011-07-27  Raphael Kubo da Costa  <kubo@profusion.mobi>
     2
     3        [EFL] Drop WorkQueueItemEfl.h in favour of the general WorkQueueItem.h
     4        https://bugs.webkit.org/show_bug.cgi?id=65269
     5
     6        Reviewed by Kent Tamura.
     7
     8        WorkQueueItemEfl.h was being included by efl's
     9        LayoutTestControllerEfl.cpp, however the top-level
     10        LayoutTestController still included WorkQueueItem.h, causing a lot of
     11        type mismatches when running the WorkQueueItem code.
     12
     13        We can stick to the original WorkQueueItem header by making a few
     14        changes to EFL's LayoutTestController.
     15
     16        This should make tests such as
     17        fast/loader/non-deferred-substitute-load.html stop crashing.
     18
     19        * DumpRenderTree/efl/LayoutTestControllerEfl.cpp:
     20        (LayoutTestController::queueLoad):
     21        * DumpRenderTree/efl/WorkQueueItemEfl.cpp:
     22        (LoadItem::invoke):
     23        (LoadHTMLStringItem::invoke):
     24        (ScriptItem::invoke):
     25        * DumpRenderTree/efl/WorkQueueItemEfl.h: Removed.
     26
    1272011-07-27  Dimitri Glazkov  <dglazkov@chromium.org>
    228
  • trunk/Tools/DumpRenderTree/efl/LayoutTestControllerEfl.cpp

    r90361 r91898  
    4242#include "OwnFastMallocPtr.h"
    4343#include "WorkQueue.h"
    44 #include "WorkQueueItemEfl.h"
     44#include "WorkQueueItem.h"
    4545#include "ewk_private.h"
    4646#include <EWebKit.h>
     
    177177    String absoluteUrl = String::fromUTF8(ewk_frame_uri_get(mainFrame));
    178178    absoluteUrl.append(url->characters(), url->length());
    179     String targetString(target->characters(), target->length());
    180 
    181     WorkQueue::shared()->queue(new LoadItem(absoluteUrl, targetString));
     179
     180    JSRetainPtr<JSStringRef> jsAbsoluteURL(
     181        Adopt, JSStringCreateWithUTF8CString(absoluteUrl.utf8().data()));
     182
     183    WorkQueue::shared()->queue(new LoadItem(jsAbsoluteURL.get(), target));
    182184}
    183185
  • trunk/Tools/DumpRenderTree/efl/WorkQueueItemEfl.cpp

    r89053 r91898  
    2121
    2222#include "config.h"
    23 #include "WorkQueueItemEfl.h"
     23#include "WorkQueueItem.h"
    2424
    2525#include "DumpRenderTree.h"
     
    2727#include <EWebKit.h>
    2828#include <JavaScriptCore/JSStringRef.h>
     29#include <JavaScriptCore/OpaqueJSString.h>
     30#include <JavaScriptCore/runtime/UString.h>
    2931#include <JavaScriptCore/wtf/text/CString.h>
    3032
     
    3335    Evas_Object* targetFrame;
    3436
    35     if (m_target.isEmpty())
     37    if (!m_target->length())
    3638        targetFrame = mainFrame;
    3739    else
    38         targetFrame = ewk_frame_child_find(mainFrame, m_target.utf8().data());
     40        targetFrame = ewk_frame_child_find(mainFrame, m_target->ustring().utf8().data());
    3941
    40     ewk_frame_uri_set(targetFrame, m_url.utf8().data());
     42    ewk_frame_uri_set(targetFrame, m_url->ustring().utf8().data());
    4143
    4244    return true;
     
    4547bool LoadHTMLStringItem::invoke() const
    4648{
    47     if (m_unreachableURL.isEmpty())
    48         ewk_frame_contents_set(mainFrame, m_content.utf8().data(), 0, 0, 0, m_baseURL.utf8().data());
     49    if (!m_unreachableURL->length())
     50        ewk_frame_contents_set(mainFrame, m_content->ustring().utf8().data(), 0, 0, 0, m_baseURL->ustring().utf8().data());
    4951    else
    50         ewk_frame_contents_alternate_set(mainFrame, m_content.utf8().data(), 0, 0, 0, m_baseURL.utf8().data(), m_unreachableURL.utf8().data());
     52        ewk_frame_contents_alternate_set(mainFrame, m_content->ustring().utf8().data(), 0, 0, 0, m_baseURL->ustring().utf8().data(), m_unreachableURL->ustring().utf8().data());
    5153
    5254    return true;
     
    6163bool ScriptItem::invoke() const
    6264{
    63     return ewk_frame_script_execute(mainFrame, m_script.utf8().data());
     65    return ewk_frame_script_execute(mainFrame, m_script->ustring().utf8().data());
    6466}
    6567
Note: See TracChangeset for help on using the changeset viewer.