| 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 #ifndef CHROME_BROWSER_UI_GTK_BOOKMARKS_BOOKMARK_BAR_GTK_H_ | 5 #ifndef CHROME_BROWSER_UI_GTK_BOOKMARKS_BOOKMARK_BAR_GTK_H_ |
| 6 #define CHROME_BROWSER_UI_GTK_BOOKMARKS_BOOKMARK_BAR_GTK_H_ | 6 #define CHROME_BROWSER_UI_GTK_BOOKMARKS_BOOKMARK_BAR_GTK_H_ |
| 7 #pragma once | 7 #pragma once |
| 8 | 8 |
| 9 #include <gtk/gtk.h> | 9 #include <gtk/gtk.h> |
| 10 | 10 |
| 11 #include <vector> | 11 #include <vector> |
| 12 | 12 |
| 13 #include "base/gtest_prod_util.h" | 13 #include "base/gtest_prod_util.h" |
| 14 #include "base/memory/scoped_ptr.h" | 14 #include "base/memory/scoped_ptr.h" |
| 15 #include "chrome/browser/bookmarks/bookmark_context_menu_controller.h" | 15 #include "chrome/browser/bookmarks/bookmark_context_menu_controller.h" |
| 16 #include "chrome/browser/bookmarks/bookmark_model_observer.h" | 16 #include "chrome/browser/bookmarks/bookmark_model_observer.h" |
| 17 #include "chrome/browser/prefs/pref_member.h" | 17 #include "chrome/browser/prefs/pref_member.h" |
| 18 #include "chrome/browser/sync/profile_sync_service.h" | 18 #include "chrome/browser/sync/profile_sync_service.h" |
| 19 #include "chrome/browser/ui/bookmarks/bookmark_bar.h" | 19 #include "chrome/browser/ui/bookmarks/bookmark_bar.h" |
| 20 #include "chrome/browser/ui/gtk/bookmarks/bookmark_bar_instructions_gtk.h" | 20 #include "chrome/browser/ui/gtk/bookmarks/bookmark_bar_instructions_gtk.h" |
| 21 #include "chrome/browser/ui/gtk/menu_bar_helper.h" | 21 #include "chrome/browser/ui/gtk/menu_bar_helper.h" |
| 22 #include "chrome/browser/ui/gtk/owned_widget_gtk.h" | |
| 23 #include "chrome/browser/ui/gtk/view_id_util.h" | 22 #include "chrome/browser/ui/gtk/view_id_util.h" |
| 24 #include "content/common/notification_observer.h" | 23 #include "content/common/notification_observer.h" |
| 25 #include "content/common/notification_registrar.h" | 24 #include "content/common/notification_registrar.h" |
| 26 #include "ui/base/animation/animation.h" | 25 #include "ui/base/animation/animation.h" |
| 27 #include "ui/base/animation/animation_delegate.h" | 26 #include "ui/base/animation/animation_delegate.h" |
| 28 #include "ui/base/animation/slide_animation.h" | 27 #include "ui/base/animation/slide_animation.h" |
| 29 #include "ui/base/gtk/gtk_signal.h" | 28 #include "ui/base/gtk/gtk_signal.h" |
| 29 #include "ui/base/gtk/owned_widget_gtk.h" |
| 30 #include "ui/gfx/point.h" | 30 #include "ui/gfx/point.h" |
| 31 #include "ui/gfx/size.h" | 31 #include "ui/gfx/size.h" |
| 32 | 32 |
| 33 class BookmarkMenuController; | 33 class BookmarkMenuController; |
| 34 class Browser; | 34 class Browser; |
| 35 class BrowserWindowGtk; | 35 class BrowserWindowGtk; |
| 36 class CustomContainerButton; | 36 class CustomContainerButton; |
| 37 class GtkThemeService; | 37 class GtkThemeService; |
| 38 class MenuGtk; | 38 class MenuGtk; |
| 39 class PageNavigator; | 39 class PageNavigator; |
| (...skipping 267 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 307 | 307 |
| 308 // Provides us with the offset into the background theme image. | 308 // Provides us with the offset into the background theme image. |
| 309 TabstripOriginProvider* tabstrip_origin_provider_; | 309 TabstripOriginProvider* tabstrip_origin_provider_; |
| 310 | 310 |
| 311 // Model providing details as to the starred entries/folders that should be | 311 // Model providing details as to the starred entries/folders that should be |
| 312 // shown. This is owned by the Profile. | 312 // shown. This is owned by the Profile. |
| 313 BookmarkModel* model_; | 313 BookmarkModel* model_; |
| 314 | 314 |
| 315 // Contains |bookmark_hbox_|. Event box exists to prevent leakage of | 315 // Contains |bookmark_hbox_|. Event box exists to prevent leakage of |
| 316 // background color from the toplevel application window's GDK window. | 316 // background color from the toplevel application window's GDK window. |
| 317 OwnedWidgetGtk event_box_; | 317 ui::OwnedWidgetGtk event_box_; |
| 318 | 318 |
| 319 // Used to detached the bookmark bar when on the NTP. | 319 // Used to detached the bookmark bar when on the NTP. |
| 320 GtkWidget* ntp_padding_box_; | 320 GtkWidget* ntp_padding_box_; |
| 321 | 321 |
| 322 // Used to paint the background of the bookmark bar when in detached mode. | 322 // Used to paint the background of the bookmark bar when in detached mode. |
| 323 GtkWidget* paint_box_; | 323 GtkWidget* paint_box_; |
| 324 | 324 |
| 325 // Used to position all children. | 325 // Used to position all children. |
| 326 GtkWidget* bookmark_hbox_; | 326 GtkWidget* bookmark_hbox_; |
| 327 | 327 |
| 328 // Alignment widget that is visible if there are no bookmarks on | 328 // Alignment widget that is visible if there are no bookmarks on |
| 329 // the bookmar bar. | 329 // the bookmar bar. |
| 330 GtkWidget* instructions_; | 330 GtkWidget* instructions_; |
| 331 | 331 |
| 332 // BookmarkBarInstructionsGtk that holds the label and the link for importing | 332 // BookmarkBarInstructionsGtk that holds the label and the link for importing |
| 333 // bookmarks when there are no bookmarks on the bookmark bar. | 333 // bookmarks when there are no bookmarks on the bookmark bar. |
| 334 scoped_ptr<BookmarkBarInstructionsGtk> instructions_gtk_; | 334 scoped_ptr<BookmarkBarInstructionsGtk> instructions_gtk_; |
| 335 | 335 |
| 336 // GtkToolbar which contains all the bookmark buttons. | 336 // GtkToolbar which contains all the bookmark buttons. |
| 337 OwnedWidgetGtk bookmark_toolbar_; | 337 ui::OwnedWidgetGtk bookmark_toolbar_; |
| 338 | 338 |
| 339 // The button that shows extra bookmarks that don't fit on the bookmark | 339 // The button that shows extra bookmarks that don't fit on the bookmark |
| 340 // bar. | 340 // bar. |
| 341 GtkWidget* overflow_button_; | 341 GtkWidget* overflow_button_; |
| 342 | 342 |
| 343 // A separator between the main bookmark bar area and | 343 // A separator between the main bookmark bar area and |
| 344 // |other_bookmarks_button_|. | 344 // |other_bookmarks_button_|. |
| 345 GtkWidget* other_bookmarks_separator_; | 345 GtkWidget* other_bookmarks_separator_; |
| 346 | 346 |
| 347 // The other bookmarks button. | 347 // The other bookmarks button. |
| (...skipping 58 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 406 BooleanPrefMember edit_bookmarks_enabled_; | 406 BooleanPrefMember edit_bookmarks_enabled_; |
| 407 | 407 |
| 408 ScopedRunnableMethodFactory<BookmarkBarGtk> method_factory_; | 408 ScopedRunnableMethodFactory<BookmarkBarGtk> method_factory_; |
| 409 | 409 |
| 410 BookmarkBar::State bookmark_bar_state_; | 410 BookmarkBar::State bookmark_bar_state_; |
| 411 | 411 |
| 412 DISALLOW_COPY_AND_ASSIGN(BookmarkBarGtk); | 412 DISALLOW_COPY_AND_ASSIGN(BookmarkBarGtk); |
| 413 }; | 413 }; |
| 414 | 414 |
| 415 #endif // CHROME_BROWSER_UI_GTK_BOOKMARKS_BOOKMARK_BAR_GTK_H_ | 415 #endif // CHROME_BROWSER_UI_GTK_BOOKMARKS_BOOKMARK_BAR_GTK_H_ |
| OLD | NEW |