diff options
author | ncj674@motorola.com <ncj674@motorola.com@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-11-24 19:19:29 +0000 |
---|---|---|
committer | ncj674@motorola.com <ncj674@motorola.com@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-11-24 19:19:29 +0000 |
commit | a82fd7054597a772df1e2d7e1c69a5d6c0508169 (patch) | |
tree | ca840691697ff65b53e43546da18f28088edfbab /chrome/browser/autocomplete/autocomplete_edit.h | |
parent | 422537de9822bdf52c242a98c2a095e18f4bd46d (diff) | |
download | chromium_src-a82fd7054597a772df1e2d7e1c69a5d6c0508169.zip chromium_src-a82fd7054597a772df1e2d7e1c69a5d6c0508169.tar.gz chromium_src-a82fd7054597a772df1e2d7e1c69a5d6c0508169.tar.bz2 |
Strip invalid characters (line breaks, tabs), javascript:schemes from the copied text while pasting text, droping text and creating right click popup for omnibox.
BUG=82181, 103703.
TEST=Copy a string with line breaks "\n" or tabs "\t".
Then right click on omnibox.
Chromium should not trigger DCHECKS.
Review URL: http://codereview.chromium.org/8513002
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@111548 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/autocomplete/autocomplete_edit.h')
-rw-r--r-- | chrome/browser/autocomplete/autocomplete_edit.h | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/chrome/browser/autocomplete/autocomplete_edit.h b/chrome/browser/autocomplete/autocomplete_edit.h index 6dd75fd..a57c7ce 100644 --- a/chrome/browser/autocomplete/autocomplete_edit.h +++ b/chrome/browser/autocomplete/autocomplete_edit.h @@ -291,6 +291,9 @@ class AutocompleteEditModel : public AutocompleteControllerDelegate { // Called when the user pastes in text. void on_paste() { paste_state_ = PASTING; } + // Returns true if pasting is in progress. + bool is_pasting() const { return paste_state_ == PASTING; } + // Called when the user presses up or down. |count| is a repeat count, // negative for moving up, positive for moving down. void OnUpOrDownKeyPressed(int count); |