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

Side by Side Diff: chrome/browser/android/compositor/scene_layer/scene_layer.h

Issue 852433002: [Android] Upstream scene layers (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebased Created 5 years, 11 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 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 CHROME_BROWSER_ANDROID_COMPOSITOR_SCENE_LAYER_SCENE_LAYER_H_
6 #define CHROME_BROWSER_ANDROID_COMPOSITOR_SCENE_LAYER_SCENE_LAYER_H_
7
8 #include <jni.h>
9
10 #include "base/android/jni_weak_ref.h"
11 #include "base/android/scoped_java_ref.h"
12 #include "base/basictypes.h"
13 #include "base/memory/ref_counted.h"
14 #include "third_party/skia/include/core/SkColor.h"
15
16 namespace cc {
17 class Layer;
18 }
19
20 namespace chrome {
21 namespace android {
22
23 class SceneLayer {
24 public:
25 static SceneLayer* FromJavaObject(JNIEnv* env, jobject jobj);
26
27 SceneLayer(JNIEnv* env, jobject jobj);
28 SceneLayer(JNIEnv* env, jobject jobj, scoped_refptr<cc::Layer> layer);
29 virtual ~SceneLayer();
30
31 // Notifies that this scene layer is about to be detached from its parent.
32 virtual void OnDetach();
33
34 virtual void Destroy(JNIEnv* env, jobject jobj);
35
Jaekyun Seok (inactive) 2015/01/13 08:21:22 Don't we need to write comments for public members
Changwan Ryu 2015/01/13 10:18:00 Done.
36 scoped_refptr<cc::Layer> layer() { return layer_; }
37
38 virtual bool ShouldShowBackground();
39 virtual SkColor GetBackgroundColor();
40
41 protected:
42 JavaObjectWeakGlobalRef weak_java_scene_layer_;
43 scoped_refptr<cc::Layer> layer_;
44
45 private:
46 DISALLOW_COPY_AND_ASSIGN(SceneLayer);
47 };
48
49 bool RegisterSceneLayer(JNIEnv* env);
50
51 } // namespace android
52 } // namespace chrome
53
54 #endif // CHROME_BROWSER_ANDROID_COMPOSITOR_SCENE_LAYER_SCENE_LAYER_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698