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

Side by Side Diff: trunk/src/apps/shell_window.cc

Issue 24262008: Revert 224473 "Remove dependency on ui::ScaleFactor from ui/gfx" (Closed) Base URL: svn://svn.chromium.org/chrome/
Patch Set: Created 7 years, 3 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
« no previous file with comments | « no previous file | trunk/src/ash/desktop_background/wallpaper_resizer_unittest.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 439 matching lines...) Expand 10 before | Expand all | Expand 10 after
450 app_icon_image_.reset(new extensions::IconImage( 450 app_icon_image_.reset(new extensions::IconImage(
451 profile(), 451 profile(),
452 extension(), 452 extension(),
453 extensions::IconsInfo::GetIcons(extension()), 453 extensions::IconsInfo::GetIcons(extension()),
454 delegate_->PreferredIconSize(), 454 delegate_->PreferredIconSize(),
455 extensions::IconsInfo::GetDefaultAppIcon(), 455 extensions::IconsInfo::GetDefaultAppIcon(),
456 this)); 456 this));
457 457
458 // Triggers actual image loading with 1x resources. The 2x resource will 458 // Triggers actual image loading with 1x resources. The 2x resource will
459 // be handled by IconImage class when requested. 459 // be handled by IconImage class when requested.
460 app_icon_image_->image_skia().GetRepresentation(1.0f); 460 app_icon_image_->image_skia().GetRepresentation(ui::SCALE_FACTOR_100P);
461 } 461 }
462 462
463 void ShellWindow::CloseContents(WebContents* contents) { 463 void ShellWindow::CloseContents(WebContents* contents) {
464 native_app_window_->Close(); 464 native_app_window_->Close();
465 } 465 }
466 466
467 bool ShellWindow::ShouldSuppressDialogs() { 467 bool ShellWindow::ShouldSuppressDialogs() {
468 return true; 468 return true;
469 } 469 }
470 470
(...skipping 179 matching lines...) Expand 10 before | Expand all | Expand 10 after
650 region.bounds.x(), 650 region.bounds.x(),
651 region.bounds.y(), 651 region.bounds.y(),
652 region.bounds.right(), 652 region.bounds.right(),
653 region.bounds.bottom(), 653 region.bounds.bottom(),
654 region.draggable ? SkRegion::kUnion_Op : SkRegion::kDifference_Op); 654 region.draggable ? SkRegion::kUnion_Op : SkRegion::kDifference_Op);
655 } 655 }
656 return sk_region; 656 return sk_region;
657 } 657 }
658 658
659 } // namespace apps 659 } // namespace apps
OLDNEW
« no previous file with comments | « no previous file | trunk/src/ash/desktop_background/wallpaper_resizer_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698