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 19028 - Regression - Cannot close Editor when Tabs in one row on jdk1.4.
Summary: Regression - Cannot close Editor when Tabs in one row on jdk1.4.
Status: CLOSED WONTFIX
Alias: None
Product: platform
Classification: Unclassified
Component: Window System (show other bugs)
Version: 3.x
Hardware: Sun SunOS
: P2 blocker (vote)
Assignee: Peter Zavadsky
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2002-01-04 09:33 UTC by Jan Zajicek
Modified: 2008-12-22 17:37 UTC (History)
0 users

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments
stacktrace (3.70 KB, text/plain)
2002-01-04 09:35 UTC, Jan Zajicek
Details
Possible patch, but could be risky. (8.38 KB, patch)
2002-01-08 13:25 UTC, Peter Zavadsky
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Jan Zajicek 2002-01-04 09:33:53 UTC
#200201040331
jdk1.4.0-rc-b90

Attached exception is thrown and editor cannot be closed. Switch Tabbed UI to
Tabs in one row (Tools, Options, Ide configuration System, System settings,
Multi-Tab style). Open two files in editor. Try close editor via 'x'.

This is probably a regression caused by fix of issue #16033. So marking as P2.
Comment 1 Jan Zajicek 2002-01-04 09:35:29 UTC
Created attachment 3977 [details]
stacktrace
Comment 2 Peter Zavadsky 2002-01-04 10:44:11 UTC
Fixed in [release33].

Fix:
core/../windows/frames/SplittedContainerImpl.java [1.31.6.5]

Note:
It seems, it was just more robust check needed in the old code, which
failed after using the new API.
Comment 3 Jan Zajicek 2002-01-07 09:59:53 UTC
The exception is fixed, but popip menu cannot be invoked over the tab
now. Reopenning
Comment 4 _ ttran 2002-01-07 11:09:42 UTC
please don't forget to mark jdk 1.4 only bugs with JDK_1.4 keyword
Comment 5 Peter Zavadsky 2002-01-07 18:20:38 UTC
The second problem is worse. Jdk1.4 uses ineternal components for
drawing the scrollable tab layout, so our mouse listener on
JTabbedPane is out in that case. 
I try to find if there is some solution to by pass it. Not decided yet
if it is a jdk bug.
Comment 6 _ ttran 2002-01-08 08:55:53 UTC
Peter, is it possible to disallow those alternative tabs altogether in
JDK 1.4?
Comment 7 Peter Zavadsky 2002-01-08 09:29:18 UTC
Trung,
if you mean to disable the One scroll row option at all, of course it
is, it was 3.3.1 in that state already (one/two weeks ago).

If you mean just that for that option wouldn't be used those internal
components, no. The jdk1.4 tabbedPaneUI uses them for drawing that
style internally.
But I try to solve it by little hack.
Comment 8 Peter Zavadsky 2002-01-08 13:25:54 UTC
Created attachment 4006 [details]
Possible patch, but could be risky.
Comment 9 Peter Zavadsky 2002-01-08 13:34:37 UTC
I provided patch which would work with current state of jdk1.4 impl.

But I think the problem is on jdk side. I submitted two bugs according
this issue. There seems to be not only problem with listening on
JTabbedPane when SCROLL_TAB_LAYOUT policy is set (#4620537), but also
with translating coordinates of tabs when JTabbedPane uses
BOTTOM_PLACEMENT (what is default in IDE) with combination of
SCROLL_TAB_LAYOUT policy (#4620540).

I'll wait a bit how jdk team respond to those bugs.

To the patch:
It's risky because if it would be applied and then the jdk bugs fixed
it could lead to much more problems, like two popups on one click, or
showing popup on different  position then clicked, e.g. even outside
the TC container.

Therefore I'm not very willing to use the patch, and rather would
expect those bugs will be fixed the way JTabbedPane will work same way
under both layout policies.
Comment 10 Peter Zavadsky 2002-01-09 09:24:30 UTC
Jdk team accepted those bugs, will be fixed probably in some patch of
jdk later, so I'm closing this as wontfix.
Comment 11 Quality Engineering 2003-07-01 16:07:37 UTC
Resolved for 3.4.x or earlier, no new info since then -> verified.

Comment 12 Quality Engineering 2003-07-01 16:42:52 UTC
Resolved for 3.4.x or earlier, no new info since then -> closing.