Modify

Opened 12 years ago

Last modified 12 years ago

#7148 new defect

Nodes that are not selectable are posible select via selection history

Reported by: alv Owned by: team
Priority: normal Milestone:
Component: Core Version: latest
Keywords: deleted selection patch Cc:

Description (last modified by alv)

The title may seem cryptic, but steps to reproduce:

  • draw a unclosed way with four nodes
  • select each node
  • distribute nodes
  • select one of the middle nodes
  • delete that node
  • using the select history on the right hand selection panel, select the first line that reads "4 nodes"
  • you see three remaining (as in not deleted) nodes selected
  • select distribute nodes

expected result:

  • equal distances between the three nodes

result:

  • no change, equal distance between all four nodes, including the deleted.

In fact, all (or many) tool actions work with the deleted nodes as if they still existed, when reselected in this manner. At least align in line, align in circle, orthogonalize (ways + two deleted nodes).

Attachments (1)

0001-fix-7148-Make-sure-that-only-selectable-items-are-se.patch (3.1 KB ) - added by KalleLampila 12 years ago.

Download all attachments as: .zip

Change History (10)

comment:1 by alv, 12 years ago

Description: modified (diff)
Keywords: distribute removed
Summary: Distribute nodes and selected but already deleted nodesTools make use of selected but already deleted nodes

comment:2 by KalleLampila, 12 years ago

Keywords: patch added
Summary: Tools make use of selected but already deleted nodes[PATCH] Tools make use of selected but already deleted nodes

comment:3 by KalleLampila, 12 years ago

Deleted nodes should not be selected. Patch make sure that only selectable item are selected. It also fix name calculation to selection history menu.

comment:4 by stoecker, 12 years ago

Summary: [PATCH] Tools make use of selected but already deleted nodesTools make use of selected but already deleted nodes

This patch is wrong. JOSM handles deleted, incomplete and other non-real data. This is perfectly valid. The tools need be fixed not to use this data when doing their job.

in reply to:  4 comment:5 by bastiK, 12 years ago

Replying to stoecker:

This patch is wrong. JOSM handles deleted, incomplete and other non-real data. This is perfectly valid. The tools need be fixed not to use this data when doing their job.

I agree, but most of the editing tools cannot handle deleted objects. Maybe we should add a parameter

getSelected(boolean includeDeleted)

and

getSelected() { return getSelected(false); }

in reply to:  4 comment:6 by anonymous, 12 years ago

Replying to stoecker:

The tools need be fixed not to use this data when doing their job.

Why not provide a method in the selection code for getting all data that is currently visible? That way the tools wouldn't all have to make the check by themselves.

in reply to:  4 comment:7 by KalleLampila, 12 years ago

Summary: Tools make use of selected but already deleted nodesNodes that are not selectable are posible select via selection history

Replying to stoecker:

This patch is wrong. JOSM handles deleted, incomplete and other non-real data. This is perfectly valid. The tools need be fixed not to use this data when doing their job.

I think that you are misunderstood patch. It not prevent handles deleted, incomplete and other non-real data. It only prevent select primitives that are not selectable.

There is not any error in distribute nodes as you can read original bug description. (User only don't see that deleted node)

What is purpose of PrimitiveId:isSelectable() function?

comment:8 by stoecker, 12 years ago

Deleted elements are and should be selectable, like incomplete ones. If you can't select them, you can't work with them. Don't mix select by click with select by other means (like search).

comment:9 by alv, 12 years ago

If the search should find deleted objects with their id, it doesn't. Tried with r4279 and r4620.

Modify Ticket

Change Properties
Set your email in Preferences
Action
as new The owner will remain team.
as The resolution will be set. Next status will be 'closed'.
to The owner will be changed from team to the specified user.
Next status will be 'needinfo'. The owner will be changed from team to alv.
as duplicate The resolution will be set to duplicate. Next status will be 'closed'. The specified ticket will be cross-referenced with this ticket.
The owner will be changed from team to anonymous. Next status will be 'assigned'.

Add Comment


E-mail address and name can be saved in the Preferences .
 
Note: See TracTickets for help on using tickets.