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

Side by Side Diff: chrome/browser/ui/browser_navigator.cc

Issue 11419276: Remove tabstrip wrappers in browser_tabstrip. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: gtk Created 8 years 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
« no previous file with comments | « chrome/browser/ui/browser_focus_uitest.cc ('k') | chrome/browser/ui/browser_tabstrip.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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/browser_navigator.h" 5 #include "chrome/browser/ui/browser_navigator.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 8
9 #include "base/command_line.h" 9 #include "base/command_line.h"
10 #include "base/stringprintf.h" 10 #include "base/stringprintf.h"
(...skipping 542 matching lines...) Expand 10 before | Expand all | Expand 10 after
553 chrome::GetWebContentsAt(params->browser, singleton_index); 553 chrome::GetWebContentsAt(params->browser, singleton_index);
554 554
555 if (target->IsCrashed()) { 555 if (target->IsCrashed()) {
556 target->GetController().Reload(true); 556 target->GetController().Reload(true);
557 } else if (params->path_behavior == NavigateParams::IGNORE_AND_NAVIGATE && 557 } else if (params->path_behavior == NavigateParams::IGNORE_AND_NAVIGATE &&
558 target->GetURL() != params->url) { 558 target->GetURL() != params->url) {
559 LoadURLInContents(target, params->url, params); 559 LoadURLInContents(target, params->url, params);
560 } 560 }
561 561
562 // If the singleton tab isn't already selected, select it. 562 // If the singleton tab isn't already selected, select it.
563 if (params->source_contents != params->target_contents) 563 if (params->source_contents != params->target_contents) {
564 chrome::ActivateTabAt(params->browser, singleton_index, user_initiated); 564 params->browser->tab_strip_model()->ActivateTabAt(singleton_index,
565 user_initiated);
566 }
565 } 567 }
566 568
567 if (params->disposition != CURRENT_TAB) { 569 if (params->disposition != CURRENT_TAB) {
568 content::NotificationService::current()->Notify( 570 content::NotificationService::current()->Notify(
569 chrome::NOTIFICATION_TAB_ADDED, 571 chrome::NOTIFICATION_TAB_ADDED,
570 content::Source<content::WebContentsDelegate>(params->browser), 572 content::Source<content::WebContentsDelegate>(params->browser),
571 content::Details<WebContents>(params->target_contents->web_contents())); 573 content::Details<WebContents>(params->target_contents->web_contents()));
572 } 574 }
573 } 575 }
574 576
(...skipping 16 matching lines...) Expand all
591 bool reverse_on_redirect = false; 593 bool reverse_on_redirect = false;
592 content::BrowserURLHandler::GetInstance()->RewriteURLIfNecessary( 594 content::BrowserURLHandler::GetInstance()->RewriteURLIfNecessary(
593 &rewritten_url, browser_context, &reverse_on_redirect); 595 &rewritten_url, browser_context, &reverse_on_redirect);
594 596
595 // Some URLs are mapped to uber subpages. Do not allow them in incognito. 597 // Some URLs are mapped to uber subpages. Do not allow them in incognito.
596 return !(rewritten_url.scheme() == chrome::kChromeUIScheme && 598 return !(rewritten_url.scheme() == chrome::kChromeUIScheme &&
597 rewritten_url.host() == chrome::kChromeUIUberHost); 599 rewritten_url.host() == chrome::kChromeUIUberHost);
598 } 600 }
599 601
600 } // namespace chrome 602 } // namespace chrome
OLDNEW
« no previous file with comments | « chrome/browser/ui/browser_focus_uitest.cc ('k') | chrome/browser/ui/browser_tabstrip.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698