Commit 3b1f3bf0 authored by James Cook's avatar James Cook Committed by Commit Bot

cros: Eliminate access to ash::kShelfSize in chrome

It's an internal ash detail. Use extension_misc::EXTENSION_ICON_MEDIUM
in the 2 places in Chrome Apps code that need an appropriate size.

Bug: 678705
Test: browser_tests
Change-Id: I780377a91f1f7da633f784e4fc35bc0b77a9f7de
Reviewed-on: https://chromium-review.googlesource.com/1035443Reviewed-by: default avatarMichael Wasserman <msw@chromium.org>
Commit-Queue: James Cook <jamescook@chromium.org>
Cr-Commit-Position: refs/heads/master@{#554862}
parent 07e3ac15
specific_include_rules = {
# TODO(mash): Remove. http://crbug.com/678705
"chrome_app_delegate\.cc": [
"+ash/shelf/shelf_constants.h",
],
}
\ No newline at end of file
...@@ -44,7 +44,6 @@ ...@@ -44,7 +44,6 @@
#include "services/service_manager/public/cpp/interface_provider.h" #include "services/service_manager/public/cpp/interface_provider.h"
#if defined(OS_CHROMEOS) #if defined(OS_CHROMEOS)
#include "ash/shelf/shelf_constants.h"
#include "chrome/browser/chromeos/lock_screen_apps/state_controller.h" #include "chrome/browser/chromeos/lock_screen_apps/state_controller.h"
#endif #endif
...@@ -302,7 +301,8 @@ bool ChromeAppDelegate::CheckMediaAccessPermission( ...@@ -302,7 +301,8 @@ bool ChromeAppDelegate::CheckMediaAccessPermission(
int ChromeAppDelegate::PreferredIconSize() const { int ChromeAppDelegate::PreferredIconSize() const {
#if defined(OS_CHROMEOS) #if defined(OS_CHROMEOS)
return ash::kShelfSize; // Use a size appropriate for the ash shelf (see ash::kShelfSize).
return extension_misc::EXTENSION_ICON_MEDIUM;
#else #else
return extension_misc::EXTENSION_ICON_SMALL; return extension_misc::EXTENSION_ICON_SMALL;
#endif #endif
......
...@@ -12,7 +12,6 @@ ...@@ -12,7 +12,6 @@
#include "ash/shelf/app_list_button.h" #include "ash/shelf/app_list_button.h"
#include "ash/shelf/shelf.h" #include "ash/shelf/shelf.h"
#include "ash/shelf/shelf_button.h" #include "ash/shelf/shelf_button.h"
#include "ash/shelf/shelf_constants.h"
#include "ash/shelf/shelf_view.h" #include "ash/shelf/shelf_view.h"
#include "ash/shelf/shelf_view_test_api.h" #include "ash/shelf/shelf_view_test_api.h"
#include "ash/shelf/shelf_widget.h" #include "ash/shelf/shelf_widget.h"
...@@ -853,7 +852,7 @@ IN_PROC_BROWSER_TEST_F(LauncherPlatformAppBrowserTest, SetIcon) { ...@@ -853,7 +852,7 @@ IN_PROC_BROWSER_TEST_F(LauncherPlatformAppBrowserTest, SetIcon) {
// Ensure icon heights are correct (see test.js in app_icon/ test directory) // Ensure icon heights are correct (see test.js in app_icon/ test directory)
// Note, images are no longer available in ChromeLauncherController. They are // Note, images are no longer available in ChromeLauncherController. They are
// are passed directly to the ShelfController. // are passed directly to the ShelfController.
EXPECT_EQ(ash::kShelfSize, app_item_image.height()); EXPECT_EQ(extension_misc::EXTENSION_ICON_MEDIUM, app_item_image.height());
EXPECT_EQ(extension_misc::EXTENSION_ICON_LARGE, EXPECT_EQ(extension_misc::EXTENSION_ICON_LARGE,
app_item_custom_image.height()); app_item_custom_image.height());
EXPECT_EQ(64, panel_item_image.height()); EXPECT_EQ(64, panel_item_image.height());
......
...@@ -23,7 +23,6 @@ ...@@ -23,7 +23,6 @@
#include "ash/public/cpp/shelf_types.h" #include "ash/public/cpp/shelf_types.h"
#include "ash/public/cpp/window_properties.h" #include "ash/public/cpp/window_properties.h"
#include "ash/shelf/shelf_application_menu_model.h" #include "ash/shelf/shelf_application_menu_model.h"
#include "ash/shelf/shelf_constants.h"
#include "ash/shelf/shelf_controller.h" #include "ash/shelf/shelf_controller.h"
#include "ash/shell.h" #include "ash/shell.h"
#include "ash/wm/tablet_mode/tablet_mode_controller.h" #include "ash/wm/tablet_mode/tablet_mode_controller.h"
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment