| # Copyright 2016 The Chromium Authors. All rights reserved. |
| # Use of this source code is governed by a BSD-style license that can be |
| # found in the LICENSE file. |
| |
| bundle_data("resources") { |
| sources = [ |
| "resources/tabswitcher_full_history.png", |
| "resources/tabswitcher_full_history@2x.png", |
| "resources/tabswitcher_full_history@3x.png", |
| "resources/tabswitcher_incognito.png", |
| "resources/tabswitcher_incognito@2x.png", |
| "resources/tabswitcher_incognito@3x.png", |
| "resources/tabswitcher_laptop.png", |
| "resources/tabswitcher_laptop@2x.png", |
| "resources/tabswitcher_laptop@3x.png", |
| "resources/tabswitcher_menu.png", |
| "resources/tabswitcher_menu@2x.png", |
| "resources/tabswitcher_menu@3x.png", |
| "resources/tabswitcher_new_tab.png", |
| "resources/tabswitcher_new_tab@2x.png", |
| "resources/tabswitcher_new_tab@3x.png", |
| "resources/tabswitcher_new_tab_fab.png", |
| "resources/tabswitcher_new_tab_fab@2x.png", |
| "resources/tabswitcher_new_tab_fab@3x.png", |
| "resources/tabswitcher_open_tabs.png", |
| "resources/tabswitcher_open_tabs@2x.png", |
| "resources/tabswitcher_open_tabs@3x.png", |
| "resources/tabswitcher_other_devices.png", |
| "resources/tabswitcher_other_devices@2x.png", |
| "resources/tabswitcher_other_devices@3x.png", |
| "resources/tabswitcher_overflow_arrow.png", |
| "resources/tabswitcher_overflow_arrow@2x.png", |
| "resources/tabswitcher_overflow_arrow@3x.png", |
| "resources/tabswitcher_phone.png", |
| "resources/tabswitcher_phone@2x.png", |
| "resources/tabswitcher_phone@3x.png", |
| "resources/tabswitcher_recently_closed.png", |
| "resources/tabswitcher_recently_closed@2x.png", |
| "resources/tabswitcher_recently_closed@3x.png", |
| "resources/tabswitcher_tab_switcher_button.png", |
| "resources/tabswitcher_tab_switcher_button@2x.png", |
| "resources/tabswitcher_tab_switcher_button@3x.png", |
| "resources/tabswitcher_tablet.png", |
| "resources/tabswitcher_tablet@2x.png", |
| "resources/tabswitcher_tablet@3x.png", |
| ] |
| outputs = [ |
| "{{bundle_resources_dir}}/{{source_file_part}}", |
| ] |
| } |
| |
| source_set("tab_switcher") { |
| sources = [ |
| "tab_model_snapshot.h", |
| "tab_model_snapshot.mm", |
| "tab_switcher.h", |
| "tab_switcher_button.h", |
| "tab_switcher_button.mm", |
| "tab_switcher_cache.h", |
| "tab_switcher_cache.mm", |
| "tab_switcher_controller.h", |
| "tab_switcher_controller.mm", |
| "tab_switcher_header_cell.h", |
| "tab_switcher_header_cell.mm", |
| "tab_switcher_header_view.h", |
| "tab_switcher_header_view.mm", |
| "tab_switcher_model.h", |
| "tab_switcher_model.mm", |
| "tab_switcher_model_private.h", |
| "tab_switcher_panel_cell.h", |
| "tab_switcher_panel_cell.mm", |
| "tab_switcher_panel_collection_view_layout.h", |
| "tab_switcher_panel_collection_view_layout.mm", |
| "tab_switcher_panel_controller.h", |
| "tab_switcher_panel_controller.mm", |
| "tab_switcher_panel_overlay_view.h", |
| "tab_switcher_panel_overlay_view.mm", |
| "tab_switcher_panel_view.h", |
| "tab_switcher_panel_view.mm", |
| "tab_switcher_session_cell_data.h", |
| "tab_switcher_session_cell_data.mm", |
| "tab_switcher_session_changes.h", |
| "tab_switcher_session_changes.mm", |
| "tab_switcher_tab_strip_placeholder_view.h", |
| "tab_switcher_tab_strip_placeholder_view.mm", |
| "tab_switcher_transition_context.h", |
| "tab_switcher_transition_context.mm", |
| "tab_switcher_view.h", |
| "tab_switcher_view.mm", |
| ] |
| deps = [ |
| ":resources", |
| ":utils", |
| "//base", |
| "//components/browser_sync", |
| "//components/sessions", |
| "//components/signin/core/browser", |
| "//components/sync", |
| "//components/sync_sessions", |
| "//ios/chrome/app/strings", |
| "//ios/chrome/app/theme", |
| "//ios/chrome/browser", |
| "//ios/chrome/browser/browser_state", |
| "//ios/chrome/browser/favicon", |
| "//ios/chrome/browser/metrics:metrics_internal", |
| "//ios/chrome/browser/sessions", |
| "//ios/chrome/browser/signin", |
| "//ios/chrome/browser/sync", |
| "//ios/chrome/browser/tabs", |
| "//ios/chrome/browser/ui", |
| "//ios/chrome/browser/ui/colors", |
| "//ios/chrome/browser/ui/commands", |
| "//ios/chrome/browser/ui/keyboard", |
| "//ios/chrome/browser/ui/material_components", |
| "//ios/chrome/browser/ui/ntp/recent_tabs/views", |
| "//ios/chrome/browser/ui/sync", |
| "//ios/chrome/browser/ui/tabs", |
| "//ios/chrome/browser/ui/toolbar", |
| "//ios/chrome/common:ios_app_bundle_id_prefix_header", |
| "//ios/public/provider/chrome/browser", |
| "//ios/third_party/material_components_ios", |
| "//ios/third_party/material_roboto_font_loader_ios", |
| "//ios/third_party/material_text_accessibility_ios", |
| "//ios/web", |
| "//ui/base", |
| "//ui/gfx", |
| "//url", |
| ] |
| public_deps = [ |
| "//ios/chrome/browser/ui/ntp/recent_tabs", |
| ] |
| allow_circular_includes_from = [ "//ios/chrome/browser/ui/tabs" ] |
| libs = [ |
| "QuartzCore.framework", |
| "UIKit.framework", |
| ] |
| } |
| |
| source_set("utils") { |
| sources = [ |
| "tab_switcher_utils.h", |
| "tab_switcher_utils.mm", |
| ] |
| deps = [ |
| "//base", |
| "//components/browser_sync", |
| "//components/sync", |
| "//components/sync_sessions", |
| "//ios/chrome/app/strings", |
| "//ios/chrome/app/theme", |
| "//ios/chrome/browser/browser_state", |
| "//ios/chrome/browser/favicon", |
| "//ios/chrome/browser/sync", |
| "//ios/chrome/browser/ui", |
| "//ui/base", |
| ] |
| } |
| |
| source_set("unit_tests") { |
| configs += [ "//build/config/compiler:enable_arc" ] |
| testonly = true |
| sources = [ |
| "tab_model_snapshot_unittest.mm", |
| "tab_switcher_model_unittest.mm", |
| "tab_switcher_utils_unittest.mm", |
| ] |
| deps = [ |
| ":tab_switcher", |
| ":utils", |
| "//base", |
| "//ios/chrome/browser/browser_state:test_support", |
| "//ios/chrome/browser/tabs", |
| "//ios/chrome/browser/ui/ntp/recent_tabs", |
| "//testing/gtest", |
| "//third_party/ocmock", |
| ] |
| } |
| |
| source_set("eg_tests") { |
| configs += [ "//build/config/compiler:enable_arc" ] |
| testonly = true |
| sources = [ |
| "tab_switcher_controller_egtest.mm", |
| ] |
| deps = [ |
| "//base", |
| "//base/test:test_support", |
| "//ios/chrome/app:app_internal", |
| "//ios/chrome/app/strings", |
| "//ios/chrome/browser", |
| "//ios/chrome/browser/ui", |
| "//ios/chrome/browser/ui/commands", |
| "//ios/chrome/browser/ui/tools_menu", |
| "//ios/chrome/test/app:test_support", |
| "//ios/chrome/test/earl_grey:test_support", |
| "//ios/third_party/earl_grey", |
| "//ui/base", |
| ] |
| libs = [ |
| "UIKit.framework", |
| "XCTest.framework", |
| ] |
| } |