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

Side by Side Diff: chrome/browser/ui/panels/panel_browser_window_gtk.cc

Issue 10337010: Revert r123782. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: . Created 8 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 | 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/panels/panel_browser_window_gtk.h" 5 #include "chrome/browser/ui/panels/panel_browser_window_gtk.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "chrome/browser/ui/browser_list.h" 8 #include "chrome/browser/ui/browser_list.h"
9 #include "chrome/browser/ui/gtk/browser_titlebar.h" 9 #include "chrome/browser/ui/gtk/browser_titlebar.h"
10 #include "chrome/browser/ui/gtk/custom_button.h" 10 #include "chrome/browser/ui/gtk/custom_button.h"
11 #include "chrome/browser/ui/gtk/gtk_theme_service.h"
11 #include "chrome/browser/ui/gtk/nine_box.h" 12 #include "chrome/browser/ui/gtk/nine_box.h"
12 #include "chrome/browser/ui/gtk/theme_service_gtk.h"
13 #include "chrome/browser/ui/panels/panel.h" 13 #include "chrome/browser/ui/panels/panel.h"
14 #include "chrome/browser/ui/panels/panel_bounds_animation.h" 14 #include "chrome/browser/ui/panels/panel_bounds_animation.h"
15 #include "chrome/browser/ui/panels/panel_browser_titlebar_gtk.h" 15 #include "chrome/browser/ui/panels/panel_browser_titlebar_gtk.h"
16 #include "chrome/browser/ui/panels/panel_drag_gtk.h" 16 #include "chrome/browser/ui/panels/panel_drag_gtk.h"
17 #include "chrome/browser/ui/panels/panel_manager.h" 17 #include "chrome/browser/ui/panels/panel_manager.h"
18 #include "chrome/browser/ui/panels/panel_strip.h" 18 #include "chrome/browser/ui/panels/panel_strip.h"
19 #include "chrome/common/chrome_notification_types.h" 19 #include "chrome/common/chrome_notification_types.h"
20 #include "content/public/browser/notification_service.h" 20 #include "content/public/browser/notification_service.h"
21 #include "grit/theme_resources_standard.h" 21 #include "grit/theme_resources_standard.h"
22 #include "grit/ui_resources.h" 22 #include "grit/ui_resources.h"
(...skipping 257 matching lines...) Expand 10 before | Expand all | Expand 10 after
280 GtkWidget* widget, 280 GtkWidget* widget,
281 GdkEventExpose* event) { 281 GdkEventExpose* event) {
282 NOTREACHED(); 282 NOTREACHED();
283 } 283 }
284 284
285 const gfx::Image* PanelBrowserWindowGtk::GetThemeFrameImage() const { 285 const gfx::Image* PanelBrowserWindowGtk::GetThemeFrameImage() const {
286 PaintState paint_state = GetPaintState(); 286 PaintState paint_state = GetPaintState();
287 if (paint_state == PAINT_FOR_ATTENTION) 287 if (paint_state == PAINT_FOR_ATTENTION)
288 return GetAttentionBackgroundImage(); 288 return GetAttentionBackgroundImage();
289 289
290 ThemeServiceGtk* theme_provider = ThemeServiceGtk::GetFrom( 290 GtkThemeService* theme_provider = GtkThemeService::GetFrom(
291 browser()->profile()); 291 browser()->profile());
292 if (theme_provider->UsingDefaultTheme()) { 292 if (theme_provider->UsingDefaultTheme()) {
293 // We choose to use the window frame theme to paint panels for the default 293 // We choose to use the window frame theme to paint panels for the default
294 // theme. This is because the default tab theme does not work well for the 294 // theme. This is because the default tab theme does not work well for the
295 // user to recognize active and inactive panels. 295 // user to recognize active and inactive panels.
296 return theme_provider->GetImageNamed(paint_state == PAINT_AS_ACTIVE ? 296 return theme_provider->GetImageNamed(paint_state == PAINT_AS_ACTIVE ?
297 IDR_THEME_FRAME : IDR_THEME_FRAME_INACTIVE); 297 IDR_THEME_FRAME : IDR_THEME_FRAME_INACTIVE);
298 } 298 }
299 299
300 return theme_provider->GetImageNamed(paint_state == PAINT_AS_ACTIVE ? 300 return theme_provider->GetImageNamed(paint_state == PAINT_AS_ACTIVE ?
(...skipping 407 matching lines...) Expand 10 before | Expand all | Expand 10 after
708 break; 708 break;
709 case RESTORE_BUTTON: 709 case RESTORE_BUTTON:
710 button = titlebar->unminimize_button(); 710 button = titlebar->unminimize_button();
711 break; 711 break;
712 default: 712 default:
713 NOTREACHED(); 713 NOTREACHED();
714 return false; 714 return false;
715 } 715 }
716 return gtk_widget_get_visible(button->widget()); 716 return gtk_widget_get_visible(button->widget());
717 } 717 }
OLDNEW
« no previous file with comments | « chrome/browser/ui/panels/panel_browser_titlebar_gtk.cc ('k') | chrome/browser/ui/webui/options2/browser_options_handler2.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698