Steps to reproduce:
1. Select Text
2. Drag it to the search bar and drop it.
Expected behaviour:
The text is copied to the search bar.
Actual behaviour:
The text is copied to the search bar and is submitted despite me neither clicking search nor pressing enter.
It is logical to expect drag & drop to act as a shortcut for rightclick -> copy -> move -> rightclick -> paste, which is the case in FF.
Search bar drag & drop unbidden search Topic is solved
Re: Search bar drag & drop unbidden search
I'm sorry but the expected behavior for dropping an item is to perform the default action on it.
If you drop a URL onto a browser, you'd expect it to open it. If you drop text on a search box, you'd expect it to launch a search for that text. If you drop an image on the browser, you'd expect it to display it. If you want to just paste the text, then paste the text...?
If you drop a URL onto a browser, you'd expect it to open it. If you drop text on a search box, you'd expect it to launch a search for that text. If you drop an image on the browser, you'd expect it to display it. If you want to just paste the text, then paste the text...?
"Son, in life you do not fight battles because you expect to win, you fight them merely because they need to be fought." -- Snagglepuss


-
zerogravity
Re: Search bar drag & drop unbidden search
But then why is text that is dragged & dropped to the location/search bar copied but does not have the default action performed on it? I like it this way, but should it not at least be consistent?Moonchild wrote:I'm sorry but the expected behavior for dropping an item is to perform the default action on it.
Re: Search bar drag & drop unbidden search
Maybe the location bar knows only to deal with URLs. It sees random text as an invalid adress that you may want to correct.zerogravity wrote:I like it this way, but should it not at least be consistent?
Anyway you can use this inconsistency to your advantage and perform search.
Re: Search bar drag & drop unbidden search
The address bar is primarily just that: for addresses/URLs. If you drop text that is an invalid URL, it's ambiguous whether it is a misspelled URL or an intended search, and as a result no action is the "default action" (you can thank the people who thought combining address bar and search functionality in one field was a good idea for that one).
If you drag a valid URL to the address bar, the browser will immediately browse to it since that is the default action for the address bar if given something valid.
Conversely, the search bar is *always* used only for searching, so no matter what is dropped there, the default action will always be a search.
If you drag a valid URL to the address bar, the browser will immediately browse to it since that is the default action for the address bar if given something valid.
Conversely, the search bar is *always* used only for searching, so no matter what is dropped there, the default action will always be a search.
"Son, in life you do not fight battles because you expect to win, you fight them merely because they need to be fought." -- Snagglepuss



