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

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

Issue 2189893004: Unify display ids between Display and PlatformDisplay. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Move id into PlatformDisplay and fix tests. Created 4 years, 4 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 227 matching lines...) Expand 10 before | Expand all | Expand 10 after
238 class TestPlatformDisplayFactory : public PlatformDisplayFactory { 238 class TestPlatformDisplayFactory : public PlatformDisplayFactory {
239 public: 239 public:
240 explicit TestPlatformDisplayFactory(int32_t* cursor_id_storage); 240 explicit TestPlatformDisplayFactory(int32_t* cursor_id_storage);
241 ~TestPlatformDisplayFactory(); 241 ~TestPlatformDisplayFactory();
242 242
243 // PlatformDisplayFactory: 243 // PlatformDisplayFactory:
244 PlatformDisplay* CreatePlatformDisplay() override; 244 PlatformDisplay* CreatePlatformDisplay() override;
245 245
246 private: 246 private:
247 int32_t* cursor_id_storage_; 247 int32_t* cursor_id_storage_;
248 int64_t next_display_id = 1;
msw 2016/07/28 19:01:02 nit: trailing underscore
kylechar 2016/07/28 19:20:16 Done.
248 249
249 DISALLOW_COPY_AND_ASSIGN(TestPlatformDisplayFactory); 250 DISALLOW_COPY_AND_ASSIGN(TestPlatformDisplayFactory);
250 }; 251 };
251 252
252 // ----------------------------------------------------------------------------- 253 // -----------------------------------------------------------------------------
253 254
254 // A stub implementation of FrameGeneratorDelegate. 255 // A stub implementation of FrameGeneratorDelegate.
255 class TestFrameGeneratorDelegate : public FrameGeneratorDelegate { 256 class TestFrameGeneratorDelegate : public FrameGeneratorDelegate {
256 public: 257 public:
257 explicit TestFrameGeneratorDelegate(std::unique_ptr<ServerWindow> root); 258 explicit TestFrameGeneratorDelegate(std::unique_ptr<ServerWindow> root);
(...skipping 313 matching lines...) Expand 10 before | Expand all | Expand 10 after
571 ServerWindow* NewWindowInTree(WindowTree* tree, ClientWindowId* client_id); 572 ServerWindow* NewWindowInTree(WindowTree* tree, ClientWindowId* client_id);
572 ServerWindow* NewWindowInTreeWithParent(WindowTree* tree, 573 ServerWindow* NewWindowInTreeWithParent(WindowTree* tree,
573 ServerWindow* parent, 574 ServerWindow* parent,
574 ClientWindowId* client_id); 575 ClientWindowId* client_id);
575 576
576 } // namespace test 577 } // namespace test
577 } // namespace ws 578 } // namespace ws
578 } // namespace ui 579 } // namespace ui
579 580
580 #endif // SERVICES_UI_WS_TEST_UTILS_H_ 581 #endif // SERVICES_UI_WS_TEST_UTILS_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698