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 241948 - In "New .." context menu dialog "Javascript file" is shown twice
Summary: In "New .." context menu dialog "Javascript file" is shown twice
Status: RESOLVED WONTFIX
Alias: None
Product: web
Classification: Unclassified
Component: HTML Project (show other bugs)
Version: 8.0
Hardware: All All
: P3 normal (vote)
Assignee: Tomas Mysik
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2014-02-16 18:22 UTC by c69
Modified: 2014-07-24 06:17 UTC (History)
0 users

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments
screenshot of the issue (13.26 KB, image/png)
2014-02-16 18:22 UTC, c69
Details

Note You need to log in before you can comment on or make changes to this bug.
Description c69 2014-02-16 18:22:24 UTC
Created attachment 145258 [details]
screenshot of the issue

On PHP and HTML5 project.

1) Right-click, choose "New .."
2) You will see "Javascript file .." twice

Expected:
 Each option should be shown only once.
Comment 1 Marian Mirilovic 2014-02-19 06:11:04 UTC
NB version/build number ?
JDK version ?
Steps to reproduce ?
Comment 2 c69 2014-02-26 01:12:24 UTC
Product Version: NetBeans IDE 8.0 Beta (Build 201401141042)
Java: 1.8.0; Java HotSpot(TM) 64-Bit Server VM 25.0-b69
Runtime: Java(TM) SE Runtime Environment 1.8.0-b129
System: Windows 7 version 6.1 running on amd64; Cp1251; en_US (nb)
User directory: C:\Users\_censored_\AppData\Roaming\NetBeans\8.0beta
Cache directory: C:\Users\_censored_\AppData\Local\NetBeans\Cache\8.0beta


Steps to reproduce:

(setup) create and/or open some project HTML5 or PHP project
(1) in Projects - right click any HTML5 or PHP project
(2) Choose New...
(3) Check the context menu: it contains two items named "Javascript file .." (see attached screenshot)
Comment 3 Stanislav Aubrecht 2014-02-26 09:27:36 UTC
The actual steps to reproduce is to choose 'Other - JavaScript File', then there are two 'JavaScript' items in the New menu.
Not sure where this belongs, please feel free to reassign, thanks.
Comment 4 Jaroslav Havlin 2014-05-30 12:49:19 UTC
(In reply to Stanislav Aubrecht from comment #3)
> Not sure where this belongs, please feel free to reassign, thanks.
I guess projects/Generic Infrastructure. Feel free to reassign again. Thank you.
Comment 5 Tomas Stupka 2014-07-23 12:13:42 UTC
the template path is used to recognize duplicates

maybe it would be enought for 
ClientSideProject.RecommendedAndPrivilegedTemplatesImpl.getPrivilegedTemplates()
to return Templates/Other/javascript.js
instead of registering Templates/ClientSide/javascript.js which points to the same resource and seems to duplicate Templates/Other/javascript.js

reassigning ...
Comment 6 Tomas Mysik 2014-07-24 06:17:57 UTC
The is a difference between these 2 new JS file wizards - the one from HTML5 category allows to specify source root (Site Root or Unit Tests folder if it is set); the one from Other category does not allow it. That is why this file is displayed twice. The same applies from other templates from HTML5 category.

Thanks for reporting.