diff options
author | Jeff Brown <jeffbrown@google.com> | 2010-08-23 12:01:02 -0700 |
---|---|---|
committer | Jeff Brown <jeffbrown@google.com> | 2010-09-30 11:52:48 -0700 |
commit | 20e987bfc35d0ae6cb6344ead65ed44ee7cf8750 (patch) | |
tree | 7ae616a2c7a21a09950760babb0b980c40e4651a /core/jni/android/graphics/Matrix.h | |
parent | 4f4870f0bb7009e6d974b5d2c371924214684735 (diff) | |
download | frameworks_base-20e987bfc35d0ae6cb6344ead65ed44ee7cf8750.zip frameworks_base-20e987bfc35d0ae6cb6344ead65ed44ee7cf8750.tar.gz frameworks_base-20e987bfc35d0ae6cb6344ead65ed44ee7cf8750.tar.bz2 |
Add MotionEvent Matrix transformations.
Fixed issued in ViewGroup's transformation of MotionEvents to ensure
that the entire historical trace is transformed, not just the current
pointer.
Simplified the code in ViewGroup for splitting events across Views.
The new code also handles the case where some pointers are dispatched
to the ViewGroup in addition to its children whereas the previous
code would drop some pointers on the floor.
Change-Id: I56ac31903e1de8a9c376d9c935b7217b0c42d93e
Diffstat (limited to 'core/jni/android/graphics/Matrix.h')
-rw-r--r-- | core/jni/android/graphics/Matrix.h | 30 |
1 files changed, 30 insertions, 0 deletions
diff --git a/core/jni/android/graphics/Matrix.h b/core/jni/android/graphics/Matrix.h new file mode 100644 index 0000000..31edf88 --- /dev/null +++ b/core/jni/android/graphics/Matrix.h @@ -0,0 +1,30 @@ +/* + * Copyright (C) 2010 The Android Open Source Project + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#ifndef _ANDROID_GRAPHICS_MATRIX_H +#define _ANDROID_GRAPHICS_MATRIX_H + +#include "jni.h" +#include "SkMatrix.h" + +namespace android { + +/* Gets the underlying SkMatrix from a Matrix object. */ +extern SkMatrix* android_graphics_Matrix_getSkMatrix(JNIEnv* env, jobject matrixObj); + +} // namespace android + +#endif // _ANDROID_GRAPHICS_MATRIX_H |