This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 120886 - alignment is no longer based on the first selected node
Summary: alignment is no longer based on the first selected node
Status: VERIFIED FIXED
Alias: None
Product: uml
Classification: Unclassified
Component: General Diagram (show other bugs)
Version: 6.x
Hardware: All All
: P2 blocker (vote)
Assignee: Craig Conover
URL:
Keywords: REGRESSION
Depends on:
Blocks:
 
Reported: 2007-11-01 19:08 UTC by Peter Lam
Modified: 2007-11-02 18:39 UTC (History)
0 users

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Peter Lam 2007-11-01 19:08:31 UTC
In latest trunk build 20071101, alignment of elements is now based on the last element that was selected. It used to be
based on the first element that was selected but not very consistent since it sometimes based on the 1st element also.
This is a regression and might be a result of fixing issue 118983.

Repro steps:
- create a diagram of any type
- create and name 3 elements
- select all elements one at a time using Ctrl+select
- right click on any element and select an alignment option
Result: the elements are aligned to the last element selected for alignment.
Comment 1 Craig Conover 2007-11-01 21:54:43 UTC
I can't consistently get it to align to the first or last selected element. Seems a bit random really.
Comment 2 Peter Lam 2007-11-01 22:10:42 UTC
Yes, inconsistent but most of the time it's aligned by the last selected element.
Comment 3 Craig Conover 2007-11-01 22:51:07 UTC
Attempted to improve performance using a Set rather than a List which is the for the randomness of the "anchor" node.
Sets don't guarantee any order when iterated. Reverted back to using a List. First selected element will always be the
anchor node.
Comment 4 Peter Lam 2007-11-02 18:39:35 UTC
verified in trunk build 20071102142454.