OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 #include "android_webview/native/aw_contents.h" | 5 #include "android_webview/native/aw_contents.h" |
6 | 6 |
7 #include <android/bitmap.h> | 7 #include <android/bitmap.h> |
8 #include <sys/system_properties.h> | 8 #include <sys/system_properties.h> |
9 | 9 |
10 #include "android_webview/browser/aw_browser_context.h" | 10 #include "android_webview/browser/aw_browser_context.h" |
(...skipping 523 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
534 } | 534 } |
535 | 535 |
536 void AwContents::Destroy(JNIEnv* env, jobject obj) { | 536 void AwContents::Destroy(JNIEnv* env, jobject obj) { |
537 delete this; | 537 delete this; |
538 } | 538 } |
539 | 539 |
540 // static | 540 // static |
541 void SetAwDrawSWFunctionTable(JNIEnv* env, jclass, jint function_table) { | 541 void SetAwDrawSWFunctionTable(JNIEnv* env, jclass, jint function_table) { |
542 g_draw_sw_functions = | 542 g_draw_sw_functions = |
543 reinterpret_cast<AwDrawSWFunctionTable*>(function_table); | 543 reinterpret_cast<AwDrawSWFunctionTable*>(function_table); |
544 // TODO(leandrogracia): uncomment once the glue layer implements this method. | 544 g_is_skia_version_compatible = |
545 //g_is_skia_version_compatible = | 545 g_draw_sw_functions->is_skia_version_compatible(&SkGraphics::GetVersion); |
546 // g_draw_sw_functions->is_skia_version_compatible(&SkGraphics::GetVersion); | |
547 LOG_IF(WARNING, !g_is_skia_version_compatible) << | 546 LOG_IF(WARNING, !g_is_skia_version_compatible) << |
548 "Skia native versions are not compatible."; | 547 "Skia native versions are not compatible."; |
549 } | 548 } |
550 | 549 |
551 // static | 550 // static |
552 jint GetAwDrawGLFunction(JNIEnv* env, jclass) { | 551 jint GetAwDrawGLFunction(JNIEnv* env, jclass) { |
553 return reinterpret_cast<jint>(&DrawGLFunction); | 552 return reinterpret_cast<jint>(&DrawGLFunction); |
554 } | 553 } |
555 | 554 |
556 namespace { | 555 namespace { |
(...skipping 525 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1082 if (!picture) { | 1081 if (!picture) { |
1083 render_view_host_ext_->CapturePictureSync(); | 1082 render_view_host_ext_->CapturePictureSync(); |
1084 picture = RendererPictureMap::GetInstance()->GetRendererPicture( | 1083 picture = RendererPictureMap::GetInstance()->GetRendererPicture( |
1085 web_contents_->GetRoutingID()); | 1084 web_contents_->GetRoutingID()); |
1086 } | 1085 } |
1087 | 1086 |
1088 return picture; | 1087 return picture; |
1089 } | 1088 } |
1090 | 1089 |
1091 } // namespace android_webview | 1090 } // namespace android_webview |
OLD | NEW |