}
}
-void WebContentsDelegateEfl::LoadingStateChanged(WebContents* source) {
+void WebContentsDelegateEfl::LoadingStateChanged(WebContents* source,
+ bool to_different_document) {
if (source->IsLoading())
web_view_->SmartCallback<EWebViewCallbacks::LoadProgressStarted>().call();
else
void WebContentsDelegateEfl::WebContentsCreated(
WebContents* source_contents,
- int64 source_frame_id,
+ int opener_render_frame_id,
const string16& frame_name,
const GURL& target_url,
WebContents* new_contents) {
}
void WebContentsDelegateEfl::RegisterProtocolHandler(WebContents* web_contents,
- const std::string& protocol, const GURL& url, const string16& title, bool user_gesture) {
+ const std::string& protocol, const GURL& url, bool user_gesture) {
scoped_ptr<tizen_webview::Custom_Handlers_Data> protocol_data(
new tizen_webview::Custom_Handlers_Data(protocol.c_str(),
- url.host().c_str(), url.spec().c_str(), UTF16ToUTF8(title).c_str()));
+ url.host().c_str(), url.spec().c_str()));
web_view_->SmartCallback<EWebViewCallbacks::RegisterProtocolHandler>().call(protocol_data.get());
}
web_view_->InvokeAuthCallback(login_delegate, request->url(), realm);
}
-void WebContentsDelegateEfl::DidStartProvisionalLoadForFrame(int64 frame_id,
- int64 parent_frame_id,
- bool is_main_frame,
+void WebContentsDelegateEfl::DidStartProvisionalLoadForFrame(RenderFrameHost* render_frame_host,
const GURL& validated_url,
bool is_error_page,
- bool is_iframe_srcdoc,
- RenderViewHost* render_view_host) {
+ bool is_iframe_srcdoc) {
web_view_->SmartCallback<EWebViewCallbacks::ProvisionalLoadStarted>().call();
}
-void WebContentsDelegateEfl::DidCommitProvisionalLoadForFrame(int64 frame_id,
- bool is_main_frame,
+void WebContentsDelegateEfl::DidCommitProvisionalLoadForFrame(RenderFrameHost* render_frame_host,
const GURL& url,
- PageTransition transition_type,
- RenderViewHost* render_view_host) {
+ PageTransition transition_type) {
web_view_->SmartCallback<EWebViewCallbacks::LoadCommitted>().call();
}
static_cast<BrowserContextEfl*>(web_contents_->GetBrowserContext())->AddVisitedURLs(params.redirects);
}
-void WebContentsDelegateEfl::DidFailProvisionalLoad(int64 frame_id,
- const string16& frame_unique_name,
- bool is_main_frame,
+void WebContentsDelegateEfl::DidFailProvisionalLoad(RenderFrameHost* render_frame_host,
const GURL& validated_url,
int error_code,
- const string16& error_description,
- RenderViewHost* render_view_host) {
- DidFailLoad(frame_id, validated_url, is_main_frame, error_code, error_description, render_view_host);
+ const string16& error_description) {
+ DidFailLoad(render_frame_host, validated_url, error_code, error_description);
}
-void WebContentsDelegateEfl::DidFailLoad(int64 frame_id,
+void WebContentsDelegateEfl::DidFailLoad(RenderFrameHost* render_frame_host,
const GURL& validated_url,
- bool is_main_frame,
int error_code,
- const string16& error_description,
- RenderViewHost* render_view_host) {
- if (!is_main_frame)
+ const string16& error_description) {
+ if (render_frame_host->GetParent())
return;
scoped_ptr<_Ewk_Error> error(new _Ewk_Error(error_code,
web_view_->SmartCallback<EWebViewCallbacks::LoadError>().call(error.get());
}
-void WebContentsDelegateEfl::DidFinishLoad(int64 frame_id,
- const GURL& validated_url,
- bool is_main_frame,
- RenderViewHost* render_view_host) {
- if (!is_main_frame)
+void WebContentsDelegateEfl::DidFinishLoad(RenderFrameHost* render_frame_host,
+ const GURL& validated_url) {
+ if (!render_frame_host->GetParent())
return;
NavigationEntry *entry = web_contents()->GetController().GetActiveEntry();
web_view_->SmartCallback<EWebViewCallbacks::LoadStarted>().call();
}
-void WebContentsDelegateEfl::DidUpdateFaviconURL(int32 page_id, const std::vector<FaviconURL>& candidates) {
+void WebContentsDelegateEfl::DidUpdateFaviconURL(const std::vector<FaviconURL>& candidates) {
// select and set proper favicon
for (unsigned int i = 0; i < candidates.size(); ++i) {
FaviconURL favicon = candidates[i];
web_view_->HidePopupMenu();
}
-void WebContentsDelegateEfl::ShowContextMenu(RenderFrameHost* render_frame_host, const ContextMenuParams& params) {
- web_view_->ShowContextMenu(params);
-}
-
-void WebContentsDelegateEfl::CancelContextMenu(int request_id) {
- web_view_->CancelContextMenu(request_id);
-}
-
void WebContentsDelegateEfl::FindReply(WebContents* web_contents,
int request_id,
int number_of_matches,
Send(reply);
}
-void WebContentsDelegateEfl::DidFirstVisuallyNonEmptyPaint(int32 page_id) {
+void WebContentsDelegateEfl::DidFirstVisuallyNonEmptyPaint() {
web_view_->SmartCallback<EWebViewCallbacks::FrameRendered>().call(0);
}
unsigned changed_flags) OVERRIDE;
virtual void LoadProgressChanged(WebContents* source, double progress) OVERRIDE;
- virtual void LoadingStateChanged(WebContents* source) OVERRIDE;
+ virtual void LoadingStateChanged(WebContents* source,
+ bool to_different_document) OVERRIDE;
virtual bool ShouldCreateWebContents(
WebContents*,
virtual void WebContentsCreated(
WebContents* source_contents,
- int64 source_frame_id,
+ int opener_render_frame_id,
const base::string16& frame_name,
const GURL& target_url,
WebContents* new_contents) OVERRIDE;
void RegisterProtocolHandler(WebContents* web_contents,
const std::string& protocol,
const GURL& url,
- const base::string16& title,
bool user_gesture) OVERRIDE;
void FindReply(WebContents* web_contents,
EWebView* web_view() const { return web_view_; }
WebContents* web_contents() const { return web_contents_; }
- virtual void DidStartProvisionalLoadForFrame(int64 frame_id,
- int64 parent_frame_id,
- bool is_main_frame,
+ virtual void DidStartProvisionalLoadForFrame(RenderFrameHost* render_frame_host,
const GURL& validated_url,
bool is_error_page,
- bool is_iframe_srcdoc,
- RenderViewHost* render_view_host) OVERRIDE;
+ bool is_iframe_srcdoc) OVERRIDE;
- virtual void DidCommitProvisionalLoadForFrame(int64 frame_id,
- bool is_main_frame,
+ virtual void DidCommitProvisionalLoadForFrame(RenderFrameHost* render_frame_host,
const GURL& url,
- PageTransition transition_type,
- RenderViewHost* render_view_host) OVERRIDE;
+ PageTransition transition_type) OVERRIDE;
virtual void DidNavigateAnyFrame(const LoadCommittedDetails& details, const FrameNavigateParams& params) OVERRIDE;
void OnAuthRequired(net::URLRequest* request,
const std::string& realm,
LoginDelegateEfl* login_delegate);
- virtual void DidFailProvisionalLoad(int64 frame_id,
- const base::string16& frame_unique_name,
- bool is_main_frame,
+ virtual void DidFailProvisionalLoad(RenderFrameHost* render_frame_host,
const GURL& validated_url,
int error_code,
- const base::string16& error_description,
- RenderViewHost* render_view_host) OVERRIDE;
- virtual void DidFailLoad(int64 frame_id,
+ const base::string16& error_description) OVERRIDE;
+ virtual void DidFailLoad(RenderFrameHost* render_frame_host,
const GURL& validated_url,
- bool is_main_frame,
int error_code,
- const base::string16& error_description,
- RenderViewHost* render_view_host) OVERRIDE;
+ const base::string16& error_description) OVERRIDE;
- virtual void DidFinishLoad(int64 frame_id,
- const GURL& validated_url,
- bool is_main_frame,
- RenderViewHost* render_view_host) OVERRIDE;
+ virtual void DidFinishLoad(RenderFrameHost* render_frame_host,
+ const GURL& validated_url) OVERRIDE;
virtual void DidStartLoading(RenderViewHost* render_view_host) OVERRIDE;
- virtual void DidUpdateFaviconURL(int32 page_id,
- const std::vector<FaviconURL>& candidates) OVERRIDE;
+ virtual void DidUpdateFaviconURL(const std::vector<FaviconURL>& candidates) OVERRIDE;
virtual void DidDownloadFavicon(bool success, const GURL& icon_url, const SkBitmap& bitmap);
void OnFormSubmit(const GURL&);
void SetContentSecurityPolicy(const std::string& policy, tizen_webview::ContentSecurityPolicyType header_type);
void ShowPopupMenu(const gfx::Rect& rect, blink::TextDirection textDirection, double pageScaleFactor, const std::vector<MenuItem>& items, int data, int selectedIndex, bool multiple);
void HidePopupMenu();
- virtual void ShowContextMenu(RenderFrameHost* render_frame_host, const ContextMenuParams& params) OVERRIDE;
- virtual void CancelContextMenu(int request_id) OVERRIDE;
+
void set_new_window_policy(bool policy) { should_open_new_window_ = policy; }
bool get_new_window_policy() const { return should_open_new_window_; }
JavaScriptDialogManager* GetJavaScriptDialogManager() OVERRIDE;
- void DidFirstVisuallyNonEmptyPaint(int32 page_id) OVERRIDE;
+ void DidFirstVisuallyNonEmptyPaint() OVERRIDE;
bool OnMessageReceived(const IPC::Message& message) OVERRIDE;
void OnPrintedMetafileReceived(const DidPrintPagesParams& params);