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

Side by Side Diff: chrome/browser/chromeos/frame/panel_controller.cc

Issue 7015051: Re-land: (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 9 years, 7 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/chromeos/frame/panel_controller.h" 5 #include "chrome/browser/chromeos/frame/panel_controller.h"
6 6
7 #if defined(TOUCH_UI) 7 #if defined(TOUCH_UI)
8 #include <X11/Xlib.h> 8 #include <X11/Xlib.h>
9 #if defined(HAVE_XINPUT2) 9 #if defined(HAVE_XINPUT2)
10 #include <X11/extensions/XInput2.h> 10 #include <X11/extensions/XInput2.h>
(...skipping 165 matching lines...) Expand 10 before | Expand all | Expand 10 after
176 focused_(false), 176 focused_(false),
177 urgent_(false) { 177 urgent_(false) {
178 } 178 }
179 179
180 void PanelController::Init(bool initial_focus, 180 void PanelController::Init(bool initial_focus,
181 const gfx::Rect& window_bounds, 181 const gfx::Rect& window_bounds,
182 XID creator_xid, 182 XID creator_xid,
183 WmIpcPanelUserResizeType resize_type) { 183 WmIpcPanelUserResizeType resize_type) {
184 gfx::Rect title_bounds(0, 0, window_bounds.width(), kTitleHeight); 184 gfx::Rect title_bounds(0, 0, window_bounds.width(), kTitleHeight);
185 185
186 title_window_ = views::Widget::CreateWidget(); 186 title_window_ = new views::Widget;
187 views::Widget::InitParams params(views::Widget::InitParams::TYPE_WINDOW); 187 views::Widget::InitParams params(views::Widget::InitParams::TYPE_WINDOW);
188 params.transparent = true; 188 params.transparent = true;
189 params.bounds = title_bounds; 189 params.bounds = title_bounds;
190 title_window_->Init(params); 190 title_window_->Init(params);
191 gtk_widget_set_size_request(title_window_->GetNativeView(), 191 gtk_widget_set_size_request(title_window_->GetNativeView(),
192 title_bounds.width(), title_bounds.height()); 192 title_bounds.width(), title_bounds.height());
193 title_ = title_window_->GetNativeView(); 193 title_ = title_window_->GetNativeView();
194 title_xid_ = ui::GetX11WindowFromGtkWidget(title_); 194 title_xid_ = ui::GetX11WindowFromGtkWidget(title_);
195 195
196 WmIpc::instance()->SetWindowType( 196 WmIpc::instance()->SetWindowType(
(...skipping 309 matching lines...) Expand 10 before | Expand all | Expand 10 after
506 views::Button* sender, const views::Event& event) { 506 views::Button* sender, const views::Event& event) {
507 if (panel_controller_ && sender == close_button_) 507 if (panel_controller_ && sender == close_button_)
508 panel_controller_->OnCloseButtonPressed(); 508 panel_controller_->OnCloseButtonPressed();
509 } 509 }
510 510
511 PanelController::TitleContentView::~TitleContentView() { 511 PanelController::TitleContentView::~TitleContentView() {
512 VLOG(1) << "panel: delete " << this; 512 VLOG(1) << "panel: delete " << this;
513 } 513 }
514 514
515 } // namespace chromeos 515 } // namespace chromeos
OLDNEW
« no previous file with comments | « chrome/browser/chromeos/frame/dom_browser_view.cc ('k') | chrome/browser/chromeos/input_method/candidate_window.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698