Closed Bug 295067 Opened 20 years ago Closed 17 years ago

Dragging Plain Text over the location bar gives the wrong cursor icon

Categories

(Firefox :: Address Bar, defect)

x86
All
defect
Not set
normal

Tracking

()

RESOLVED WORKSFORME

People

(Reporter: jaime.bugzilla, Unassigned)

References

Details

Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.8b2) Gecko/20050521
Firefox/1.0+ ID:2005052112

Plain Text can no longer be DnD onto the location bar (URL's still can) however
the wrong cursor icon is displayed when moving over the address bar.

The cursor icon should display the no entry cursor when dragging plain text over
the address bar not the insert text cursor.
dupe of #295066
Summary: Dragging Plain Text over the address bar gives the wrong cursor icon → Dragging Plain Text over the location bar gives the wrong cursor icon
(In reply to comment #1)
> dupe of #295066

No it isn't, it's different.  It has to do with the fact that although you
/can't/ put plain text into the location bar, it shows the drop icon for drag n
drop stuff.
It appears that canDrop is set to true when dropping text for the DnD observer
but when dropping text on the urlbar the following is written to the js console:
Error: [Exception... "'Drop of testcase denied.' when calling method:
[nsIDOMEventListener::handleEvent]"  nsresult: "0x8057001e
(NS_ERROR_XPC_JS_THREW_STRING)"  location: "<unknown>"  data: no]

If this is intended behavior (e.g. text can't be dropped on the urlbar) then
canDrop should be set to false when dragging text over the urlbar. I suspect a
one off case could be added where if the element that is being dragged over and
the flavour is "text/unicode" that canDrop could be set to false... this is of
course overly simplified.
^^^ No. That bug is about the fact that dropping certain URIs doesn't actually
load them. As far as I can tell, this bug is about the fact that the
drag-and-drop cursor (what shows before you release the left mouse button over
the location-bar) is the "drop allowed" cursor, and not the "drop disallowed"
cursor (the one you see when trying to drop text onto the reload button for example.

If the current behavious in bug 289513 is intended, then this bug should be
fixed to show the disallowed cursor when attempting to drop invalid text to the
location bar. If however, bug 289513 gets fixed to allow URIs like
www.mozilla.org to be dropped, then the cursor should be "allow" for those URIs,
but "disallow" for plain-text.

In my opinion, the current behaviour in bug 289513 is good. URIs without a
protocol shouldn't be allowed to be dropped and auto-converted to http:. chrome:
URIs, ftp: URIs, data: URIs can all be dropped. Therefore in my opinion this bug
should be fixed and bug 289513 marked INVALID (correct behaviour.)
Version: unspecified → Trunk
OS: Windows XP → All
Marking WFM. 

On current trunk I am able to drop text into the location bar as expected.
Status: NEW → RESOLVED
Closed: 17 years ago
Resolution: --- → WORKSFORME
You need to log in before you can comment on or make changes to this bug.