[CleanUp] Use base::STLSetDifference() in place of std::set_difference()
[chromium-blink-merge.git] / android_webview / native / aw_picture.h
blob2cbb5b793f4d982b5615cc0a83b2e8e6152dfb18
1 // Copyright 2013 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 ANDROID_WEBVIEW_NATIVE_AW_PICTURE_H_
6 #define ANDROID_WEBVIEW_NATIVE_AW_PICTURE_H_
8 #include <jni.h>
10 #include "base/android/jni_helper.h"
11 #include "base/android/scoped_java_ref.h"
12 #include "base/memory/scoped_ptr.h"
13 #include "content/public/browser/web_contents_observer.h"
14 #include "skia/ext/refptr.h"
16 class SkPicture;
18 namespace android_webview {
20 class AwPicture {
21 public:
22 AwPicture(skia::RefPtr<SkPicture> picture);
23 ~AwPicture();
25 // Methods called from Java.
26 void Destroy(JNIEnv* env, jobject obj);
27 jint GetWidth(JNIEnv* env, jobject obj);
28 jint GetHeight(JNIEnv* env, jobject obj);
29 void Draw(JNIEnv* env, jobject obj, jobject canvas,
30 jint left, jint top, jint right, jint bottom);
32 private:
33 skia::RefPtr<SkPicture> picture_;
35 DISALLOW_IMPLICIT_CONSTRUCTORS(AwPicture);
38 bool RegisterAwPicture(JNIEnv* env);
40 } // android_webview
42 #endif // ANDROID_WEBVIEW_NATIVE_AW_PICTURE_