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

Side by Side Diff: chrome/browser/ui/views/frame/browser_view.cc

Issue 5314002: Changes appearance of the NTP for the guest mode. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/chrome/browser/chromeos/login
Patch Set: Created 10 years, 1 month 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/chromeos/login/login_utils.cc ('k') | no next file » | 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) 2010 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2010 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/views/frame/browser_view.h" 5 #include "chrome/browser/views/frame/browser_view.h"
6 6
7 #if defined(OS_LINUX) 7 #if defined(OS_LINUX)
8 #include <gtk/gtk.h> 8 #include <gtk/gtk.h>
9 #endif 9 #endif
10 10
(...skipping 577 matching lines...) Expand 10 before | Expand all | Expand 10 after
588 588
589 bool BrowserView::UseVerticalTabs() const { 589 bool BrowserView::UseVerticalTabs() const {
590 return browser_->tabstrip_model()->delegate()->UseVerticalTabs(); 590 return browser_->tabstrip_model()->delegate()->UseVerticalTabs();
591 } 591 }
592 592
593 bool BrowserView::IsOffTheRecord() const { 593 bool BrowserView::IsOffTheRecord() const {
594 return browser_->profile()->IsOffTheRecord(); 594 return browser_->profile()->IsOffTheRecord();
595 } 595 }
596 596
597 bool BrowserView::ShouldShowOffTheRecordAvatar() const { 597 bool BrowserView::ShouldShowOffTheRecordAvatar() const {
598 bool should_show_off_the_record_avatar = 598 return IsOffTheRecord() && IsBrowserTypeNormal();
599 IsOffTheRecord() && IsBrowserTypeNormal();
600 #if defined(OS_CHROMEOS)
601 should_show_off_the_record_avatar = should_show_off_the_record_avatar &&
602 !CommandLine::ForCurrentProcess()->HasSwitch(switches::kGuestSession);
603 #endif
604 return should_show_off_the_record_avatar;
605 } 599 }
606 600
607 bool BrowserView::AcceleratorPressed(const views::Accelerator& accelerator) { 601 bool BrowserView::AcceleratorPressed(const views::Accelerator& accelerator) {
608 std::map<views::Accelerator, int>::const_iterator iter = 602 std::map<views::Accelerator, int>::const_iterator iter =
609 accelerator_table_.find(accelerator); 603 accelerator_table_.find(accelerator);
610 DCHECK(iter != accelerator_table_.end()); 604 DCHECK(iter != accelerator_table_.end());
611 605
612 int command_id = iter->second; 606 int command_id = iter->second;
613 if (browser_->command_updater()->SupportsCommand(command_id) && 607 if (browser_->command_updater()->SupportsCommand(command_id) &&
614 browser_->command_updater()->IsCommandEnabled(command_id)) { 608 browser_->command_updater()->IsCommandEnabled(command_id)) {
(...skipping 1889 matching lines...) Expand 10 before | Expand all | Expand 10 after
2504 SetAccessibleName(l10n_util::GetString(IDS_PRODUCT_NAME)); 2498 SetAccessibleName(l10n_util::GetString(IDS_PRODUCT_NAME));
2505 2499
2506 return view; 2500 return view;
2507 } 2501 }
2508 #endif 2502 #endif
2509 2503
2510 // static 2504 // static
2511 FindBar* BrowserWindow::CreateFindBar(Browser* browser) { 2505 FindBar* BrowserWindow::CreateFindBar(Browser* browser) {
2512 return browser::CreateFindBar(static_cast<BrowserView*>(browser->window())); 2506 return browser::CreateFindBar(static_cast<BrowserView*>(browser->window()));
2513 } 2507 }
OLDNEW
« no previous file with comments | « chrome/browser/chromeos/login/login_utils.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698