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

Side by Side Diff: apps/shell_window.cc

Issue 24175004: Remove dependency on ui::ScaleFactor from ui/gfx (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
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 | ash/desktop_background/wallpaper_resizer_unittest.cc » ('j') | cc/layers/layer.cc » ('J')
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 434 matching lines...) Expand 10 before | Expand all | Expand 10 after
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
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
OLDNEW
« no previous file with comments | « no previous file | ash/desktop_background/wallpaper_resizer_unittest.cc » ('j') | cc/layers/layer.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698