am d82cc1de: Merge "Fixup JNI" into ics-mr0

* commit 'd82cc1de848a678fa4bcaefdbc763307f3df4a75':
  Fixup JNI
This commit is contained in:
John Reck
2011-10-14 10:12:14 -07:00
committed by Android Git Automerger

View File

@@ -4517,7 +4517,7 @@ public class WebView extends AbsoluteLayout
boolean UIAnimationsRunning = false; boolean UIAnimationsRunning = false;
// Currently for each draw we compute the animation values; // Currently for each draw we compute the animation values;
// We may in the future decide to do that independently. // We may in the future decide to do that independently.
if (mNativeClass != 0 && nativeEvaluateLayersAnimations()) { if (mNativeClass != 0 && nativeEvaluateLayersAnimations(mNativeClass)) {
UIAnimationsRunning = true; UIAnimationsRunning = true;
// If we have unfinished (or unstarted) animations, // If we have unfinished (or unstarted) animations,
// we ask for a repaint. We only need to do this in software // we ask for a repaint. We only need to do this in software
@@ -4533,9 +4533,9 @@ public class WebView extends AbsoluteLayout
extras = DRAW_EXTRAS_FIND; extras = DRAW_EXTRAS_FIND;
} else if (mSelectingText && !USE_JAVA_TEXT_SELECTION) { } else if (mSelectingText && !USE_JAVA_TEXT_SELECTION) {
extras = DRAW_EXTRAS_SELECTION; extras = DRAW_EXTRAS_SELECTION;
nativeSetSelectionPointer(mDrawSelectionPointer, nativeSetSelectionPointer(mNativeClass,
mZoomManager.getInvScale(), mDrawSelectionPointer,
mSelectX, mSelectY - getTitleHeight()); mZoomManager.getInvScale(), mSelectX, mSelectY - getTitleHeight());
} else if (drawCursorRing) { } else if (drawCursorRing) {
extras = DRAW_EXTRAS_CURSOR_RING; extras = DRAW_EXTRAS_CURSOR_RING;
} }
@@ -4549,8 +4549,8 @@ public class WebView extends AbsoluteLayout
} }
if (canvas.isHardwareAccelerated()) { if (canvas.isHardwareAccelerated()) {
int functor = nativeGetDrawGLFunction(mGLViewportEmpty ? null : mGLRectViewport, int functor = nativeGetDrawGLFunction(mNativeClass,
mGLViewportEmpty ? null : mViewRectViewport, getScale(), extras); mGLViewportEmpty ? null : mGLRectViewport, mGLViewportEmpty ? null : mViewRectViewport, getScale(), extras);
((HardwareCanvas) canvas).callDrawGLFunction(functor); ((HardwareCanvas) canvas).callDrawGLFunction(functor);
if (mHardwareAccelSkia != getSettings().getHardwareAccelSkiaEnabled()) { if (mHardwareAccelSkia != getSettings().getHardwareAccelSkiaEnabled()) {
@@ -9433,9 +9433,9 @@ public class WebView extends AbsoluteLayout
// We never want to change button state if we are hardware accelerated, // We never want to change button state if we are hardware accelerated,
// but we DO want to invalidate as necessary so that the GL ring // but we DO want to invalidate as necessary so that the GL ring
// can be drawn // can be drawn
nativeRecordButtons(false, false, inval); nativeRecordButtons(mNativeClass, false, false, inval);
} else { } else {
nativeRecordButtons(focus, pressed, inval); nativeRecordButtons(mNativeClass, focus, pressed, inval);
} }
} }
@@ -9470,9 +9470,9 @@ public class WebView extends AbsoluteLayout
private native int nativeDraw(Canvas canvas, int color, int extra, private native int nativeDraw(Canvas canvas, int color, int extra,
boolean splitIfNeeded); boolean splitIfNeeded);
private native void nativeDumpDisplayTree(String urlOrNull); private native void nativeDumpDisplayTree(String urlOrNull);
private native boolean nativeEvaluateLayersAnimations(); private native boolean nativeEvaluateLayersAnimations(int nativeInstance);
private native int nativeGetDrawGLFunction(Rect rect, Rect viewRect, private native int nativeGetDrawGLFunction(int nativeInstance, Rect rect,
float scale, int extras); Rect viewRect, float scale, int extras);
private native void nativeUpdateDrawGLFunction(Rect rect, Rect viewRect); private native void nativeUpdateDrawGLFunction(Rect rect, Rect viewRect);
private native void nativeExtendSelection(int x, int y); private native void nativeExtendSelection(int x, int y);
private native int nativeFindAll(String findLower, String findUpper, private native int nativeFindAll(String findLower, String findUpper,
@@ -9535,8 +9535,8 @@ public class WebView extends AbsoluteLayout
private native boolean nativePointInNavCache(int x, int y, int slop); private native boolean nativePointInNavCache(int x, int y, int slop);
// Like many other of our native methods, you must make sure that // Like many other of our native methods, you must make sure that
// mNativeClass is not null before calling this method. // mNativeClass is not null before calling this method.
private native void nativeRecordButtons(boolean focused, private native void nativeRecordButtons(int nativeInstance,
boolean pressed, boolean invalidate); boolean focused, boolean pressed, boolean invalidate);
private native void nativeResetSelection(); private native void nativeResetSelection();
private native Point nativeSelectableText(); private native Point nativeSelectableText();
private native void nativeSelectAll(); private native void nativeSelectAll();
@@ -9557,8 +9557,8 @@ public class WebView extends AbsoluteLayout
private native void nativeReplaceBaseContent(int content); private native void nativeReplaceBaseContent(int content);
private native void nativeCopyBaseContentToPicture(Picture pict); private native void nativeCopyBaseContentToPicture(Picture pict);
private native boolean nativeHasContent(); private native boolean nativeHasContent();
private native void nativeSetSelectionPointer(boolean set, private native void nativeSetSelectionPointer(int nativeInstance,
float scale, int x, int y); boolean set, float scale, int x, int y);
private native boolean nativeStartSelection(int x, int y); private native boolean nativeStartSelection(int x, int y);
private native void nativeStopGL(); private native void nativeStopGL();
private native Rect nativeSubtractLayers(Rect content); private native Rect nativeSubtractLayers(Rect content);