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

Side by Side Diff: sky/viewer/services/inspector_impl.h

Issue 710043004: Make it possible to have multiple InspectorBackends (Closed) Base URL: git@github.com:domokit/mojo.git@master
Patch Set: Split out ServerImpl, somehow breaks JS connections... Created 6 years, 1 month 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 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 SKY_VIEWER_SERVICES_INSPECTOR_IMPL_H_ 5 #ifndef SKY_VIEWER_SERVICES_INSPECTOR_IMPL_H_
6 #define SKY_VIEWER_SERVICES_INSPECTOR_IMPL_H_ 6 #define SKY_VIEWER_SERVICES_INSPECTOR_IMPL_H_
7 7
8 #include "base/basictypes.h" 8 #include "base/basictypes.h"
9 #include "base/memory/weak_ptr.h" 9 #include "base/memory/weak_ptr.h"
10 #include "mojo/public/cpp/application/interface_factory_impl.h" 10 #include "mojo/public/cpp/application/interface_factory_impl.h"
11 #include "sky/viewer/services/inspector.mojom.h" 11 #include "sky/viewer/services/inspector.mojom.h"
12 #include "sky/services/inspector/inspector.mojom.h"
12 13
13 namespace sky { 14 namespace sky {
14 class DocumentView; 15 class DocumentView;
15 16
16 class InspectorServiceImpl : public mojo::InterfaceImpl<InspectorService> { 17 class InspectorServiceImpl : public mojo::InterfaceImpl<InspectorService> {
17 public: 18 public:
18 explicit InspectorServiceImpl(DocumentView*); 19 explicit InspectorServiceImpl(DocumentView*);
19 virtual ~InspectorServiceImpl(); 20 virtual ~InspectorServiceImpl();
20 21
21 private: 22 private:
22 // Overridden from InspectorService: 23 // Overridden from InspectorService:
23 void Inject() override; 24 void Inject() override;
24 25
25 base::WeakPtr<DocumentView> view_; 26 base::WeakPtr<DocumentView> view_;
26 27
27 DISALLOW_COPY_AND_ASSIGN(InspectorServiceImpl); 28 DISALLOW_COPY_AND_ASSIGN(InspectorServiceImpl);
28 }; 29 };
29 30
30 typedef mojo::InterfaceFactoryImplWithContext< 31 typedef mojo::InterfaceFactoryImplWithContext<
31 InspectorServiceImpl, DocumentView> InspectorServiceFactory; 32 InspectorServiceImpl, DocumentView> InspectorServiceFactory;
32 33
33 } // namespace sky 34 } // namespace sky
34 35
35 #endif // SKY_VIEWER_SERVICES_INSPECTOR_IMPL_H_ 36 #endif // SKY_VIEWER_SERVICES_INSPECTOR_IMPL_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698