Home
last modified time | relevance | path

Searched refs:Key (Results 1 – 25 of 83) sorted by relevance

1234

/packages/apps/Launcher2/src/com/android/launcher2/
DPagedViewIconCache.java34 public static class Key { class in PagedViewIconCache
43 public Key(ApplicationInfo info) { in Key() method in PagedViewIconCache.Key
47 public Key(ResolveInfo info) { in Key() method in PagedViewIconCache.Key
53 public Key(AppWidgetProviderInfo info) { in Key() method in PagedViewIconCache.Key
67 if (o instanceof Key) { in equals()
68 Key k = (Key) o; in equals()
79 private final HashMap<Key, Bitmap> mIconOutlineCache = new HashMap<Key, Bitmap>();
82 for (Key key : mIconOutlineCache.keySet()) { in clear()
87 private void retainAll(HashSet<Key> keysToKeep, Key.Type t) { in retainAll()
88 HashSet<Key> keysToRemove = new HashSet<Key>(mIconOutlineCache.keySet()); in retainAll()
[all …]
/packages/apps/MusicFX/src/com/android/musicfx/
DControlPanelEffect.java61 static enum Key { enum in ControlPanelEffect
167 final boolean isGlobalEnabled = prefs.getBoolean(Key.global_enabled.toString(), in initEffectsPreferences()
169 editor.putBoolean(Key.global_enabled.toString(), isGlobalEnabled); in initEffectsPreferences()
173 final boolean isVIEnabled = prefs.getBoolean(Key.virt_enabled.toString(), in initEffectsPreferences()
176 final int vIStrength = prefs.getInt(Key.virt_strength.toString(), in initEffectsPreferences()
179 editor.putBoolean(Key.virt_enabled.toString(), isVIEnabled); in initEffectsPreferences()
180 editor.putInt(Key.virt_strength.toString(), vIStrength); in initEffectsPreferences()
187 editor.putBoolean(Key.virt_strength_supported.toString(), in initEffectsPreferences()
199 final boolean isBBEnabled = prefs.getBoolean(Key.bb_enabled.toString(), in initEffectsPreferences()
201 final int bBStrength = prefs.getInt(Key.bb_strength.toString(), in initEffectsPreferences()
[all …]
DActivityMusic.java281 mAudioSession, ControlPanelEffect.Key.eq_num_presets); in onCreate()
285 mCallingPackageName, mAudioSession, ControlPanelEffect.Key.eq_preset_name, i); in onCreate()
305 mAudioSession, ControlPanelEffect.Key.global_enabled, isChecked); in onCreate()
342 mAudioSession, ControlPanelEffect.Key.virt_strength, progress); in onCreate()
350 mAudioSession, ControlPanelEffect.Key.virt_enabled, true); in onCreate()
360 mAudioSession, ControlPanelEffect.Key.virt_enabled, false); in onCreate()
371 mAudioSession, ControlPanelEffect.Key.virt_enabled, isChecked); in onCreate()
404 mAudioSession, ControlPanelEffect.Key.bb_strength, progress); in onCreate()
412 mAudioSession, ControlPanelEffect.Key.bb_enabled, true); in onCreate()
422 mAudioSession, ControlPanelEffect.Key.bb_enabled, false); in onCreate()
[all …]
/packages/inputmethods/LatinIME/tests/src/com/android/inputmethod/keyboard/layout/expected/
DActualKeyboardBuilder.java19 import com.android.inputmethod.keyboard.Key;
37 public final class ActualKeyboardBuilder extends AbstractKeyboardBuilder<Key> {
38 private static ArrayList<Key> filterOutSpacer(final List<Key> keys) { in filterOutSpacer()
39 final ArrayList<Key> filteredKeys = new ArrayList<>(); in filterOutSpacer()
40 for (final Key key : keys) { in filterOutSpacer()
55 public static Key[][] buildKeyboard(final List<Key> sortedKeys) { in buildKeyboard()
57 final ArrayList<Key> filteredSortedKeys = filterOutSpacer(sortedKeys); in buildKeyboard()
60 final ArrayList<ArrayList<Key>> rows = new ArrayList<>(); in buildKeyboard()
61 ArrayList<Key> elements = new ArrayList<>(); in buildKeyboard()
63 for (final Key key : filteredSortedKeys) { in buildKeyboard()
[all …]
/packages/inputmethods/LatinIME/java/src/com/android/inputmethod/keyboard/emoji/
DDynamicGridKeyboard.java23 import com.android.inputmethod.keyboard.Key;
50 private final ArrayDeque<Key> mPendingKeys = new ArrayDeque<>();
52 private List<Key> mCachedGridKeys;
57 final Key key0 = getTemplateKey(TEMPLATE_KEY_CODE_0); in DynamicGridKeyboard()
58 final Key key1 = getTemplateKey(TEMPLATE_KEY_CODE_1); in DynamicGridKeyboard()
67 private Key getTemplateKey(final int code) { in getTemplateKey()
68 for (final Key key : super.getSortedKeys()) { in getTemplateKey()
76 public void addPendingKey(final Key usedKey) { in addPendingKey()
91 public void addKeyFirst(final Key usedKey) { in addKeyFirst()
98 public void addKeyLast(final Key usedKey) { in addKeyLast()
[all …]
DEmojiPageKeyboardView.java28 import com.android.inputmethod.keyboard.Key;
45 public void onPressKey(Key key); in onPressKey()
46 public void onReleaseKey(Key key); in onReleaseKey()
51 public void onPressKey(final Key key) {}
53 public void onReleaseKey(final Key key) {}
122 final Key key = getKey(e); in onTouchEvent()
130 private Key mCurrentKey;
134 private Key getKey(final MotionEvent e) { in getKey()
141 void callListenerOnReleaseKey(final Key releasedKey, final boolean withKeyRegistering) { in callListenerOnReleaseKey()
149 void callListenerOnPressKey(final Key pressedKey) { in callListenerOnPressKey()
[all …]
DEmojiCategory.java29 import com.android.inputmethod.keyboard.Key;
381 final Key[][] sortedKeys = sortKeysIntoPages( in getKeyboard()
387 for (final Key emojiKey : sortedKeys[pageId]) { in getKeyboard()
408 private static Comparator<Key> EMOJI_KEY_COMPARATOR = new Comparator<Key>() {
410 public int compare(final Key lhs, final Key rhs) {
430 private static Key[][] sortKeysIntoPages(final List<Key> inKeys, final int maxPageCount) { in sortKeysIntoPages()
431 final ArrayList<Key> keys = new ArrayList<>(inKeys); in sortKeysIntoPages()
434 final Key[][] retval = new Key[pageCount][maxPageCount]; in sortKeysIntoPages()
/packages/inputmethods/LatinIME/java/src/com/android/inputmethod/keyboard/internal/
DKeyboardParams.java21 import com.android.inputmethod.keyboard.Key;
68 public final SortedSet<Key> mSortedKeys = new TreeSet<>(ROW_COLUMN_COMPARATOR);
70 public final ArrayList<Key> mShiftKeys = new ArrayList<>();
72 public final ArrayList<Key> mAltCodeKeysWhileTyping = new ArrayList<>();
94 private static final Comparator<Key> ROW_COLUMN_COMPARATOR = new Comparator<Key>() {
96 public int compare(final Key lhs, final Key rhs) {
119 public void onAddKey(@Nonnull final Key newKey) { in onAddKey()
120 final Key key = mUniqueKeysCache.getUniqueKey(newKey); in onAddKey()
145 for (final Key key : mSortedKeys) { in removeRedundantMoreKeys()
148 final ArrayList<Key> allKeys = new ArrayList<>(mSortedKeys); in removeRedundantMoreKeys()
[all …]
DUniqueKeysCache.java19 import com.android.inputmethod.keyboard.Key;
28 public abstract @Nonnull Key getUniqueKey(@Nonnull Key key); in getUniqueKey()
39 public Key getUniqueKey(Key key) { return key; }
48 private final HashMap<Key, Key> mCache;
67 public Key getUniqueKey(final Key key) { in getUniqueKey()
71 final Key existingKey = mCache.get(key); in getUniqueKey()
DKeyPreviewChoreographer.java25 import com.android.inputmethod.keyboard.Key;
43 private final HashMap<Key,KeyPreviewView> mShowingKeyPreviewViews = new HashMap<>();
51 public KeyPreviewView getKeyPreviewView(final Key key, final ViewGroup placerView) { in getKeyPreviewView()
67 public boolean isShowingKeyPreview(final Key key) { in isShowingKeyPreview()
71 public void dismissKeyPreview(final Key key, final boolean withAnimation) { in dismissKeyPreview()
97 public void placeAndShowKeyPreview(final Key key, final KeyboardIconsSet iconsSet, in placeAndShowKeyPreview()
106 private void placeKeyPreview(final Key key, final KeyPreviewView keyPreviewView, in placeKeyPreview()
144 void showKeyPreview(final Key key, final KeyPreviewView keyPreviewView, in showKeyPreview()
161 public Animator createShowUpAnimator(final Key key, final KeyPreviewView keyPreviewView) { in createShowUpAnimator()
172 private Animator createDismissAnimator(final Key key, final KeyPreviewView keyPreviewView) { in createDismissAnimator()
DDrawingProxy.java19 import com.android.inputmethod.keyboard.Key;
32 public void onKeyPressed(@Nonnull Key key, boolean withPreview); in onKeyPressed()
39 public void onKeyReleased(@Nonnull Key key, boolean withAnimation); in onKeyReleased()
49 public MoreKeysPanel showMoreKeysKeyboard(@Nonnull Key key, @Nonnull PointerTracker tracker); in showMoreKeysKeyboard()
DTimerHandler.java23 import com.android.inputmethod.keyboard.Key;
77 drawingProxy.onKeyReleased((Key) msg.obj, false /* withAnimation */); in handleMessage()
88 final Key key = tracker.getKey(); in startKeyRepeatTimerOf()
111 final Key key = tracker.getKey(); in startLongPressTimerOf()
139 public void startTypingStateTimer(@Nonnull final Key typedKey) { in startTypingStateTimer()
220 public void postDismissKeyPreview(@Nonnull final Key key, final long delay) { in postDismissKeyPreview()
/packages/inputmethods/LatinIME/java/src/com/android/inputmethod/accessibility/
DKeyboardAccessibilityDelegate.java30 import com.android.inputmethod.keyboard.Key;
54 private Key mLastHoverKey;
88 protected final void setLastHoverKey(final Key key) { in setLastHoverKey()
92 protected final Key getLastHoverKey() { in getLastHoverKey()
160 protected final Key getHoverKeyOf(final MotionEvent event) { in getHoverKeyOf()
197 final Key key = getHoverKeyOf(event); in onHoverEnter()
213 final Key lastKey = getLastHoverKey(); in onHoverMove()
214 final Key key = getHoverKeyOf(event); in onHoverMove()
235 final Key lastKey = getLastHoverKey(); in onHoverExit()
242 final Key key = getHoverKeyOf(event); in onHoverExit()
[all …]
DKeyboardAccessibilityNodeProvider.java31 import com.android.inputmethod.keyboard.Key;
102 private Key getKeyOf(final int virtualViewId) { in getKeyOf()
106 final List<Key> sortedKeys = mKeyboard.getSortedKeys(); in getKeyOf()
114 private int getVirtualViewIdOf(final Key key) { in getVirtualViewIdOf()
118 final List<Key> sortedKeys = mKeyboard.getSortedKeys(); in getVirtualViewIdOf()
138 public AccessibilityEvent createAccessibilityEvent(final Key key, final int eventType) { in createAccessibilityEvent()
151 public void onHoverEnterTo(final Key key) { in onHoverEnterTo()
165 public void onHoverExitFrom(final Key key) { in onHoverExitFrom()
208 final List<Key> sortedKeys = mKeyboard.getSortedKeys(); in createAccessibilityNodeInfo()
211 final Key key = sortedKeys.get(index); in createAccessibilityNodeInfo()
[all …]
DAccessibilityLongPressTimer.java23 import com.android.inputmethod.keyboard.Key;
29 public void performLongClickOn(Key key); in performLongClickOn()
50 mCallback.performLongClickOn((Key)msg.obj); in handleMessage()
58 public void startLongPress(final Key key) { in startLongPress()
/packages/inputmethods/LatinIME/java/src/com/android/inputmethod/keyboard/
DPointerTracker.java122 private Key mCurrentKey = null;
244 private boolean callListenerOnPressAndCheckKeyboardLayoutChange(final Key key, in callListenerOnPressAndCheckKeyboardLayoutChange()
276 private void callListenerOnCodeInput(final Key key, final int primaryCode, final int x, in callListenerOnCodeInput()
309 private void callListenerOnRelease(final Key key, final int primaryCode, in callListenerOnRelease()
372 public Key getKey() { in getKey()
381 public Key getKeyOn(final int x, final int y) { in getKeyOn()
385 private void setReleasedKeyGraphics(@Nullable final Key key, final boolean withAnimation) { in setReleasedKeyGraphics()
393 for (final Key shiftKey : mKeyboard.mShiftKeys) { in setReleasedKeyGraphics()
402 final Key altKey = mKeyboard.getKey(altCode); in setReleasedKeyGraphics()
406 for (final Key k : mKeyboard.mAltCodeKeysWhileTyping) { in setReleasedKeyGraphics()
[all …]
DProximityInfo.java42 private static final List<Key> EMPTY_KEY_LIST = Collections.emptyList();
56 private final List<Key> mSortedKeys;
58 private final List<Key>[] mGridNeighbors;
63 @Nonnull final List<Key> sortedKeys, in ProximityInfo()
98 static boolean needsProximityInfo(final Key key) { in needsProximityInfo()
103 private static int getProximityInfoKeysCount(final List<Key> keys) { in getProximityInfoKeysCount()
105 for (final Key key : keys) { in getProximityInfoKeysCount()
115 final List<Key>[] gridNeighborKeys = mGridNeighbors; in createNativeProximityInfo()
119 final List<Key> neighborKeys = gridNeighborKeys[i]; in createNativeProximityInfo()
123 final Key neighborKey = neighborKeys.get(j); in createNativeProximityInfo()
[all …]
DKeyboard.java86 private final List<Key> mSortedKeys;
88 public final List<Key> mShiftKeys;
90 public final List<Key> mAltCodeKeysWhileTyping;
94 private final SparseArray<Key> mKeyCache = new SparseArray<>();
185 public List<Key> getSortedKeys() { in getSortedKeys()
190 public Key getKey(final int code) { in getKey()
200 for (final Key key : getSortedKeys()) { in getKey()
211 public boolean hasKey(@Nonnull final Key aKey) { in hasKey()
216 for (final Key key : getSortedKeys()) { in hasKey()
238 public List<Key> getNearestKeys(final int x, final int y) { in getNearestKeys()
[all …]
DKeyboardLayout.java45 public KeyboardLayout(ArrayList<Key> layoutKeys, int mostCommonKeyWidth, in KeyboardLayout()
59 Key key = layoutKeys.get(i); in KeyboardLayout()
109 public static KeyboardLayout newKeyboardLayout(@Nonnull final List<Key> sortedKeys, in newKeyboardLayout()
112 final ArrayList<Key> layoutKeys = new ArrayList<Key>(); in newKeyboardLayout()
113 for (final Key key : sortedKeys) { in newKeyboardLayout()
DKey.java52 public class Key implements Comparable<Key> { class
214 public Key(@Nullable final String label, final int iconId, final int code, in Key() method in Key
255 public Key(@Nullable final String keySpec, @Nonnull final TypedArray keyAttr, in Key() method in Key
414 protected Key(@Nonnull final Key key) { in Key() method in Key
418 private Key(@Nonnull final Key key, @Nullable final MoreKeySpec[] moreKeys) { in Key() method in Key
445 public static Key removeRedundantMoreKeys(@Nonnull final Key key, in removeRedundantMoreKeys()
450 return (filteredMoreKeys == moreKeys) ? key : new Key(key, filteredMoreKeys); in removeRedundantMoreKeys()
466 private static int computeHashCode(final Key key) { in computeHashCode()
493 private boolean equalsInternal(final Key o) { in equalsInternal()
511 public int compareTo(Key o) { in compareTo()
[all …]
DMoreKeysKeyboardView.java49 private Key mCurrentKey;
87 protected void onDrawKeyTopVisuals(final Key key, final Canvas canvas, final Paint paint, in onDrawKeyTopVisuals()
195 protected void onKeyInput(final Key key, final int x, final int y) { in onKeyInput()
209 private Key detectKey(int x, int y) { in detectKey()
210 final Key oldKey = mCurrentKey; in detectKey()
211 final Key newKey = mKeyDetector.detectHitKey(x, y); in detectKey()
227 private void updateReleaseKeyGraphics(final Key key) { in updateReleaseKeyGraphics()
232 private void updatePressKeyGraphics(final Key key) { in updatePressKeyGraphics()
/packages/apps/Launcher3/src/com/android/launcher3/
DLauncherBackupHelper.java49 import com.android.launcher3.backup.nano.BackupProtos.Key;
145 private final ArrayList<Key> mKeys;
171 mKeys = new ArrayList<Key>(); in LauncherBackupHelper()
190 for (Key key : journal.key) { in applyJournal()
244 for (Key key : mKeys) { in performBackup()
381 Key key = backupKeyToKey(backupKey); in restoreEntity()
384 case Key.FAVORITE: in restoreEntity()
388 case Key.SCREEN: in restoreEntity()
392 case Key.ICON: in restoreEntity()
396 case Key.WIDGET: in restoreEntity()
[all …]
/packages/inputmethods/LatinIME/tests/src/com/android/inputmethod/keyboard/
DKeyboardLayoutTest.java33 .newKeyboardLayout(new ArrayList<Key>(), 11, 12, 13, 14); in testNewKeyboardLayout()
46 Key key1 = new Key("label1", 101, 102, "101", "101hint", 103, 104, 105, 106, 1100, 1101, in testNewKeyboardLayout()
48 Key key2 = new Key("label2", 201, 103, "201", "201hint", 203, 204, 205, 206, 2100, 2101, in testNewKeyboardLayout()
51 ArrayList<Key> sortedKeys = new ArrayList<>(2); in testNewKeyboardLayout()
/packages/inputmethods/OpenWnn/src/jp/co/omronsoft/openwnn/
DKeyboard.java117 private Key mShiftKey;
138 private List<Key> mKeys;
141 private List<Key> mModifierKeys;
222 public static class Key { class in Keyboard
306 public Key(Row parent) { in Key() method in Keyboard.Key
323 public Key(Resources res, Row parent, int x, int y, XmlResourceParser parser) { in Key() method in Keyboard.Key
542 mKeys = new ArrayList<Key>(); in Keyboard()
543 mModifierKeys = new ArrayList<Key>(); in Keyboard()
585 final Key key = new Key(row); in Keyboard()
605 public List<Key> getKeys() { in getKeys()
[all …]
DKeyboardView.java50 import jp.co.omronsoft.openwnn.Keyboard.Key;
126 boolean onLongPress(Keyboard.Key key); in onLongPress()
159 private Map<Key,View> mMiniKeyboardCache;
161 private Key[] mKeys;
211 private Key mInvalidatedKey;
369 mMiniKeyboardCache = new HashMap<Key,View>(); in KeyboardView()
472 List<Key> keys = mKeyboard.getKeys(); in setKeyboard()
473 mKeys = keys.toArray(new Key[keys.size()]); in setKeyboard()
645 final Key[] keys = mKeys; in computeProximityThreshold()
650 Key key = keys[i]; in computeProximityThreshold()
[all …]

1234