| 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 "ash/shell/window_type_launcher.h" | 5 #include "ash/shell/window_type_launcher.h" |
| 6 | 6 |
| 7 #include <utility> | 7 #include <utility> |
| 8 | 8 |
| 9 #include "ash/content/shell_content_state.h" | 9 #include "ash/content/shell_content_state.h" |
| 10 #include "ash/root_window_controller.h" | 10 #include "ash/root_window_controller.h" |
| (...skipping 159 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 170 | 170 |
| 171 } // namespace | 171 } // namespace |
| 172 | 172 |
| 173 void InitWindowTypeLauncher() { | 173 void InitWindowTypeLauncher() { |
| 174 views::Widget* widget = | 174 views::Widget* widget = |
| 175 views::Widget::CreateWindowWithContextAndBounds( | 175 views::Widget::CreateWindowWithContextAndBounds( |
| 176 new WindowTypeLauncher, | 176 new WindowTypeLauncher, |
| 177 Shell::GetPrimaryRootWindow(), | 177 Shell::GetPrimaryRootWindow(), |
| 178 gfx::Rect(120, 150, 300, 410)); | 178 gfx::Rect(120, 150, 300, 410)); |
| 179 widget->GetNativeView()->SetName("WindowTypeLauncher"); | 179 widget->GetNativeView()->SetName("WindowTypeLauncher"); |
| 180 wm::SetShadowType(widget->GetNativeView(), | 180 ::wm::SetShadowType(widget->GetNativeView(), ::wm::SHADOW_TYPE_RECTANGULAR); |
| 181 wm::SHADOW_TYPE_RECTANGULAR); | |
| 182 widget->Show(); | 181 widget->Show(); |
| 183 } | 182 } |
| 184 | 183 |
| 185 WindowTypeLauncher::WindowTypeLauncher() | 184 WindowTypeLauncher::WindowTypeLauncher() |
| 186 : create_button_(new views::LabelButton( | 185 : create_button_(new views::LabelButton( |
| 187 this, base::ASCIIToUTF16("Create Window"))), | 186 this, base::ASCIIToUTF16("Create Window"))), |
| 188 panel_button_(new views::LabelButton( | 187 panel_button_(new views::LabelButton( |
| 189 this, base::ASCIIToUTF16("Create Panel"))), | 188 this, base::ASCIIToUTF16("Create Panel"))), |
| 190 create_nonresizable_button_(new views::LabelButton( | 189 create_nonresizable_button_(new views::LabelButton( |
| 191 this, base::ASCIIToUTF16("Create Non-Resizable Window"))), | 190 this, base::ASCIIToUTF16("Create Non-Resizable Window"))), |
| (...skipping 174 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 366 NULL, | 365 NULL, |
| 367 gfx::Rect(point, gfx::Size()), | 366 gfx::Rect(point, gfx::Size()), |
| 368 views::MENU_ANCHOR_TOPLEFT, | 367 views::MENU_ANCHOR_TOPLEFT, |
| 369 source_type) == MenuRunner::MENU_DELETED) { | 368 source_type) == MenuRunner::MENU_DELETED) { |
| 370 return; | 369 return; |
| 371 } | 370 } |
| 372 } | 371 } |
| 373 | 372 |
| 374 } // namespace shell | 373 } // namespace shell |
| 375 } // namespace ash | 374 } // namespace ash |
| OLD | NEW |