| OLD | NEW |
| 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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 // A helper class that contains the gtk widgets that make up the titlebar. The | 5 // A helper class that contains the gtk widgets that make up the titlebar. The |
| 6 // titlebar consists of the tabstrip and if the custom chrome frame is turned | 6 // titlebar consists of the tabstrip and if the custom chrome frame is turned |
| 7 // on, it includes the taller titlebar and minimize, restore, maximize, and | 7 // on, it includes the taller titlebar and minimize, restore, maximize, and |
| 8 // close buttons. | 8 // close buttons. |
| 9 | 9 |
| 10 #ifndef CHROME_BROWSER_UI_GTK_BROWSER_TITLEBAR_H_ | 10 #ifndef CHROME_BROWSER_UI_GTK_BROWSER_TITLEBAR_H_ |
| 11 #define CHROME_BROWSER_UI_GTK_BROWSER_TITLEBAR_H_ | 11 #define CHROME_BROWSER_UI_GTK_BROWSER_TITLEBAR_H_ |
| 12 #pragma once | 12 #pragma once |
| 13 | 13 |
| 14 #include <gtk/gtk.h> | 14 #include <gtk/gtk.h> |
| 15 | 15 |
| 16 #include "app/active_window_watcher_x.h" | |
| 17 #include "app/gtk_signal.h" | |
| 18 #include "base/scoped_ptr.h" | 16 #include "base/scoped_ptr.h" |
| 19 #include "chrome/common/notification_observer.h" | 17 #include "chrome/common/notification_observer.h" |
| 20 #include "chrome/common/notification_registrar.h" | 18 #include "chrome/common/notification_registrar.h" |
| 19 #include "ui/base/gtk/gtk_signal.h" |
| 21 #include "ui/base/models/simple_menu_model.h" | 20 #include "ui/base/models/simple_menu_model.h" |
| 21 #include "ui/base/x/active_window_watcher_x.h" |
| 22 | 22 |
| 23 class BrowserWindowGtk; | 23 class BrowserWindowGtk; |
| 24 class CustomDrawButton; | 24 class CustomDrawButton; |
| 25 class GtkThemeProvider; | 25 class GtkThemeProvider; |
| 26 class MenuGtk; | 26 class MenuGtk; |
| 27 class PopupPageMenuModel; | 27 class PopupPageMenuModel; |
| 28 class TabContents; | 28 class TabContents; |
| 29 | 29 |
| 30 class BrowserTitlebar : public NotificationObserver, | 30 class BrowserTitlebar : public NotificationObserver, |
| 31 public ActiveWindowWatcherX::Observer, | 31 public ui::ActiveWindowWatcherX::Observer, |
| 32 public ui::SimpleMenuModel::Delegate { | 32 public ui::SimpleMenuModel::Delegate { |
| 33 public: | 33 public: |
| 34 // A default button order string for when we aren't asking gconf for the | 34 // A default button order string for when we aren't asking gconf for the |
| 35 // metacity configuration. | 35 // metacity configuration. |
| 36 static const char kDefaultButtonString[]; | 36 static const char kDefaultButtonString[]; |
| 37 | 37 |
| 38 BrowserTitlebar(BrowserWindowGtk* browser_window, GtkWindow* window); | 38 BrowserTitlebar(BrowserWindowGtk* browser_window, GtkWindow* window); |
| 39 virtual ~BrowserTitlebar(); | 39 virtual ~BrowserTitlebar(); |
| 40 | 40 |
| 41 GtkWidget* widget() { | 41 GtkWidget* widget() { |
| (...skipping 188 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 230 // The throbber used when the window is in app mode or popup window mode. | 230 // The throbber used when the window is in app mode or popup window mode. |
| 231 Throbber throbber_; | 231 Throbber throbber_; |
| 232 | 232 |
| 233 // Theme provider for building buttons. | 233 // Theme provider for building buttons. |
| 234 GtkThemeProvider* theme_provider_; | 234 GtkThemeProvider* theme_provider_; |
| 235 | 235 |
| 236 NotificationRegistrar registrar_; | 236 NotificationRegistrar registrar_; |
| 237 }; | 237 }; |
| 238 | 238 |
| 239 #endif // CHROME_BROWSER_UI_GTK_BROWSER_TITLEBAR_H_ | 239 #endif // CHROME_BROWSER_UI_GTK_BROWSER_TITLEBAR_H_ |
| OLD | NEW |