summaryrefslogtreecommitdiffstats
path: root/chrome/browser/autocomplete/autocomplete_edit_view_mac.h
diff options
context:
space:
mode:
authorshess@chromium.org <shess@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-05-23 00:58:58 +0000
committershess@chromium.org <shess@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-05-23 00:58:58 +0000
commitfea0d343e62f931872a0f394bdc81fe738b5582b (patch)
treef82f29bde89496114ee57e42fa6ba0eb7d5ad30e /chrome/browser/autocomplete/autocomplete_edit_view_mac.h
parente1ad61d15ecbde52047d9a8887330433f2378e82 (diff)
downloadchromium_src-fea0d343e62f931872a0f394bdc81fe738b5582b.zip
chromium_src-fea0d343e62f931872a0f394bdc81fe738b5582b.tar.gz
chromium_src-fea0d343e62f931872a0f394bdc81fe738b5582b.tar.bz2
Don't make |field_| first responder in SetSelectedRange() unless |model_| has_focus already.
http://crbug.com/11920 TEST=Browser to www.google.com, focus is in search field, bring up new tab, click back to first tab, focus should be in search field. TEST=Select messages in gmail, focus should NOT go to autocomplete field (omnibox, url bar). Review URL: http://codereview.chromium.org/113751 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@16823 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/autocomplete/autocomplete_edit_view_mac.h')
-rw-r--r--chrome/browser/autocomplete/autocomplete_edit_view_mac.h3
1 files changed, 2 insertions, 1 deletions
diff --git a/chrome/browser/autocomplete/autocomplete_edit_view_mac.h b/chrome/browser/autocomplete/autocomplete_edit_view_mac.h
index aec861c..8f70070 100644
--- a/chrome/browser/autocomplete/autocomplete_edit_view_mac.h
+++ b/chrome/browser/autocomplete/autocomplete_edit_view_mac.h
@@ -111,7 +111,8 @@ class AutocompleteEditViewMac : public AutocompleteEditView {
// situations.
bool IsFirstResponder() const;
- // Grab focus if needed and set the selection to |range|.
+ // If |model_| believes it has focus, grab focus if needed and set
+ // the selection to |range|. Otherwise does nothing.
void SetSelectedRange(const NSRange range);
// Update the field with |display_text| and highlight the host and