OLD | NEW |
1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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 "apps/shell_window.h" | 5 #include "apps/shell_window.h" |
6 | 6 |
7 #include "apps/native_app_window.h" | 7 #include "apps/native_app_window.h" |
8 #include "apps/shell_window_geometry_cache.h" | 8 #include "apps/shell_window_geometry_cache.h" |
9 #include "apps/shell_window_registry.h" | 9 #include "apps/shell_window_registry.h" |
10 #include "base/strings/string_util.h" | 10 #include "base/strings/string_util.h" |
(...skipping 434 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
445 app_icon_image_.reset(new extensions::IconImage( | 445 app_icon_image_.reset(new extensions::IconImage( |
446 profile(), | 446 profile(), |
447 extension(), | 447 extension(), |
448 extensions::IconsInfo::GetIcons(extension()), | 448 extensions::IconsInfo::GetIcons(extension()), |
449 delegate_->PreferredIconSize(), | 449 delegate_->PreferredIconSize(), |
450 extensions::IconsInfo::GetDefaultAppIcon(), | 450 extensions::IconsInfo::GetDefaultAppIcon(), |
451 this)); | 451 this)); |
452 | 452 |
453 // Triggers actual image loading with 1x resources. The 2x resource will | 453 // Triggers actual image loading with 1x resources. The 2x resource will |
454 // be handled by IconImage class when requested. | 454 // be handled by IconImage class when requested. |
455 app_icon_image_->image_skia().GetRepresentation(ui::SCALE_FACTOR_100P); | 455 app_icon_image_->image_skia().GetRepresentation(1.0f); |
456 } | 456 } |
457 | 457 |
458 void ShellWindow::CloseContents(WebContents* contents) { | 458 void ShellWindow::CloseContents(WebContents* contents) { |
459 native_app_window_->Close(); | 459 native_app_window_->Close(); |
460 } | 460 } |
461 | 461 |
462 bool ShellWindow::ShouldSuppressDialogs() { | 462 bool ShellWindow::ShouldSuppressDialogs() { |
463 return true; | 463 return true; |
464 } | 464 } |
465 | 465 |
(...skipping 179 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
645 region.bounds.x(), | 645 region.bounds.x(), |
646 region.bounds.y(), | 646 region.bounds.y(), |
647 region.bounds.right(), | 647 region.bounds.right(), |
648 region.bounds.bottom(), | 648 region.bounds.bottom(), |
649 region.draggable ? SkRegion::kUnion_Op : SkRegion::kDifference_Op); | 649 region.draggable ? SkRegion::kUnion_Op : SkRegion::kDifference_Op); |
650 } | 650 } |
651 return sk_region; | 651 return sk_region; |
652 } | 652 } |
653 | 653 |
654 } // namespace apps | 654 } // namespace apps |
OLD | NEW |