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

Side by Side Diff: chrome/browser/ui/panels/panel_browser_window_cocoa.mm

Issue 7242017: Support minimizing the panel into 3-pixel line on Windows. Also support bringing up/down the titl... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 9 years, 5 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) 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 #include "chrome/browser/ui/panels/panel_browser_window_cocoa.h" 5 #include "chrome/browser/ui/panels/panel_browser_window_cocoa.h"
6 6
7 #include "base/logging.h" 7 #include "base/logging.h"
8 #include "chrome/browser/ui/browser.h" 8 #include "chrome/browser/ui/browser.h"
9 #include "chrome/browser/ui/panels/panel.h" 9 #include "chrome/browser/ui/panels/panel.h"
10 #import "chrome/browser/ui/panels/panel_window_controller_cocoa.h" 10 #import "chrome/browser/ui/panels/panel_window_controller_cocoa.h"
(...skipping 66 matching lines...) Expand 10 before | Expand all | Expand 10 after
77 gfx::Rect PanelBrowserWindowCocoa::GetPanelBounds() const { 77 gfx::Rect PanelBrowserWindowCocoa::GetPanelBounds() const {
78 return bounds_; 78 return bounds_;
79 } 79 }
80 80
81 void PanelBrowserWindowCocoa::SetPanelBounds(const gfx::Rect& bounds) { 81 void PanelBrowserWindowCocoa::SetPanelBounds(const gfx::Rect& bounds) {
82 bounds_ = bounds; 82 bounds_ = bounds;
83 NSRect frame = ConvertCoordinatesToCocoa(bounds); 83 NSRect frame = ConvertCoordinatesToCocoa(bounds);
84 [[controller_ window] setFrame:frame display:YES animate:YES]; 84 [[controller_ window] setFrame:frame display:YES animate:YES];
85 } 85 }
86 86
87 void PanelBrowserWindowCocoa::MinimizePanel() { 87 void PanelBrowserWindowCocoa::SetPanelExpansionState(
88 Panel::ExpansionState expansion_state) {
88 NOTIMPLEMENTED(); 89 NOTIMPLEMENTED();
89 } 90 }
90 91
91 void PanelBrowserWindowCocoa::RestorePanel() { 92 bool PanelBrowserWindowCocoa::ShouldBringUpPanelTitleBar(int mouse_x,
93 int mouse_y) const {
92 NOTIMPLEMENTED(); 94 NOTIMPLEMENTED();
95 return false;
93 } 96 }
94 97
95 void PanelBrowserWindowCocoa::ClosePanel() { 98 void PanelBrowserWindowCocoa::ClosePanel() {
96 if (isClosed()) 99 if (isClosed())
97 return; 100 return;
98 101
99 NSWindow* window = [controller_ window]; 102 NSWindow* window = [controller_ window];
100 NSRect frame = [window frame]; 103 NSRect frame = [window frame];
101 frame.size.height = kMinimumWindowSize; 104 frame.size.height = kMinimumWindowSize;
102 [window setFrame:frame display:YES animate:YES]; 105 [window setFrame:frame display:YES animate:YES];
(...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after
135 138
136 void PanelBrowserWindowCocoa::FlashPanelFrame() { 139 void PanelBrowserWindowCocoa::FlashPanelFrame() {
137 NOTIMPLEMENTED(); 140 NOTIMPLEMENTED();
138 } 141 }
139 142
140 void PanelBrowserWindowCocoa::DestroyPanelBrowser() { 143 void PanelBrowserWindowCocoa::DestroyPanelBrowser() {
141 [controller_ close]; 144 [controller_ close];
142 controller_ = NULL; 145 controller_ = NULL;
143 } 146 }
144 147
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698