Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(256)

Unified Diff: chrome/browser/ui/omnibox/omnibox_edit_model.cc

Issue 22795005: Omnibox: don't assume omnibox has focus in OnAfterPossibleChange(). (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/ui/omnibox/omnibox_edit_model.cc
diff --git a/chrome/browser/ui/omnibox/omnibox_edit_model.cc b/chrome/browser/ui/omnibox/omnibox_edit_model.cc
index 4ee0baf09bcd9a3ca909c61bd67523d2afd9959f..06557cad6dc2b5f57b3696f7364027644d764f14 100644
--- a/chrome/browser/ui/omnibox/omnibox_edit_model.cc
+++ b/chrome/browser/ui/omnibox/omnibox_edit_model.cc
@@ -1032,10 +1032,9 @@ bool OmniboxEditModel::OnAfterPossibleChange(const string16& old_text,
if (text_differs || selection_differs) {
// Record current focus state for this input if we haven't already.
- DCHECK_NE(OMNIBOX_FOCUS_NONE, focus_state_);
Peter Kasting 2013/08/12 18:58:15 You should comment about Linux' dumb behavior here
samarth 2013/08/12 19:13:40 Added comment and crbug.com/271590. I'll fix Linu
if (focus_source_ == INVALID) {
- focus_source_ = (focus_state_ == OMNIBOX_FOCUS_VISIBLE) ?
- OMNIBOX : FAKEBOX;
+ focus_source_ = (focus_state_ == OMNIBOX_FOCUS_INVISIBLE) ?
+ FAKEBOX : OMNIBOX;
}
// Restore caret visibility whenever the user changes text or selection in
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698