OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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/views/panels/panel_view.h" | 5 #include "chrome/browser/ui/views/panels/panel_view.h" |
6 | 6 |
7 #include <map> | 7 #include <map> |
8 #include "base/logging.h" | 8 #include "base/logging.h" |
9 #include "base/message_loop.h" | 9 #include "base/message_loop.h" |
10 #include "base/utf_string_conversions.h" | 10 #include "base/utf_string_conversions.h" |
(...skipping 255 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
266 GetAcceleratorTable(); | 266 GetAcceleratorTable(); |
267 for (std::map<ui::Accelerator, int>::const_iterator iter = | 267 for (std::map<ui::Accelerator, int>::const_iterator iter = |
268 accelerator_table.begin(); | 268 accelerator_table.begin(); |
269 iter != accelerator_table.end(); ++iter) { | 269 iter != accelerator_table.end(); ++iter) { |
270 focus_manager->RegisterAccelerator( | 270 focus_manager->RegisterAccelerator( |
271 iter->first, ui::AcceleratorManager::kNormalPriority, this); | 271 iter->first, ui::AcceleratorManager::kNormalPriority, this); |
272 } | 272 } |
273 | 273 |
274 #if defined(OS_WIN) | 274 #if defined(OS_WIN) |
275 ui::win::SetAppIdForWindow( | 275 ui::win::SetAppIdForWindow( |
276 ShellIntegration::GetAppModelIdForProfile(UTF8ToWide(panel->app_name()), | 276 ShellIntegration::GetAppModelIdForProfile( |
277 panel->profile()->GetPath()), | 277 base::UTF8ToWide(panel->app_name()), |
| 278 panel->profile()->GetPath()), |
278 chrome::HWNDForWidget(window_)); | 279 chrome::HWNDForWidget(window_)); |
279 #endif | 280 #endif |
280 } | 281 } |
281 | 282 |
282 PanelView::~PanelView() { | 283 PanelView::~PanelView() { |
283 } | 284 } |
284 | 285 |
285 void PanelView::ShowPanel() { | 286 void PanelView::ShowPanel() { |
286 ShowPanelInactive(); | 287 ShowPanelInactive(); |
287 ActivatePanel(); | 288 ActivatePanel(); |
(...skipping 667 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
955 DCHECK(thickness_for_mouse_resizing > 0); | 956 DCHECK(thickness_for_mouse_resizing > 0); |
956 SkRegion* region = new SkRegion; | 957 SkRegion* region = new SkRegion; |
957 region->op(0, 0, thickness_for_mouse_resizing, height, SkRegion::kUnion_Op); | 958 region->op(0, 0, thickness_for_mouse_resizing, height, SkRegion::kUnion_Op); |
958 region->op(width - thickness_for_mouse_resizing, 0, width, height, | 959 region->op(width - thickness_for_mouse_resizing, 0, width, height, |
959 SkRegion::kUnion_Op); | 960 SkRegion::kUnion_Op); |
960 region->op(0, height - thickness_for_mouse_resizing, width, height, | 961 region->op(0, height - thickness_for_mouse_resizing, width, height, |
961 SkRegion::kUnion_Op); | 962 SkRegion::kUnion_Op); |
962 web_contents->GetRenderViewHost()->GetView()->SetClickthroughRegion(region); | 963 web_contents->GetRenderViewHost()->GetView()->SetClickthroughRegion(region); |
963 #endif | 964 #endif |
964 } | 965 } |
OLD | NEW |