Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(307)

Side by Side Diff: services/ui/ws/test_utils.h

Issue 2916823002: Move Mus into chrome's process when running with --mus.
Patch Set: Undo Screen TLS change, don't use Screen::GetScreen() in Mus. Created 3 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 // Copyright 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef SERVICES_UI_WS_TEST_UTILS_H_ 5 #ifndef SERVICES_UI_WS_TEST_UTILS_H_
6 #define SERVICES_UI_WS_TEST_UTILS_H_ 6 #define SERVICES_UI_WS_TEST_UTILS_H_
7 7
8 #include <stdint.h> 8 #include <stdint.h>
9 9
10 #include <memory> 10 #include <memory>
(...skipping 589 matching lines...) Expand 10 before | Expand all | Expand 10 after
600 void OnNoMoreDisplays() override; 600 void OnNoMoreDisplays() override;
601 std::unique_ptr<WindowTreeBinding> CreateWindowTreeBinding( 601 std::unique_ptr<WindowTreeBinding> CreateWindowTreeBinding(
602 BindingType type, 602 BindingType type,
603 ws::WindowServer* window_server, 603 ws::WindowServer* window_server,
604 ws::WindowTree* tree, 604 ws::WindowTree* tree,
605 mojom::WindowTreeRequest* tree_request, 605 mojom::WindowTreeRequest* tree_request,
606 mojom::WindowTreeClientPtr* client) override; 606 mojom::WindowTreeClientPtr* client) override;
607 bool IsTestConfig() const override; 607 bool IsTestConfig() const override;
608 void OnWillCreateTreeForWindowManager( 608 void OnWillCreateTreeForWindowManager(
609 bool automatically_create_display_roots) override; 609 bool automatically_create_display_roots) override;
610 scoped_refptr<base::SingleThreadTaskRunner>& GetResourceRunner() override;
611 base::WeakPtr<ui::ImageCursors> GetImageCursorsWeakPtr() override;
610 612
611 private: 613 private:
612 WindowServer* window_server_ = nullptr; 614 WindowServer* window_server_ = nullptr;
613 bool got_on_no_more_displays_ = false; 615 bool got_on_no_more_displays_ = false;
614 // All TestWindowTreeBinding objects created via CreateWindowTreeBinding. 616 // All TestWindowTreeBinding objects created via CreateWindowTreeBinding.
615 // These are owned by the corresponding WindowTree. 617 // These are owned by the corresponding WindowTree.
616 std::vector<TestWindowTreeBinding*> bindings_; 618 std::vector<TestWindowTreeBinding*> bindings_;
619 scoped_refptr<base::SingleThreadTaskRunner> resource_runner_ = nullptr;
620 std::unique_ptr<ui::ImageCursors> image_cursors_;
617 621
618 DISALLOW_COPY_AND_ASSIGN(TestWindowServerDelegate); 622 DISALLOW_COPY_AND_ASSIGN(TestWindowServerDelegate);
619 }; 623 };
620 624
621 // ----------------------------------------------------------------------------- 625 // -----------------------------------------------------------------------------
622 626
623 // Helper class which creates and sets up the necessary objects for tests that 627 // Helper class which creates and sets up the necessary objects for tests that
624 // use the WindowServer. 628 // use the WindowServer.
625 class WindowServerTestHelper { 629 class WindowServerTestHelper {
626 public: 630 public:
(...skipping 132 matching lines...) Expand 10 before | Expand all | Expand 10 after
759 ClientWindowId* client_id = nullptr); 763 ClientWindowId* client_id = nullptr);
760 ServerWindow* NewWindowInTreeWithParent(WindowTree* tree, 764 ServerWindow* NewWindowInTreeWithParent(WindowTree* tree,
761 ServerWindow* parent, 765 ServerWindow* parent,
762 ClientWindowId* client_id = nullptr); 766 ClientWindowId* client_id = nullptr);
763 767
764 } // namespace test 768 } // namespace test
765 } // namespace ws 769 } // namespace ws
766 } // namespace ui 770 } // namespace ui
767 771
768 #endif // SERVICES_UI_WS_TEST_UTILS_H_ 772 #endif // SERVICES_UI_WS_TEST_UTILS_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698