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 180655 - Sample folders refinements in the New Project dialog box
Summary: Sample folders refinements in the New Project dialog box
Status: CLOSED FIXED
Alias: None
Product: javame
Classification: Unclassified
Component: -- Other -- (show other bugs)
Version: 6.x
Hardware: PC Windows Vista
: P3 normal (vote)
Assignee: spoonerj30
URL:
Keywords: SIMPLEFIX
Depends on:
Blocks:
 
Reported: 2010-02-12 06:07 UTC by gliesian
Modified: 2011-11-04 17:12 UTC (History)
4 users (show)

See Also:
Issue Type: ENHANCEMENT
Exception Reporter:


Attachments
Proposed patch (9.57 KB, patch)
2011-09-04 12:00 UTC, spoonerj30
Details | Diff
Revised Patch (9.04 KB, patch)
2011-09-05 02:31 UTC, spoonerj30
Details | Diff
screenshot of New Project dialog with patch applied (77.97 KB, image/png)
2011-09-09 14:14 UTC, tomwheeler
Details
Revised Patch (15.23 KB, patch)
2011-09-12 02:36 UTC, spoonerj30
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description gliesian 2010-02-12 06:07:18 UTC
In the New Project Categories, the Samples directory structure does not map against the base folders as show in the Categories below.

-------------------
- Categories Tree -
-------------------
Java
Java Web
Java EE
Java ME
Maven
Groovy
NetBeans Modules
Samples
--Java
--Java Web
--Web Services
--Java EE
--Maven
--Java ME (MIDP)
--Java ME (Ricoh SDK/J)
--Groovy
--NetBeans Modules

I would suggest organizing (mirroring) the sample folders closer to the Categories folders by creating a Java ME folder, moving the Java ME (MIDP) and Java ME (Ricoh SDK/J) folders under that folder and moving the Web Services folder under the Java Web folder.  Also, Maven is after Java ME initially and then before Java ME in the Samples tree.  This should be consistent.  

---------------------------------------------------
- Suggested Categories Refinements (Modified Tree)-
---------------------------------------------------
Java
Java Web
Java EE
Java ME
Maven
Groovy
NetBeans Modules
Samples
--Java
--Java Web
----Web Services 
--Java EE
--Java ME 
----Java ME (MIDP)
----Java ME (Ricoh SDK/J) 
--Groovy
--Maven 
--NetBeans Modules
Comment 1 gliesian 2010-02-12 06:09:18 UTC
Oops. Maven and Groovy were in sync.

---------------------------------------------------
- Suggested Categories Refinements (Modified Tree)-
---------------------------------------------------
Java
Java Web
Java EE
Java ME
Maven
Groovy
NetBeans Modules
Samples
--Java
--Java Web
----Web Services 
--Java EE
--Java ME 
----Java ME (MIDP)
----Java ME (Ricoh SDK/J) 
--Maven 
--Groovy
--NetBeans Modules
Comment 2 Ondrej Langr 2010-02-15 05:26:09 UTC
Good point. 

One note, though .. we certainly do not want to introduce an additional level of hierarchy. So .. slight modification: 

---------------------------------------------------
- Suggested Categories Refinements (Modified Tree)-
---------------------------------------------------
Java
Java Web
Java EE
Java ME
Maven
Groovy
NetBeans Modules
Samples
--Java
--Java Web
--Java Web Services 
--Java EE
--Java ME 
--Maven 
--Groovy
--NetBeans Modules
Comment 3 Jesse Glick 2010-02-15 14:16:21 UTC
Not part of the project system; IDE-wide changes.
Comment 4 Ondrej Langr 2010-03-25 14:22:42 UTC
At first reassigning to j2ee team, please rename "Web Services" to "Java Web Services" and reassign back. 

-----------------------------------------------------------------
- Suggested Categories Refinements 2 (added other project types)-
-----------------------------------------------------------------
Java
Java Web
Java EE
Java ME
JavaFX
Maven
PHP
Ruby
Groovy
C/C++
NetBeans Modules
Samples
--Java
--Java Web
--Java Web Services 
--Java EE
--Java ME 
--JavaFX
--Maven 
--PHP
--Ruby
--Groovy
--C/C++
--NetBeans Modules
Comment 5 Milan Kuchtiak 2010-05-05 09:44:01 UTC
Renamed Web Services to Java Web Services:
http://hg.netbeans.org/main/rev/72424dd92c0c
Comment 6 Jesse Glick 2010-05-05 15:48:11 UTC
I think the rest is in Java ME.
Comment 7 spoonerj30 2011-08-27 19:20:54 UTC
Steps to be taken in following modules:

mobility.midpexamples
j2me.cdc.project.ricoh

Change folder name in both modules' layer files to "Java ME"
Change coresponding displayName in both modules' Bundle.property files
Comment 8 tomwheeler 2011-08-28 15:13:04 UTC
Jonathan is working on this with Anuradha for the First Patch program, so I am adding myself to the cc list.
Comment 9 spoonerj30 2011-09-04 05:09:37 UTC
(Correction to previous steps)

Steps taken in the following modules:

mobility.midpexamples (MIDP Wireless Examples)
j2me.cdc.project.ricoh (Java ME CDC Ricoh Plugin Implementation)
j2me.cdc.project.bdj (Java ME CDC BD-J Plugin Implementation)

1. Changed Project/Samples/<NAME> folder name to "JAVA_ME" in layer files
2. Changed Templates/Project/Samples/<NAME> of the display name and the samples to "JAVA_ME" in Bundle files
3. Added a module specific tag to the end of each description to distinguish the different types of examples; e.g. in the Ricoh samples I added (Ricoh SKD/J) to the end of the each sample description.

