| Index: mojo/services/view_manager/view_manager_connection_unittest.cc
|
| diff --git a/mojo/services/view_manager/view_manager_connection_unittest.cc b/mojo/services/view_manager/view_manager_connection_unittest.cc
|
| index 231c903c413c3aa28a933bcca1c6a0deb398743a..be242a78d8b78a8747ef8e971b529262b41f2f25 100644
|
| --- a/mojo/services/view_manager/view_manager_connection_unittest.cc
|
| +++ b/mojo/services/view_manager/view_manager_connection_unittest.cc
|
| @@ -60,7 +60,7 @@ uint32_t CreateViewId(uint16_t connection_id, uint16_t view_id) {
|
|
|
| // Creates a node with the specified id. Returns true on success. Blocks until
|
| // we get back result from server.
|
| -bool CreateNode(ViewManager* view_manager, uint16_t id) {
|
| +bool CreateNode(IViewManager* view_manager, uint16_t id) {
|
| bool result = false;
|
| view_manager->CreateNode(id, base::Bind(&BooleanCallback, &result));
|
| DoRunLoop();
|
| @@ -70,7 +70,7 @@ bool CreateNode(ViewManager* view_manager, uint16_t id) {
|
| // TODO(sky): make a macro for these functions, they are all the same.
|
|
|
| // Deletes a node, blocking until done.
|
| -bool DeleteNode(ViewManager* view_manager,
|
| +bool DeleteNode(IViewManager* view_manager,
|
| uint32_t node_id,
|
| int32_t change_id) {
|
| bool result = false;
|
| @@ -81,7 +81,7 @@ bool DeleteNode(ViewManager* view_manager,
|
| }
|
|
|
| // Adds a node, blocking until done.
|
| -bool AddNode(ViewManager* view_manager,
|
| +bool AddNode(IViewManager* view_manager,
|
| uint32_t parent,
|
| uint32_t child,
|
| int32_t change_id) {
|
| @@ -93,7 +93,7 @@ bool AddNode(ViewManager* view_manager,
|
| }
|
|
|
| // Removes a node, blocking until done.
|
| -bool RemoveNodeFromParent(ViewManager* view_manager,
|
| +bool RemoveNodeFromParent(IViewManager* view_manager,
|
| uint32_t node_id,
|
| int32_t change_id) {
|
| bool result = false;
|
| @@ -105,7 +105,7 @@ bool RemoveNodeFromParent(ViewManager* view_manager,
|
|
|
| // Creates a view with the specified id. Returns true on success. Blocks until
|
| // we get back result from server.
|
| -bool CreateView(ViewManager* view_manager, uint16_t id) {
|
| +bool CreateView(IViewManager* view_manager, uint16_t id) {
|
| bool result = false;
|
| view_manager->CreateView(id, base::Bind(&BooleanCallback, &result));
|
| DoRunLoop();
|
| @@ -114,7 +114,7 @@ bool CreateView(ViewManager* view_manager, uint16_t id) {
|
|
|
| // Sets a view on the specified node. Returns true on success. Blocks until we
|
| // get back result from server.
|
| -bool SetView(ViewManager* view_manager,
|
| +bool SetView(IViewManager* view_manager,
|
| uint32_t node_id,
|
| uint32_t view_id,
|
| int32_t change_id) {
|
| @@ -129,7 +129,7 @@ bool SetView(ViewManager* view_manager,
|
|
|
| typedef std::vector<std::string> Changes;
|
|
|
| -class ViewManagerClientImpl : public ViewManagerClient {
|
| +class ViewManagerClientImpl : public IViewManagerClient {
|
| public:
|
| ViewManagerClientImpl() : id_(0), quit_count_(0) {}
|
|
|
| @@ -144,7 +144,7 @@ class ViewManagerClientImpl : public ViewManagerClient {
|
| }
|
|
|
| private:
|
| - // ViewManagerClient overrides:
|
| + // IViewManagerClient overrides:
|
| virtual void OnConnectionEstablished(uint16_t connection_id) OVERRIDE {
|
| id_ = connection_id;
|
| current_run_loop->Quit();
|
| @@ -194,7 +194,7 @@ class ViewManagerConnectionTest : public testing::Test {
|
| ViewManagerConnectionTest() : service_factory_(&root_node_manager_) {}
|
|
|
| virtual void SetUp() OVERRIDE {
|
| - InterfacePipe<ViewManagerClient, ViewManager> pipe;
|
| + InterfacePipe<IViewManagerClient, IViewManager> pipe;
|
| view_manager_.reset(pipe.handle_to_peer.Pass(), &client_);
|
| connection_.Initialize(
|
| &service_factory_,
|
| @@ -207,7 +207,7 @@ class ViewManagerConnectionTest : public testing::Test {
|
| // Creates a second connection to the viewmanager.
|
| void EstablishSecondConnection() {
|
| connection2_.reset(new ViewManagerConnection);
|
| - InterfacePipe<ViewManagerClient, ViewManager> pipe;
|
| + InterfacePipe<IViewManagerClient, IViewManager> pipe;
|
| view_manager2_.reset(pipe.handle_to_peer.Pass(), &client2_);
|
| connection2_->Initialize(
|
| &service_factory_,
|
| @@ -227,10 +227,10 @@ class ViewManagerConnectionTest : public testing::Test {
|
| ServiceConnector<ViewManagerConnection, RootNodeManager> service_factory_;
|
| ViewManagerConnection connection_;
|
| ViewManagerClientImpl client_;
|
| - RemotePtr<ViewManager> view_manager_;
|
| + RemotePtr<IViewManager> view_manager_;
|
|
|
| ViewManagerClientImpl client2_;
|
| - RemotePtr<ViewManager> view_manager2_;
|
| + RemotePtr<IViewManager> view_manager2_;
|
| scoped_ptr<ViewManagerConnection> connection2_;
|
|
|
| DISALLOW_COPY_AND_ASSIGN(ViewManagerConnectionTest);
|
|
|