Diff
Modified: trunk/Source/WebKit/efl/ChangeLog (92038 => 92039)
--- trunk/Source/WebKit/efl/ChangeLog 2011-07-30 02:00:35 UTC (rev 92038)
+++ trunk/Source/WebKit/efl/ChangeLog 2011-07-30 02:00:35 UTC (rev 92039)
@@ -1,3 +1,23 @@
+2011-07-29 Michal Pakula vel Rutka <[email protected]>
+
+ [EFL] Implement EditorClientEfl::respondToChangedContents
+ http://bugs.webkit.org/show_bug.cgi?id=64259
+
+ Implements respondToChangedContents by calling callback both from
+ ewk_frame and ewk_view with frame and view objects respectively.
+
+ Reviewed by Antonio Gomes.
+
+ * WebCoreSupport/EditorClientEfl.cpp:
+ (WebCore::EditorClientEfl::respondToChangedContents):
+ * ewk/ewk_frame.cpp:
+ (ewk_frame_editor_client_contents_changed):
+ * ewk/ewk_frame.h:
+ * ewk/ewk_private.h:
+ * ewk/ewk_view.cpp:
+ (ewk_view_editor_client_contents_changed):
+ * ewk/ewk_view.h:
+
2011-07-29 Grzegorz Czajkowski <[email protected]>
[EFL] Move ewk_view API documentation to the header file
Modified: trunk/Source/WebKit/efl/WebCoreSupport/EditorClientEfl.cpp (92038 => 92039)
--- trunk/Source/WebKit/efl/WebCoreSupport/EditorClientEfl.cpp 2011-07-30 02:00:35 UTC (rev 92038)
+++ trunk/Source/WebKit/efl/WebCoreSupport/EditorClientEfl.cpp 2011-07-30 02:00:35 UTC (rev 92039)
@@ -122,7 +122,15 @@
void EditorClientEfl::respondToChangedContents()
{
- notImplemented();
+ Evas_Object* frame = ewk_view_frame_focused_get(m_view);
+
+ if (!frame)
+ frame = ewk_view_frame_main_get(m_view);
+
+ if (!frame)
+ return;
+
+ ewk_frame_editor_client_contents_changed(frame);
}
void EditorClientEfl::respondToChangedSelection()
Modified: trunk/Source/WebKit/efl/ewk/ewk_frame.cpp (92038 => 92039)
--- trunk/Source/WebKit/efl/ewk/ewk_frame.cpp 2011-07-30 02:00:35 UTC (rev 92038)
+++ trunk/Source/WebKit/efl/ewk/ewk_frame.cpp 2011-07-30 02:00:35 UTC (rev 92039)
@@ -2032,3 +2032,18 @@
EWK_FRAME_SD_GET_OR_RETURN(o, sd);
ewk_view_editor_client_selection_changed(sd->view);
}
+
+/**
+ * @internal
+ * Reports that editor client's contents were changed.
+ *
+ * @param o Frame
+ *
+ * Emits signal: "editorclient,contents,changed" with no parameters.
+ */
+void ewk_frame_editor_client_contents_changed(Evas_Object *o)
+{
+ evas_object_smart_callback_call(o, "editorclient,contents,changed", 0);
+ EWK_FRAME_SD_GET_OR_RETURN(o, sd);
+ ewk_view_editor_client_contents_changed(sd->view);
+}
Modified: trunk/Source/WebKit/efl/ewk/ewk_frame.h (92038 => 92039)
--- trunk/Source/WebKit/efl/ewk/ewk_frame.h 2011-07-30 02:00:35 UTC (rev 92038)
+++ trunk/Source/WebKit/efl/ewk/ewk_frame.h 2011-07-30 02:00:35 UTC (rev 92039)
@@ -58,6 +58,8 @@
* - "resource,request,willsend", Ewk_Frame_Resource_Request*: a resource will
* be requested.
* - "state,save", void: frame's state will be saved as a history item.
+ * - "editorclient,contents,changed", void: reports that editor client's
+ * contents were changed
*/
#ifndef ewk_frame_h
Modified: trunk/Source/WebKit/efl/ewk/ewk_private.h (92038 => 92039)
--- trunk/Source/WebKit/efl/ewk/ewk_private.h 2011-07-30 02:00:35 UTC (rev 92038)
+++ trunk/Source/WebKit/efl/ewk/ewk_private.h 2011-07-30 02:00:35 UTC (rev 92039)
@@ -111,6 +111,7 @@
void ewk_view_download_request(Evas_Object *o, Ewk_Download *download);
+void ewk_view_editor_client_contents_changed(Evas_Object *o);
void ewk_view_editor_client_selection_changed(Evas_Object *o);
int ewk_util_dpi_get(void);
@@ -179,6 +180,7 @@
const char* ewk_settings_default_user_agent_get(void);
+void ewk_frame_editor_client_contents_changed(Evas_Object *o);
void ewk_frame_editor_client_selection_changed(Evas_Object *o);
#ifdef __cplusplus
Modified: trunk/Source/WebKit/efl/ewk/ewk_view.cpp (92038 => 92039)
--- trunk/Source/WebKit/efl/ewk/ewk_view.cpp 2011-07-30 02:00:35 UTC (rev 92038)
+++ trunk/Source/WebKit/efl/ewk/ewk_view.cpp 2011-07-30 02:00:35 UTC (rev 92039)
@@ -3646,3 +3646,16 @@
{
evas_object_smart_callback_call(o, "editorclient,selection,changed", 0);
}
+
+/**
+ * @internal
+ * Reports to the view that editor client's contents were changed.
+ *
+ * @param o View.
+ *
+ * Emits signal: "editorclient,contents,changed" with no parameters.
+ */
+void ewk_view_editor_client_contents_changed(Evas_Object *o)
+{
+ evas_object_smart_callback_call(o, "editorclient,contents,changed", 0);
+}
Modified: trunk/Source/WebKit/efl/ewk/ewk_view.h (92038 => 92039)
--- trunk/Source/WebKit/efl/ewk/ewk_view.h 2011-07-30 02:00:35 UTC (rev 92038)
+++ trunk/Source/WebKit/efl/ewk/ewk_view.h 2011-07-30 02:00:35 UTC (rev 92039)
@@ -90,6 +90,8 @@
* - "restore", Evas_Object *: reports that view should be restored to default conditions
* and it gives a frame that originated restore as an argument.
* - "tooltip,text,set", const char*: sets tooltip text and displays if it is currently hidden.
+ * - "editorclient,contents,changed", void: reports to the view that editor
+ * client's contents were changed
*/
typedef struct _Ewk_View_Smart_Data Ewk_View_Smart_Data;