From 16b2f08cd30064ff4bf1e3d6b931c9fb6ca4480b Mon Sep 17 00:00:00 2001 From: Cheng Zhao Date: Sun, 26 Apr 2015 21:31:48 +0800 Subject: [PATCH] Don't use Chromium's history list --- atom/browser/api/atom_api_web_contents.cc | 2 ++ atom/browser/native_window.cc | 1 + 2 files changed, 3 insertions(+) diff --git a/atom/browser/api/atom_api_web_contents.cc b/atom/browser/api/atom_api_web_contents.cc index 4e27e1e64e59..0400e9457e37 100644 --- a/atom/browser/api/atom_api_web_contents.cc +++ b/atom/browser/api/atom_api_web_contents.cc @@ -140,6 +140,7 @@ content::WebContents* WebContents::OpenURLFromTab( load_url_params.is_renderer_initiated = params.is_renderer_initiated; load_url_params.transferred_global_request_id = params.transferred_global_request_id; + load_url_params.should_clear_history_list = true; web_contents()->GetController().LoadURLWithParams(load_url_params); return web_contents(); @@ -380,6 +381,7 @@ void WebContents::LoadURL(const GURL& url, const mate::Dictionary& options) { blink::WebReferrerPolicyDefault); params.transition_type = ui::PAGE_TRANSITION_TYPED; + params.should_clear_history_list = true; params.override_user_agent = content::NavigationController::UA_OVERRIDE_TRUE; web_contents()->GetController().LoadURLWithParams(params); } diff --git a/atom/browser/native_window.cc b/atom/browser/native_window.cc index c2ed3b0fe79e..0f757e8c619f 100644 --- a/atom/browser/native_window.cc +++ b/atom/browser/native_window.cc @@ -565,6 +565,7 @@ content::WebContents* NativeWindow::OpenURLFromTab( load_url_params.is_renderer_initiated = params.is_renderer_initiated; load_url_params.transferred_global_request_id = params.transferred_global_request_id; + load_url_params.should_clear_history_list = true; source->GetController().LoadURLWithParams(load_url_params); return source;