Closed Bug 398422 Opened 17 years ago Closed 17 years ago

Dragging bookmarks folder fails with "aArray has no properties"

Categories

(Core :: XUL, defect)

1.8 Branch
x86
Linux
defect
Not set
normal

Tracking

()

RESOLVED FIXED

People

(Reporter: ajschult784, Assigned: jag+mozilla)

References

(Blocks 1 open bug)

Details

(Keywords: fixed1.8.1.9, regression, verified1.8.1.8)

Attachments

(1 file)

 
(oops)

With a branch build (1.1.5pre), I made a bookmarks folder and tried to move it.  That failed with:

Error: aArray has no properties
Source File: chrome://communicator/content/bookmarks/bookmarks.js
Line: 1042

Looking at the code...
http://mxr.mozilla.org/seamonkey/source/suite/common/bookmarks/bookmarks.js#1421
moveSelection does:
aSelection.isValid = BookmarksUtils.isSelectionValidForInsertion(aSelection, aTarget, "move");

isSelectionValidForInsertion checks some things and (in my case) returns |aSelection.isValid| (which happens to be void).  So, the net result is:

aSelection.isValid = aSelection.isValid;

so aSelection.isValid is bogus and then later on it tries to use it (in BookmarksUtils.any(transaction.isValid);).

moveSelection is being called by onDrag in bookmarksTree.xml (line 605), which gets |seletion| from BookmarksUtils.getSelectionFromXferData(dragSession).
Summary: Dragging bookmarks folder fails with "aArray has no properties → Dragging bookmarks folder fails with "aArray has no properties"
Version: Trunk → 1.8 Branch
this regressed on the branch (although bookmarks code itself hasn't changed).  1.1.4 doesn't have the problem. trunk is also OK.
Flags: blocking-seamonkey1.1.5?
Keywords: regression
Regression from bug 267833 perhaps?
I actually get a different JS error just by opening Bookmarks, but it goes away if I back out attachment 280936 [details] [diff] [review] locally...
Blocks: 267833
So... I just opened bookmarks manager, pointed the mouse at a folder, dragged it to another folder, and dropped.  That works, with no JS errors.

Am I using the wrong steps to reproduce?  What are the right ones?  Are people testing in a build with the patch for bug 398404 in it?
> So... I just opened bookmarks manager, pointed the mouse at a folder, dragged
> it to another folder, and dropped.  That works, with no JS errors.

I was dragging a folder and dropping between two existing bookmarks, but using your steps also fails.

I see the bug with today's nightly branch build.
this regressed due to bug 179658... not sure how 267833 is related (I don't see an error just opening bookmarks manager)
Blocks: 179658
I suggest filing a core bug to track the issue too, so branch drivers will see it.
actually, I'm going to move this to core since (AFAICT) there is no bug in SeaMonkey code...

this is failing because on

http://bonsai.mozilla.org/cvsblame.cgi?file=/mozilla/xpfe/components/bookmarks/resources/bookmarksTree.xml&rev=1.18.24.2&mark=585#583

DS.getCurrentSession() returns a session whose numDropItems = 0 (before bug 179658, it was 1).
Assignee: nobody → jag
Component: Bookmarks → XP Toolkit/Widgets
Flags: blocking-seamonkey1.1.5?
Product: Mozilla Application Suite → Core
QA Contact: bookmarks → xptoolkit.widgets
Flags: blocking1.8.1.9?
Flags: blocking1.8.1.8?
(In reply to comment #5)
>Are people testing in a build with the patch for bug 398404 in it?
I wasn't. Sorry about that.
No longer blocks: 267833
This is an nsDragService:5 log before (1 items) and after (0 items)
FWIW, I see the same behavior in a current Firefox branch CVS build.
(In reply to comment #12)
> FWIW, I see the same behavior in a current Firefox branch CVS build.
> 
confirmed, i see the same with 2.0.0.8rc1 builds like Mozilla/5.0 (X11; U; Linux i686; da; rv:1.8.1.8) Gecko/2007100416 Firefox/2.0.0.8 on Linux. Windows and Mac are fine.
Speaking briefly with dveditz, I wondered whether this would affect Thunderbird. I just tested version 2.0.0.7pre (20071008) on Ubuntu and I do not see this problem in Thunderbird.
Backed the fix out of the 1.8 branch as well as the GECKO181_20071004_RELBRANCH
Status: NEW → RESOLVED
Closed: 17 years ago
Flags: blocking1.8.1.9?
Flags: blocking1.8.1.9+
Flags: blocking1.8.1.8?
Flags: blocking1.8.1.8+
Resolution: --- → FIXED
verified fixed 1.8.1.8 using  Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.8.1.8) Gecko/2007100816 Firefox/2.0.0.8 (Firefox 2.0.0.8 RC2) 

Dragging bookmarks folder works now as expected and without any JS error in the Error Console

-> Adding verified keyword
Correcting blocking flags that got renamed due to firedrill release insertions
Flags: blocking1.8.1.11+ → blocking1.8.1.9+
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: