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

Side by Side Diff: chrome/browser/ui/panels/panel_browser_frame_view.cc

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, 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) 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_frame_view.h" 5 #include "chrome/browser/ui/panels/panel_browser_frame_view.h"
6 6
7 #include "chrome/browser/extensions/extension_service.h" 7 #include "chrome/browser/extensions/extension_service.h"
8 #include "chrome/browser/profiles/profile.h" 8 #include "chrome/browser/profiles/profile.h"
9 #include "chrome/browser/themes/theme_service.h" 9 #include "chrome/browser/themes/theme_service.h"
10 #include "chrome/browser/ui/panels/panel.h" 10 #include "chrome/browser/ui/panels/panel.h"
(...skipping 182 matching lines...) Expand 10 before | Expand all | Expand 10 after
193 PanelBrowserView* browser_view) 193 PanelBrowserView* browser_view)
194 : BrowserNonClientFrameView(), 194 : BrowserNonClientFrameView(),
195 frame_(frame), 195 frame_(frame),
196 browser_view_(browser_view), 196 browser_view_(browser_view),
197 paint_state_(NOT_PAINTED), 197 paint_state_(NOT_PAINTED),
198 settings_button_(NULL), 198 settings_button_(NULL),
199 close_button_(NULL), 199 close_button_(NULL),
200 title_icon_(NULL), 200 title_icon_(NULL),
201 title_label_(NULL) { 201 title_label_(NULL) {
202 EnsureResourcesInitialized(); 202 EnsureResourcesInitialized();
203 frame_->set_frame_type(views::Widget::FRAME_TYPE_FORCE_CUSTOM);
204 203
205 settings_button_ = new views::MenuButton(NULL, std::wstring(), this, false); 204 settings_button_ = new views::MenuButton(NULL, std::wstring(), this, false);
206 settings_button_->SetIcon(*(settings_button_resources.normal_image)); 205 settings_button_->SetIcon(*(settings_button_resources.normal_image));
207 settings_button_->SetHoverIcon(*(settings_button_resources.hover_image)); 206 settings_button_->SetHoverIcon(*(settings_button_resources.hover_image));
208 settings_button_->SetPushedIcon(*(settings_button_resources.pushed_image)); 207 settings_button_->SetPushedIcon(*(settings_button_resources.pushed_image));
209 settings_button_->set_alignment(views::TextButton::ALIGN_CENTER); 208 settings_button_->set_alignment(views::TextButton::ALIGN_CENTER);
210 settings_button_->set_border(NULL); 209 settings_button_->set_border(NULL);
211 settings_button_->SetTooltipText( 210 settings_button_->SetTooltipText(
212 UTF16ToWide(l10n_util::GetStringUTF16(IDS_NEW_TAB_APP_SETTINGS))); 211 UTF16ToWide(l10n_util::GetStringUTF16(IDS_NEW_TAB_APP_SETTINGS)));
213 settings_button_->SetAccessibleName( 212 settings_button_->SetAccessibleName(
(...skipping 456 matching lines...) Expand 10 before | Expand all | Expand 10 after
670 settings_menu_contents_->AddItem( 669 settings_menu_contents_->AddItem(
671 COMMAND_DISABLE, l10n_util::GetStringUTF16(IDS_EXTENSIONS_DISABLE)); 670 COMMAND_DISABLE, l10n_util::GetStringUTF16(IDS_EXTENSIONS_DISABLE));
672 settings_menu_contents_->AddItem( 671 settings_menu_contents_->AddItem(
673 COMMAND_UNINSTALL, l10n_util::GetStringUTF16(IDS_EXTENSIONS_UNINSTALL)); 672 COMMAND_UNINSTALL, l10n_util::GetStringUTF16(IDS_EXTENSIONS_UNINSTALL));
674 settings_menu_contents_->AddSeparator(); 673 settings_menu_contents_->AddSeparator();
675 settings_menu_contents_->AddItem( 674 settings_menu_contents_->AddItem(
676 COMMAND_MANAGE, l10n_util::GetStringUTF16(IDS_MANAGE_EXTENSIONS)); 675 COMMAND_MANAGE, l10n_util::GetStringUTF16(IDS_MANAGE_EXTENSIONS));
677 676
678 settings_menu_.reset(new views::Menu2(settings_menu_contents_.get())); 677 settings_menu_.reset(new views::Menu2(settings_menu_contents_.get()));
679 } 678 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698