diff --git a/ash/BUILD.gn b/ash/BUILD.gn index bb48399b1bd6d8..ceabc8ffdea9c2 100644 --- a/ash/BUILD.gn +++ b/ash/BUILD.gn @@ -1206,7 +1206,6 @@ component("ash") { public_deps = [ "//ash/public/cpp", "//ash/public/cpp/vector_icons", - "//ash/resources", "//ash/resources/vector_icons", "//ash/strings", "//ash/wayland", @@ -1829,7 +1828,6 @@ test("ash_unittests") { "//ash/public/cpp", "//ash/public/cpp:unit_tests", "//ash/public/cpp/vector_icons", - "//ash/resources", "//ash/resources/vector_icons", "//ash/strings", "//ash/touch_hud", @@ -2128,7 +2126,6 @@ static_library("test_support_common") { "//ash/components/fast_ink", "//ash/public/cpp", "//ash/public/interfaces:test_interfaces", - "//ash/resources", "//base", "//base:i18n", "//base/test:test_support", @@ -2230,7 +2227,6 @@ repack("ash_service_resources") { output = "$root_out_dir/ash_service_resources.pak" sources = [ "$root_gen_dir/ash/components/resources/ash_components_resources_100_percent.pak", - "$root_gen_dir/ash/resources/ash_resources_100_percent.pak", "$root_gen_dir/ash/strings/ash_strings_en-US.pak", "$root_gen_dir/ui/chromeos/resources/ui_chromeos_resources_100_percent.pak", "$root_gen_dir/ui/chromeos/strings/ui_chromeos_strings_en-US.pak", @@ -2241,7 +2237,6 @@ repack("ash_service_resources") { ] deps = [ "//ash/components/resources", - "//ash/resources", "//ash/strings", "//ui/chromeos/resources", "//ui/chromeos/strings", @@ -2256,14 +2251,12 @@ repack("ash_service_resources_200") { output = "$root_out_dir/ash_service_resources_200.pak" sources = [ "$root_gen_dir/ash/components/resources/ash_components_resources_200_percent.pak", - "$root_gen_dir/ash/resources/ash_resources_200_percent.pak", "$root_gen_dir/ui/chromeos/resources/ui_chromeos_resources_200_percent.pak", "$root_gen_dir/ui/resources/ui_resources_200_percent.pak", "$root_gen_dir/ui/views/resources/views_resources_200_percent.pak", ] deps = [ "//ash/components/resources", - "//ash/resources", "//ui/chromeos/resources", "//ui/resources", "//ui/views/resources", diff --git a/ash/display/resolution_notification_controller.cc b/ash/display/resolution_notification_controller.cc index 22e7bb21473761..7d31f4eedce941 100644 --- a/ash/display/resolution_notification_controller.cc +++ b/ash/display/resolution_notification_controller.cc @@ -6,7 +6,7 @@ #include -#include "ash/resources/grit/ash_resources.h" +#include "ash/resources/vector_icons/vector_icons.h" #include "ash/session/session_controller.h" #include "ash/shell.h" #include "ash/strings/grit/ash_strings.h" @@ -14,7 +14,6 @@ #include "base/strings/utf_string_conversions.h" #include "ui/base/l10n/l10n_util.h" #include "ui/base/l10n/time_format.h" -#include "ui/base/resource/resource_bundle.h" #include "ui/display/display.h" #include "ui/display/manager/display_manager.h" #include "ui/display/manager/managed_display_info.h" @@ -221,17 +220,22 @@ void ResolutionNotificationController::CreateOrUpdateNotification( base::UTF8ToUTF16( change_info_->current_resolution.size().ToString())); - ui::ResourceBundle& bundle = ui::ResourceBundle::GetSharedInstance(); - auto notification = std::make_unique( - message_center::NOTIFICATION_TYPE_SIMPLE, kNotificationId, message, - timeout_message, bundle.GetImageNamed(IDR_AURA_NOTIFICATION_DISPLAY), - base::string16() /* display_source */, GURL(), - message_center::NotifierId(message_center::NotifierId::SYSTEM_COMPONENT, - kNotifierDisplayResolutionChange), - data, - base::MakeRefCounted( - weak_factory_.GetWeakPtr())); - notification->SetSystemPriority(); + std::unique_ptr notification = + Notification::CreateSystemNotification( + message_center::NOTIFICATION_TYPE_SIMPLE, kNotificationId, message, + timeout_message, gfx::Image(), + base::string16(), // display_source + GURL(), + message_center::NotifierId( + message_center::NotifierId::SYSTEM_COMPONENT, + kNotifierDisplayResolutionChange), + data, + base::MakeRefCounted( + weak_factory_.GetWeakPtr()), + kNotificationScreenIcon, + message_center::SystemNotificationWarningLevel::NORMAL); + notification->set_priority(message_center::SYSTEM_PRIORITY); + message_center->AddNotification(std::move(notification)); } diff --git a/ash/resources/BUILD.gn b/ash/resources/BUILD.gn index 625e6dcd4c0d07..630351a9dc2f96 100644 --- a/ash/resources/BUILD.gn +++ b/ash/resources/BUILD.gn @@ -9,15 +9,6 @@ import("//ui/base/ui_features.gni") assert(is_chromeos) assert(enable_hidpi) -grit("resources") { - source = "ash_resources.grd" - outputs = [ - "grit/ash_resources.h", - "ash_resources_100_percent.pak", - "ash_resources_200_percent.pak", - ] -} - # Repacks resources needed for ash_unittests, etc. at a given scale. # TODO(msw): Use ui_test.pak instead of its pieces? (no 200% support?) template("ash_test_resources") { @@ -29,7 +20,6 @@ template("ash_test_resources") { sources = [ "$root_gen_dir/ash/components/resources/ash_components_resources_${percent}_percent.pak", "$root_gen_dir/ash/public/cpp/resources/ash_public_unscaled_resources.pak", - "$root_gen_dir/ash/resources/ash_resources_${percent}_percent.pak", "$root_gen_dir/ui/app_list/resources/app_list_resources_${percent}_percent.pak", "$root_gen_dir/ui/chromeos/resources/ui_chromeos_resources_${percent}_percent.pak", "$root_gen_dir/ui/resources/ui_resources_${percent}_percent.pak", @@ -50,7 +40,6 @@ template("ash_test_resources") { deps = [ "//ash/components/resources", "//ash/public/cpp/resources:ash_public_unscaled_resources", - "//ash/resources", "//mojo/public/js:resources", "//ui/app_list/resources", "//ui/chromeos/resources", diff --git a/ash/resources/ash_resources.grd b/ash/resources/ash_resources.grd deleted file mode 100644 index 1edf3c94d321a2..00000000000000 --- a/ash/resources/ash_resources.grd +++ /dev/null @@ -1,19 +0,0 @@ - - - - - - - - - - - - - - - - - diff --git a/ash/resources/default_100_percent/cros/notification/display_notification_icon.png b/ash/resources/default_100_percent/cros/notification/display_notification_icon.png deleted file mode 100644 index e49d82a23cefff..00000000000000 Binary files a/ash/resources/default_100_percent/cros/notification/display_notification_icon.png and /dev/null differ diff --git a/ash/resources/default_200_percent/cros/notification/display_notification_icon.png b/ash/resources/default_200_percent/cros/notification/display_notification_icon.png deleted file mode 100644 index 832e974fcc968a..00000000000000 Binary files a/ash/resources/default_200_percent/cros/notification/display_notification_icon.png and /dev/null differ diff --git a/ash/system/bluetooth/bluetooth_notification_controller.cc b/ash/system/bluetooth/bluetooth_notification_controller.cc index 58e6b8203c48e5..c517b81b1cea94 100644 --- a/ash/system/bluetooth/bluetooth_notification_controller.cc +++ b/ash/system/bluetooth/bluetooth_notification_controller.cc @@ -7,7 +7,6 @@ #include #include -#include "ash/resources/grit/ash_resources.h" #include "ash/resources/vector_icons/vector_icons.h" #include "ash/strings/grit/ash_strings.h" #include "base/bind.h" diff --git a/ash/system/locale/locale_notification_controller.cc b/ash/system/locale/locale_notification_controller.cc index bb84369c86a25f..8c2a573567e4dd 100644 --- a/ash/system/locale/locale_notification_controller.cc +++ b/ash/system/locale/locale_notification_controller.cc @@ -8,7 +8,6 @@ #include #include "ash/public/cpp/vector_icons/vector_icons.h" -#include "ash/resources/grit/ash_resources.h" #include "ash/strings/grit/ash_strings.h" #include "ash/system/tray/system_tray_notifier.h" #include "base/strings/string16.h" diff --git a/ash/system/power/battery_notification.cc b/ash/system/power/battery_notification.cc index 6202550fed027b..75d9066619e7a1 100644 --- a/ash/system/power/battery_notification.cc +++ b/ash/system/power/battery_notification.cc @@ -5,7 +5,6 @@ #include "ash/system/power/battery_notification.h" #include "ash/public/cpp/power_utils.h" -#include "ash/resources/grit/ash_resources.h" #include "ash/resources/vector_icons/vector_icons.h" #include "ash/strings/grit/ash_strings.h" #include "ash/system/power/power_status.h" diff --git a/ash/system/power/dual_role_notification.cc b/ash/system/power/dual_role_notification.cc index 9f6b204f1715c3..a27e009f444fc8 100644 --- a/ash/system/power/dual_role_notification.cc +++ b/ash/system/power/dual_role_notification.cc @@ -6,7 +6,6 @@ #include -#include "ash/resources/grit/ash_resources.h" #include "ash/resources/vector_icons/vector_icons.h" #include "ash/shell.h" #include "ash/strings/grit/ash_strings.h" diff --git a/ash/system/power/peripheral_battery_notifier.cc b/ash/system/power/peripheral_battery_notifier.cc index f1b9023bf2296d..f3850e7ca201b6 100644 --- a/ash/system/power/peripheral_battery_notifier.cc +++ b/ash/system/power/peripheral_battery_notifier.cc @@ -6,7 +6,6 @@ #include -#include "ash/resources/grit/ash_resources.h" #include "ash/resources/vector_icons/vector_icons.h" #include "ash/shell.h" #include "ash/strings/grit/ash_strings.h" diff --git a/ash/system/power/tray_power.cc b/ash/system/power/tray_power.cc index 193554d563b172..82a2020e964427 100644 --- a/ash/system/power/tray_power.cc +++ b/ash/system/power/tray_power.cc @@ -8,7 +8,7 @@ #include "ash/accessibility/accessibility_delegate.h" #include "ash/public/cpp/ash_switches.h" -#include "ash/resources/grit/ash_resources.h" + #include "ash/resources/vector_icons/vector_icons.h" #include "ash/strings/grit/ash_strings.h" #include "ash/system/date/date_view.h" diff --git a/ash/system/screen_layout_observer.cc b/ash/system/screen_layout_observer.cc index b4b96a34e9bf23..78aae213ca1ab5 100644 --- a/ash/system/screen_layout_observer.cc +++ b/ash/system/screen_layout_observer.cc @@ -11,7 +11,6 @@ #include "ash/display/screen_orientation_controller.h" #include "ash/metrics/user_metrics_action.h" #include "ash/metrics/user_metrics_recorder.h" -#include "ash/resources/grit/ash_resources.h" #include "ash/resources/vector_icons/vector_icons.h" #include "ash/session/session_controller.h" #include "ash/shell.h" diff --git a/ash/system/screen_security/screen_capture_tray_item.cc b/ash/system/screen_security/screen_capture_tray_item.cc index 472194a9d4e6b7..61616d874ee390 100644 --- a/ash/system/screen_security/screen_capture_tray_item.cc +++ b/ash/system/screen_security/screen_capture_tray_item.cc @@ -9,7 +9,7 @@ #include "ash/metrics/user_metrics_action.h" #include "ash/metrics/user_metrics_recorder.h" #include "ash/public/cpp/ash_features.h" -#include "ash/resources/grit/ash_resources.h" + #include "ash/resources/vector_icons/vector_icons.h" #include "ash/shell.h" #include "ash/strings/grit/ash_strings.h" diff --git a/ash/system/screen_security/screen_share_tray_item.cc b/ash/system/screen_security/screen_share_tray_item.cc index 38ee08664271d7..eed0520c52156e 100644 --- a/ash/system/screen_security/screen_share_tray_item.cc +++ b/ash/system/screen_security/screen_share_tray_item.cc @@ -6,7 +6,6 @@ #include -#include "ash/resources/grit/ash_resources.h" #include "ash/resources/vector_icons/vector_icons.h" #include "ash/shell.h" #include "ash/strings/grit/ash_strings.h" diff --git a/chrome/browser/chromeos/BUILD.gn b/chrome/browser/chromeos/BUILD.gn index a841b1418d9ebd..0e1ff76ef6c532 100644 --- a/chrome/browser/chromeos/BUILD.gn +++ b/chrome/browser/chromeos/BUILD.gn @@ -21,7 +21,6 @@ source_set("chromeos") { configs += [ "//build/config/compiler:wexit_time_destructors" ] public_deps = [ - "//ash/resources", "//ash/strings", "//chrome:extra_resources", "//chrome:resources", @@ -2179,7 +2178,6 @@ source_set("unit_tests") { ":attestation_proto", ":test_support", "//ash", - "//ash/resources", "//base", "//chrome/common", "//chromeos/components/tether:test_support", diff --git a/chrome/browser/ui/app_list/DEPS b/chrome/browser/ui/app_list/DEPS index 226b2da1149c3d..53de606bd22e19 100644 --- a/chrome/browser/ui/app_list/DEPS +++ b/chrome/browser/ui/app_list/DEPS @@ -6,10 +6,3 @@ include_rules = [ "+ash/public", ] - -specific_include_rules = { - # TODO(733662): Remove when app_list is migrated. - "crostini_app_model_builder\.cc": [ - "+ash/resources/grit/ash_resources.h", - ], -} diff --git a/chrome/browser/ui/app_list/crostini/crostini_app_model_builder.cc b/chrome/browser/ui/app_list/crostini/crostini_app_model_builder.cc index 446fb5d580c3d8..cd9517b0d469e1 100644 --- a/chrome/browser/ui/app_list/crostini/crostini_app_model_builder.cc +++ b/chrome/browser/ui/app_list/crostini/crostini_app_model_builder.cc @@ -4,7 +4,6 @@ #include "chrome/browser/ui/app_list/crostini/crostini_app_model_builder.h" -#include "ash/resources/grit/ash_resources.h" #include "chrome/browser/chromeos/crostini/crostini_manager.h" #include "chrome/browser/chromeos/crostini/crostini_pref_names.h" #include "chrome/browser/chromeos/crostini/crostini_registry_service_factory.h" @@ -12,11 +11,9 @@ #include "chrome/browser/profiles/profile.h" #include "chrome/browser/ui/app_list/app_list_controller_delegate.h" #include "chrome/browser/ui/app_list/crostini/crostini_app_item.h" -#include "chrome/grit/chrome_unscaled_resources.h" #include "components/crx_file/id_util.h" #include "components/prefs/pref_change_registrar.h" #include "ui/base/l10n/l10n_util.h" -#include "ui/base/resource/resource_bundle.h" CrostiniAppModelBuilder::CrostiniAppModelBuilder( AppListControllerDelegate* controller) diff --git a/chrome/chrome_paks.gni b/chrome/chrome_paks.gni index 9c2c9cbddc5734..fde31eb044edf6 100644 --- a/chrome/chrome_paks.gni +++ b/chrome/chrome_paks.gni @@ -59,12 +59,10 @@ template("chrome_repack_percent") { if (is_chromeos) { sources += [ "$root_gen_dir/ash/components/resources/ash_components_resources_${percent}_percent.pak", - "$root_gen_dir/ash/resources/ash_resources_${percent}_percent.pak", "$root_gen_dir/ui/chromeos/resources/ui_chromeos_resources_${percent}_percent.pak", ] deps += [ "//ash/components/resources", - "//ash/resources", "//ui/chromeos/resources", ] } diff --git a/chrome/test/BUILD.gn b/chrome/test/BUILD.gn index 24c485d177de55..b20e8beee3282b 100644 --- a/chrome/test/BUILD.gn +++ b/chrome/test/BUILD.gn @@ -3250,7 +3250,6 @@ test("unit_tests") { deps += [ "//ash:test_support_with_content", "//ash/public/cpp/resources:ash_public_unscaled_resources", - "//ash/resources", "//ash/strings", ] } @@ -4882,7 +4881,6 @@ if (!is_android) { "//ash:interactive_ui_test_support", "//ash/app_list/presenter:test_support", "//ash/public/interfaces:test_interfaces", - "//ash/resources", "//chrome/browser/media/router:test_support", "//chromeos", "//mojo/edk", diff --git a/tools/check_grd_for_unused_strings.py b/tools/check_grd_for_unused_strings.py index d997db66ccb29e..2defb2fc0a7238 100755 --- a/tools/check_grd_for_unused_strings.py +++ b/tools/check_grd_for_unused_strings.py @@ -137,7 +137,6 @@ def main(): ui_chromeos_dir = os.path.join(ui_dir, 'chromeos') grd_files = [ os.path.join(ash_base_dir, 'ash_strings.grd'), - os.path.join(ash_base_dir, 'resources', 'ash_resources.grd'), os.path.join(ash_components_dir, 'ash_components_strings.grd'), os.path.join(ash_components_dir, 'resources', 'ash_components_resources.grd'), diff --git a/tools/gritsettings/resource_ids b/tools/gritsettings/resource_ids index 7e838ac964fc6c..fc16a42e623e99 100644 --- a/tools/gritsettings/resource_ids +++ b/tools/gritsettings/resource_ids @@ -293,9 +293,6 @@ "ash/public/cpp/resources/ash_public_unscaled_resources.grd": { "includes": [24260], }, - "ash/resources/ash_resources.grd": { - "structures": [24280], - }, "ash/shell/ash_shell_resources.grd": { "includes": [24290], }, diff --git a/tools/resources/find_unused_resources.py b/tools/resources/find_unused_resources.py index d6e52c866ed2ba..eab5ba3c6a1dcf 100755 --- a/tools/resources/find_unused_resources.py +++ b/tools/resources/find_unused_resources.py @@ -12,7 +12,7 @@ Example: cd /work/chrome/src - tools/resources/find_unused_resouces.py ash/resources/ash_resources.grd + tools/resources/find_unused_resouces.py chrome/browser/browser_resources.grd """ __author__ = 'jamescook@chromium.org (James Cook)'