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 42593 - New SPI to handle closing of MultiView components
Summary: New SPI to handle closing of MultiView components
Status: CLOSED FIXED
Alias: None
Product: platform
Classification: Unclassified
Component: Window System (show other bugs)
Version: 4.x
Hardware: PC Linux
: P3 blocker (vote)
Assignee: apireviews
URL:
Keywords: API, API_REVIEW_FAST
Depends on:
Blocks: 41190
  Show dependency tree
 
Reported: 2004-04-29 06:51 UTC by Milos Kleint
Modified: 2008-12-23 00:26 UTC (History)
0 users

See Also:
Issue Type: ENHANCEMENT
Exception Reporter:


Attachments
api diffs (22.28 KB, text/plain)
2004-04-29 06:54 UTC, Milos Kleint
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Milos Kleint 2004-04-29 06:51:03 UTC
New SPI addition is required to correctly handle
closing of MutiView components.
The current TopComponent canClose() semantics
assumes that the component will resolve the state
and show a dialog to the user if the in unsafe state.
New SPI was added to delegate correctly to the
inner elements.
1. Each MVElement is asked about it's state. (it
returns an instance of CloseOperationState newly
added class)
2. if everything is ok, the component can be
closed, if not resolution handling delegated to an
instance of CloseOperationHandler. Any ui is shown
there.

The CloseOperationHandler is passed to the
multiview component at creation time in the
factory. the state object instances are also
created by the factory.
Comment 1 Milos Kleint 2004-04-29 06:54:07 UTC
Created attachment 14610 [details]
api diffs
Comment 2 Jaroslav Tulach 2004-04-29 07:44:10 UTC
the string constant in COS should not be there. The factory method
could be in COS or at least linked from COS javadoc otherwise people
will not find it.
Comment 3 Milos Kleint 2004-04-29 08:21:09 UTC
done.
Comment 4 Milos Kleint 2004-05-04 10:09:44 UTC
done.
Comment 5 Marian Mirilovic 2005-12-20 15:49:01 UTC
This issue was solved long time ago. Because nobody has reopened it neither
added comments, we are verifying/closing it now. 
If you are still able to reproduce the problem, please reopen. Thanks in advance.