Restart renderer process for all navigations and reloads, fixes #157.

This commit is contained in:
Cheng Zhao 2014-01-14 16:03:01 +08:00
parent 931182b677
commit 249366c90a
5 changed files with 45 additions and 2 deletions

View file

@ -98,4 +98,14 @@ void AtomRendererClient::WillReleaseScriptContext(
}
}
bool AtomRendererClient::ShouldFork(WebKit::WebFrame* frame,
const GURL& url,
const std::string& http_method,
bool is_initial_navigation,
bool is_server_redirect,
bool* send_referrer) {
// Handle all the navigations and reloads in browser.
return true;
}
} // namespace atom

View file

@ -35,6 +35,12 @@ class AtomRendererClient : public content::ContentRendererClient {
virtual void WillReleaseScriptContext(WebKit::WebFrame* frame,
v8::Handle<v8::Context>,
int world_id) OVERRIDE;
virtual bool ShouldFork(WebKit::WebFrame* frame,
const GURL& url,
const std::string& http_method,
bool is_initial_navigation,
bool is_server_redirect,
bool* send_referrer);
std::vector<node::Environment*> web_page_envs_;