| Index: chrome/browser/ui/cocoa/omnibox/omnibox_view_mac.mm
|
| ===================================================================
|
| --- chrome/browser/ui/cocoa/omnibox/omnibox_view_mac.mm (revision 85569)
|
| +++ chrome/browser/ui/cocoa/omnibox/omnibox_view_mac.mm (working copy)
|
| @@ -1063,6 +1063,7 @@
|
| ui::Clipboard::BUFFER_STANDARD)) {
|
| string16 text16;
|
| clipboard->ReadText(ui::Clipboard::BUFFER_STANDARD, &text16);
|
| + StripJavascriptSchema(text16, &text16);
|
|
|
| // Note: Unlike in the find popup and textfield view, here we completely
|
| // remove whitespace strings containing newlines. We assume users are
|
| @@ -1083,11 +1084,13 @@
|
| if (clipboard->IsFormatAvailable(ui::Clipboard::GetUrlWFormatType(),
|
| ui::Clipboard::BUFFER_STANDARD)) {
|
| std::string url_str;
|
| + string16 text;
|
| clipboard->ReadBookmark(NULL, &url_str);
|
| // pass resulting url string through GURL to normalize
|
| GURL url(url_str);
|
| if (url.is_valid()) {
|
| - return UTF8ToUTF16(url.spec());
|
| + StripJavascriptSchema(UTF8ToUTF16(url.spec()), &text);
|
| + return text;
|
| }
|
| }
|
|
|
|
|