OLD | NEW |
1 // Copyright (c) 2009 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2009 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_GTK_BROWSER_WINDOW_GTK_H_ | 5 #ifndef CHROME_BROWSER_GTK_BROWSER_WINDOW_GTK_H_ |
6 #define CHROME_BROWSER_GTK_BROWSER_WINDOW_GTK_H_ | 6 #define CHROME_BROWSER_GTK_BROWSER_WINDOW_GTK_H_ |
7 | 7 |
8 #include <gtk/gtk.h> | 8 #include <gtk/gtk.h> |
9 | 9 |
10 #include <map> | 10 #include <map> |
(...skipping 122 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
133 virtual void TabStripEmpty(); | 133 virtual void TabStripEmpty(); |
134 | 134 |
135 // Accessor for the tab strip. | 135 // Accessor for the tab strip. |
136 TabStripGtk* tabstrip() const { return tabstrip_.get(); } | 136 TabStripGtk* tabstrip() const { return tabstrip_.get(); } |
137 | 137 |
138 void UpdateDevToolsForContents(TabContents* contents); | 138 void UpdateDevToolsForContents(TabContents* contents); |
139 | 139 |
140 void UpdateUIForContents(TabContents* contents); | 140 void UpdateUIForContents(TabContents* contents); |
141 | 141 |
142 void OnBoundsChanged(const gfx::Rect& bounds); | 142 void OnBoundsChanged(const gfx::Rect& bounds); |
| 143 void OnDebouncedBoundsChanged(); |
143 void OnStateChanged(GdkWindowState state, GdkWindowState changed_mask); | 144 void OnStateChanged(GdkWindowState state, GdkWindowState changed_mask); |
144 | 145 |
145 // Returns false if we're not ready to close yet. E.g., a tab may have an | 146 // Returns false if we're not ready to close yet. E.g., a tab may have an |
146 // onbeforeunload handler that prevents us from closing. | 147 // onbeforeunload handler that prevents us from closing. |
147 bool CanClose() const; | 148 bool CanClose() const; |
148 | 149 |
149 bool ShouldShowWindowIcon() const; | 150 bool ShouldShowWindowIcon() const; |
150 | 151 |
151 // Add the find bar widget to the window hierarchy. | 152 // Add the find bar widget to the window hierarchy. |
152 void AddFindBar(FindBarGtk* findbar); | 153 void AddFindBar(FindBarGtk* findbar); |
(...skipping 201 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
354 | 355 |
355 // The tab strip. Always non-NULL. | 356 // The tab strip. Always non-NULL. |
356 scoped_ptr<TabStripGtk> tabstrip_; | 357 scoped_ptr<TabStripGtk> tabstrip_; |
357 | 358 |
358 // The container for info bars. Always non-NULL. | 359 // The container for info bars. Always non-NULL. |
359 scoped_ptr<InfoBarContainerGtk> infobar_container_; | 360 scoped_ptr<InfoBarContainerGtk> infobar_container_; |
360 | 361 |
361 // The timer used to update frames for the Loading Animation. | 362 // The timer used to update frames for the Loading Animation. |
362 base::RepeatingTimer<BrowserWindowGtk> loading_animation_timer_; | 363 base::RepeatingTimer<BrowserWindowGtk> loading_animation_timer_; |
363 | 364 |
| 365 // The timer used to save the window position for session restore. |
| 366 base::OneShotTimer<BrowserWindowGtk> mainwin_configure_debounce_timer_; |
| 367 |
364 // Whether the custom chrome frame pref is set. Normally you want to use | 368 // Whether the custom chrome frame pref is set. Normally you want to use |
365 // UseCustomFrame() above to determine whether to use the custom frame or | 369 // UseCustomFrame() above to determine whether to use the custom frame or |
366 // not. | 370 // not. |
367 BooleanPrefMember use_custom_frame_pref_; | 371 BooleanPrefMember use_custom_frame_pref_; |
368 | 372 |
369 #if defined(OS_CHROMEOS) | 373 #if defined(OS_CHROMEOS) |
370 // True if a drag is active. See description above setter for details. | 374 // True if a drag is active. See description above setter for details. |
371 bool drag_active_; | 375 bool drag_active_; |
372 // Controls interactions with the window manager for popup panels. | 376 // Controls interactions with the window manager for popup panels. |
373 PanelController* panel_controller_; | 377 PanelController* panel_controller_; |
(...skipping 25 matching lines...) Expand all Loading... |
399 // first time. This is to work around a compiz bug. | 403 // first time. This is to work around a compiz bug. |
400 bool maximize_after_show_; | 404 bool maximize_after_show_; |
401 | 405 |
402 // The accelerator group used to handle accelerators, owned by this object. | 406 // The accelerator group used to handle accelerators, owned by this object. |
403 GtkAccelGroup* accel_group_; | 407 GtkAccelGroup* accel_group_; |
404 | 408 |
405 DISALLOW_COPY_AND_ASSIGN(BrowserWindowGtk); | 409 DISALLOW_COPY_AND_ASSIGN(BrowserWindowGtk); |
406 }; | 410 }; |
407 | 411 |
408 #endif // CHROME_BROWSER_GTK_BROWSER_WINDOW_GTK_H_ | 412 #endif // CHROME_BROWSER_GTK_BROWSER_WINDOW_GTK_H_ |
OLD | NEW |