Note: one of the layer files used an older DTD version which prevented me from making the corrections using the simpler steps I described earlier.
Comment 10 spoonerj30 2011-09-04 12:00:29 UTC
Created attachment 110379 [details]
Proposed patch
Comment 11 spoonerj30 2011-09-05 02:31:51 UTC
Created attachment 110383 [details]
Revised Patch

Removed comments in Bundle files
Comment 12 tomwheeler 2011-09-09 13:54:02 UTC
Anuradha told me he thinks the patch is ready for integration.  I have applied it to my local hg checkout and am running a full build now.  If I can verify it, I will push the change to core-main either today or tomorrow.
Comment 13 tomwheeler 2011-09-09 14:14:25 UTC
Created attachment 110570 [details]
screenshot of New Project dialog with patch applied
Comment 14 tomwheeler 2011-09-09 14:14:36 UTC
I applied the patch and it appears to match the description from Ondrej Langr on 2010-02-15 (see attached screenshot), so I am going to push it to core-main now.
Comment 15 tomwheeler 2011-09-09 14:20:13 UTC
Pushed in the following changeset:

   http://hg.netbeans.org/core-main/rev/983d685dde11

Jonathan, this should be part of a nightly build in a few days (certainly by Monday).  

When it is, please download the netbeans-trunk-nightly-YYYYMMDDTTTT-ml.zip    nightly build then (where YYYYMMDDTTTT will be the date/time of the build) from the following URL:

   http://bits.netbeans.org/download/trunk/nightly/latest/zip/

And check to see that your change is now part of the IDE.  If so, please note the build number (visible in Help->About from the IDE when you verify it) in this issue and mark the status as VERIFIED.

Nice work!
Comment 16 Jesse Glick 2011-09-09 17:22:05 UTC
http://deadlock.netbeans.org/hudson/job/NB-Core-Build/7104/ has failures resulting from this patch:

No warnings relating to folder ordering; cf: http://deadlock.netbeans.org/hudson/job/nbms-and-javadoc/lastSuccessfulBuild/artifact/nbbuild/build/generated/layers.txt
Not all children in Templates/Project/Samples/JAVA_ME/ marked with the position attribute: [ButtonTest.zip, HardKey.zip, Puzzle15Xlet.zip, SampleLockControl.zip, TimeSet.zip], but some are: [VDCustomComponents.zip, CurrencyConverter.zip, GameBuilderDemo.zip, LocalizationDemo.zip, SunSamples-Demos.zip, AdvancedMultimediaSupplements.zip, AudioSamples.zip, BluetoothDemo.zip, CityGuide.zip, I18nDemo.zip, JSR172Demo.zip, MMAPIDemos.zip, NetworkDemo.zip, ObexDemo.zip, OpenGLESDemo.zip, PDAPDemo.zip, PhotoAlbum.zip, SIPDemo.zip, SVGContactList.zip, SVGDemo.zip, UIDemo.zip, WMADemo.zip]

Some modules override some files without using the weight attribute correctly Some modules conflict on the definition of position for Templates/Project/Samples/JAVA_ME: {org.netbeans.modules.j2me.cdc.project.ricoh=410, org.netbeans.modules.mobility.midpexamples=403}

(I will back the change out later today if you have not resolved the issues yet.)
Comment 17 tomwheeler 2011-09-09 17:40:27 UTC
Jesse,

It's probably best if you could back out the patch till we can fix the attributes issue.  I do not have copy of the NB sources on the machine I'm using and it would take me several hours to clone one from Hg.
Comment 18 Jesse Glick 2011-09-09 17:51:52 UTC
OK, backing out in core-main #2e644c6f5213 for now.
Comment 19 spoonerj30 2011-09-09 18:42:10 UTC
Will fix this weekend.
Comment 20 Quality Engineering 2011-09-10 14:28:37 UTC
Integrated into 'main-golden'
Changeset: http://hg.netbeans.org/main-golden/rev/983d685dde11
User: Thomas W. Wheeler <tomwheeler@netbeans.org>
Log: applying patch (attachment ID 110383) submitted for issue #180655 for Jonathan Spooner
Comment 21 spoonerj30 2011-09-12 02:36:42 UTC
Created attachment 110635 [details]
Revised Patch

Corrections:

Commented out the SystemFileSystem.localizingBundle and position attributes in j2me.cdc.project.bdj and j2me.cdc.project.ricoh leaving the mobility.midpexamples module as the controller for these attributes.

Added a position attribute to j2me.cdc.project.ricoh's and j2me.cdc.project.bdj's children.
Comment 22 tomwheeler 2011-09-14 05:32:46 UTC
I verified this issue as follows:

 * manually inspected the patch
 * imported it into hg
 * ran "ant clean" followed by "ant" to build everything from scratch
 * ran "ant tryme" to launch the IDE built from source
 * verified that the dialog matches the previously attached screenshot
 * ran "ant commit-validation" 
 * inspected the validation test output (100% pass for all 71 tests)

I then pushed the change to core-main:

  http://hg.netbeans.org/core-main/rev/3ec935260a98

Provided the additional tests on the Hudson server pass, you will just need to download the nightly build and mark the issue VERIFIED as described earlier.
Comment 23 Quality Engineering 2011-09-15 14:16:51 UTC
Integrated into 'main-golden'
Changeset: http://hg.netbeans.org/main-golden/rev/3ec935260a98
User: Thomas W. Wheeler <tomwheeler@netbeans.org>
Log: applying patch (attachment ID 110635) submitted for issue #180655 for Jonathan Spooner