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 23273 - Wrong implementation of WindowDriver.close()
Summary: Wrong implementation of WindowDriver.close()
Status: CLOSED FIXED
Alias: None
Product: qa
Classification: Unclassified
Component: Code (show other bugs)
Version: 3.x
Hardware: Sun All
: P1 blocker (vote)
Assignee: issues@qa
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2002-05-09 10:15 UTC by Jiri Skrivanek
Modified: 2011-02-17 09:32 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 Jiri Skrivanek 2002-05-09 10:15:15 UTC
In class DefaultWindowDriver there is following
implementation of the close method:

eDriver.dispatchEvent(oper.getSource(), 
      new WindowEvent((Window)oper.getSource(),
		      WindowEvent.WINDOW_CLOSED));
	((WindowOperator)oper).setVisible(false);

There should be WindowEvent.WINDOW_CLOSING instead
as was in WindowOperator before.

Test case to reproduce (run in IDE):

        JFrameOperator frame = new
JFrameOperator("Explorer [");
        JTreeOperator tree = new
JTreeOperator(frame);
        String sampledir =
System.getProperty("netbeans.user")+File.separator+"sampledir";
        TreePath path =
tree.findPath(sampledir+"|examples|advanced|README",
"|");
        tree.clickOnPath(path, 2);
        JFrameOperator editor = new
JFrameOperator("Source Editor [");
        editor.close();
        tree.clickOnPath(path, 2);

Source editor is made unvisible but not actually
closed. That is why IDE doesn't open source editor
again.
Comment 1 Alexandre Iline 2002-05-11 03:42:45 UTC
53c53
< 					      
WindowEvent.WINDOW_CLOSED));
---
> 					      
WindowEvent.WINDOW_CLOSING));

Comment 2 Jiri Skrivanek 2002-05-13 08:01:33 UTC
Verified.