Please use the Apache issue tracking system for new NetBeans issues (https://issues.apache.org/jira/projects/NETBEANS0/issues) !!
Bug 211215 - Wrong Browse/Add Jar Dialog Box Shows
Wrong Browse/Add Jar Dialog Box Shows
Status: VERIFIED FIXED
Product: platform
Classification: Unclassified
Component: Directory Chooser
7.2
PC Windows Vista
: P3 (vote)
: 7.2
Assigned To: Ondrej Vrabec
issues@platform
:
: 212506 (view as bug list)
Depends on: 216099
Blocks:
  Show dependency treegraph
 
Reported: 2012-04-16 02:05 UTC by MackSix
Modified: 2012-10-03 01:36 UTC (History)
2 users (show)

See Also:
Issue Type: DEFECT
:


Attachments
Screenshot (741.74 KB, image/png)
2012-04-16 02:05 UTC, MackSix
Details
Screenshot (881.62 KB, image/png)
2012-04-16 02:06 UTC, MackSix
Details
Screenshot (739.02 KB, image/png)
2012-04-16 02:07 UTC, MackSix
Details
log file (60.68 KB, application/octet-stream)
2012-04-16 18:56 UTC, MackSix
Details
Startup XML, NPSS, LOG, Screenshots (1.00 MB, application/zip)
2012-04-17 10:46 UTC, MackSix
Details
screenshot with damaged Home button (83.31 KB, image/png)
2012-06-13 11:08 UTC, Vladimir Riha
Details

Note You need to log in before you can comment on or make changes to this bug.
Description MackSix 2012-04-16 02:05:53 UTC
Created attachment 118292 [details]
Screenshot

I have noticed that sometimes the wrong Browse/Add Jar dialog box is shown. The dialog box is in at least 3 different locations with 3 different names. It will show the Metal Look & Feel folder icons and have 2 extra buttons (Desktop & Details). All the toolbar buttons have different icons on them.

Not sure how to reproduce it, although it was soon after a new installation of NetBeans.

See Attached Screenshots.
Comment 1 MackSix 2012-04-16 02:06:20 UTC
Created attachment 118293 [details]
Screenshot
Comment 2 MackSix 2012-04-16 02:07:08 UTC
Created attachment 118294 [details]
Screenshot
Comment 3 MackSix 2012-04-16 02:07:34 UTC
Product Version: NetBeans IDE Dev (Build 201204150400)
Java: 1.7.0_03; Java HotSpot(TM) Client VM 22.1-b02
System: Windows Vista version 6.0 running on x86; Cp1252; en_US (nb)
Comment 4 Stanislav Aubrecht 2012-04-16 13:11:10 UTC
cannot reproduce in: 

Product Version: NetBeans IDE Dev (Build 20120416-b588a93c890c)
Java: 1.7.0_03; Java HotSpot(TM) Client VM 22.1-b02
System: Windows 7 version 6.1 running on x86; Cp1250; en_US (nb)


Next time you see this error, please attach messages.log. There might be some exceptions or warnings related to this problem...
Comment 5 MackSix 2012-04-16 18:56:19 UTC
Created attachment 118364 [details]
log file

It happened after installing:

Product Version: NetBeans IDE Dev (Build 201204160400)
Java: 1.7.0_03; Java HotSpot(TM) Client VM 22.1-b02
System: Windows Vista version 6.0 running on x86; Cp1252; en_US (nb)

Here is the log file.

This was on the second restart and I had opened a couple of project forms in the GUI editor and was previewing them with different look & feel from the context menu in Navigator. It may have something to do with that, not sure. Will try to reproduce. I restarted Netbeans and the dialog boxes are back to normal.
Comment 6 Stanislav Aubrecht 2012-04-17 08:31:28 UTC
Thanks for the log, it doesn't contain anything interesting though...
Comment 7 MackSix 2012-04-17 10:44:59 UTC
(In reply to comment #6)
> Thanks for the log, it doesn't contain anything interesting though...

I think this is happening on startup in every case. Would the startup XML and CLI Timeline be any help? I don't know anything about them, but I learned to generate them. I had this bug happen while generating them. See attached Zip with those files and the corresponding messages.log file.
Comment 8 MackSix 2012-04-17 10:46:10 UTC
Created attachment 118391 [details]
Startup XML, NPSS, LOG, Screenshots
Comment 9 MackSix 2012-04-17 11:16:47 UTC
This is interesting, If I create the NPSS snapshot and generate the starup XML, his is repeatable each time I use these steps:

1.) Start NetBeans and open a project with a JFrame form and open it up in the Editor in design mode.

2.) Shutdown NetBeans while project and JFrame form is still open.

3.) Make sure you have the Welcome tab open in the Editor so that is shows on next startup.

3.) Setup NetBeans to create NPSS snapshot using these instructions http://wiki.netbeans.org/FitnessViaCLITimeLine 

4.) Start NetBeans with -J-Dorg.netbeans.log.startup=xml and  -J-Dorg.netbeans.log.startup.logfile=filename to generate startup XML.

5.) As soon as you can see "File" on menu, immediately click on it with mouse and move mouse button down the menu and back up.

6.) Then click on the tab with JFrame form and bring it in focus. Wait until the Design shows.

