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

Side by Side Diff: components/arc/wallpaper/arc_wallpaper_bridge.h

Issue 2264743002: cheets: implement cros side of WallpaperManagerService. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: cheets: implement cros side of WallpaperManagerService. 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
(Empty)
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
3 // found in the LICENSE file.
4
5 #ifndef COMPONENTS_ARC_WALLPAPER_ARC_WALLPAPER_BRIDGE_H_
6 #define COMPONENTS_ARC_WALLPAPER_ARC_WALLPAPER_BRIDGE_H_
7
8 #include <stdint.h>
9
10 #include "base/macros.h"
11 #include "base/threading/thread_checker.h"
12 #include "components/arc/arc_service.h"
13 #include "components/arc/common/wallpaper.mojom.h"
14 #include "components/arc/instance_holder.h"
15 #include "mojo/public/cpp/bindings/binding.h"
16
17 namespace arc {
18
19 class ArcBridgeService;
20 class SetWallpaperDelegate;
21
22 class ArcWallpaperBridge
23 : public ArcService,
24 public InstanceHolder<mojom::WallpaperInstance>::Observer,
25 public mojom::WallpaperHost {
26 public:
27 ArcWallpaperBridge(ArcBridgeService* bridge_service,
28 const std::shared_ptr<SetWallpaperDelegate>& delegate);
29 ~ArcWallpaperBridge() override;
30
31 // InstanceHolder<mojom::WallpaperInstance>::Observer overrides.
32 void OnInstanceReady() override;
33
34 // mojo::WallpaperHost overrides.
Shuhei Takahashi 2016/08/23 09:34:22 nit: mojo[m]::
Muyuan 2016/08/23 19:45:49 Done.
35 void SetWallpaper(mojo::Array<uint8_t> jpeg_data) override;
36 void GetWallpaper(
37 const base::Callback<void(mojo::Array<uint8_t>)>& callback) override;
38
39 private:
40 std::shared_ptr<SetWallpaperDelegate> wallpaper_delegate_;
41 mojo::Binding<mojom::WallpaperHost> binding_;
42 base::ThreadChecker thread_checker_;
43
44 DISALLOW_COPY_AND_ASSIGN(ArcWallpaperBridge);
45 };
46
47 } // namespace arc
48
49 #endif // COMPONENTS_ARC_WALLPAPER_ARC_WALLPAPER_BRIDGE_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698