| Index: chrome/browser/ui/toolbar/toolbar_model.h
|
| diff --git a/chrome/browser/ui/toolbar/toolbar_model.h b/chrome/browser/ui/toolbar/toolbar_model.h
|
| index c9aead57fff741cfa46fb07dc355dc6b48afb5a5..04017e8a671492fd0561ff37b0997ab13df5d736 100644
|
| --- a/chrome/browser/ui/toolbar/toolbar_model.h
|
| +++ b/chrome/browser/ui/toolbar/toolbar_model.h
|
| @@ -29,6 +29,20 @@ class ToolbarModel {
|
| #undef DEFINE_TOOLBAR_MODEL_SECURITY_LEVEL
|
| };
|
|
|
| + // If search URLs may be displayed as search terms, these are the types of
|
| + // search terms that may be extracted from the URL. See comments on GetText()
|
| + // and GetSearchTermsType().
|
| + enum SearchTermsType {
|
| + // There are no search terms.
|
| + NO_SEARCH_TERMS,
|
| + // There are regular search terms.
|
| + NORMAL_SEARCH_TERMS,
|
| + // There are search terms that require a more prominent UI. For example,
|
| + // if the search term looks like a URL then it should be clear to the user
|
| + // that a search term is being displayed.
|
| + URL_LIKE_SEARCH_TERMS,
|
| + };
|
| +
|
| virtual ~ToolbarModel() {}
|
|
|
| // Returns the text for the current page's URL. This will have been formatted
|
| @@ -50,9 +64,12 @@ class ToolbarModel {
|
| // Returns the URL of the current navigation entry.
|
| virtual GURL GetURL() const = 0;
|
|
|
| - // Returns true if a call to GetText(true) would successfully replace the URL
|
| - // with search terms.
|
| - virtual bool WouldReplaceSearchURLWithSearchTerms() const = 0;
|
| + // This indicates the type of search terms returned by a call to
|
| + // GetText(true).
|
| + virtual SearchTermsType GetSearchTermsType() const = 0;
|
| +
|
| + // Setter for whether extraction of URL like search terms is allowed.
|
| + virtual void SetSupportsExtractionOfURLLikeSearchTerms(bool value) = 0;
|
|
|
| // Returns the security level that the toolbar should display.
|
| virtual SecurityLevel GetSecurityLevel() const = 0;
|
|
|