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 103143 - Confirmation for package deletion has no visible effect
Summary: Confirmation for package deletion has no visible effect
Status: VERIFIED FIXED
Alias: None
Product: uml
Classification: Unclassified
Component: Project (show other bugs)
Version: 6.x
Hardware: All All
: P2 blocker (vote)
Assignee: Yang Su
URL:
Keywords: REGRESSION
Depends on:
Blocks:
 
Reported: 2007-05-02 14:34 UTC by Sergey Petrov
Modified: 2007-06-20 14:56 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 Sergey Petrov 2007-05-02 14:34:36 UTC
reproducible with m9-070501
not reproducible in 551

steps:
1. create package with scoped diagram
2. select package node
3. press Delete
4. confirm object deletion (press Yes)
note package is deleted
dialog for package deletion appears
5. press No after reading of "are you sure.."
package is deleted
Comment 1 Sergey Petrov 2007-05-03 11:58:51 UTC
after ide restart package is restored (close/open project have no effect)
Comment 2 Yang Su 2007-05-17 22:39:43 UTC
I tried on 070516 build, up to step 4, there's no dialog popped up after object
deletion confirmation, the package node was deleted along with scoped diagram,
saved diagram, restarted IDE, package node was not present, as expected. So,
basically, I cannot reproduce it on the latest build.
Comment 3 Sergey Petrov 2007-05-18 12:35:17 UTC
tried with 070515, I believe it works the same as 070516
and propose additional step now:
step 0: create java platform model uml project.

By historical reasons the dialog was here because of roundtrip functionality and
possible source code loss.
Comment 4 Yang Su 2007-05-18 19:15:35 UTC
Oh I see, I must have tried on platform independent project before, sorry.

It seems to me, having two confirmation dialogs is a usability issue by itself,
apart from the regression. Do we really have to warn user that deleting package
could result in deleting source files under the package? Isn't that obvious and
conventional? Java project doesn't give that extra warning info when user
deletes package node, too much caution is sometimes irritating.

That said, can we just get rid of that second confirmation dialog when deleting
package from project tree or diagram?
Comment 5 Sergey Petrov 2007-05-18 20:48:13 UTC
for example user usually have to do some extra actions if he tried to remove not
empty folder in system either additional confirmation or additional option to
remove command, our packages are model containers, user may not see complete
picture if remove package from diagram for example, but can loss a lot of
classes and even diagram from which he removes the package
So I liked second confirmation a lot, but may be first confirmation should be
changes for packages.
Comment 6 Yang Su 2007-05-22 00:58:08 UTC
Thanks for explaining. I can imagine the use case of having a second
confirmation when deleting package element from diagram and checking "delete
from project tree", since it's a two-step action. I still feel it's redundant in
project tree case, moreover, the live roundtrip is longer there, there's no
chance source files will be deleted as a result of package deletion. Isn't the
message misleading now? Not to mention that this dialog is invoked at element
instance level, e.g. if three package nodes are selected to be deleted, three
dialogs will pop up, some people may not like it.

Anyway, I've made changes to restore the previous behavior which is why this
issue was filed. The regression was caused by fix to issue 99091, which is also
addressed.

BTW, it's a trivial change to bypass default delete confirmation for package
node in 'design' and 'implementation' project mode, if we ever decide to take
this approach later.
Comment 7 Andrew Korostelev 2007-06-20 14:56:03 UTC
verified in netbeans-hudson-trunk-980-full (Build 070620)

related issue 106147 is reopened.