Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(152)

Side by Side Diff: chrome/browser/ui/views/external_tab_container_win.cc

Issue 10963018: Rework arguments of HistoryService::AddPage() (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix Windows compile Created 8 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "chrome/browser/ui/views/external_tab_container_win.h" 5 #include "chrome/browser/ui/views/external_tab_container_win.h"
6 6
7 #include <string> 7 #include <string>
8 8
9 #include "base/bind.h" 9 #include "base/bind.h"
10 #include "base/bind_helpers.h" 10 #include "base/bind_helpers.h"
(...skipping 416 matching lines...) Expand 10 before | Expand all | Expand 10 after
427 content::FrameNavigateParams nav_params; 427 content::FrameNavigateParams nav_params;
428 nav_params.referrer = content::Referrer(referrer, 428 nav_params.referrer = content::Referrer(referrer,
429 params.referrer.policy); 429 params.referrer.policy);
430 nav_params.url = params.url; 430 nav_params.url = params.url;
431 nav_params.page_id = -1; 431 nav_params.page_id = -1;
432 nav_params.transition = content::PAGE_TRANSITION_LINK; 432 nav_params.transition = content::PAGE_TRANSITION_LINK;
433 433
434 content::LoadCommittedDetails details; 434 content::LoadCommittedDetails details;
435 details.did_replace_entry = false; 435 details.did_replace_entry = false;
436 436
437 scoped_refptr<history::HistoryAddPageArgs> add_page_args( 437 const history::HistoryAddPageArgs& add_page_args =
438 tab_contents_->history_tab_helper()-> 438 tab_contents_->history_tab_helper()->
439 CreateHistoryAddPageArgs(params.url, details, nav_params)); 439 CreateHistoryAddPageArgs(params.url, details, nav_params);
440 tab_contents_->history_tab_helper()-> 440 tab_contents_->history_tab_helper()->
441 UpdateHistoryForNavigation(add_page_args); 441 UpdateHistoryForNavigation(add_page_args);
442 442
443 return tab_contents_->web_contents(); 443 return tab_contents_->web_contents();
444 } 444 }
445 break; 445 break;
446 default: 446 default:
447 NOTREACHED(); 447 NOTREACHED();
448 break; 448 break;
449 } 449 }
(...skipping 822 matching lines...) Expand 10 before | Expand all | Expand 10 after
1272 if (params.disposition == CURRENT_TAB) { 1272 if (params.disposition == CURRENT_TAB) {
1273 DCHECK(route_all_top_level_navigations_); 1273 DCHECK(route_all_top_level_navigations_);
1274 forward_params.disposition = NEW_FOREGROUND_TAB; 1274 forward_params.disposition = NEW_FOREGROUND_TAB;
1275 } 1275 }
1276 WebContents* new_contents = 1276 WebContents* new_contents =
1277 ExternalTabContainerWin::OpenURLFromTab(source, forward_params); 1277 ExternalTabContainerWin::OpenURLFromTab(source, forward_params);
1278 // support only one navigation for a dummy tab before it is killed. 1278 // support only one navigation for a dummy tab before it is killed.
1279 ::DestroyWindow(GetNativeView()); 1279 ::DestroyWindow(GetNativeView());
1280 return new_contents; 1280 return new_contents;
1281 } 1281 }
OLDNEW
« no previous file with comments | « chrome/browser/ui/toolbar/back_forward_menu_model_unittest.cc ('k') | chrome/browser/ui/webui/bidi_checker_web_ui_test.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698