HomeSort by relevance Sort by last modified time
    Searched refs:shortcuts (Results 1 - 25 of 39) sorted by null

1 2

  /packages/apps/QuickSearchBox/src/com/android/quicksearchbox/
ShortcutPromoter.java 23 * A promoter limits the maximum number of shortcuts per source
40 void promoteShortcuts(SuggestionCursor shortcuts, int maxPromoted,
42 int shortcutCount = shortcuts == null ? 0 : shortcuts.getCount();
46 shortcuts.moveTo(i);
47 Source source = shortcuts.getSuggestionSource();
48 if (source != null && accept(shortcuts)) {
52 promoted.add(new SuggestionPosition(shortcuts));
WebPromoter.java 35 // Add web shortcuts
36 SuggestionCursor shortcuts = suggestions.getShortcuts(); local
37 int shortcutCount = shortcuts == null ? 0 : shortcuts.getCount();
41 shortcuts.moveTo(i);
42 if (shortcuts.isWebSearchSuggestion()) {
44 promoted.add(new SuggestionPosition(shortcuts, i));
Suggestions.java 136 * @param shortcuts The shortcuts.
138 public void setShortcuts(ShortcutCursor shortcuts) {
139 if (DBG) Log.d(TAG, "setShortcuts(" + shortcuts + ")");
141 throw new IllegalStateException("Got duplicate shortcuts: old: " + mShortcuts
142 + ", new: " + shortcuts);
144 if (shortcuts == null) return;
146 shortcuts.close();
149 if (!mQuery.equals(shortcuts.getUserQuery())) {
150 throw new IllegalArgumentException("Got shortcuts for wrong query:
    [all...]
SingleCorpusPromoter.java 22 * Promotes shortcuts and suggestions from a single corpus.
43 // Add shortcuts
44 SuggestionCursor shortcuts = suggestions.getShortcuts(); local
45 promoteUntilFull(shortcuts, mMaxShortcuts, promoted);
DefaultCorpusRanker.java 52 * @param shortcuts Shortcut repository for getting corpus scores.
54 public DefaultCorpusRanker(Corpora corpora, ShortcutRepository shortcuts) {
57 mShortcuts = shortcuts;
ShortcutCursor.java 27 * A SuggestionCursor that allows shortcuts to be updated by overlaying
47 private ShortcutCursor(String query, SuggestionCursor shortcuts, Handler uiThread,
50 mShortcuts = shortcuts;
72 if (DBG) Log.d(TAG, "Total shortcuts: " + count);
86 // Needed to make refreshed shortcuts be treated as shortcuts
SearchActivity.java 567 if (DBG) Log.d(TAG, "Removing suggestion " + position + " from shortcuts");
648 public boolean consume(ShortcutCursor shortcuts) {
649 suggestions.setShortcuts(shortcuts);
ShortcutRepositoryImplLog.java 65 "SELECT " + Shortcuts.intent_key.fullName + " FROM " + Shortcuts.TABLE_NAME;
70 Shortcuts.shortcut_id.name() + "=? AND " + Shortcuts.source.name() + "=?";
115 Shortcuts.TABLE_NAME + " ON " + ClickLog.intent_key.fullName + " = " +
116 Shortcuts.intent_key.fullName;
121 Shortcuts.intent_key.fullName,
122 Shortcuts.source.fullName,
123 Shortcuts.source_version_code.fullName,
124 Shortcuts.format.fullName + AS + SearchManager.SUGGEST_COLUMN_FORMAT
    [all...]
  /packages/apps/QuickSearchBox/tests/src/com/android/quicksearchbox/
SourceShortcutRefresherTest.java 73 ListSuggestionCursor shortcuts = new ListSuggestionCursor(mQuery, shortcut1); local
74 mRefresher.refresh(shortcuts, mListener);
84 ListSuggestionCursor shortcuts = new ListSuggestionCursor(mQuery, shortcut1); local
85 mRefresher.refresh(shortcuts, mListener);
95 ListSuggestionCursor shortcuts = new ListSuggestionCursor(mQuery, shortcut1); local
96 mRefresher.refresh(shortcuts, mListener);
BlendingPromoterTest.java 118 SuggestionCursor shortcuts = cursor(mS11, mS12, mS21, mS22, mWeb1, mWeb2); local
119 ListSuggestionCursorNoDuplicates promoted = promote(config(), shortcuts, maxPromoted);
120 int expectedCount = Math.min(maxPromoted, shortcuts.getCount());
122 int count = Math.min(maxPromoted, shortcuts.getCount());
123 assertSameSuggestions(slice(promoted, 0, count), slice(shortcuts, 0, count));
126 private SuggestionCursor limit(SuggestionCursor shortcuts, int maxShortcutsPerWebSource,
130 return promote(config, shortcuts, maxPromoted);
133 private ListSuggestionCursorNoDuplicates promote(Config config, SuggestionCursor shortcuts,
138 promoter.promoteShortcuts(shortcuts, maxPromoted, promoted);
RankAwarePromoterTest.java 114 SuggestionCursor shortcuts = mShortcuts. local
116 for (int i = 0; i < shortcuts.getCount(); ++i) {
117 promoted.add(new SuggestionPosition(shortcuts, 1));
142 Source mockSource = new MockSource("Shortcuts");
ResultPromoterTest.java 89 private ListSuggestionCursor promoteShortcuts(SuggestionCursor shortcuts) {
92 promoter.promoteShortcuts(shortcuts, MAX_PROMOTED_SUGGESTIONS, promoted);
  /packages/apps/QuickSearchBox/src/com/android/quicksearchbox/preferences/
ClearShortcutsController.java 27 * Logic behind the 'clear shortcuts' preference.
42 public ClearShortcutsController(ShortcutRepository shortcuts) {
43 mShortcuts = shortcuts;
74 * Enables/disables the "Clear search shortcuts" preference depending
89 Log.i(TAG, "Clearing shortcuts...");
PreferenceControllerFactory.java 54 ShortcutRepository shortcuts = QsbApplication.get(getContext()).getShortcutRepository(); local
55 addController(new ClearShortcutsController(shortcuts), p);
  /packages/inputmethods/LatinIME/tools/dicttool/src/com/android/inputmethod/latin/dicttool/
CombinedInputOutput.java 128 ArrayList<WeightedString> shortcuts = new ArrayList<WeightedString>(); local
134 dict.add(word, freq, shortcuts.isEmpty() ? null : shortcuts, isNotAWord);
139 if (!shortcuts.isEmpty()) shortcuts = new ArrayList<WeightedString>();
168 shortcuts.add(new WeightedString(shortcut, shortcutFreq));
192 dict.add(word, freq, shortcuts.isEmpty() ? null : shortcuts, isNotAWord);
XmlDictInputOutput.java 81 * @param shortcuts the shortcuts as a map. This may be empty, but may not be null.
83 public UnigramHandler(final HashMap<String, ArrayList<WeightedString>> shortcuts) {
85 mShortcutsMap = shortcuts;
301 * @param shortcuts the file to read the shortcuts & whitelist from, or null.
306 final InputStream shortcuts, final InputStream bigrams)
316 if (null != shortcuts) parser.parse(shortcuts, shortcutAndWhitelistHandler);
339 * which has no support for bigrams or shortcuts/whitelist
    [all...]
DictionaryMaker.java 98 + " with XML input (other formats include bigrams and shortcuts already)");
330 final FileInputStream shortcuts = null == shortcutXmlFilename ? null : local
334 return XmlDictInputOutput.readDictionaryXml(unigrams, shortcuts, bigrams);
  /packages/inputmethods/LatinIME/java/src/com/android/inputmethod/latin/
SubtypeSwitcher.java 132 final Map<InputMethodInfo, List<InputMethodSubtype>> shortcuts = local
136 for (final InputMethodInfo imi : shortcuts.keySet()) {
137 final List<InputMethodSubtype> subtypes = shortcuts.get(imi);
138 // TODO: Returns the first found IMI for now. Should handle all shortcuts as
  /packages/inputmethods/LatinIME/java/src/com/android/inputmethod/latin/makedict/
BinaryDictIOUtils.java 712 * @param shortcuts
722 final ArrayList<WeightedString> shortcuts, final boolean isNotAWord,
    [all...]
  /packages/inputmethods/LatinIME/tests/src/com/android/inputmethod/latin/makedict/
BinaryDictIOTests.java 165 final ArrayList<WeightedString> shortcuts = CollectionUtils.newArrayList(); local
168 shortcuts.add(new WeightedString(shortcut, UNIGRAM_FREQ));
171 dict.add(word, UNIGRAM_FREQ, (shortcutMap == null) ? null : shortcuts,
275 final SparseArray<List<Integer>> bigrams, final Map<String, List<String>> shortcuts,
288 addUnigrams(words.size(), dict, words, shortcuts); local
290 checkDictionary(dict, words, bigrams, shortcuts);
293 final long read = timeReadingAndCheckDict(file, words, bigrams, shortcuts, bufferType);
301 results.add(runReadAndWrite(sWords, sEmptyBigrams, null /* shortcuts */, bufferType,
303 results.add(runReadAndWrite(sWords, sChainBigrams, null /* shortcuts */, bufferType,
305 results.add(runReadAndWrite(sWords, sStarBigrams, null /* shortcuts */, bufferType
    [all...]
BinaryDictIOUtilsTests.java 95 Log.d(TAG, " shortcuts = " + ws.mWord);
177 final ArrayList<WeightedString> shortcuts) {
192 BinaryDictIOUtils.insertWord(buffer, outStream, word, frequency, bigrams, shortcuts,
  /development/samples/ApiDemos/src/com/example/android/apis/app/
MenuInflateFromXml.java 46 R.menu.checkable, R.menu.shortcuts, R.menu.order, R.menu.category_order,
55 "Checkable", "Shortcuts", "Order", "Category and Order",
  /external/libvpx/libvpx/examples/includes/PHP-SmartyPants-1.5.1e/
smartypants.php 87 # 2 : set all, using old school en- and em- dash shortcuts
88 # 3 : set all, using inverted old school en and em- dash shortcuts
333 # use old smart dash shortcuts, "--" for en, "---" for em
  /packages/apps/QuickSearchBox/src/com/android/quicksearchbox/ui/
SearchActivityViewTwoPane.java 87 mResultsView = (ClusteredSuggestionsView) findViewById(R.id.shortcuts);
  /dalvik/docs/
prettify.js 538 * order if the shortcut ones fail. May have shortcuts.
545 var shortcuts = {};
553 shortcuts[shortcutChars.charAt(c)] = patternParts;
574 var patternParts = shortcuts[tail.charAt(0)];
    [all...]

Completed in 852 milliseconds

1 2