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

Side by Side Diff: chrome/browser/cocoa/browser_window_cocoa.h

Issue 2475002: Initial cut at scaffolding for mac sidetabs. No visible changes to browser wi... (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 10 years, 6 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) 2010 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2010 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_COCOA_BROWSER_WINDOW_COCOA_H_ 5 #ifndef CHROME_BROWSER_COCOA_BROWSER_WINDOW_COCOA_H_
6 #define CHROME_BROWSER_COCOA_BROWSER_WINDOW_COCOA_H_ 6 #define CHROME_BROWSER_COCOA_BROWSER_WINDOW_COCOA_H_
7 7
8 #include "base/task.h" 8 #include "base/task.h"
9 #include "chrome/browser/browser_window.h" 9 #include "chrome/browser/browser_window.h"
10 #include "chrome/browser/bookmarks/bookmark_model.h" 10 #include "chrome/browser/bookmarks/bookmark_model.h"
(...skipping 85 matching lines...) Expand 10 before | Expand all | Expand 10 after
96 bool show_history); 96 bool show_history);
97 virtual void ShowPageMenu(); 97 virtual void ShowPageMenu();
98 virtual void ShowAppMenu(); 98 virtual void ShowAppMenu();
99 virtual bool PreHandleKeyboardEvent(const NativeWebKeyboardEvent& event, 99 virtual bool PreHandleKeyboardEvent(const NativeWebKeyboardEvent& event,
100 bool* is_keyboard_shortcut); 100 bool* is_keyboard_shortcut);
101 virtual void HandleKeyboardEvent(const NativeWebKeyboardEvent& event); 101 virtual void HandleKeyboardEvent(const NativeWebKeyboardEvent& event);
102 virtual void ShowCreateShortcutsDialog(TabContents* tab_contents); 102 virtual void ShowCreateShortcutsDialog(TabContents* tab_contents);
103 virtual void Cut(); 103 virtual void Cut();
104 virtual void Copy(); 104 virtual void Copy();
105 virtual void Paste(); 105 virtual void Paste();
106 virtual void ToggleTabStripMode() {} 106 virtual void ToggleTabStripMode();
107 virtual void SetToolbarCollapsedMode(bool val) {} 107 virtual void SetToolbarCollapsedMode(bool val) {}
108 108
109 // Overridden from NotificationObserver 109 // Overridden from NotificationObserver
110 virtual void Observe(NotificationType type, 110 virtual void Observe(NotificationType type,
111 const NotificationSource& source, 111 const NotificationSource& source,
112 const NotificationDetails& details); 112 const NotificationDetails& details);
113 113
114 // Adds the given FindBar cocoa controller to this browser window. 114 // Adds the given FindBar cocoa controller to this browser window.
115 void AddFindBar(FindBarCocoaController* find_bar_cocoa_controller); 115 void AddFindBar(FindBarCocoaController* find_bar_cocoa_controller);
116 116
117 // Returns the cocoa-world BrowserWindowController 117 // Returns the cocoa-world BrowserWindowController
118 BrowserWindowController* cocoa_controller() { return controller_; } 118 BrowserWindowController* cocoa_controller() { return controller_; }
119 119
120 protected: 120 protected:
121 virtual void DestroyBrowser(); 121 virtual void DestroyBrowser();
122 122
123 private: 123 private:
124 int GetCommandId(const NativeWebKeyboardEvent& event); 124 int GetCommandId(const NativeWebKeyboardEvent& event);
125 bool HandleKeyboardEventInternal(NSEvent* event); 125 bool HandleKeyboardEventInternal(NSEvent* event);
126 NSWindow* window() const; // Accessor for the (current) |NSWindow|. 126 NSWindow* window() const; // Accessor for the (current) |NSWindow|.
127 127
128 NotificationRegistrar registrar_; 128 NotificationRegistrar registrar_;
129 Browser* browser_; // weak, owned by controller 129 Browser* browser_; // weak, owned by controller
130 BrowserWindowController* controller_; // weak, owns us 130 BrowserWindowController* controller_; // weak, owns us
131 ScopedRunnableMethodFactory<Browser> confirm_close_factory_; 131 ScopedRunnableMethodFactory<Browser> confirm_close_factory_;
132 }; 132 };
133 133
134 #endif // CHROME_BROWSER_COCOA_BROWSER_WINDOW_COCOA_H_ 134 #endif // CHROME_BROWSER_COCOA_BROWSER_WINDOW_COCOA_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698