recent_files_bubble.cc 1.1 KB

1234567891011121314151617181920212223242526272829303132
  1. // Copyright 2020 The Chromium Authors. All rights reserved.
  2. // Use of this source code is governed by a BSD-style license that can be
  3. // found in the LICENSE file.
  4. #include "ash/system/holding_space/recent_files_bubble.h"
  5. #include "ash/public/cpp/holding_space/holding_space_constants.h"
  6. #include "ash/system/holding_space/downloads_section.h"
  7. #include "ash/system/holding_space/screen_captures_section.h"
  8. namespace ash {
  9. RecentFilesBubble::RecentFilesBubble(HoldingSpaceViewDelegate* delegate)
  10. : HoldingSpaceTrayChildBubble(delegate) {
  11. SetID(kHoldingSpaceRecentFilesBubbleId);
  12. }
  13. RecentFilesBubble::~RecentFilesBubble() = default;
  14. const char* RecentFilesBubble::GetClassName() const {
  15. return "RecentFilesBubble";
  16. }
  17. std::vector<std::unique_ptr<HoldingSpaceItemViewsSection>>
  18. RecentFilesBubble::CreateSections() {
  19. std::vector<std::unique_ptr<HoldingSpaceItemViewsSection>> sections;
  20. sections.push_back(std::make_unique<ScreenCapturesSection>(delegate()));
  21. sections.push_back(std::make_unique<DownloadsSection>(delegate()));
  22. return sections;
  23. }
  24. } // namespace ash