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

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

Issue 2906803002: Rename MaximizeMode to TabletMode (Closed)
Patch Set: updated filter Created 3 years, 7 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
OLDNEW
1 // Copyright 2012 The Chromium Authors. All rights reserved. 1 // Copyright 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/frame/browser_non_client_frame_view_ash.h" 5 #include "chrome/browser/ui/views/frame/browser_non_client_frame_view_ash.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 8
9 #include "ash/ash_layout_constants.h" 9 #include "ash/ash_layout_constants.h"
10 #include "ash/frame/caption_buttons/frame_caption_button_container_view.h" 10 #include "ash/frame/caption_buttons/frame_caption_button_container_view.h"
(...skipping 307 matching lines...) Expand 10 before | Expand all | Expand 10 after
318 void BrowserNonClientFrameViewAsh::OnOverviewModeStarting() { 318 void BrowserNonClientFrameViewAsh::OnOverviewModeStarting() {
319 frame()->GetNativeWindow()->SetProperty(aura::client::kTopViewColor, 319 frame()->GetNativeWindow()->SetProperty(aura::client::kTopViewColor,
320 GetFrameColor()); 320 GetFrameColor());
321 caption_button_container_->SetVisible(false); 321 caption_button_container_->SetVisible(false);
322 } 322 }
323 323
324 void BrowserNonClientFrameViewAsh::OnOverviewModeEnded() { 324 void BrowserNonClientFrameViewAsh::OnOverviewModeEnded() {
325 caption_button_container_->SetVisible(true); 325 caption_button_container_->SetVisible(true);
326 } 326 }
327 327
328 void BrowserNonClientFrameViewAsh::OnMaximizeModeStarted() { 328 void BrowserNonClientFrameViewAsh::OnTabletModeStarted() {
329 caption_button_container_->UpdateSizeButtonVisibility(); 329 caption_button_container_->UpdateSizeButtonVisibility();
330 InvalidateLayout(); 330 InvalidateLayout();
331 frame()->client_view()->InvalidateLayout(); 331 frame()->client_view()->InvalidateLayout();
332 frame()->GetRootView()->Layout(); 332 frame()->GetRootView()->Layout();
333 } 333 }
334 334
335 void BrowserNonClientFrameViewAsh::OnMaximizeModeEnded() { 335 void BrowserNonClientFrameViewAsh::OnTabletModeEnded() {
336 OnMaximizeModeStarted(); 336 OnTabletModeStarted();
337 } 337 }
338 338
339 /////////////////////////////////////////////////////////////////////////////// 339 ///////////////////////////////////////////////////////////////////////////////
340 // TabIconViewModel: 340 // TabIconViewModel:
341 341
342 bool BrowserNonClientFrameViewAsh::ShouldTabIconViewAnimate() const { 342 bool BrowserNonClientFrameViewAsh::ShouldTabIconViewAnimate() const {
343 // This function is queried during the creation of the window as the 343 // This function is queried during the creation of the window as the
344 // TabIconView we host is initialized, so we need to null check the selected 344 // TabIconView we host is initialized, so we need to null check the selected
345 // WebContents because in this condition there is not yet a selected tab. 345 // WebContents because in this condition there is not yet a selected tab.
346 content::WebContents* current_tab = browser_view()->GetActiveWebContents(); 346 content::WebContents* current_tab = browser_view()->GetActiveWebContents();
(...skipping 105 matching lines...) Expand 10 before | Expand all | Expand 10 after
452 toolbar_bounds.width(), 0); 452 toolbar_bounds.width(), 0);
453 BrowserView::Paint1pxHorizontalLine(canvas, GetToolbarTopSeparatorColor(), 453 BrowserView::Paint1pxHorizontalLine(canvas, GetToolbarTopSeparatorColor(),
454 separator_rect, true); 454 separator_rect, true);
455 455
456 // Toolbar/content separator. 456 // Toolbar/content separator.
457 toolbar_bounds.Inset(kClientEdgeThickness, 0); 457 toolbar_bounds.Inset(kClientEdgeThickness, 0);
458 BrowserView::Paint1pxHorizontalLine( 458 BrowserView::Paint1pxHorizontalLine(
459 canvas, tp->GetColor(ThemeProperties::COLOR_TOOLBAR_BOTTOM_SEPARATOR), 459 canvas, tp->GetColor(ThemeProperties::COLOR_TOOLBAR_BOTTOM_SEPARATOR),
460 toolbar_bounds, true); 460 toolbar_bounds, true);
461 } 461 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698