Changeset 96411 in webkit
- Timestamp:
- Sep 30, 2011 11:44:46 AM (13 years ago)
- Location:
- trunk/Tools
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Tools/ChangeLog
r96405 r96411 1 2011-09-30 Raphael Kubo da Costa <kubo@profusion.mobi> 2 3 [EFL] Support and keep track of extra windows (views). 4 https://bugs.webkit.org/show_bug.cgi?id=68454 5 6 Reviewed by Antonio Gomes. 7 8 So far, window.open and related JavaScript code would not work, as 9 DRTView did not implementation 10 Ewk_View_Smart_Class::window_{open,close}. The default implementation 11 in ewk just returns the current window/view, which broke any 12 layouttest which relied on window.open. 13 14 We now properly create and remove these new views. Unfortunately, the 15 current way ewk works (and due to the fact that we cannot pass class 16 methods as function pointers to the EFL functions), DRTView needs to 17 know that DRTChrome exists and call `browser' directly in some points. 18 19 * DumpRenderTree/efl/DumpRenderTreeView.cpp: 20 (onWindowCreate): 21 (onWindowCloseDelayed): 22 (onWindowClose): 23 (drtViewTiledAdd): 24 1 25 2011-09-30 Qi Zhang <qi.2.zhang@nokia.com> 2 26 -
trunk/Tools/DumpRenderTree/efl/DumpRenderTreeView.cpp
r89821 r96411 27 27 #include "DumpRenderTreeView.h" 28 28 29 #include "DumpRenderTree.h" 30 #include "DumpRenderTreeChrome.h" 31 #include "LayoutTestController.h" 29 32 #include <EWebKit.h> 33 #include <Ecore.h> 30 34 #include <Eina.h> 31 35 #include <Evas.h> … … 59 63 } 60 64 65 static Evas_Object* onWindowCreate(Ewk_View_Smart_Data*, Eina_Bool, const Ewk_Window_Features*) 66 { 67 return gLayoutTestController->canOpenWindows() ? browser->createNewWindow() : 0; 68 } 69 70 static Eina_Bool onWindowCloseDelayed(void* data) 71 { 72 Evas_Object* view = static_cast<Evas_Object*>(data); 73 browser->removeWindow(view); 74 return EINA_FALSE; 75 } 76 77 static void onWindowClose(Ewk_View_Smart_Data* smartData) 78 { 79 Evas_Object* view = smartData->self; 80 ecore_idler_add(onWindowCloseDelayed, view); 81 } 82 61 83 Evas_Object* drtViewTiledAdd(Evas* evas) 62 84 { … … 73 95 api.run_javascript_confirm = onJavaScriptConfirm; 74 96 api.run_javascript_prompt = onJavaScriptPrompt; 97 api.window_create = onWindowCreate; 98 api.window_close = onWindowClose; 75 99 76 100 return evas_object_smart_add(evas, evas_smart_class_new(&api.sc));
Note: See TracChangeset
for help on using the changeset viewer.