Move keyboard related internal class to separate package
Change-Id: Ic1459066b865cde5104b3734193f76c997959c68main
parent
0150be2a9b
commit
72934bd596
|
@ -16,7 +16,7 @@
|
|||
|
||||
package com.android.inputmethod.deprecated.languageswitcher;
|
||||
|
||||
import com.android.inputmethod.keyboard.KeyboardParser;
|
||||
import com.android.inputmethod.keyboard.internal.KeyboardParser;
|
||||
import com.android.inputmethod.latin.DictionaryFactory;
|
||||
import com.android.inputmethod.latin.R;
|
||||
import com.android.inputmethod.latin.Settings;
|
||||
|
|
|
@ -18,6 +18,8 @@ package com.android.inputmethod.keyboard;
|
|||
|
||||
import android.util.Log;
|
||||
|
||||
import com.android.inputmethod.keyboard.internal.Key;
|
||||
|
||||
import java.util.Arrays;
|
||||
import java.util.List;
|
||||
|
||||
|
|
|
@ -21,6 +21,9 @@ import android.content.res.Resources;
|
|||
import android.graphics.drawable.Drawable;
|
||||
import android.util.Log;
|
||||
|
||||
import com.android.inputmethod.keyboard.internal.Key;
|
||||
import com.android.inputmethod.keyboard.internal.KeyboardParser;
|
||||
import com.android.inputmethod.keyboard.internal.KeyboardShiftState;
|
||||
import com.android.inputmethod.latin.R;
|
||||
|
||||
import org.xmlpull.v1.XmlPullParserException;
|
||||
|
@ -448,7 +451,7 @@ public class Keyboard {
|
|||
}
|
||||
}
|
||||
|
||||
protected static void setDefaultBounds(Drawable drawable) {
|
||||
public static void setDefaultBounds(Drawable drawable) {
|
||||
if (drawable != null)
|
||||
drawable.setBounds(0, 0, drawable.getIntrinsicWidth(),
|
||||
drawable.getIntrinsicHeight());
|
||||
|
|
|
@ -27,6 +27,9 @@ import android.view.View;
|
|||
import android.view.inputmethod.EditorInfo;
|
||||
|
||||
import com.android.inputmethod.compat.InputMethodManagerCompatWrapper;
|
||||
import com.android.inputmethod.keyboard.internal.Key;
|
||||
import com.android.inputmethod.keyboard.internal.ModifierKeyState;
|
||||
import com.android.inputmethod.keyboard.internal.ShiftKeyState;
|
||||
import com.android.inputmethod.latin.LatinIME;
|
||||
import com.android.inputmethod.latin.LatinImeLogger;
|
||||
import com.android.inputmethod.latin.R;
|
||||
|
|
|
@ -47,6 +47,10 @@ import android.widget.LinearLayout;
|
|||
import android.widget.PopupWindow;
|
||||
import android.widget.TextView;
|
||||
|
||||
import com.android.inputmethod.keyboard.internal.Key;
|
||||
import com.android.inputmethod.keyboard.internal.MiniKeyboardBuilder;
|
||||
import com.android.inputmethod.keyboard.internal.PointerTrackerQueue;
|
||||
import com.android.inputmethod.keyboard.internal.SwipeTracker;
|
||||
import com.android.inputmethod.latin.LatinImeLogger;
|
||||
import com.android.inputmethod.latin.R;
|
||||
|
||||
|
|
|
@ -33,6 +33,8 @@ import android.graphics.Rect;
|
|||
import android.graphics.drawable.BitmapDrawable;
|
||||
import android.graphics.drawable.Drawable;
|
||||
|
||||
import com.android.inputmethod.keyboard.internal.Key;
|
||||
import com.android.inputmethod.keyboard.internal.SlidingLocaleDrawable;
|
||||
import com.android.inputmethod.latin.R;
|
||||
import com.android.inputmethod.latin.SubtypeSwitcher;
|
||||
|
||||
|
|
|
@ -24,6 +24,7 @@ import android.util.Log;
|
|||
import android.view.MotionEvent;
|
||||
|
||||
import com.android.inputmethod.deprecated.VoiceProxy;
|
||||
import com.android.inputmethod.keyboard.internal.Key;
|
||||
import com.android.inputmethod.latin.LatinImeLogger;
|
||||
import com.android.inputmethod.latin.Utils;
|
||||
|
||||
|
|
|
@ -18,6 +18,8 @@ package com.android.inputmethod.keyboard;
|
|||
|
||||
import android.content.Context;
|
||||
|
||||
import com.android.inputmethod.keyboard.internal.Key;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
public class MiniKeyboard extends Keyboard {
|
||||
|
|
|
@ -16,6 +16,8 @@
|
|||
|
||||
package com.android.inputmethod.keyboard;
|
||||
|
||||
import com.android.inputmethod.keyboard.internal.Key;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
public class MiniKeyboardKeyDetector extends KeyDetector {
|
||||
|
|
|
@ -17,6 +17,9 @@
|
|||
package com.android.inputmethod.keyboard;
|
||||
|
||||
import com.android.inputmethod.keyboard.KeyboardView.UIHandler;
|
||||
import com.android.inputmethod.keyboard.internal.Key;
|
||||
import com.android.inputmethod.keyboard.internal.PointerTrackerKeyState;
|
||||
import com.android.inputmethod.keyboard.internal.PointerTrackerQueue;
|
||||
import com.android.inputmethod.latin.LatinImeLogger;
|
||||
import com.android.inputmethod.latin.R;
|
||||
import com.android.inputmethod.latin.SubtypeSwitcher;
|
||||
|
|
|
@ -25,6 +25,7 @@ import android.view.MotionEvent;
|
|||
import android.view.View;
|
||||
import android.widget.PopupWindow;
|
||||
|
||||
import com.android.inputmethod.keyboard.internal.Key;
|
||||
import com.android.inputmethod.latin.R;
|
||||
|
||||
/**
|
||||
|
|
|
@ -19,6 +19,8 @@ package com.android.inputmethod.keyboard;
|
|||
import android.view.MotionEvent;
|
||||
import android.widget.PopupWindow;
|
||||
|
||||
import com.android.inputmethod.keyboard.internal.Key;
|
||||
|
||||
public interface PopupPanel {
|
||||
/**
|
||||
* Show popup panel.
|
||||
|
|
|
@ -16,6 +16,7 @@
|
|||
|
||||
package com.android.inputmethod.keyboard;
|
||||
|
||||
import com.android.inputmethod.keyboard.internal.Key;
|
||||
import com.android.inputmethod.latin.Utils;
|
||||
|
||||
import java.util.Arrays;
|
||||
|
|
|
@ -14,10 +14,11 @@
|
|||
* the License.
|
||||
*/
|
||||
|
||||
package com.android.inputmethod.keyboard;
|
||||
package com.android.inputmethod.keyboard.internal;
|
||||
|
||||
import com.android.inputmethod.keyboard.KeyStyles.KeyStyle;
|
||||
import com.android.inputmethod.keyboard.KeyboardParser.ParseException;
|
||||
import com.android.inputmethod.keyboard.Keyboard;
|
||||
import com.android.inputmethod.keyboard.internal.KeyStyles.KeyStyle;
|
||||
import com.android.inputmethod.keyboard.internal.KeyboardParser.ParseException;
|
||||
import com.android.inputmethod.latin.R;
|
||||
|
||||
import android.content.res.Resources;
|
|
@ -14,9 +14,9 @@
|
|||
* the License.
|
||||
*/
|
||||
|
||||
package com.android.inputmethod.keyboard;
|
||||
package com.android.inputmethod.keyboard.internal;
|
||||
|
||||
import com.android.inputmethod.keyboard.KeyboardParser.ParseException;
|
||||
import com.android.inputmethod.keyboard.internal.KeyboardParser.ParseException;
|
||||
import com.android.inputmethod.latin.R;
|
||||
|
||||
import android.content.res.TypedArray;
|
|
@ -14,7 +14,7 @@
|
|||
* the License.
|
||||
*/
|
||||
|
||||
package com.android.inputmethod.keyboard;
|
||||
package com.android.inputmethod.keyboard.internal;
|
||||
|
||||
import android.content.Context;
|
||||
import android.content.res.Resources;
|
||||
|
@ -26,6 +26,8 @@ import android.util.Xml;
|
|||
import android.view.InflateException;
|
||||
|
||||
import com.android.inputmethod.compat.EditorInfoCompatUtils;
|
||||
import com.android.inputmethod.keyboard.Keyboard;
|
||||
import com.android.inputmethod.keyboard.KeyboardId;
|
||||
import com.android.inputmethod.latin.R;
|
||||
|
||||
import org.xmlpull.v1.XmlPullParser;
|
|
@ -14,10 +14,12 @@
|
|||
* the License.
|
||||
*/
|
||||
|
||||
package com.android.inputmethod.keyboard;
|
||||
package com.android.inputmethod.keyboard.internal;
|
||||
|
||||
import android.util.Log;
|
||||
|
||||
import com.android.inputmethod.keyboard.KeyboardSwitcher;
|
||||
|
||||
public class KeyboardShiftState {
|
||||
private static final String TAG = "KeyboardShiftState";
|
||||
private static final boolean DEBUG = KeyboardSwitcher.DEBUG_STATE;
|
|
@ -14,8 +14,11 @@
|
|||
* the License.
|
||||
*/
|
||||
|
||||
package com.android.inputmethod.keyboard;
|
||||
package com.android.inputmethod.keyboard.internal;
|
||||
|
||||
import com.android.inputmethod.keyboard.Keyboard;
|
||||
import com.android.inputmethod.keyboard.KeyboardView;
|
||||
import com.android.inputmethod.keyboard.MiniKeyboard;
|
||||
import com.android.inputmethod.latin.R;
|
||||
|
||||
import android.content.Context;
|
|
@ -14,10 +14,12 @@
|
|||
* the License.
|
||||
*/
|
||||
|
||||
package com.android.inputmethod.keyboard;
|
||||
package com.android.inputmethod.keyboard.internal;
|
||||
|
||||
import android.util.Log;
|
||||
|
||||
import com.android.inputmethod.keyboard.KeyboardSwitcher;
|
||||
|
||||
public class ModifierKeyState {
|
||||
protected static final String TAG = "ModifierKeyState";
|
||||
protected static final boolean DEBUG = KeyboardSwitcher.DEBUG_STATE;
|
|
@ -14,12 +14,15 @@
|
|||
* the License.
|
||||
*/
|
||||
|
||||
package com.android.inputmethod.keyboard;
|
||||
package com.android.inputmethod.keyboard.internal;
|
||||
|
||||
import com.android.inputmethod.keyboard.KeyDetector;
|
||||
import com.android.inputmethod.keyboard.PointerTracker;
|
||||
|
||||
/**
|
||||
* This class keeps track of a key index and a position where {@link PointerTracker} is.
|
||||
*/
|
||||
/* package */ class PointerTrackerKeyState {
|
||||
public class PointerTrackerKeyState {
|
||||
private final KeyDetector mKeyDetector;
|
||||
|
||||
// The position and time at which first down event occurred.
|
|
@ -14,7 +14,9 @@
|
|||
* the License.
|
||||
*/
|
||||
|
||||
package com.android.inputmethod.keyboard;
|
||||
package com.android.inputmethod.keyboard.internal;
|
||||
|
||||
import com.android.inputmethod.keyboard.PointerTracker;
|
||||
|
||||
import java.util.LinkedList;
|
||||
|
|
@ -14,8 +14,9 @@
|
|||
* the License.
|
||||
*/
|
||||
|
||||
package com.android.inputmethod.keyboard;
|
||||
package com.android.inputmethod.keyboard.internal;
|
||||
|
||||
import com.android.inputmethod.keyboard.Keyboard;
|
||||
import com.android.inputmethod.latin.R;
|
||||
|
||||
import android.content.res.Resources;
|
|
@ -14,8 +14,9 @@
|
|||
* the License.
|
||||
*/
|
||||
|
||||
package com.android.inputmethod.keyboard;
|
||||
package com.android.inputmethod.keyboard.internal;
|
||||
|
||||
import com.android.inputmethod.keyboard.Keyboard;
|
||||
import com.android.inputmethod.latin.R;
|
||||
|
||||
import android.content.res.Resources;
|
|
@ -14,7 +14,7 @@
|
|||
* the License.
|
||||
*/
|
||||
|
||||
package com.android.inputmethod.keyboard;
|
||||
package com.android.inputmethod.keyboard.internal;
|
||||
|
||||
import android.util.Log;
|
||||
|
|
@ -14,7 +14,7 @@
|
|||
* the License.
|
||||
*/
|
||||
|
||||
package com.android.inputmethod.keyboard;
|
||||
package com.android.inputmethod.keyboard.internal;
|
||||
|
||||
import android.content.Context;
|
||||
import android.content.res.TypedArray;
|
||||
|
@ -28,6 +28,8 @@ import android.graphics.drawable.Drawable;
|
|||
import android.text.TextPaint;
|
||||
import android.view.ViewConfiguration;
|
||||
|
||||
import com.android.inputmethod.keyboard.Keyboard;
|
||||
import com.android.inputmethod.keyboard.LatinKeyboard;
|
||||
import com.android.inputmethod.latin.R;
|
||||
import com.android.inputmethod.latin.SubtypeSwitcher;
|
||||
|
||||
|
@ -78,7 +80,7 @@ public class SlidingLocaleDrawable extends Drawable {
|
|||
mThreshold = ViewConfiguration.get(context).getScaledTouchSlop();
|
||||
}
|
||||
|
||||
void setDiff(int diff) {
|
||||
public void setDiff(int diff) {
|
||||
if (diff == Integer.MAX_VALUE) {
|
||||
mHitThreshold = false;
|
||||
mCurrentLanguage = null;
|
|
@ -14,7 +14,7 @@
|
|||
* the License.
|
||||
*/
|
||||
|
||||
package com.android.inputmethod.keyboard;
|
||||
package com.android.inputmethod.keyboard.internal;
|
||||
|
||||
import android.view.MotionEvent;
|
||||
|
|
@ -14,9 +14,9 @@
|
|||
* the License.
|
||||
*/
|
||||
|
||||
package com.android.inputmethod.keyboard;
|
||||
package com.android.inputmethod.keyboard.internal;
|
||||
|
||||
import com.android.inputmethod.keyboard.KeyStyles.EmptyKeyStyle;
|
||||
import com.android.inputmethod.keyboard.internal.KeyStyles.EmptyKeyStyle;
|
||||
|
||||
import android.test.AndroidTestCase;
|
||||
import android.text.TextUtils;
|
|
@ -14,9 +14,9 @@
|
|||
* the License.
|
||||
*/
|
||||
|
||||
package com.android.inputmethod.keyboard;
|
||||
package com.android.inputmethod.keyboard.internal;
|
||||
|
||||
import com.android.inputmethod.keyboard.MiniKeyboardBuilder.MiniKeyboardLayoutParams;
|
||||
import com.android.inputmethod.keyboard.internal.MiniKeyboardBuilder.MiniKeyboardLayoutParams;
|
||||
|
||||
import android.test.AndroidTestCase;
|
||||
|
|
@ -14,8 +14,10 @@
|
|||
* the License.
|
||||
*/
|
||||
|
||||
package com.android.inputmethod.keyboard;
|
||||
package com.android.inputmethod.keyboard.internal;
|
||||
|
||||
import com.android.inputmethod.keyboard.Keyboard;
|
||||
import com.android.inputmethod.keyboard.internal.PopupCharactersParser.PopupCharactersParserError;
|
||||
import com.android.inputmethod.latin.R;
|
||||
import android.content.res.Resources;
|
||||
import android.graphics.drawable.Drawable;
|
|
@ -16,7 +16,7 @@
|
|||
|
||||
package com.android.inputmethod.latin;
|
||||
|
||||
import com.android.inputmethod.keyboard.SwipeTracker.EventRingBuffer;
|
||||
import com.android.inputmethod.keyboard.internal.SwipeTracker.EventRingBuffer;
|
||||
|
||||
import android.test.AndroidTestCase;
|
||||
|
||||
|
|
|
@ -16,10 +16,10 @@
|
|||
|
||||
package com.android.inputmethod.latin;
|
||||
|
||||
import com.android.inputmethod.keyboard.Key;
|
||||
import com.android.inputmethod.keyboard.KeyDetector;
|
||||
import com.android.inputmethod.keyboard.KeyboardId;
|
||||
import com.android.inputmethod.keyboard.LatinKeyboard;
|
||||
import com.android.inputmethod.keyboard.internal.Key;
|
||||
|
||||
import android.content.Context;
|
||||
import android.text.TextUtils;
|
||||
|
|
Loading…
Reference in New Issue