Changeset 73039 in webkit


Ignore:
Timestamp:
Dec 1, 2010 10:36:44 AM (13 years ago)
Author:
mitz@apple.com
Message:

WebKitTestRunner needs layoutTestController.findString
https://bugs.webkit.org/show_bug.cgi?id=50238

Reviewed by Darin Adler.

  • WebKitTestRunner/InjectedBundle/Bindings/LayoutTestController.idl: Added findString().
  • WebKitTestRunner/InjectedBundle/LayoutTestController.cpp:

(WTR::LayoutTestController::findString): Updated signature for autogenerated bindings.

  • WebKitTestRunner/InjectedBundle/LayoutTestController.h: Ditto.
Location:
trunk/WebKitTools
Files:
6 edited

Legend:

Unmodified
Added
Removed
  • trunk/WebKitTools/ChangeLog

    r73028 r73039  
     12010-12-01  Dan Bernstein  <mitz@apple.com>
     2
     3        Reviewed by Darin Adler.
     4
     5        WebKitTestRunner needs layoutTestController.findString
     6        https://bugs.webkit.org/show_bug.cgi?id=50238
     7
     8        * WebKitTestRunner/InjectedBundle/Bindings/LayoutTestController.idl: Added findString().
     9        * WebKitTestRunner/InjectedBundle/LayoutTestController.cpp:
     10        (WTR::LayoutTestController::findString): Updated signature for autogenerated bindings.
     11        * WebKitTestRunner/InjectedBundle/LayoutTestController.h: Ditto.
     12
    1132010-12-01  Steve Falkenburg  <sfalken@apple.com>
    214
  • trunk/WebKitTools/MiniBrowser/MiniBrowser.xcodeproj

    • Property svn:ignore
      •  

        old new  
        1 *.mode2v3
        21*.pbxuser
        3 *.perspective
         2*.perspective*
         3*.mode*
  • trunk/WebKitTools/WebKitTestRunner/InjectedBundle/Bindings/LayoutTestController.idl

    r71458 r73039  
    7474        // Compositing testing.
    7575        DOMString layerTreeAsText();
     76
     77        // Text search testing.
     78        boolean findString(in DOMString target, in object optionsArray);
    7679    };
    7780
  • trunk/WebKitTools/WebKitTestRunner/InjectedBundle/LayoutTestController.cpp

    r72937 r73039  
    234234}
    235235
    236 bool LayoutTestController::findString(JSContextRef context, JSStringRef target, JSObjectRef optionsArray)
     236bool LayoutTestController::findString(JSStringRef target, JSValueRef optionsArrayAsValue)
    237237{
    238238    WKFindOptions options = 0;
    239239
     240    WKBundleFrameRef mainFrame = WKBundlePageGetMainFrame(InjectedBundle::shared().page()->page());
     241    JSContextRef context = WKBundleFrameGetJavaScriptContext(mainFrame);
    240242    JSRetainPtr<JSStringRef> lengthPropertyName(Adopt, JSStringCreateWithUTF8CString("length"));
     243    JSObjectRef optionsArray = JSValueToObject(context, optionsArrayAsValue, 0);
    241244    JSValueRef lengthValue = JSObjectGetProperty(context, optionsArray, lengthPropertyName.get(), 0);
    242245    if (!JSValueIsNumber(context, lengthValue))
  • trunk/WebKitTools/WebKitTestRunner/InjectedBundle/LayoutTestController.h

    r72937 r73039  
    103103
    104104    // Text search testing.
    105     bool findString(JSContextRef, JSStringRef, JSObjectRef optionsArray);
     105    bool findString(JSStringRef, JSValueRef optionsArray);
    106106
    107107    enum WhatToDump { RenderTree, MainFrameText, AllFramesText };
  • trunk/WebKitTools/WebKitTestRunner/WebKitTestRunner.xcodeproj

    • Property svn:ignore
      •  

        old new  
        11*.pbxuser
        2 *.mode2v3
         2*.perspective*
         3*.mode*
Note: See TracChangeset for help on using the changeset viewer.