Chromium Code Reviews| OLD | NEW |
|---|---|
| (Empty) | |
| 1 // Copyright 2015 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 | |
| 5 #ifndef ASH_TEST_TRAY_CAST_TEST_API_H_ | |
| 6 #define ASH_TEST_TRAY_CAST_TEST_API_H_ | |
| 7 | |
| 8 #include <string> | |
| 9 | |
| 10 #include "ash/ash_export.h" | |
| 11 #include "ash/system/cast/tray_cast.h" | |
| 12 | |
| 13 namespace ash { | |
| 14 | |
| 15 class ASH_EXPORT TrayCastTestAPI { | |
| 16 public: | |
| 17 explicit TrayCastTestAPI(TrayCast* tray_cast); | |
| 18 ~TrayCastTestAPI(); | |
| 19 | |
| 20 bool IsTrayInitializedForTest() const; | |
|
oshima
2015/07/17 22:59:29
You can simply call it IsTrayInitialized() because
jdufault
2015/07/18 00:55:42
Done.
| |
| 21 bool IsTrayVisibleForTest() const; | |
| 22 | |
| 23 // IsTrayCastViewVisibleForTest returns true if the active casting view is | |
| 24 // visible, ie, the TrayCast believes we are casting. | |
| 25 // IsTraySelectViewVisibleForTest returns true when the view for selecting a | |
| 26 // receiver is active, ie, the TrayCast believes we are not casting. | |
| 27 bool IsTrayCastViewVisibleForTest() const; | |
| 28 bool IsTraySelectViewVisibleForTest() const; | |
| 29 | |
| 30 // Start a new cast to the given receiver. | |
| 31 void StartCastForTest(const std::string& receiver_id); | |
| 32 void StopCastForTest(); | |
| 33 | |
| 34 // Exposed callback to update the casting state. The test code needs to call | |
| 35 // this function manually, as there is no actual casting going on. In a real | |
| 36 // environment, this method is invoked by the casting system in Chrome. | |
| 37 void OnCastingSessionStartedOrStopped(bool is_casting); | |
| 38 | |
| 39 private: | |
| 40 TrayCast* tray_cast_; | |
| 41 }; | |
|
oshima
2015/07/17 22:59:28
DISALLOW_COPY_AND_ASSIGN
jdufault
2015/07/18 00:55:42
Done.
| |
| 42 | |
| 43 } // namespace ash | |
| 44 | |
| 45 #endif // ASH_TEST_TRAY_CAST_TEST_API_H_ | |
| OLD | NEW |