⚠ Archived content — this site is no longer maintained.   Current WebKit documentation is at docs.webkit.org.

Changeset 120428 in webkit


Ignore:
Timestamp:
Jun 15, 2012, 2:24:04 AM (14 years ago)
Author:
commit-queue@webkit.org
Message:

[EFL] EFL's LayoutTestController does not support titleTextDirection
https://bugs.webkit.org/show_bug.cgi?id=86475

Patch by Christophe Dumez <Christophe Dumez> on 2012-06-15
Reviewed by Hajime Morita.

Source/WebKit/efl:

Emit the "title,changed" signal even if the title direction has
changed but not its text.

  • ewk/ewk_frame.cpp:

(ewk_frame_title_set):

Tools:

Add titleTextDirection getter and setter to LayoutTestController and
expose its value to JavaScript.
Update the titleTextDirection value from EFL's "title,changed"
callback in DumpRenderTree.

  • DumpRenderTree/LayoutTestController.cpp:

(LayoutTestController::LayoutTestController):
(getTitleTextDirectionCallback):
(LayoutTestController::staticValues):

  • DumpRenderTree/LayoutTestController.h:

(LayoutTestController::titleTextDirection):
(LayoutTestController::setTitleTextDirection):
(LayoutTestController):

  • DumpRenderTree/efl/DumpRenderTreeChrome.cpp:

(DumpRenderTreeChrome::onFrameTitleChanged):

LayoutTests:

Unskip title-directionality tests now that EFL's LayoutTestController
supports titleTextDirection.

  • platform/efl/TestExpectations:
Location:
trunk
Files:
8 edited

Legend:

