[SyncFS] Build indexes from FileTracker entries on disk.
[chromium-blink-merge.git] / mojo / shell / view_manager_loader.h
blob85454e239152afe8de5528a556e2c3e83662f23b
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
3 // found in the LICENSE file.
5 #ifndef MOJO_SHELL_VIEW_MANAGER_LOADER_H_
6 #define MOJO_SHELL_VIEW_MANAGER_LOADER_H_
8 #include "base/memory/scoped_ptr.h"
9 #include "base/memory/scoped_vector.h"
10 #include "mojo/public/cpp/application/application_delegate.h"
11 #include "mojo/service_manager/service_loader.h"
13 namespace mojo {
15 class Application;
17 namespace shell {
19 // ServiceLoader responsible for creating connections to the ViewManager.
20 class ViewManagerLoader : public ServiceLoader, public ApplicationDelegate {
21 public:
22 ViewManagerLoader();
23 virtual ~ViewManagerLoader();
25 private:
26 // ServiceLoader overrides:
27 virtual void LoadService(
28 ServiceManager* manager,
29 const GURL& url,
30 ScopedMessagePipeHandle shell_handle) OVERRIDE;
31 virtual void OnServiceError(ServiceManager* manager,
32 const GURL& url) OVERRIDE;
34 // ApplicationDelegate overrides.
35 virtual bool ConfigureIncomingConnection(
36 mojo::ApplicationConnection* connection) MOJO_OVERRIDE;
38 ScopedVector<Application> apps_;
40 DISALLOW_COPY_AND_ASSIGN(ViewManagerLoader);
43 } // namespace shell
44 } // namespace mojo
46 #endif // MOJO_SHELL_VIEW_MANAGER_LOADER_H_