chromium/components/browser_ui/styles/android/BUILD.gn

# Copyright 2019 The Chromium Authors
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.

import("//build/config/android/rules.gni")
import("//device/vr/buildflags/buildflags.gni")

android_library("java") {
  sources = [
    "java/src/org/chromium/components/browser_ui/styles/ChromeColors.java",
    "java/src/org/chromium/components/browser_ui/styles/SemanticColorUtils.java",
  ]
  deps = [
    ":java_resources",
    "//third_party/android_deps:material_design_java",
    "//third_party/androidx:androidx_annotation_annotation_java",
    "//third_party/androidx:androidx_appcompat_appcompat_java",
    "//third_party/androidx:androidx_appcompat_appcompat_resources_java",
  ]
  resources_package = "org.chromium.components.browser_ui.styles"
}

android_resources("java_resources") {
  sources = [
    "java/res/color/chip_text_color_secondary_list.xml",
    "java/res/color/color_on_surface_with_alpha_10.xml",
    "java/res/color/color_primary_with_alpha_10.xml",
    "java/res/color/color_primary_with_alpha_15.xml",
    "java/res/color/color_primary_with_alpha_20.xml",
    "java/res/color/color_primary_with_alpha_5.xml",
    "java/res/color/default_icon_color_accent1_tint_list.xml",
    "java/res/color/default_icon_color_dark_tint_list.xml",
    "java/res/color/default_icon_color_disabled.xml",
    "java/res/color/default_icon_color_light_tint_list.xml",
    "java/res/color/default_icon_color_secondary_light_tint_list.xml",
    "java/res/color/default_icon_color_secondary_tint_list.xml",
    "java/res/color/default_icon_color_tint_list.xml",
    "java/res/color/default_icon_color_white_tint_list.xml",
    "java/res/color/default_text_color_accent1_tint_list.xml",
    "java/res/color/default_text_color_disabled_list.xml",
    "java/res/color/default_text_color_hint_list.xml",
    "java/res/color/default_text_color_link_tint_list.xml",
    "java/res/color/default_text_color_list.xml",
    "java/res/color/default_text_color_on_accent1_container_list.xml",
    "java/res/color/default_text_color_on_accent1_list.xml",
    "java/res/color/default_text_color_secondary_list.xml",
    "java/res/color/filled_button_bg_dynamic_list.xml",
    "java/res/color/icon_animated_faded_color_list.xml",
    "java/res/color/progress_bar_bg_color_list.xml",
    "java/res/color/selection_control_button_tint_list.xml",
    "java/res/color/target_view_color_list.xml",
    "java/res/color/text_button_ripple_color_list.xml",
    "java/res/color/text_highlight_color.xml",
    "java/res/color/toolbar_button_highlight_color.xml",
    "java/res/color/toolbar_icon_unfocused_activity_tint_list.xml",
    "java/res/drawable-hdpi/btn_star_filled.png",
    "java/res/drawable-hdpi/ic_chrome.png",
    "java/res/drawable-hdpi/ic_delete_white_24dp.png",
    "java/res/drawable-hdpi/ic_edit_24dp.png",
    "java/res/drawable-hdpi/ic_logo_googleg_24dp.png",
    "java/res/drawable-hdpi/ic_open_in_new_white_24dp.png",
    "java/res/drawable-hdpi/ic_pause_white_36dp.png",
    "java/res/drawable-hdpi/ic_play_arrow_white_36dp.png",
    "java/res/drawable-hdpi/ic_refresh_white_24dp.png",
    "java/res/drawable-hdpi/ic_refresh_white_36dp.png",
    "java/res/drawable-hdpi/ic_share_white_24dp.png",
    "java/res/drawable-hdpi/ic_storage.png",
    "java/res/drawable-hdpi/modern_toolbar_shadow.png",
    "java/res/drawable-hdpi/navigation_bubble_shadow.9.png",
    "java/res/drawable-hdpi/plus.png",
    "java/res/drawable-hdpi/settings_all_sites.png",
    "java/res/drawable-hdpi/settings_cog.png",
    "java/res/drawable-hdpi/top_round_foreground.9.png",
    "java/res/drawable-hdpi/top_round_shadow.9.png",
    "java/res/drawable-ldrtl-hdpi/ic_share_white_24dp.png",
    "java/res/drawable-ldrtl-mdpi/ic_share_white_24dp.png",
    "java/res/drawable-ldrtl-xhdpi/ic_share_white_24dp.png",
    "java/res/drawable-ldrtl-xxhdpi/ic_share_white_24dp.png",
    "java/res/drawable-ldrtl-xxxhdpi/ic_share_white_24dp.png",
    "java/res/drawable-mdpi/btn_star_filled.png",
    "java/res/drawable-mdpi/ic_chrome.png",
    "java/res/drawable-mdpi/ic_delete_white_24dp.png",
    "java/res/drawable-mdpi/ic_edit_24dp.png",
    "java/res/drawable-mdpi/ic_logo_googleg_24dp.png",
    "java/res/drawable-mdpi/ic_open_in_new_white_24dp.png",
    "java/res/drawable-mdpi/ic_pause_white_36dp.png",
    "java/res/drawable-mdpi/ic_play_arrow_white_36dp.png",
    "java/res/drawable-mdpi/ic_refresh_white_24dp.png",
    "java/res/drawable-mdpi/ic_refresh_white_36dp.png",
    "java/res/drawable-mdpi/ic_share_white_24dp.png",
    "java/res/drawable-mdpi/ic_storage.png",
    "java/res/drawable-mdpi/modern_toolbar_shadow.png",
    "java/res/drawable-mdpi/navigation_bubble_shadow.9.png",
    "java/res/drawable-mdpi/plus.png",
    "java/res/drawable-mdpi/settings_all_sites.png",
    "java/res/drawable-mdpi/settings_cog.png",
    "java/res/drawable-mdpi/top_round_foreground.9.png",
    "java/res/drawable-mdpi/top_round_shadow.9.png",
    "java/res/drawable-xhdpi/btn_star_filled.png",
    "java/res/drawable-xhdpi/ic_chrome.png",
    "java/res/drawable-xhdpi/ic_delete_white_24dp.png",
    "java/res/drawable-xhdpi/ic_edit_24dp.png",
    "java/res/drawable-xhdpi/ic_logo_googleg_24dp.png",
    "java/res/drawable-xhdpi/ic_open_in_new_white_24dp.png",
    "java/res/drawable-xhdpi/ic_pause_white_36dp.png",
    "java/res/drawable-xhdpi/ic_play_arrow_white_36dp.png",
    "java/res/drawable-xhdpi/ic_refresh_white_24dp.png",
    "java/res/drawable-xhdpi/ic_refresh_white_36dp.png",
    "java/res/drawable-xhdpi/ic_share_white_24dp.png",
    "java/res/drawable-xhdpi/ic_storage.png",
    "java/res/drawable-xhdpi/modern_toolbar_shadow.png",
    "java/res/drawable-xhdpi/navigation_bubble_shadow.9.png",
    "java/res/drawable-xhdpi/plus.png",
    "java/res/drawable-xhdpi/settings_all_sites.png",
    "java/res/drawable-xhdpi/settings_cog.png",
    "java/res/drawable-xhdpi/top_round_foreground.9.png",
    "java/res/drawable-xhdpi/top_round_shadow.9.png",
    "java/res/drawable-xxhdpi/btn_star_filled.png",
    "java/res/drawable-xxhdpi/ic_chrome.png",
    "java/res/drawable-xxhdpi/ic_delete_white_24dp.png",
    "java/res/drawable-xxhdpi/ic_edit_24dp.png",
    "java/res/drawable-xxhdpi/ic_logo_googleg_24dp.png",
    "java/res/drawable-xxhdpi/ic_open_in_new_white_24dp.png",
    "java/res/drawable-xxhdpi/ic_pause_white_36dp.png",
    "java/res/drawable-xxhdpi/ic_play_arrow_white_36dp.png",
    "java/res/drawable-xxhdpi/ic_refresh_white_24dp.png",
    "java/res/drawable-xxhdpi/ic_refresh_white_36dp.png",
    "java/res/drawable-xxhdpi/ic_share_white_24dp.png",
    "java/res/drawable-xxhdpi/ic_storage.png",
    "java/res/drawable-xxhdpi/modern_toolbar_shadow.png",
    "java/res/drawable-xxhdpi/navigation_bubble_shadow.9.png",
    "java/res/drawable-xxhdpi/plus.png",
    "java/res/drawable-xxhdpi/settings_all_sites.png",
    "java/res/drawable-xxhdpi/settings_cog.png",
    "java/res/drawable-xxhdpi/top_round_foreground.9.png",
    "java/res/drawable-xxhdpi/top_round_shadow.9.png",
    "java/res/drawable-xxxhdpi/btn_star_filled.png",
    "java/res/drawable-xxxhdpi/ic_chrome.png",
    "java/res/drawable-xxxhdpi/ic_delete_white_24dp.png",
    "java/res/drawable-xxxhdpi/ic_edit_24dp.png",
    "java/res/drawable-xxxhdpi/ic_logo_googleg_24dp.png",
    "java/res/drawable-xxxhdpi/ic_open_in_new_white_24dp.png",
    "java/res/drawable-xxxhdpi/ic_pause_white_36dp.png",
    "java/res/drawable-xxxhdpi/ic_play_arrow_white_36dp.png",
    "java/res/drawable-xxxhdpi/ic_refresh_white_24dp.png",
    "java/res/drawable-xxxhdpi/ic_refresh_white_36dp.png",
    "java/res/drawable-xxxhdpi/ic_share_white_24dp.png",
    "java/res/drawable-xxxhdpi/ic_storage.png",
    "java/res/drawable-xxxhdpi/navigation_bubble_shadow.9.png",
    "java/res/drawable-xxxhdpi/plus.png",
    "java/res/drawable-xxxhdpi/settings_all_sites.png",
    "java/res/drawable-xxxhdpi/settings_cog.png",
    "java/res/drawable-xxxhdpi/top_round_foreground.9.png",
    "java/res/drawable-xxxhdpi/top_round_shadow.9.png",
    "java/res/drawable/checkmark_blue.xml",
    "java/res/drawable/circle_white.xml",
    "java/res/drawable/gm_ads_click_24.xml",
    "java/res/drawable/ic_account_circle.xml",
    "java/res/drawable/ic_account_circle_24dp.xml",
    "java/res/drawable/ic_add.xml",
    "java/res/drawable/ic_bar_chart_24dp.xml",
    "java/res/drawable/ic_bolt_24dp.xml",
    "java/res/drawable/ic_brightness_medium_24dp.xml",
    "java/res/drawable/ic_business.xml",
    "java/res/drawable/ic_call_end_white_24dp.xml",
    "java/res/drawable/ic_check_circle_filled_green_24dp.xml",
    "java/res/drawable/ic_collections_grey.xml",
    "java/res/drawable/ic_cookie_24dp.xml",
    "java/res/drawable/ic_data_personalization_20dp.xml",
    "java/res/drawable/ic_data_viz_grey.xml",
    "java/res/drawable/ic_data_viz_grey_24.xml",
    "java/res/drawable/ic_desktop_windows.xml",
    "java/res/drawable/ic_dino.xml",
    "java/res/drawable/ic_dns_24dp.xml",
    "java/res/drawable/ic_domain_verification_24dp.xml",
    "java/res/drawable/ic_done_blue.xml",
    "java/res/drawable/ic_download.xml",
    "java/res/drawable/ic_drive_document_24dp.xml",
    "java/res/drawable/ic_drive_file_24dp.xml",
    "java/res/drawable/ic_drive_image_24dp.xml",
    "java/res/drawable/ic_eye_crossed.xml",
    "java/res/drawable/ic_fast_forward_white_24dp.xml",
    "java/res/drawable/ic_fast_rewind_white_24dp.xml",
    "java/res/drawable/ic_file_download_24dp.xml",
    "java/res/drawable/ic_file_download_36dp.xml",
    "java/res/drawable/ic_flash_on_24dp.xml",
    "java/res/drawable/ic_folder_blue_24dp.xml",
    "java/res/drawable/ic_gshield.xml",
    "java/res/drawable/ic_gshield_24.xml",
    "java/res/drawable/ic_help_and_feedback.xml",
    "java/res/drawable/ic_history_24dp.xml",
    "java/res/drawable/ic_info_outline_grey_16dp.xml",
    "java/res/drawable/ic_info_outline_grey_24dp.xml",
    "java/res/drawable/ic_language.xml",
    "java/res/drawable/ic_language_24.xml",
    "java/res/drawable/ic_lightbulb_24dp.xml",
    "java/res/drawable/ic_link.xml",
    "java/res/drawable/ic_link_24dp.xml",
    "java/res/drawable/ic_manage_search_24dp.xml",
    "java/res/drawable/ic_mic_off_white_24dp.xml",
    "java/res/drawable/ic_mic_white_24dp.xml",
    "java/res/drawable/ic_music_note_24dp.xml",
    "java/res/drawable/ic_notification_add_24dp.xml",
    "java/res/drawable/ic_offline_pin_24dp_on_dark_bg.xml",
    "java/res/drawable/ic_offline_pin_24dp_on_light_bg.xml",
    "java/res/drawable/ic_outline_email_24dp.xml",
    "java/res/drawable/ic_outline_sms_24dp.xml",
    "java/res/drawable/ic_password_manager_key.xml",
    "java/res/drawable/ic_pause_white_24dp.xml",
    "java/res/drawable/ic_photo_camera_black.xml",
    "java/res/drawable/ic_play_arrow_white_24dp.xml",
    "java/res/drawable/ic_play_circle_filled_24dp_on_dark_bg.xml",
    "java/res/drawable/ic_play_circle_filled_24dp_on_light_bg.xml",
    "java/res/drawable/ic_remove.xml",
    "java/res/drawable/ic_replay_white_24dp.xml",
    "java/res/drawable/ic_security_grey.xml",
    "java/res/drawable/ic_select_window_24dp.xml",
    "java/res/drawable/ic_settings_black.xml",
    "java/res/drawable/ic_skip_next_white_24dp.xml",
    "java/res/drawable/ic_skip_previous_white_24dp.xml",
    "java/res/drawable/ic_speed.xml",
    "java/res/drawable/ic_speed_24.xml",
    "java/res/drawable/ic_stop_white_24dp.xml",
    "java/res/drawable/ic_tune_24dp.xml",
    "java/res/drawable/ic_update_grey.xml",
    "java/res/drawable/ic_videocam_24dp.xml",
    "java/res/drawable/ic_videocam_off_white_24dp.xml",
    "java/res/drawable/ic_visibility_black.xml",
    "java/res/drawable/ic_visibility_off_black.xml",
    "java/res/drawable/ic_volume_off_white_24dp.xml",
    "java/res/drawable/ic_volume_on_white_24dp.xml",
    "java/res/drawable/ic_warning_red_16dp.xml",
    "java/res/drawable/ic_warning_red_24dp.xml",
    "java/res/drawable/ic_warning_red_outline_32dp.xml",
    "java/res/drawable/ic_youtube_searched_for_24dp.xml",
    "java/res/drawable/smartphone_black_24dp.xml",
    "java/res/drawable/star_outline_24dp.xml",
    "java/res/drawable/toolbar_hairline.xml",
    "java/res/values-night/colors.xml",
    "java/res/values-night/dimens.xml",
    "java/res/values-night/drawables.xml",
    "java/res/values-night/values.xml",
    "java/res/values-sw600dp-v27/styles.xml",
    "java/res/values-sw600dp/styles.xml",
    "java/res/values-v27/styles.xml",
    "java/res/values-v31/colors.xml",
    "java/res/values/colors.xml",
    "java/res/values/dimens.xml",
    "java/res/values/drawables.xml",
    "java/res/values/semantic_colors_dynamic.xml",
    "java/res/values/styles.xml",
    "java/res/values/themes.xml",
    "java/res/values/values.xml",
    "java/res_chromium/drawable-hdpi/fre_product_logo.png",
    "java/res_chromium/drawable-hdpi/product_logo_name.png",
    "java/res_chromium/drawable-mdpi/fre_product_logo.png",
    "java/res_chromium/drawable-mdpi/product_logo_name.png",
    "java/res_chromium/drawable-xhdpi/fre_product_logo.png",
    "java/res_chromium/drawable-xhdpi/product_logo_name.png",
    "java/res_chromium/drawable-xxhdpi/fre_product_logo.png",
    "java/res_chromium/drawable-xxhdpi/product_logo_name.png",
    "java/res_chromium/drawable-xxxhdpi/fre_product_logo.png",
    "java/res_chromium/drawable-xxxhdpi/product_logo_name.png",
  ]

  if (enable_arcore) {
    sources += [ "java/res-arcore/drawable/ic_ar_core_install.xml" ]
  }

  deps = [
    "//third_party/android_deps:material_design_java",
    "//ui/android:ui_java_resources",
  ]
}

# Overrides icon / name defined in chrome_app_java_resources.
android_resources("chrome_public_apk_resources") {
  resource_overlay = true
  sources = [
    "java/res_chromium/drawable-hdpi/fre_product_logo.png",
    "java/res_chromium/drawable-hdpi/product_logo_name.png",
    "java/res_chromium/drawable-mdpi/fre_product_logo.png",
    "java/res_chromium/drawable-mdpi/product_logo_name.png",
    "java/res_chromium/drawable-xhdpi/fre_product_logo.png",
    "java/res_chromium/drawable-xhdpi/product_logo_name.png",
    "java/res_chromium/drawable-xxhdpi/fre_product_logo.png",
    "java/res_chromium/drawable-xxhdpi/product_logo_name.png",
    "java/res_chromium/drawable-xxxhdpi/fre_product_logo.png",
    "java/res_chromium/drawable-xxxhdpi/product_logo_name.png",
  ]
}