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 111713 - Refactor doesn't allow to delete few elements.
Summary: Refactor doesn't allow to delete few elements.
Status: NEW
Alias: None
Product: xml
Classification: Unclassified
Component: Schema Tools (show other bugs)
Version: 6.x
Hardware: PC Windows XP
: P2 blocker (vote)
Assignee: Sonali Kochar
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2007-08-02 11:48 UTC by Michael Nazarov
Modified: 2007-08-09 18:17 UTC (History)
2 users (show)

See Also:
Issue Type: ENHANCEMENT
Exception Reporter:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Michael Nazarov 2007-08-02 11:48:30 UTC
Product Version: NetBeans IDE Dev (Build 200708020000)

If one selected more then one XML schema element and want to delete all of them - there is no way to do so.
Even if few elements selected delete prompts of one element deletion and do so.

I'm not sure is this defect of enhancement...
Comment 1 Michael Nazarov 2007-08-02 11:53:35 UTC
Correction.

This is defect:

multiple deletion doesn't work only on Schema view. While on Design view there number of deletion prompts, as many
prompts as elements selected.

BTW all elements deleted from Design page stay visible. This is not same issue as fixed 107006 and I'll file new one.
Comment 2 Sonali Kochar 2007-08-03 17:49:32 UTC
There are a couple of issues here 
(i) There are two menu items, Delete and Refactor -> Delete with the same action.
Please see http://www.netbeans.org/issues/show_bug.cgi?id=111111

I am going to decouple them. Delect menu item will do normal delete without any refactoring. Refactor -> Delete will 
do delete with refactorings.

(ii) Refactor Delete of multiple items was not possible in 5.5 nor it has been added in 6.0. This is an enhancement 
that is required to the current framework. I will convert this issue into a enhancement

Going forward the behavior will be as follows, which is the same as in 5.5
(i) If user selects more than one item, Refactor -> Delete will be deactivated and the user will be able to use the 
Delete menu item to delete these items
(ii) Is user selects only one item, user can choose Delete or Refactor -> Delete

Comment 3 Michael Nazarov 2007-08-06 17:19:28 UTC
As I know currently "Delete" and "Refactor -> Safe Delete" both point to one action.
In previous builds (two-three months ago and earlier as I remember) there were different actions.

So I don't think this is enhancement...
Comment 4 Sonali Kochar 2007-08-06 18:26:42 UTC
Delete and Refactor -> Delete should point to different actions. This is a bug and not an enhancement

Refactor -> Delete of multiple items is an enhancement.
Comment 5 Michael Nazarov 2007-08-07 11:06:26 UTC
Would you please specify the difference?

Both actions cause same dialog prompt. Both actions add new same undo action.
What is the difference?

Mikhail as far as I remember we disscussed a little about and agree there is only way do delete something from xml 
using schema view: refactoring.
Comment 6 Michael Nazarov 2007-08-09 14:00:42 UTC
No answer so I assume this is defect...
There is required functionality but last accessible only from one view.
Comment 7 Sonali Kochar 2007-08-09 18:17:20 UTC
As I mentioned in my earlier evaluation, there are two issues here.
(i) Currently, Delete and Refactor -> Delete open the same dialog, add the same undo action. This is a BUG...Two menu
items do the same thing, confusing the user. This is incorrect.
 See http://www.netbeans.org/issues/show_bug.cgi?id=111111

(ii) Refactor -> delete of more than 1 item is enhancement. 

If the only way to delete items is through refactor -> delete , then I will be removing the "Delete" option from the
context menu. Refactor -> delete of more than 1 item will be revisited in next release.