2 Copyright (C) 2009-2010 ProFUSION embedded systems
3 Copyright (C) 2009-2010 Samsung Electronics
5 This library is free software; you can redistribute it and/or
6 modify it under the terms of the GNU Library General Public
7 License as published by the Free Software Foundation; either
8 version 2 of the License, or (at your option) any later version.
10 This library is distributed in the hope that it will be useful,
11 but WITHOUT ANY WARRANTY; without even the implied warranty of
12 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 Library General Public License for more details.
15 You should have received a copy of the GNU Library General Public License
16 along with this library; see the file COPYING.LIB. If not, write to
17 the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
18 Boston, MA 02110-1301, USA.
23 * @brief Private methods of WebKit-EFL.
29 #include "BackForwardListImpl.h"
35 #include "ewk_logging.h"
39 #include <wtf/PassRefPtr.h>
40 #include <wtf/Vector.h>
46 // If defined, ewk will do type checking to ensure objects are of correct type
47 #define EWK_TYPE_CHECK 1
49 // forward declarations
51 struct PopupMenuClient;
53 struct ContextMenuItem;
56 void ewk_view_ready(Evas_Object *o);
57 void ewk_view_input_method_state_set(Evas_Object* o, Eina_Bool active);
58 void ewk_view_title_set(Evas_Object *o, const char *title);
59 void ewk_view_uri_changed(Evas_Object *o);
60 void ewk_view_load_started(Evas_Object *o);
61 void ewk_view_load_provisional(Evas_Object *o);
62 void ewk_view_frame_main_load_started(Evas_Object *o);
63 void ewk_view_frame_main_cleared(Evas_Object *o);
64 void ewk_view_frame_main_icon_received(Evas_Object *o);
65 void ewk_view_load_finished(Evas_Object *o, const Ewk_Frame_Load_Error *error);
66 void ewk_view_load_error(Evas_Object *o, const Ewk_Frame_Load_Error *error);
67 void ewk_view_load_progress_changed(Evas_Object *o);
68 void ewk_view_load_show(Evas_Object* o);
69 void ewk_view_restore_state(Evas_Object *o, Evas_Object *frame);
70 Evas_Object *ewk_view_window_create(Evas_Object *o, Eina_Bool javascript, const WebCore::WindowFeatures* coreFeatures);
71 void ewk_view_window_close(Evas_Object *o);
73 void ewk_view_mouse_link_hover_in(Evas_Object *o, void *data);
74 void ewk_view_mouse_link_hover_out(Evas_Object *o);
76 void ewk_view_toolbars_visible_set(Evas_Object *o, Eina_Bool visible);
77 void ewk_view_toolbars_visible_get(Evas_Object *o, Eina_Bool *visible);
79 void ewk_view_statusbar_visible_set(Evas_Object *o, Eina_Bool visible);
80 void ewk_view_statusbar_visible_get(Evas_Object *o, Eina_Bool *visible);
81 void ewk_view_statusbar_text_set(Evas_Object *o, const char *text);
83 void ewk_view_scrollbars_visible_set(Evas_Object *o, Eina_Bool visible);
84 void ewk_view_scrollbars_visible_get(Evas_Object *o, Eina_Bool *visible);
86 void ewk_view_menubar_visible_set(Evas_Object *o, Eina_Bool visible);
87 void ewk_view_menubar_visible_get(Evas_Object *o, Eina_Bool *visible);
89 void ewk_view_tooltip_text_set(Evas_Object *o, const char *text);
91 void ewk_view_add_console_message(Evas_Object *o, const char *message, unsigned int lineNumber, const char *sourceID);
93 void ewk_view_run_javascript_alert(Evas_Object *o, Evas_Object *frame, const char *message);
94 Eina_Bool ewk_view_run_javascript_confirm(Evas_Object *o, Evas_Object *frame, const char *message);
95 Eina_Bool ewk_view_run_javascript_prompt(Evas_Object *o, Evas_Object *frame, const char *message, const char *defaultValue, char **value);
96 Eina_Bool ewk_view_should_interrupt_javascript(Evas_Object *o);
97 uint64_t ewk_view_exceeded_database_quota(Evas_Object *o, Evas_Object *frame, const char *databaseName, uint64_t current_size, uint64_t expected_size);
99 Eina_Bool ewk_view_run_open_panel(Evas_Object *o, Evas_Object *frame, Eina_Bool allows_multiple_files, const Eina_List *suggested_filenames, Eina_List **selected_filenames);
101 void ewk_view_repaint(Evas_Object *o, Evas_Coord x, Evas_Coord y, Evas_Coord w, Evas_Coord h);
102 void ewk_view_scroll(Evas_Object *o, Evas_Coord dx, Evas_Coord dy, Evas_Coord sx, Evas_Coord sy, Evas_Coord sw, Evas_Coord sh, Evas_Coord cx, Evas_Coord cy, Evas_Coord cw, Evas_Coord ch, Eina_Bool main_frame);
103 WebCore::Page *ewk_view_core_page_get(const Evas_Object *o);
105 WTF::PassRefPtr<WebCore::Frame> ewk_view_frame_create(Evas_Object *o, Evas_Object *frame, const WTF::String& name, WebCore::HTMLFrameOwnerElement* ownerElement, const WebCore::KURL& url, const WTF::String& referrer);
107 WTF::PassRefPtr<WebCore::Widget> ewk_view_plugin_create(Evas_Object* o, Evas_Object* frame, const WebCore::IntSize& pluginSize, WebCore::HTMLPlugInElement* element, const WebCore::KURL& url, const WTF::Vector<WTF::String>& paramNames, const WTF::Vector<WTF::String>& paramValues, const WTF::String& mimeType, bool loadManually);
109 void ewk_view_popup_new(Evas_Object *o, WebCore::PopupMenuClient* client, int selected, const WebCore::IntRect& rect);
110 void ewk_view_viewport_attributes_set(Evas_Object *o, const WebCore::ViewportArguments& arguments);
112 void ewk_view_download_request(Evas_Object *o, Ewk_Download *download);
114 int ewk_view_dpi_get(void);
116 #if ENABLE(TOUCH_EVENTS)
117 void ewk_view_need_touch_events_set(Evas_Object*, bool needed);
118 Eina_Bool ewk_view_need_touch_events_get(Evas_Object*);
121 Ewk_History *ewk_history_new(WebCore::BackForwardListImpl *history);
122 void ewk_history_free(Ewk_History *history);
124 #if ENABLE(CONTEXT_MENUS)
126 Ewk_Context_Menu *ewk_context_menu_new(Evas_Object *view, WebCore::ContextMenuController *controller);
127 Eina_Bool ewk_context_menu_free(Ewk_Context_Menu *o);
128 void ewk_context_menu_item_append(Ewk_Context_Menu *o, WebCore::ContextMenuItem& core);
129 Ewk_Context_Menu *ewk_context_menu_custom_get(Ewk_Context_Menu *o);
130 void ewk_context_menu_show(Ewk_Context_Menu *o);
134 Ewk_Window_Features *ewk_window_features_new_from_core(const WebCore::WindowFeatures* core);
136 Evas_Object *ewk_frame_add(Evas *e);
137 Eina_Bool ewk_frame_init(Evas_Object *o, Evas_Object *view, WebCore::Frame *frame);
138 Evas_Object *ewk_frame_child_add(Evas_Object *o, WTF::PassRefPtr<WebCore::Frame> child, const WTF::String& name, const WebCore::KURL& url, const WTF::String& referrer);
140 WebCore::Frame *ewk_frame_core_get(const Evas_Object *o);
141 void ewk_frame_core_gone(Evas_Object *o);
143 void ewk_frame_load_started(Evas_Object *o);
144 void ewk_frame_load_provisional(Evas_Object *o);
145 void ewk_frame_load_firstlayout_finished(Evas_Object *o);
146 void ewk_frame_load_firstlayout_nonempty_finished(Evas_Object *o);
147 void ewk_frame_load_document_finished(Evas_Object *o);
148 void ewk_frame_load_finished(Evas_Object *o, const char *error_domain, int error_code, Eina_Bool is_cancellation, const char *error_description, const char *failing_url);
149 void ewk_frame_load_error(Evas_Object *o, const char *error_domain, int error_code, Eina_Bool is_cancellation, const char *error_description, const char *failing_url);
150 void ewk_frame_load_progress_changed(Evas_Object *o);
152 void ewk_frame_request_will_send(Evas_Object *o, Ewk_Frame_Resource_Request *request);
153 void ewk_frame_request_assign_identifier(Evas_Object *o, const Ewk_Frame_Resource_Request *request);
154 void ewk_frame_view_state_save(Evas_Object *o, WebCore::HistoryItem* item);
156 void ewk_frame_did_perform_first_navigation(Evas_Object *o);
158 void ewk_frame_contents_size_changed(Evas_Object *o, Evas_Coord w, Evas_Coord h);
159 void ewk_frame_title_set(Evas_Object *o, const char *title);
161 void ewk_frame_view_create_for_view(Evas_Object *o, Evas_Object *view);
162 Eina_Bool ewk_frame_uri_changed(Evas_Object *o);
163 void ewk_frame_force_layout(Evas_Object *o);
165 WTF::PassRefPtr<WebCore::Widget> ewk_frame_plugin_create(Evas_Object* o, const WebCore::IntSize& pluginSize, WebCore::HTMLPlugInElement* element, const WebCore::KURL& url, const WTF::Vector<WTF::String>& paramNames, const WTF::Vector<WTF::String>& paramValues, const WTF::String& mimeType, bool loadManually);
167 Eina_Bool ewk_view_navigation_policy_decision(Evas_Object* o, Ewk_Frame_Resource_Request* request);
169 void ewk_view_contents_size_changed(Evas_Object *o, Evas_Coord w, Evas_Coord h);
171 WebCore::FloatRect ewk_view_page_rect_get(Evas_Object *o);
173 const char* ewk_settings_default_user_agent_get(void);
179 #endif // ewk_private_h