Home | History | Annotate | Download | only in search_engines

Lines Matching refs:KEYWORD

47 // the rare case the term replaces the URL it's unlikely another keyword would
81 // we need to extend this to mark a prefix as "not less than" a keyword it
148 // Strip "www." off the front of the keyword; otherwise the keyword won't work
154 string16 TemplateURLModel::CleanUserInputKeyword(const string16& keyword) {
156 string16 result(l10n_util::ToLower(keyword));
158 if (url_parse::ExtractScheme(UTF16ToUTF8(keyword).c_str(),
159 static_cast<int>(keyword.length()),
214 const string16& keyword,
217 DCHECK(!keyword.empty()); // This should only be called for non-empty
220 const TemplateURL* existing_url = GetTemplateURLForKeyword(keyword);
222 // We already have a TemplateURL for this keyword. Only allow it to be
229 // We don't have a TemplateURL with keyword. Only allow a new one if there
232 // keyword to a generated TemplateURL, we won't regenerate another keyword for
258 // Find matching keyword range. Searches the element map for keywords
278 const string16& keyword) const {
280 keyword_to_template_map_.find(keyword));
322 // TODO(mpcomplete): disable the keyword when the extension is disabled.
333 string16 keyword = UTF8ToUTF16(extension->omnibox_keyword());
337 template_url->set_keyword(keyword);
339 // ID, as well as forcing the TemplateURL to be treated as a search keyword.
346 // TODO(mpcomplete): only replace if the user hasn't changed the keyword.
386 const string16& keyword,
390 new_url.set_keyword(keyword);
551 string16 TemplateURLModel::GetKeywordShortName(const string16& keyword,
553 const TemplateURL* template_url = GetTemplateURLForKeyword(keyword);
647 DCHECK(initializers[i].keyword);
660 template_url->set_keyword(UTF8ToUTF16(initializers[i].keyword));
685 if (!template_url->keyword().empty())
686 keyword_to_template_map_.erase(template_url->keyword());
706 if (!template_url->keyword().empty())
707 keyword_to_template_map_[template_url->keyword()] = template_url;
775 std::string keyword;
791 keyword = UTF16ToUTF8(t_url->keyword());
802 prefs->SetString(prefs::kDefaultSearchProviderKeyword, keyword);
837 string16 keyword =
852 (*default_provider)->set_keyword(keyword);
878 url1->keyword() == url2->keyword() &&
922 if (!existing_turl->keyword().empty())
923 keyword_to_template_map_.erase(existing_turl->keyword());
929 if (!existing_turl->keyword().empty())
930 keyword_to_template_map_[existing_turl->keyword()] = existing_turl;
972 // replacement or isn't valid for use in keyword search terms.
984 PageTransition::KEYWORD) {
985 // The visit is the result of the user entering a keyword, generate a
986 // KEYWORD_GENERATED visit for the KEYWORD so that the keyword typed
1005 // the entry the keyword may no longer correspond to the host name. It may be
1019 GURL url(URLFixerUpper::FixupURL(UTF16ToUTF8(t_url.keyword()),
1024 // Synthesize a visit for the keyword. This ensures the url for the keyword is
1072 if (!t_url->keyword().empty())
1073 keyword_to_template_map_[t_url->keyword()] = t_url;