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 40992

Summary: need a way to override the basic delete behaviour in explorer
Product: platform Reporter: bwl <bwl>
Component: ExplorerAssignee: t_h <t_h>
Status: RESOLVED DUPLICATE    
Severity: blocker CC: jtulach
Priority: P3 Keywords: API
Version: 3.x   
Hardware: PC   
OS: Windows ME/2000   
Issue Type: ENHANCEMENT Exception Reporter:
Attachments: patch to ExplorerActions
interface for delete handling (confirmation and actual delete)

Description bwl 2004-03-15 06:16:36 UTC
For the NetBeans platform based application we 
have built we needed a way to override the delete 
behaviour provided by the explorer.  It wasn't 
sufficient to create our own explorer views with 
the modified behaviour.  We needed it in the 
basic filesystem explorer too.  

The patch that I'll attach makes the 
ExplorerActions class delegate the confirmation 
and delete handling to another class.  The 
implementation is registered on the default 
filesystem and obtained via lookup.  If there is 
no implementation found a default is used, which 
performs the original delete behaviour.

This may be useful to other people developing 
using the NetBeans platform too.
Comment 1 bwl 2004-03-15 06:17:58 UTC
Created attachment 13976 [details]
patch to ExplorerActions
Comment 2 bwl 2004-03-15 06:18:45 UTC
Created attachment 13977 [details]
interface for delete handling (confirmation and actual delete)
Comment 3 Jiri Rechtacek 2004-04-07 15:46:20 UTC
Brett, thanks for proposal. We'll consider it with other planned changes.

Yardo, could you review it? You did amount of work on ExplorerActions,
you are friendly with this code. Thanks
Comment 4 Jiri Rechtacek 2004-04-07 15:48:56 UTC
It's a candidate for API_FAST_REVIEW?
Comment 5 Jaroslav Tulach 2004-04-08 09:59:56 UTC
There is ExplorerUtils class in 3.6 that fully replaces
ExplorerActions and allows custom definition of delete - form editor
is already using this I think. But you need your to know for which
TopComponent you want this behaviour to be applied.

The ability to modify the delete operation for all existing
ExplorerPanels is imho a bit dangerous and shall not be supported in
openide/explorer, maybe in a special extension to this library.
Comment 6 Jiri Rechtacek 2004-04-23 10:45:18 UTC
Assigned to new owner.
Comment 7 Antonin Nebuzelsky 2008-02-07 16:01:00 UTC
Reassigning to new module owner Tomas Holy.
Comment 8 t_h 2008-10-20 10:53:07 UTC

*** This issue has been marked as a duplicate of 56256 ***