History | Log In     View a printable version of the current page.  
Issue Details (XML | Word | Printable)

Key: IDEA-17215
Type: Bug Bug
Status: Open Open
Assignee: Maxim Shafirov
Reporter: Rod Cheater
Votes: 0
Watchers: 0
Operations

If you were logged in you would be able to see more operations.
IDEA: Feedback

Add/remove braces intention actions are not working

Created: 21 Feb 08 02:53   Updated: 27 Feb 08 01:17
Component/s: Editor. Intention Actions

Build: 7,590
Severity: Medium


 Description  « Hide
I have code like this:
for (EnvironmentElement element : list) {
  result.add(element);
}

If I sit the carat after the opening brace I used (in version 5) to be able to choose 'Remove braces'. After upgrading to version 7 I now find that I can't.

Similarly for 'Add braces'.



 All   Comments   Work Log   Change History      Sort Order:
Dmitry Jemerov - 26 Feb 08 13:54
In our opinion, the annoyance caused by this intention accidentally triggering when you press Alt-Enter Enter is greater than its actual usefulness.

Bas Leijdekkers - 26 Feb 08 15:12
Note that "Add braces" is still available. If you position the text cursor on the "result.add(element);" statement the intention option will appear:
for (EnvironmentElement element : list)
  result.add(element);

Dmitry Jemerov - 26 Feb 08 15:19
Bas,

Actually we have problems with IPP intentions conflicting with JSIPP ones. We'll need to find some way to separate them cleanly.


Bas Leijdekkers - 26 Feb 08 15:39
What kind of problems? I rarely work on JavaScript code, so I had not noticed. Could it be caused by the fact that the JSIPP intentions have the same family name as the corresponding intention in IPP?

Rod Cheater - 27 Feb 08 01:17
Huh? I can't see how anyone could possibly accidently type alt+enter, enter. If you could, you could do it anywhere. Why is remove braces any more of a problem than any other intention action? Why can't you turn it on and off like other intentions anyway?

Didn't add braces use to work from the front of the control statement? IMO, that is a more logical place to try and invoke the action.