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

assert(is_win || is_mac || is_linux || is_chromeos)

source_set("download") {
  sources = [
    "download_in_progress_dialog_view.cc",
    "download_in_progress_dialog_view.h",
  ]
  public_deps = [
    "//base",
    "//chrome/browser:browser_public_dependencies",
    "//components/download/public/common:public",
    "//components/offline_items_collection/core",
    "//content/public/browser",
    "//ui/base",
    "//ui/base/unowned_user_data",
    "//ui/events",
    "//ui/gfx",
    "//ui/gfx/animation",
    "//ui/gfx/geometry",
    "//ui/views",
  ]
  deps = [
    "//chrome/browser/profiles:profile",
    "//chrome/browser/safe_browsing",
    "//chrome/browser/safe_browsing:advanced_protection",
    "//chrome/browser/ui:layout_constants",
    "//chrome/browser/ui/hats",
    "//chrome/browser/ui/views:layout_provider",
    "//chrome/browser/ui/views/accessibility",
    "//components/constrained_window",
    "//components/safe_browsing/core/common:features",
    "//components/safe_browsing/core/common:safe_browsing_prefs",
    "//ui/strings:ui_strings_grit",
  ]

  if (!is_chromeos) {
    sources += [
      "download_cuj_event_emitter.cc",
      "download_cuj_event_emitter.h",

      # Download bubble UI is not used on ChromeOS.
      "bubble/download_bubble_contents_view.cc",
      "bubble/download_bubble_contents_view.h",
      "bubble/download_bubble_navigation_handler.h",
      "bubble/download_bubble_partial_view.cc",
      "bubble/download_bubble_partial_view.h",
      "bubble/download_bubble_password_prompt_view.cc",
      "bubble/download_bubble_password_prompt_view.h",
      "bubble/download_bubble_primary_view.cc",
      "bubble/download_bubble_primary_view.h",
      "bubble/download_bubble_row_list_view.cc",
      "bubble/download_bubble_row_list_view.h",
      "bubble/download_bubble_row_view.cc",
      "bubble/download_bubble_row_view.h",
      "bubble/download_bubble_security_view.cc",
      "bubble/download_bubble_security_view.h",
      "bubble/download_bubble_started_animation_views.cc",
      "bubble/download_bubble_started_animation_views.h",
      "bubble/download_dialog_view.cc",
      "bubble/download_dialog_view.h",
      "bubble/download_toolbar_ui_controller.cc",
      "bubble/download_toolbar_ui_controller.h",
      "download_started_animation_views.cc",
      "download_started_animation_views.h",
      "download_ui_context_menu_view.cc",
      "download_ui_context_menu_view.h",
    ]
    deps += [
      "//chrome/app:command_ids",
      "//chrome/browser:browser_process",
      "//chrome/browser:icon_manager",
      "//chrome/browser:primitives",
      "//chrome/browser/download/bubble",
      "//chrome/browser/picture_in_picture",
      "//chrome/browser/profiles:profile",
      "//chrome/browser/profiles:profile_util",
      "//chrome/browser/safe_browsing",
      "//chrome/browser/safe_browsing:advanced_protection",
      "//chrome/browser/themes",
      "//chrome/browser/ui:browser_actions",
      "//chrome/browser/ui:browser_element_identifiers",
      "//chrome/browser/ui:chrome_pages",
      "//chrome/browser/ui:ui_features",
      "//chrome/browser/ui/actions:actions_headers",
      "//chrome/browser/ui/browser_window",
      "//chrome/browser/ui/color:color_headers",
      "//chrome/browser/ui/download",
      "//chrome/browser/ui/hats",
      "//chrome/browser/ui/immersive:immersive_mode_controller",
      "//chrome/browser/ui/tabs:tab_strip",
      "//chrome/browser/ui/views/controls",
      "//chrome/browser/ui/views/toolbar",
      "//components/autofill/content/browser",
      "//components/constrained_window",
      "//components/feature_engagement/public:feature_constants",
      "//components/safe_browsing/core/common:features",
      "//components/safe_browsing/core/common:safe_browsing_policy_handler",
      "//components/safe_browsing/core/common:safe_browsing_prefs",
      "//ui/strings:ui_strings_grit",
    ]
    if (is_mac) {
      deps += [ "//chrome/browser/ui:fullscreen_util_mac" ]
    }
  }
}
