You've already forked android_translation_layer
mirror of
https://gitlab.com/android_translation_layer/android_translation_layer.git
synced 2025-10-27 11:48:10 -07:00
api-impl: add stubs / simple stuff for OsmAnd
without native libs present, launches and renders white square in map view; with native libs present, segfaults in bundled skia
This commit is contained in:
@@ -257,6 +257,9 @@ public class Canvas {
|
||||
if (dst == null) {
|
||||
throw new NullPointerException();
|
||||
}
|
||||
if(src == null) {
|
||||
src = new Rect(0, 0, bitmap.getWidth(), bitmap.getHeight());
|
||||
}
|
||||
native_drawBitmap(skia_canvas, widget, bitmap.pixbuf, src.left, src.top, src.right, src.bottom,
|
||||
dst.left, dst.top, dst.right, dst.bottom,
|
||||
(paint != null) ? paint.skia_paint : 0);
|
||||
@@ -416,6 +419,16 @@ public class Canvas {
|
||||
return false;
|
||||
}
|
||||
|
||||
public int getWidth() {
|
||||
return 10; //FIXME
|
||||
}
|
||||
|
||||
public int getHeight() {
|
||||
return 10; //FIXME
|
||||
}
|
||||
|
||||
public void drawColor(int dummy) {}
|
||||
|
||||
private static native long native_canvas_from_bitmap(long pixbuf);
|
||||
|
||||
private static native void native_save(long skia_canvas, long widget);
|
||||
|
||||
Reference in New Issue
Block a user