Unmodified
Added
Removed
  • trunk/LayoutTests/ChangeLog

    r120426 r120428  
     12012-06-15  Christophe Dumez  <christophe.dumez@intel.com>
     2
     3        [EFL] EFL's LayoutTestController does not support titleTextDirection
     4        https://bugs.webkit.org/show_bug.cgi?id=86475
     5
     6        Reviewed by Hajime Morita.
     7
     8        Unskip title-directionality tests now that EFL's LayoutTestController
     9        supports titleTextDirection.
     10
     11        * platform/efl/TestExpectations:
     12
    1132012-06-15  Emil A Eklund  <eae@chromium.org>
    214
  • trunk/LayoutTests/platform/efl/TestExpectations

    r120371 r120428  
    463463BUGWK84778 : ietestcenter/css3/multicolumn/column-width-negative-001.htm = IMAGE
    464464
    465 // Expose title direction in WebKit API
    466 BUGWK58845 : fast/dom/title-directionality.html = TEXT
    467 BUGWK58845 : fast/dom/title-directionality-removeChild.html = TEXT
    468 
    469465// Tests that sometimes fail on the bot (for GTK and Chromium ports as well)
    470466BUGWK77631 : fast/multicol/span/span-as-immediate-child-property-removal.html = TEXT PASS
  • trunk/Source/WebKit/efl/ChangeLog

    r120369 r120428  
     12012-06-15  Christophe Dumez  <christophe.dumez@intel.com>
     2
     3        [EFL] EFL's LayoutTestController does not support titleTextDirection
     4        https://bugs.webkit.org/show_bug.cgi?id=86475
     5
     6        Reviewed by Hajime Morita.
     7
     8        Emit the "title,changed" signal even if the title direction has
     9        changed but not its text.
     10
     11        * ewk/ewk_frame.cpp:
     12        (ewk_frame_title_set):
     13
    1142012-06-14  Ryuan Choi  <ryuan.choi@samsung.com>
    215
  • trunk/Source/WebKit/efl/ewk/ewk_frame.cpp

    r119243 r120428  
    16171617void ewk_frame_title_set(Evas_Object* ewkFrame, const Ewk_Text_With_Direction* title)
    16181618{
    1619     DBG("ewkFrame=%p, title=%s", ewkFrame, title->string ? title->string : "(null)");
     1619    DBG("ewkFrame=%p, title=%s, direction=%s", ewkFrame, title->string ? title->string : "(null)", title->direction == EWK_TEXT_DIRECTION_LEFT_TO_RIGHT ? "ltr" : "rtl");
    16201620    EWK_FRAME_SD_GET_OR_RETURN(ewkFrame, smartData);
    1621     if (!eina_stringshare_replace(&smartData->title.string, title->string))
     1621    if (!eina_stringshare_replace(&smartData->title.string, title->string) && (smartData->title.direction == title->direction))
    16221622        return;
    16231623    smartData->title.direction = title->direction;
  • trunk/Tools/ChangeLog

    r120427 r120428  
     12012-06-15  Christophe Dumez  <christophe.dumez@intel.com>
     2
     3        [EFL] EFL's LayoutTestController does not support titleTextDirection
     4        https://bugs.webkit.org/show_bug.cgi?id=86475
     5
     6        Reviewed by Hajime Morita.
     7
     8        Add titleTextDirection getter and setter to LayoutTestController and
     9        expose its value to JavaScript.
     10        Update the titleTextDirection value from EFL's "title,changed"
     11        callback in DumpRenderTree.
     12
     13        * DumpRenderTree/LayoutTestController.cpp:
     14        (LayoutTestController::LayoutTestController):
     15        (getTitleTextDirectionCallback):
     16        (LayoutTestController::staticValues):
     17        * DumpRenderTree/LayoutTestController.h:
     18        (LayoutTestController::titleTextDirection):
     19        (LayoutTestController::setTitleTextDirection):
     20        (LayoutTestController):
     21        * DumpRenderTree/efl/DumpRenderTreeChrome.cpp:
     22        (DumpRenderTreeChrome::onFrameTitleChanged):
     23
    1242012-06-15  Christophe Dumez  <christophe.dumez@intel.com>
    225
  • trunk/Tools/DumpRenderTree/LayoutTestController.cpp

    r120054 r120428  
    9797    , m_testPathOrURL(testPathOrURL)
    9898    , m_expectedPixelHash(expectedPixelHash)
     99    , m_titleTextDirection("ltr")
    99100{
    100101}
     
    21592160#endif
    21602161
     2162static JSValueRef getTitleTextDirectionCallback(JSContextRef context, JSObjectRef thisObject, JSStringRef propertyName, JSValueRef* exception)
     2163{
     2164    LayoutTestController* controller = static_cast<LayoutTestController*>(JSObjectGetPrivate(thisObject));
     2165    JSRetainPtr<JSStringRef> titleDirection(Adopt, JSStringCreateWithUTF8CString(controller->titleTextDirection().c_str()));
     2166    return JSValueMakeString(context, titleDirection.get());
     2167}
     2168
    21612169static bool setGlobalFlagCallback(JSContextRef context, JSObjectRef thisObject, JSStringRef propertyName, JSValueRef value, JSValueRef* exception)
    21622170{
     
    22622270        { "platformName", getPlatformNameCallback, 0, kJSPropertyAttributeReadOnly | kJSPropertyAttributeDontDelete },
    22632271#endif
     2272        { "titleTextDirection", getTitleTextDirectionCallback, 0, kJSPropertyAttributeReadOnly | kJSPropertyAttributeDontDelete },
    22642273        { 0, 0, 0, 0 }
    22652274    };
  • trunk/Tools/DumpRenderTree/LayoutTestController.h

    r120054 r120428  
    360360
    361361    void setTextDirection(JSStringRef);
     362    const std::string& titleTextDirection() const { return m_titleTextDirection; }
     363    void setTitleTextDirection(const std::string& direction) { m_titleTextDirection = direction; }
    362364
    363365    // Custom full screen behavior.
     
    424426    std::string m_testPathOrURL;
    425427    std::string m_expectedPixelHash;    // empty string if no hash
     428    std::string m_titleTextDirection;
    426429
    427430    std::set<std::string> m_willSendRequestClearHeaders;
  • trunk/Tools/DumpRenderTree/efl/DumpRenderTreeChrome.cpp

    r120386 r120428  
    470470        printf("WebView updated the title for history URL \"%s\" to \"%s\".\n", ewk_frame_uri_get(frame)
    471471               , (titleText && titleText->string) ? titleText->string : "");
     472
     473    gLayoutTestController->setTitleTextDirection(titleText->direction == EWK_TEXT_DIRECTION_LEFT_TO_RIGHT ? "ltr" : "rtl");
    472474}
    473475
Note: See TracChangeset for help on using the changeset viewer.