7.) Click on File>>Open File and the "Open" dialog box will show Metal Look & Feel and extra toolbar icons.
Comment 10 MackSix 2012-04-21 23:17:03 UTC
This is repeatable using the steps described.
Comment 11 Stanislav Aubrecht 2012-04-22 11:09:43 UTC
(In reply to comment #10)
> This is repeatable using the steps described.

Fine, but it's still a cosmetic issue, so P4
Comment 12 MackSix 2012-05-07 06:30:33 UTC
These File browser dialog boxes now show Metallic L&F full times without doing anything special to coax it to happen.

Product Version: NetBeans IDE Dev (Build 201205060400)
Java: 1.7.0_04; Java HotSpot(TM) Client VM 23.0-b21
System: Windows Vista version 6.0 running on x86; Cp1252; en_US (nb)
Comment 13 Stanislav Aubrecht 2012-05-07 06:41:03 UTC
(In reply to comment #12)
> These File browser dialog boxes now show Metallic L&F full times without doing
> anything special to coax it to happen.
> 
Does it happen also with a clean user dir?
Comment 14 MackSix 2012-05-07 07:03:26 UTC
(In reply to comment #13)
> (In reply to comment #12)
> > These File browser dialog boxes now show Metallic L&F full times without doing
> > anything special to coax it to happen.
> > 
> Does it happen also with a clean user dir?

I deleted the user dir and cache and restarted and it did not do it. I opened a small Java SE project and then closed NetBeans. I restarted it and the File>>Open File dialog shows Metal L&F
Comment 15 Stanislav Aubrecht 2012-05-07 07:07:06 UTC
Can you attach that project here? Does it contain any GUI forms? If so, can you reproduce the problem while having only Java source files opened?
Comment 16 MackSix 2012-05-07 07:09:23 UTC
(In reply to comment #15)
> Can you attach that project here? Does it contain any GUI forms? If so, can you
> reproduce the problem while having only Java source files opened?

It has nothing to do with opening the project. I deleted the user dir again and it momentarily fixed it and on restart it went back to Metal L&F and I did not open any files.
Comment 17 Vladimir Riha 2012-05-15 08:22:27 UTC
*** Bug 212506 has been marked as a duplicate of this bug. ***
Comment 18 Vladimir Riha 2012-05-15 09:01:33 UTC
I don't think it is related to java project, as described in issue #212506, it happens with PHP settings as well
Comment 19 Vladimir Riha 2012-06-13 10:53:09 UTC
Just for information, sometimes the Home button in the Dialog is not "rendered" correctly, there is no icon and it is extremely small (guess 1/4 in compared to other buttons)
Comment 20 Vladimir Riha 2012-06-13 11:08:36 UTC
Created attachment 120775 [details]
screenshot with damaged Home button
Comment 21 MackSix 2012-06-13 12:10:07 UTC
(In reply to comment #19)
> Just for information, sometimes the Home button in the Dialog is not "rendered"
> correctly, there is no icon and it is extremely small (guess 1/4 in compared to
> other buttons)

Yep, I see the button missing most of the time, but only when the dialog is rendered in the wrong L&F. This is regression, not sure why it was put at P4, it ought to be P1 and fixed for 7.2.
Comment 22 Marian Mirilovic 2012-06-13 13:05:54 UTC
Standa, 
do we know the reason ? ... or root cause of this issue ?
Comment 23 Stanislav Aubrecht 2012-06-13 15:39:20 UTC
Looks like a bug in DirChooser - during startup the dirchooser initializes UIManager defaults and asks for FileChooser UI class. In some cases the defaults are initialized to MetalFileChooserUI.
Comment 24 Stanislav Aubrecht 2012-06-13 15:45:40 UTC
This is most likely happening when the dir chooser module is initialized before the correct look&feel is set.
Comment 25 Marian Mirilovic 2012-06-13 15:53:11 UTC
Could we somehow postpone initialization or set L&F sooner ?
Comment 26 Ondrej Vrabec 2012-06-13 19:00:27 UTC
fix: http://hg.netbeans.org/core-main/rev/2bb3c590df06
Comment 27 Ondrej Vrabec 2012-06-13 19:01:21 UTC
hopefully fixed. btw i think it's a side-effect of #c08ac834bf6a
Comment 28 Vladimir Riha 2012-06-13 19:29:25 UTC
Thanks a lot for the fix, I'll verify it tomorrow
Comment 29 Quality Engineering 2012-06-15 06:15:26 UTC
Integrated into 'main-golden', will be available in build *201206150001* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress)
Changeset: http://hg.netbeans.org/main-golden/rev/2bb3c590df06
User: Ondrej Vrabec <ovrabec@netbeans.org>
Log: #211215 - Wrong Browse/Add Jar Dialog Box Shows
waiting for window system to load before changing the chooser UI
Comment 30 Vladimir Riha 2012-06-15 07:35:08 UTC
I'm no longer able to reproduce, verified


Product Version: NetBeans IDE Dev (Build 201206150001)
Java: 1.7.0_04; Java HotSpot(TM) Client VM 23.0-b21
System: Windows 7 version 6.1 running on x86; Cp1252; en_US (nb)


By use of this website, you agree to the NetBeans Policies and Terms of Use. © 2014, Oracle Corporation and/or its affiliates. Sponsored by Oracle logo