mirror of
https://github.com/moparisthebest/k-9
synced 2025-02-14 06:00:21 -05:00
Use non-deprecated constants
This commit is contained in:
parent
5311a2ef01
commit
1cbdd390f3
@ -17,6 +17,7 @@
|
|||||||
|
|
||||||
package com.fsck.k9.view;
|
package com.fsck.k9.view;
|
||||||
|
|
||||||
|
import android.annotation.SuppressLint;
|
||||||
import android.content.Context;
|
import android.content.Context;
|
||||||
import android.graphics.Rect;
|
import android.graphics.Rect;
|
||||||
import android.util.AttributeSet;
|
import android.util.AttributeSet;
|
||||||
@ -141,11 +142,11 @@ public class NonLockingScrollView extends ScrollView {
|
|||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
@SuppressWarnings("deprecation")
|
@SuppressLint("InlinedApi")
|
||||||
private static int getActionIndex(MotionEvent ev) {
|
private static int getActionIndex(MotionEvent ev) {
|
||||||
// Equivalent to MotionEvent.getActionIndex() which is in API 8+
|
// Equivalent to MotionEvent.getActionIndex() which is in API 8+
|
||||||
return ((ev.getAction() & MotionEvent.ACTION_POINTER_ID_MASK)
|
return ((ev.getAction() & MotionEvent.ACTION_POINTER_INDEX_MASK)
|
||||||
>> MotionEvent.ACTION_POINTER_ID_SHIFT);
|
>> MotionEvent.ACTION_POINTER_INDEX_SHIFT);
|
||||||
}
|
}
|
||||||
|
|
||||||
private static boolean canViewReceivePointerEvents(View child) {
|
private static boolean canViewReceivePointerEvents(View child) {
|
||||||
|
Loading…
Reference in New Issue
Block a user