[jira] [Commented] (NETBEANS-1792) Behavior of BooleanStateAction has changed

2019-05-13 Thread Thierry Danard (JIRA)


[ 
https://issues.apache.org/jira/browse/NETBEANS-1792?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16838923#comment-16838923
 ] 

Thierry Danard commented on NETBEANS-1792:
--

Pull request is [https://github.com/apache/netbeans/pull/1250]

> Behavior of BooleanStateAction has changed
> --
>
> Key: NETBEANS-1792
> URL: https://issues.apache.org/jira/browse/NETBEANS-1792
> Project: NetBeans
>  Issue Type: Bug
>  Components: platform - Actions
>Affects Versions: 10.0, 11.0
>Reporter: Thierry Danard
>Assignee: Svatopluk Dedic
>Priority: Major
>  Labels: pull-request-available
> Fix For: Next
>
> Attachments: DemoNetBeans1792.zip, image-2018-12-10-19-26-40-055.png, 
> image-2018-12-11-09-23-24-408.png, image-2018-12-11-09-47-54-474.png
>
>  Time Spent: 10m
>  Remaining Estimate: 0h
>
> I used the latest release candidate of NetBeans 10 (vc4), and found that 
> BooleanStateAction fires two "booleanState" events instead of one when a 
> button backed by a BooleanStateAction is pressed, the first event reporting 
> that the state is changing to "true", the second event reporting that the 
> state is changing back to "false" (even though the button is still showing as 
> "pressed")
> In my case, this BooleanStateAction is inside a JToolbar.
> javax.swing.JToolBar toolbar = new JToolBar();
>  toolbar.setFloatable(false);
>  toolbar.setRollover(true);
> Component tp1 = 
> SystemAction.get(MyBooleanStateAction1.class).getToolbarPresenter();
>  Component tp2 = 
> SystemAction.get(MyBooleanStateAction2.class).getToolbarPresenter();
>  Component tp3 = 
> SystemAction.get(MyBooleanStateAction3.class).getToolbarPresenter();
> tp1.setFocusable(false);
>  tp2.setFocusable(false);
>  tp3.setFocusable(false);
> toolbar.add(tp1);
>  toolbar.add(tp2);
>  toolbar.add(tp3);
> JPanel toolbarPanel = new JPanel(new BorderLayout());
>  toolbarPanel.add(toolbar, BorderLayout.WEST);
>  
> This is a breaking change, it was working just fine in NetBeans 9. It breaks 
> a lot of code in my app as I rely on the booleanState event to enable to 
> disable behaviors: right now, when a user clicks a button, it shows as 
> "pressed", but the associated function gets disabled right after it gets 
> enabled.
> I wasn't able to find a root cause after running from NetBeans source.
> I did note that the BooleanStateAction is deprecated.
> I'll try to provide a sample code to reproduce.
>  



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

-
To unsubscribe, e-mail: commits-unsubscr...@netbeans.apache.org
For additional commands, e-mail: commits-h...@netbeans.apache.org

For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists



[jira] [Updated] (NETBEANS-1792) Behavior of BooleanStateAction has changed

2019-05-13 Thread ASF GitHub Bot (JIRA)


 [ 
https://issues.apache.org/jira/browse/NETBEANS-1792?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

ASF GitHub Bot updated NETBEANS-1792:
-
Labels: pull-request-available  (was: )

> Behavior of BooleanStateAction has changed
> --
>
> Key: NETBEANS-1792
> URL: https://issues.apache.org/jira/browse/NETBEANS-1792
> Project: NetBeans
>  Issue Type: Bug
>  Components: platform - Actions
>Affects Versions: 10.0, 11.0
>Reporter: Thierry Danard
>Assignee: Svatopluk Dedic
>Priority: Major
>  Labels: pull-request-available
> Fix For: Next
>
> Attachments: DemoNetBeans1792.zip, image-2018-12-10-19-26-40-055.png, 
> image-2018-12-11-09-23-24-408.png, image-2018-12-11-09-47-54-474.png
>
>
> I used the latest release candidate of NetBeans 10 (vc4), and found that 
> BooleanStateAction fires two "booleanState" events instead of one when a 
> button backed by a BooleanStateAction is pressed, the first event reporting 
> that the state is changing to "true", the second event reporting that the 
> state is changing back to "false" (even though the button is still showing as 
> "pressed")
> In my case, this BooleanStateAction is inside a JToolbar.
> javax.swing.JToolBar toolbar = new JToolBar();
>  toolbar.setFloatable(false);
>  toolbar.setRollover(true);
> Component tp1 = 
> SystemAction.get(MyBooleanStateAction1.class).getToolbarPresenter();
>  Component tp2 = 
> SystemAction.get(MyBooleanStateAction2.class).getToolbarPresenter();
>  Component tp3 = 
> SystemAction.get(MyBooleanStateAction3.class).getToolbarPresenter();
> tp1.setFocusable(false);
>  tp2.setFocusable(false);
>  tp3.setFocusable(false);
> toolbar.add(tp1);
>  toolbar.add(tp2);
>  toolbar.add(tp3);
> JPanel toolbarPanel = new JPanel(new BorderLayout());
>  toolbarPanel.add(toolbar, BorderLayout.WEST);
>  
> This is a breaking change, it was working just fine in NetBeans 9. It breaks 
> a lot of code in my app as I rely on the booleanState event to enable to 
> disable behaviors: right now, when a user clicks a button, it shows as 
> "pressed", but the associated function gets disabled right after it gets 
> enabled.
> I wasn't able to find a root cause after running from NetBeans source.
> I did note that the BooleanStateAction is deprecated.
> I'll try to provide a sample code to reproduce.
>  



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

-
To unsubscribe, e-mail: commits-unsubscr...@netbeans.apache.org
For additional commands, e-mail: commits-h...@netbeans.apache.org

For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists



[jira] [Created] (NETBEANS-2543) File names clipped in Files window

2019-05-13 Thread Geo B (JIRA)
Geo B created NETBEANS-2543:
---

 Summary: File names clipped in Files window
 Key: NETBEANS-2543
 URL: https://issues.apache.org/jira/browse/NETBEANS-2543
 Project: NetBeans
  Issue Type: Improvement
  Components: platform - Output Window
Affects Versions: 11.0, 10.0, 9.0
 Environment: Windows Pro 10 1809, HP 500-210qe
Reporter: Geo B
 Attachments: netbeans_display.jpg

File name extensions appear clipped in Files window. For example, files with 
extension `.yaml` may appear as .yaml, .yam or .yar. See attached screen grab.




--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

-
To unsubscribe, e-mail: commits-unsubscr...@netbeans.apache.org
For additional commands, e-mail: commits-h...@netbeans.apache.org

For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists



[jira] [Commented] (NETBEANS-1792) Behavior of BooleanStateAction has changed

2019-05-13 Thread Thierry Danard (JIRA)


[ 
https://issues.apache.org/jira/browse/NETBEANS-1792?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16838890#comment-16838890
 ] 

Thierry Danard commented on NETBEANS-1792:
--

I can provide a patch.

> Behavior of BooleanStateAction has changed
> --
>
> Key: NETBEANS-1792
> URL: https://issues.apache.org/jira/browse/NETBEANS-1792
> Project: NetBeans
>  Issue Type: Bug
>  Components: platform - Actions
>Affects Versions: 10.0, 11.0
>Reporter: Thierry Danard
>Assignee: Svatopluk Dedic
>Priority: Major
> Fix For: Next
>
> Attachments: DemoNetBeans1792.zip, image-2018-12-10-19-26-40-055.png, 
> image-2018-12-11-09-23-24-408.png, image-2018-12-11-09-47-54-474.png
>
>
> I used the latest release candidate of NetBeans 10 (vc4), and found that 
> BooleanStateAction fires two "booleanState" events instead of one when a 
> button backed by a BooleanStateAction is pressed, the first event reporting 
> that the state is changing to "true", the second event reporting that the 
> state is changing back to "false" (even though the button is still showing as 
> "pressed")
> In my case, this BooleanStateAction is inside a JToolbar.
> javax.swing.JToolBar toolbar = new JToolBar();
>  toolbar.setFloatable(false);
>  toolbar.setRollover(true);
> Component tp1 = 
> SystemAction.get(MyBooleanStateAction1.class).getToolbarPresenter();
>  Component tp2 = 
> SystemAction.get(MyBooleanStateAction2.class).getToolbarPresenter();
>  Component tp3 = 
> SystemAction.get(MyBooleanStateAction3.class).getToolbarPresenter();
> tp1.setFocusable(false);
>  tp2.setFocusable(false);
>  tp3.setFocusable(false);
> toolbar.add(tp1);
>  toolbar.add(tp2);
>  toolbar.add(tp3);
> JPanel toolbarPanel = new JPanel(new BorderLayout());
>  toolbarPanel.add(toolbar, BorderLayout.WEST);
>  
> This is a breaking change, it was working just fine in NetBeans 9. It breaks 
> a lot of code in my app as I rely on the booleanState event to enable to 
> disable behaviors: right now, when a user clicks a button, it shows as 
> "pressed", but the associated function gets disabled right after it gets 
> enabled.
> I wasn't able to find a root cause after running from NetBeans source.
> I did note that the BooleanStateAction is deprecated.
> I'll try to provide a sample code to reproduce.
>  



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

-
To unsubscribe, e-mail: commits-unsubscr...@netbeans.apache.org
For additional commands, e-mail: commits-h...@netbeans.apache.org

For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists



[jira] [Commented] (NETBEANS-1792) Behavior of BooleanStateAction has changed

2019-05-13 Thread Geertjan Wielenga (JIRA)


[ 
https://issues.apache.org/jira/browse/NETBEANS-1792?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16838867#comment-16838867
 ] 

Geertjan Wielenga commented on NETBEANS-1792:
-

Thierry, since you have the fix, what’s stopping you from providing a patch?

> Behavior of BooleanStateAction has changed
> --
>
> Key: NETBEANS-1792
> URL: https://issues.apache.org/jira/browse/NETBEANS-1792
> Project: NetBeans
>  Issue Type: Bug
>  Components: platform - Actions
>Affects Versions: 10.0, 11.0
>Reporter: Thierry Danard
>Assignee: Svatopluk Dedic
>Priority: Major
> Fix For: Next
>
> Attachments: DemoNetBeans1792.zip, image-2018-12-10-19-26-40-055.png, 
> image-2018-12-11-09-23-24-408.png, image-2018-12-11-09-47-54-474.png
>
>
> I used the latest release candidate of NetBeans 10 (vc4), and found that 
> BooleanStateAction fires two "booleanState" events instead of one when a 
> button backed by a BooleanStateAction is pressed, the first event reporting 
> that the state is changing to "true", the second event reporting that the 
> state is changing back to "false" (even though the button is still showing as 
> "pressed")
> In my case, this BooleanStateAction is inside a JToolbar.
> javax.swing.JToolBar toolbar = new JToolBar();
>  toolbar.setFloatable(false);
>  toolbar.setRollover(true);
> Component tp1 = 
> SystemAction.get(MyBooleanStateAction1.class).getToolbarPresenter();
>  Component tp2 = 
> SystemAction.get(MyBooleanStateAction2.class).getToolbarPresenter();
>  Component tp3 = 
> SystemAction.get(MyBooleanStateAction3.class).getToolbarPresenter();
> tp1.setFocusable(false);
>  tp2.setFocusable(false);
>  tp3.setFocusable(false);
> toolbar.add(tp1);
>  toolbar.add(tp2);
>  toolbar.add(tp3);
> JPanel toolbarPanel = new JPanel(new BorderLayout());
>  toolbarPanel.add(toolbar, BorderLayout.WEST);
>  
> This is a breaking change, it was working just fine in NetBeans 9. It breaks 
> a lot of code in my app as I rely on the booleanState event to enable to 
> disable behaviors: right now, when a user clicks a button, it shows as 
> "pressed", but the associated function gets disabled right after it gets 
> enabled.
> I wasn't able to find a root cause after running from NetBeans source.
> I did note that the BooleanStateAction is deprecated.
> I'll try to provide a sample code to reproduce.
>  



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

-
To unsubscribe, e-mail: commits-unsubscr...@netbeans.apache.org
For additional commands, e-mail: commits-h...@netbeans.apache.org

For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists



[jira] [Commented] (NETBEANS-1792) Behavior of BooleanStateAction has changed

2019-05-13 Thread Geertjan Wielenga (JIRA)


[ 
https://issues.apache.org/jira/browse/NETBEANS-1792?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16838866#comment-16838866
 ] 

Geertjan Wielenga commented on NETBEANS-1792:
-

Svata, what must be done to fix this? Is it an easy fix, will you do it? Or 
what do you recommend?

> Behavior of BooleanStateAction has changed
> --
>
> Key: NETBEANS-1792
> URL: https://issues.apache.org/jira/browse/NETBEANS-1792
> Project: NetBeans
>  Issue Type: Bug
>  Components: platform - Actions
>Affects Versions: 10.0, 11.0
>Reporter: Thierry Danard
>Assignee: Svatopluk Dedic
>Priority: Major
> Fix For: Next
>
> Attachments: DemoNetBeans1792.zip, image-2018-12-10-19-26-40-055.png, 
> image-2018-12-11-09-23-24-408.png, image-2018-12-11-09-47-54-474.png
>
>
> I used the latest release candidate of NetBeans 10 (vc4), and found that 
> BooleanStateAction fires two "booleanState" events instead of one when a 
> button backed by a BooleanStateAction is pressed, the first event reporting 
> that the state is changing to "true", the second event reporting that the 
> state is changing back to "false" (even though the button is still showing as 
> "pressed")
> In my case, this BooleanStateAction is inside a JToolbar.
> javax.swing.JToolBar toolbar = new JToolBar();
>  toolbar.setFloatable(false);
>  toolbar.setRollover(true);
> Component tp1 = 
> SystemAction.get(MyBooleanStateAction1.class).getToolbarPresenter();
>  Component tp2 = 
> SystemAction.get(MyBooleanStateAction2.class).getToolbarPresenter();
>  Component tp3 = 
> SystemAction.get(MyBooleanStateAction3.class).getToolbarPresenter();
> tp1.setFocusable(false);
>  tp2.setFocusable(false);
>  tp3.setFocusable(false);
> toolbar.add(tp1);
>  toolbar.add(tp2);
>  toolbar.add(tp3);
> JPanel toolbarPanel = new JPanel(new BorderLayout());
>  toolbarPanel.add(toolbar, BorderLayout.WEST);
>  
> This is a breaking change, it was working just fine in NetBeans 9. It breaks 
> a lot of code in my app as I rely on the booleanState event to enable to 
> disable behaviors: right now, when a user clicks a button, it shows as 
> "pressed", but the associated function gets disabled right after it gets 
> enabled.
> I wasn't able to find a root cause after running from NetBeans source.
> I did note that the BooleanStateAction is deprecated.
> I'll try to provide a sample code to reproduce.
>  



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

-
To unsubscribe, e-mail: commits-unsubscr...@netbeans.apache.org
For additional commands, e-mail: commits-h...@netbeans.apache.org

For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists



[jira] [Updated] (NETBEANS-1792) Behavior of BooleanStateAction has changed

2019-05-13 Thread Thierry Danard (JIRA)


 [ 
https://issues.apache.org/jira/browse/NETBEANS-1792?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Thierry Danard updated NETBEANS-1792:
-
Affects Version/s: 11.0

> Behavior of BooleanStateAction has changed
> --
>
> Key: NETBEANS-1792
> URL: https://issues.apache.org/jira/browse/NETBEANS-1792
> Project: NetBeans
>  Issue Type: Bug
>  Components: platform - Actions
>Affects Versions: 10.0, 11.0
>Reporter: Thierry Danard
>Assignee: Svatopluk Dedic
>Priority: Major
> Fix For: Next
>
> Attachments: DemoNetBeans1792.zip, image-2018-12-10-19-26-40-055.png, 
> image-2018-12-11-09-23-24-408.png, image-2018-12-11-09-47-54-474.png
>
>
> I used the latest release candidate of NetBeans 10 (vc4), and found that 
> BooleanStateAction fires two "booleanState" events instead of one when a 
> button backed by a BooleanStateAction is pressed, the first event reporting 
> that the state is changing to "true", the second event reporting that the 
> state is changing back to "false" (even though the button is still showing as 
> "pressed")
> In my case, this BooleanStateAction is inside a JToolbar.
> javax.swing.JToolBar toolbar = new JToolBar();
>  toolbar.setFloatable(false);
>  toolbar.setRollover(true);
> Component tp1 = 
> SystemAction.get(MyBooleanStateAction1.class).getToolbarPresenter();
>  Component tp2 = 
> SystemAction.get(MyBooleanStateAction2.class).getToolbarPresenter();
>  Component tp3 = 
> SystemAction.get(MyBooleanStateAction3.class).getToolbarPresenter();
> tp1.setFocusable(false);
>  tp2.setFocusable(false);
>  tp3.setFocusable(false);
> toolbar.add(tp1);
>  toolbar.add(tp2);
>  toolbar.add(tp3);
> JPanel toolbarPanel = new JPanel(new BorderLayout());
>  toolbarPanel.add(toolbar, BorderLayout.WEST);
>  
> This is a breaking change, it was working just fine in NetBeans 9. It breaks 
> a lot of code in my app as I rely on the booleanState event to enable to 
> disable behaviors: right now, when a user clicks a button, it shows as 
> "pressed", but the associated function gets disabled right after it gets 
> enabled.
> I wasn't able to find a root cause after running from NetBeans source.
> I did note that the BooleanStateAction is deprecated.
> I'll try to provide a sample code to reproduce.
>  



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

-
To unsubscribe, e-mail: commits-unsubscr...@netbeans.apache.org
For additional commands, e-mail: commits-h...@netbeans.apache.org

For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists



[jira] [Commented] (NETBEANS-1792) Behavior of BooleanStateAction has changed

2019-05-13 Thread Thierry Danard (JIRA)


[ 
https://issues.apache.org/jira/browse/NETBEANS-1792?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16838863#comment-16838863
 ] 

Thierry Danard commented on NETBEANS-1792:
--

This issue is also present in NetBeans 11

> Behavior of BooleanStateAction has changed
> --
>
> Key: NETBEANS-1792
> URL: https://issues.apache.org/jira/browse/NETBEANS-1792
> Project: NetBeans
>  Issue Type: Bug
>  Components: platform - Actions
>Affects Versions: 10.0
>Reporter: Thierry Danard
>Assignee: Svatopluk Dedic
>Priority: Major
> Fix For: Next
>
> Attachments: DemoNetBeans1792.zip, image-2018-12-10-19-26-40-055.png, 
> image-2018-12-11-09-23-24-408.png, image-2018-12-11-09-47-54-474.png
>
>
> I used the latest release candidate of NetBeans 10 (vc4), and found that 
> BooleanStateAction fires two "booleanState" events instead of one when a 
> button backed by a BooleanStateAction is pressed, the first event reporting 
> that the state is changing to "true", the second event reporting that the 
> state is changing back to "false" (even though the button is still showing as 
> "pressed")
> In my case, this BooleanStateAction is inside a JToolbar.
> javax.swing.JToolBar toolbar = new JToolBar();
>  toolbar.setFloatable(false);
>  toolbar.setRollover(true);
> Component tp1 = 
> SystemAction.get(MyBooleanStateAction1.class).getToolbarPresenter();
>  Component tp2 = 
> SystemAction.get(MyBooleanStateAction2.class).getToolbarPresenter();
>  Component tp3 = 
> SystemAction.get(MyBooleanStateAction3.class).getToolbarPresenter();
> tp1.setFocusable(false);
>  tp2.setFocusable(false);
>  tp3.setFocusable(false);
> toolbar.add(tp1);
>  toolbar.add(tp2);
>  toolbar.add(tp3);
> JPanel toolbarPanel = new JPanel(new BorderLayout());
>  toolbarPanel.add(toolbar, BorderLayout.WEST);
>  
> This is a breaking change, it was working just fine in NetBeans 9. It breaks 
> a lot of code in my app as I rely on the booleanState event to enable to 
> disable behaviors: right now, when a user clicks a button, it shows as 
> "pressed", but the associated function gets disabled right after it gets 
> enabled.
> I wasn't able to find a root cause after running from NetBeans source.
> I did note that the BooleanStateAction is deprecated.
> I'll try to provide a sample code to reproduce.
>  



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

-
To unsubscribe, e-mail: commits-unsubscr...@netbeans.apache.org
For additional commands, e-mail: commits-h...@netbeans.apache.org

For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists



[jira] [Created] (NETBEANS-2542) Find in project should set Containing Text from the selected text in Output

2019-05-13 Thread Eduardo Quintanilla (JIRA)
Eduardo Quintanilla created NETBEANS-2542:
-

 Summary: Find in project should set Containing Text from the 
selected text in Output
 Key: NETBEANS-2542
 URL: https://issues.apache.org/jira/browse/NETBEANS-2542
 Project: NetBeans
  Issue Type: Improvement
  Components: utilities - Search
Affects Versions: 11.0
Reporter: Eduardo Quintanilla


Find in project should set _Containing Text_  field from the selected text in 
Output panels

 

*Steps to reproduce:*
 # Open Netbeans IDE 11 with JDK 1.
 #  Create New Project
 # Select Samples => Anagram Game
 # Execute build
 #  Inside the Output tab select BUILD SUCCESSFUL
 #  Open Find in Project (CTRL + SHIFT + F)
 # Find in Projects dialog is shown with the field Containing Text empty.

*Expected result*

_The Find in Projects_ dialog sets the value of _Containing Text_ field from 
the selected text from output panels as it does with selected text from the 
text editor.

 

*Environment*
*Product Version:*
Apache NetBeans IDE Dev (Build 20190509-ed8596836955)

*Java:*
1.8.0_191; Java HotSpot(TM) 64-Bit Server VM 25.191-b12

*Runtime:*
Java(TM) SE Runtime Environment 1.8.0_191-b12

*System:* Windows 10 version 10.0 running on amd64; Cp1252; en_US (nb)



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

-
To unsubscribe, e-mail: commits-unsubscr...@netbeans.apache.org
For additional commands, e-mail: commits-h...@netbeans.apache.org

For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists



[jira] [Commented] (NETBEANS-2221) ClassCastException when try to open class from not opened module

2019-05-13 Thread Mark Herkrath (JIRA)


[ 
https://issues.apache.org/jira/browse/NETBEANS-2221?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16838628#comment-16838628
 ] 

Mark Herkrath commented on NETBEANS-2221:
-

I am running into the same issue all the time and have done some analysis:

Code of {{org.netbeans.modules.java.source.builder.TreeFactory}}, where the 
ClassCastException happens:
{code:java}
public ExpressionTree Type(TypeMirror type) {
Type t = (Type) type;
JCExpression tp;
switch (type.getKind()) {
...
case ERROR:
tp = make.at(NOPOS).Ident(((ErrorType) type).tsym.name);
break;
default:
return make.at(NOPOS).Type((Type)type);
}

return tp.setType(t);
}  {code}
The getKind() implementation of ClassType used to always return DECLARED. 
However since Java 11, the getKind() implementation of ClassType has been 
changed:
{code:java}
   @DefinedBy(Api.LANGUAGE_MODEL)
public TypeKind getKind() {
tsym.apiComplete();
return tsym.kind == TYP ? TypeKind.DECLARED : TypeKind.ERROR;
} {code}
See [http://hg.openjdk.java.net/jdk/jdk/rev/cc2673fa8c20] due to 
[https://bugs.openjdk.java.net/browse/JDK-8187950]

As a result, the cast to ErrorType for getKind() == ERROR isn't always valid 
anymore. The strange thing is that I get the same error with Java 8u212 by 
Oracle (i.e. NB is running with that version and the Java version of my project 
is also set accordingly). Maybe it was back-ported but it's not clear to me if 
their com.sun.tools sources are publicly accessible somewhere. I don't see that 
change in the Java 8 release notes. Alternatively, NetBeans is using Java 11 
for de-compilation for whatever reason. I have at least added it as a Java 
Platform.

> ClassCastException when try to open class from not opened module
> 
>
> Key: NETBEANS-2221
> URL: https://issues.apache.org/jira/browse/NETBEANS-2221
> Project: NetBeans
>  Issue Type: Bug
>Affects Versions: 11.0
>Reporter: Tomas Huryn
>Priority: Major
>
> When I try to open a class from project which has not been opened before I 
> get the exception:
> WARNING [org.openide.filesystems.Ordering]: Not all children in / marked with 
> the position attribute: 
> [org-netbeans-modules-lsp-client-bindings-HyperlinkProviderImpl.instance], 
> but some are: [HyperlinkProviderImpl.instance, 
> org-netbeans-modules-editor-url-HyperlinkImpl.instance]
> WARNING [org.netbeans.modules.parsing.impl.TaskProcessor]: 
> ParserManager.parse called in AWT event thread by: 
> org.netbeans.modules.java.classfile.CodeGenerator.generateCode(CodeGenerator.java:152)
> Even though the source level of  is set to: 11, java.util.zip.CRC32C cannot 
> be found on the system module path: 
> Changing source level to 1.8
> SEVERE [global]
> java.lang.ClassCastException: class com.sun.tools.javac.code.Type$ClassType 
> cannot be cast to class com.sun.tools.javac.code.Type$ErrorType 
> (com.sun.tools.javac.code.Type$ClassType and 
> com.sun.tools.javac.code.Type$ErrorType are in unnamed module of loader 
> org.netbeans.StandardModule$OneModuleClassLoader @4f09236a)
>     at 
> org.netbeans.modules.java.source.builder.TreeFactory.Type(TreeFactory.java:863)
>     at org.netbeans.api.java.source.TreeMaker.Type(TreeMaker.java:1119)
>     at 
> org.netbeans.modules.java.classfile.CodeGenerator$TreeBuilder.computeAnnotationTree(CodeGenerator.java:449)
>     at 
> org.netbeans.modules.java.classfile.CodeGenerator$TreeBuilder.computeMods(CodeGenerator.java:411)
>     at 
> org.netbeans.modules.java.classfile.CodeGenerator$TreeBuilder.visitType(CodeGenerator.java:373)
>     at 
> org.netbeans.modules.java.classfile.CodeGenerator$TreeBuilder.visitType(CodeGenerator.java:285)
>     at com.sun.tools.javac.code.Symbol$ClassSymbol.accept(Symbol.java:1473)
>     at 
> javax.lang.model.util.AbstractElementVisitor6.visit(AbstractElementVisitor6.java:106)
>     at 
> org.netbeans.modules.java.classfile.CodeGenerator.generateCode(CodeGenerator.java:275)
>     at 
> org.netbeans.modules.java.classfile.CodeGenerator$1.run(CodeGenerator.java:232)
>     at 
> org.netbeans.modules.java.classfile.CodeGenerator$1.run(CodeGenerator.java:152)
>     at org.netbeans.api.java.source.JavaSource$1.run(JavaSource.java:672)
>     at org.netbeans.api.java.source.JavaSource$1.run(JavaSource.java:662)
>     at 
> org.netbeans.api.java.source.JavaSource$MultiTask.run(JavaSource.java:501)
>     at 
> org.netbeans.modules.parsing.impl.TaskProcessor.callUserTask(TaskProcessor.java:586)
>     at 
> org.netbeans.modules.parsing.api.ParserManager$UserTaskAction.run(ParserManager.java:130)
>     at 
> org.netbeans.modules.parsing.api.ParserManager$UserTaskAction.run(ParserManager.java:114)
>    

[jira] [Created] (NETBEANS-2541) Variables used in annotations display as unused.

2019-05-13 Thread Mark Claassen (JIRA)
Mark Claassen created NETBEANS-2541:
---

 Summary: Variables used in annotations display as unused.
 Key: NETBEANS-2541
 URL: https://issues.apache.org/jira/browse/NETBEANS-2541
 Project: NetBeans
  Issue Type: Bug
  Components: editor - Hints  Annotations
Affects Versions: 11.0
 Environment: Product Version: Apache NetBeans IDE 11.0 (Build 
incubator-netbeans-release-404-on-20190319)
Java: 12; Java HotSpot(TM) 64-Bit Server VM 12+33
Runtime: Java(TM) SE Runtime Environment 12+33
System: Windows 10 version 10.0 running on amd64; Cp1252; en_US (nb)
Reporter: Mark Claassen


In the following class, VALUE1 and VALUE2 are underlined by the editor as 
unused, but they are used in the annotations.

public class Tester {
    private static final String VALUE1="unchecked";
    private static final String VALUE2="unchecked";
    public Tester() {
        
    }
    @SuppressWarnings(VALUE1)
    public void test(@SuppressWarnings(VALUE2) String s) {
        
    }
}



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

-
To unsubscribe, e-mail: commits-unsubscr...@netbeans.apache.org
For additional commands, e-mail: commits-h...@netbeans.apache.org

For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists



[jira] [Assigned] (NETBEANS-1561) Reproducible NullPointerException at Refactor-Move in Java Modular Project breaks refactoring

2019-05-13 Thread Reema Taneja (JIRA)


 [ 
https://issues.apache.org/jira/browse/NETBEANS-1561?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Reema Taneja reassigned NETBEANS-1561:
--

Assignee: Reema Taneja

> Reproducible NullPointerException at Refactor-Move in Java Modular Project 
> breaks refactoring
> -
>
> Key: NETBEANS-1561
> URL: https://issues.apache.org/jira/browse/NETBEANS-1561
> Project: NetBeans
>  Issue Type: Bug
>  Components: java - Refactoring
>Affects Versions: 9.0, 10.0
>Reporter: Andreas Eckstein
>Assignee: Reema Taneja
>Priority: Major
>  Labels: ca_survey
> Attachments: testProject1.zip
>
>
> _(Edit: When reporting this first, I neglected to mention that in certain 
> situations when this NullPointerException is triggered, refactoring is 
> actually broken.)_
>  
> I found a reproducible case of NullPointerException when trying to 
> refactor-move a class. In the attached testProject1, each module contains two 
> classes. In mod1a, class Test1A2.java can be moved to package mod1a.pkg 
> without issue. Trying the same thing in mod1b with Test1B2.java results in an 
> exception.
> *Importantly, I can still select 'Refactor' afterwards, but the classes just 
> are moved without refactoring.*
> Not sure what triggers this, but simpler projects with less class/module 
> relations seem to work fine.
> Platform:
> Linux x86_64
> openjdk version "11.0.1" 2018-10-16
> NetBeans-dev-incubator-netbeans-linux-882-on-20181025-release.zip
> (I've seen this error since Netbeans 9.0/JDK9)



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

-
To unsubscribe, e-mail: commits-unsubscr...@netbeans.apache.org
For additional commands, e-mail: commits-h...@netbeans.apache.org

For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists



[jira] [Commented] (NETBEANS-1320) Could not debug node.js application from IDE

2019-05-13 Thread Andre Schild (JIRA)


[ 
https://issues.apache.org/jira/browse/NETBEANS-1320?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16838291#comment-16838291
 ] 

Andre Schild commented on NETBEANS-1320:


Unfortunally not only.

The v8 uses another protocoll for debugging, so it's more than just a config 
option in the gui

> Could not debug node.js application from IDE
> 
>
> Key: NETBEANS-1320
> URL: https://issues.apache.org/jira/browse/NETBEANS-1320
> Project: NetBeans
>  Issue Type: Bug
>  Components: javascript - Node.js
>Affects Versions: 9.0, 10.0
>Reporter: Apostolos Katranitsas
>Priority: Major
>
> Could not debug node.js application because option --debug[-brk] has changed 
> to --inspect[-brk] since node.js version 8.
> Also I don't know if the --inspect[-brk] options is working the same as the 
> --debug[-brk] option.
>  
> The file in question is the 
> [NodeExecutable.java|http://hg.netbeans.org/main/file/tip/javascript.nodejs/src/org/netbeans/modules/javascript/nodejs/exec/NodeExecutable.java].
> As the options is hard coded in the file, someone could alter the text of the 
> option or detect if node.js version is >= 8 then use the inspect option.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

-
To unsubscribe, e-mail: commits-unsubscr...@netbeans.apache.org
For additional commands, e-mail: commits-h...@netbeans.apache.org

For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists