You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@netbeans.apache.org by GitBox <gi...@apache.org> on 2021/02/10 19:04:04 UTC

[GitHub] [netbeans] KacerCZ opened a new pull request #2755: [NETBEANS-5350] Improved Fix Uses dialog

KacerCZ opened a new pull request #2755:
URL: https://github.com/apache/netbeans/pull/2755


   https://issues.apache.org/jira/browse/NETBEANS-5350
   
   Added buttons "Change Nothing" and "Restore Defaults" to Fix Uses dialog.
   This is useful when user just wants to remove unused `use` statements or wants to fix only a few imports and dialog contains large number of items.
   
   Initial state  and state after "Restore Defaults":
   ![netbeans-5350-defaults](https://user-images.githubusercontent.com/4249184/107558004-97dfc800-6bda-11eb-9505-d848de4a0bd9.png)
   
   State after "Change Nothing":
   ![netbeans-5350-none](https://user-images.githubusercontent.com/4249184/107558011-99a98b80-6bda-11eb-8023-d1ffa8c02985.png)
   


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org

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


[GitHub] [netbeans] sdedic commented on a change in pull request #2755: [NETBEANS-5350] Improved Fix Uses dialog

Posted by GitBox <gi...@apache.org>.
sdedic commented on a change in pull request #2755:
URL: https://github.com/apache/netbeans/pull/2755#discussion_r599981673



##########
File path: php/php.editor/src/org/netbeans/modules/php/editor/actions/FixDuplicateImportStmts.java
##########
@@ -147,6 +154,60 @@ private static String getBundleString(String s) {
         return NbBundle.getMessage(FixDuplicateImportStmts.class, s);
     }
 
+    @NbBundle.Messages({
+        "ClearSuggestionsButton=Clear Suggestions",
+        "RestoreDefaultsButton=Restore Defaults"
+    })
+    private void initButtons(ImportData importData) {
+        int numberOfItems = importData.getItems().size();
+        defaultVariants = new ItemVariant[numberOfItems];
+        dontUseVariants = new ItemVariant[numberOfItems];
+        for (int i = 0; i < numberOfItems; i++) {
+            DataItem dataItem = importData.getItems().get(i);
+            defaultVariants[i] = dataItem.getDefaultVariant();
+            dontUseVariants[i] = dataItem.getDefaultVariant();
+            for (ItemVariant variant : dataItem.getVariants()) {
+                if (!variant.canBeUsed()) {

Review comment:
       this seem to also work for "Cannot be resolved" items...




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org

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


[GitHub] [netbeans] tmysik commented on pull request #2755: [NETBEANS-5350] Improved Fix Uses dialog

Posted by GitBox <gi...@apache.org>.
tmysik commented on pull request #2755:
URL: https://github.com/apache/netbeans/pull/2755#issuecomment-808070758


   @KacerCZ 
   Thanks for the explanation.
   
   @sdedic 
   Sváťo, feel free to comment the UI change, if needed.
   
   Thanks.
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org

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


[GitHub] [netbeans] KacerCZ commented on pull request #2755: [NETBEANS-5350] Improved Fix Uses dialog

Posted by GitBox <gi...@apache.org>.
KacerCZ commented on pull request #2755:
URL: https://github.com/apache/netbeans/pull/2755#issuecomment-808166216


   @sdedic I added mnemonics and verified tab order is exactly as you write.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org

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


[GitHub] [netbeans] junichi11 commented on pull request #2755: [NETBEANS-5350] Improved Fix Uses dialog

Posted by GitBox <gi...@apache.org>.
junichi11 commented on pull request #2755:
URL: https://github.com/apache/netbeans/pull/2755#issuecomment-808851537


   Yes :)


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org

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


[GitHub] [netbeans] tmysik commented on pull request #2755: [NETBEANS-5350] Improved Fix Uses dialog

Posted by GitBox <gi...@apache.org>.
tmysik commented on pull request #2755:
URL: https://github.com/apache/netbeans/pull/2755#issuecomment-806488896


   @KacerCZ
   
   Would it be possible to try the visual separation as Sváťa suggested?
   
   CC @sdedic
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org

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


[GitHub] [netbeans] KacerCZ commented on pull request #2755: [NETBEANS-5350] Improved Fix Uses dialog

Posted by GitBox <gi...@apache.org>.
KacerCZ commented on pull request #2755:
URL: https://github.com/apache/netbeans/pull/2755#issuecomment-795887157


   [PHP documentation](https://www.php.net/manual/en/language.namespaces.importing.php) uses "alias" or "import" for this usage of "use" statement.
   
   PHP editor has already "Fast Import" action which inserts "require"/"include" statements. It could be confusing for user.
   
   "Remove unused aliases" sounds good.


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org

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


[GitHub] [netbeans] tmysik merged pull request #2755: [NETBEANS-5350] Improved Fix Uses dialog

Posted by GitBox <gi...@apache.org>.
tmysik merged pull request #2755:
URL: https://github.com/apache/netbeans/pull/2755


   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org

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


[GitHub] [netbeans] tmysik commented on pull request #2755: [NETBEANS-5350] Improved Fix Uses dialog

Posted by GitBox <gi...@apache.org>.
tmysik commented on pull request #2755:
URL: https://github.com/apache/netbeans/pull/2755#issuecomment-808850995


   Just to be sure - PRs can be merged now, right? 😅 
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org

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


[GitHub] [netbeans] tmysik commented on pull request #2755: [NETBEANS-5350] Improved Fix Uses dialog

Posted by GitBox <gi...@apache.org>.
tmysik commented on pull request #2755:
URL: https://github.com/apache/netbeans/pull/2755#issuecomment-806496816


   @KacerCZ 
   
   I am not sure that I understand what this PR is solving exactly, what situation - can you please explain? When exactly I want to click any of those 2 new buttons?
   
   Looking into the ticket, I see:
   
   > When user wants to fix only import of one class using "Fix Uses" action, then he has to manually go through all popup menus and select "Don't use type".
   
   When, as a user, I want to fix import of only one class? What happens with the other imported classes?
   
   Thanks.
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org

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


[GitHub] [netbeans] junichi11 commented on pull request #2755: [NETBEANS-5350] Improved Fix Uses dialog

Posted by GitBox <gi...@apache.org>.
junichi11 commented on pull request #2755:
URL: https://github.com/apache/netbeans/pull/2755#issuecomment-808824805


   @tmysik Please feel free to merge it. Thanks.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org

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


[GitHub] [netbeans] KacerCZ commented on a change in pull request #2755: [NETBEANS-5350] Improved Fix Uses dialog

Posted by GitBox <gi...@apache.org>.
KacerCZ commented on a change in pull request #2755:
URL: https://github.com/apache/netbeans/pull/2755#discussion_r601837525



##########
File path: php/php.editor/src/org/netbeans/modules/php/editor/actions/Bundle.properties
##########
@@ -33,14 +33,14 @@ ImportChoices=Import choices:
 ToggleCommentAction_shortDescription=Toggle Comment
 toggle-comment=Toggle Comment
 
-FixDupImportStmts_Title=Fix Uses in Current Namespace
-FixDupImportStmts_IntroLbl=<html>Select the fully qualified name to use in the use statement.</html>
-FixDupImportStmts_Header=Use Statements:
+FixDupImportStmts_Title=Fix Imports in Current Namespace
+FixDupImportStmts_IntroLbl=<html>Select the fully qualified name to import.</html>
+FixDupImportStmts_Header=Import:
 FixDupImportStmts_Combo_ACSD=Choose appropriate fully qualified name
 FixDupImportStmts_Combo_Name_ACSD=Fully Qualified Names
-FixDupImportStmts_UnusedImports=&Remove unused uses
+FixDupImportStmts_UnusedImports=&Remove unused imports
 FixDupImportStmts_CannotResolve=<html><font color='#FF0000'>&lt;cannot be resolved&gt;
 FixDupImportStmts_NothingToFix=<nothing to fix>
-FixDupImportStmts_checkUnusedImports_a11y=Remove unused uses checkbox
+FixDupImportStmts_checkUnusedImports_a11y=Remove unused imports checkbox
 
-Actions/Source/org-netbeans-modules-php-editor-actions-FixUsesAction$GlobalAction.instance=Fix Uses...
\ No newline at end of file
+Actions/Source/org-netbeans-modules-php-editor-actions-FixUsesAction$GlobalAction.instance=Fix Uses...

Review comment:
       Changed.




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org

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


[GitHub] [netbeans] KacerCZ commented on pull request #2755: [NETBEANS-5350] Improved Fix Uses dialog

Posted by GitBox <gi...@apache.org>.
KacerCZ commented on pull request #2755:
URL: https://github.com/apache/netbeans/pull/2755#issuecomment-807481429


   I'll try to explain my use cases.
   
   I work on projects where classes and interfaces from root namespace are not imported.
   For example `\DateTime` or `\Countable` are never imported and fully qualified name is always used.
   Also there are other types which are not imported - typically objects passed only in constructor or classes used infrequently.
   This leads to situations where list of suggested imports contains types which I don't want to import.
   
   Running "Fix Uses" action just to sort existing and remove unused imports I have to change all suggestions to "Don't use type" one by one. "Clear Suggestions" button simplifies this change to one click.
   
   Another use case is when I want to import only a few of suggested types in existing code.
   Again "Clear Suggestions" changes all proposed changes to "Don't use type" and those few for import I change back to import manually. Types marked as "Don't use type" are left in source code without change and only the selected types are imported.
   Its useful in case class is used on many places in code - action replaces all occurrences with alias.
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org

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


[GitHub] [netbeans] sdedic commented on pull request #2755: [NETBEANS-5350] Improved Fix Uses dialog

Posted by GitBox <gi...@apache.org>.
sdedic commented on pull request #2755:
URL: https://github.com/apache/netbeans/pull/2755#issuecomment-808081153


   re visual separation - I think it's clear enough. I'd suggest to add mnemonics to the controls in the dialog, and check tab-order (combos > checkbox > buttons). Sorry :( I missed that earlier (again).
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org

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


[GitHub] [netbeans] sdedic commented on pull request #2755: [NETBEANS-5350] Improved Fix Uses dialog

Posted by GitBox <gi...@apache.org>.
sdedic commented on pull request #2755:
URL: https://github.com/apache/netbeans/pull/2755#issuecomment-795511605


   A few comments (gathered with a help of an UI experienced colleague). 
   Visual: The action buttons should be separated from the checbox by some visual spacing; like at least width of the button. They appear to be funcionally connected to the checkbox on the screenshot, which is not true.
   
   Wording:
   > Select fully qualified names to use in the use statement
   
   - Either select different work for "use" verb, or somehow highlight (bold, syntax-highlight) the "use" statement name. Similar in the checkbox "unused uses" ( -> unneeded **use** statements, unnecessary uses,...)
   
   - Don't use type  -- suggest that the type is not going to be used in the source; instead, the selection means 'do not produce use statement'. Consider rewording to "Do nothing" or "Skip"
   - Change nothing -- seems more like 'reset' or 'cance'. Consider other wording like "Clear suggestions", "Clear all actions".
   


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org

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


[GitHub] [netbeans] KacerCZ commented on pull request #2755: [NETBEANS-5350] Improved Fix Uses dialog

Posted by GitBox <gi...@apache.org>.
KacerCZ commented on pull request #2755:
URL: https://github.com/apache/netbeans/pull/2755#issuecomment-806076677


   @sdedic Tests are hopefully fixed.
   @tmysik Could you review this PR, please?


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org

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


[GitHub] [netbeans] KacerCZ commented on pull request #2755: [NETBEANS-5350] Improved Fix Uses dialog

Posted by GitBox <gi...@apache.org>.
KacerCZ commented on pull request #2755:
URL: https://github.com/apache/netbeans/pull/2755#issuecomment-808897913


   Thanks for the review.
   
   Please set 12.4 milestone.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org

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


[GitHub] [netbeans] KacerCZ commented on pull request #2755: [NETBEANS-5350] Improved Fix Uses dialog

Posted by GitBox <gi...@apache.org>.
KacerCZ commented on pull request #2755:
URL: https://github.com/apache/netbeans/pull/2755#issuecomment-799682053


   @junichi11 What is your opinion on naming "alias" vs "import"?
   


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org

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


[GitHub] [netbeans] tmysik commented on a change in pull request #2755: [NETBEANS-5350] Improved Fix Uses dialog

Posted by GitBox <gi...@apache.org>.
tmysik commented on a change in pull request #2755:
URL: https://github.com/apache/netbeans/pull/2755#discussion_r601243946



##########
File path: php/php.editor/src/org/netbeans/modules/php/editor/actions/Bundle.properties
##########
@@ -33,14 +33,14 @@ ImportChoices=Import choices:
 ToggleCommentAction_shortDescription=Toggle Comment
 toggle-comment=Toggle Comment
 
-FixDupImportStmts_Title=Fix Uses in Current Namespace
-FixDupImportStmts_IntroLbl=<html>Select the fully qualified name to use in the use statement.</html>
-FixDupImportStmts_Header=Use Statements:
+FixDupImportStmts_Title=Fix Imports in Current Namespace
+FixDupImportStmts_IntroLbl=<html>Select the fully qualified name to import.</html>
+FixDupImportStmts_Header=Import:
 FixDupImportStmts_Combo_ACSD=Choose appropriate fully qualified name
 FixDupImportStmts_Combo_Name_ACSD=Fully Qualified Names
-FixDupImportStmts_UnusedImports=&Remove unused uses
+FixDupImportStmts_UnusedImports=&Remove unused imports
 FixDupImportStmts_CannotResolve=<html><font color='#FF0000'>&lt;cannot be resolved&gt;
 FixDupImportStmts_NothingToFix=<nothing to fix>
-FixDupImportStmts_checkUnusedImports_a11y=Remove unused uses checkbox
+FixDupImportStmts_checkUnusedImports_a11y=Remove unused imports checkbox
 
-Actions/Source/org-netbeans-modules-php-editor-actions-FixUsesAction$GlobalAction.instance=Fix Uses...
\ No newline at end of file
+Actions/Source/org-netbeans-modules-php-editor-actions-FixUsesAction$GlobalAction.instance=Fix Uses...

Review comment:
       Perhaps better `Fix Imports...` then?
   




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org

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


[GitHub] [netbeans] KacerCZ commented on pull request #2755: [NETBEANS-5350] Improved Fix Uses dialog

Posted by GitBox <gi...@apache.org>.
KacerCZ commented on pull request #2755:
URL: https://github.com/apache/netbeans/pull/2755#issuecomment-808106189


   @sdedic "C" for "Clear Suggestions" and "D" for "Restore Defaults" is OK?


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org

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


[GitHub] [netbeans] KacerCZ commented on pull request #2755: [NETBEANS-5350] Improved Fix Uses dialog

Posted by GitBox <gi...@apache.org>.
KacerCZ commented on pull request #2755:
URL: https://github.com/apache/netbeans/pull/2755#issuecomment-807486101


   > Would it be possible to try the visual separation as Sváťa suggested?
   
   I made space between checkbox and buttons even larger.
   ![netbeans-5350-button-spacing](https://user-images.githubusercontent.com/4249184/112543448-10c76780-8db6-11eb-96fb-ae143dbcceed.png)
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org

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


[GitHub] [netbeans] KacerCZ commented on a change in pull request #2755: [NETBEANS-5350] Improved Fix Uses dialog

Posted by GitBox <gi...@apache.org>.
KacerCZ commented on a change in pull request #2755:
URL: https://github.com/apache/netbeans/pull/2755#discussion_r574001791



##########
File path: php/php.editor/src/org/netbeans/modules/php/editor/actions/FixDuplicateImportStmts.java
##########
@@ -147,6 +153,58 @@ private static String getBundleString(String s) {
         return NbBundle.getMessage(FixDuplicateImportStmts.class, s);
     }
 
+    @NbBundle.Messages({
+        "ChangeNothingButton=Change Nothing",
+        "RestoreDefaultsButton=Restore Defaults"
+    })
+    private void initButtons(ImportData importData) {
+        int numberOfItems = importData.getItems().size();
+        defaultVariants = new ItemVariant[numberOfItems];
+        dontUseVariants = new ItemVariant[numberOfItems];
+        for (int i = 0; i < numberOfItems; i++) {
+            DataItem dataItem = importData.getItems().get(i);
+            defaultVariants[i] = dataItem.getDefaultVariant();
+            dontUseVariants[i] = dataItem.getDefaultVariant();
+            for (ItemVariant variant : dataItem.getVariants()) {
+                if (!variant.canBeUsed()) {
+                    dontUseVariants[i] = variant;
+                }
+            }
+        }
+
+        JPanel buttonsPanel = new JPanel(new BorderLayout(5, 3));
+        bottomPanel.add(buttonsPanel, BorderLayout.LINE_END);

Review comment:
       I used same way as "Remove unused uses" is added to `bottomPanel`.
   I don't know why it was not created in designer.




----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org

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


[GitHub] [netbeans] KacerCZ commented on pull request #2755: [NETBEANS-5350] Improved Fix Uses dialog

Posted by GitBox <gi...@apache.org>.
KacerCZ commented on pull request #2755:
URL: https://github.com/apache/netbeans/pull/2755#issuecomment-803658644


   Original code used "import" so I decided to use it also in labels.
   
   Here are new dialogs with updated texts:
   ![netbeans-5350-2-defaults](https://user-images.githubusercontent.com/4249184/111920582-10fef480-8a90-11eb-8883-9b5037da3a00.png)
   ![netbeans-5350-2-none](https://user-images.githubusercontent.com/4249184/111920588-12c8b800-8a90-11eb-8315-e55f60c69f94.png)
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org

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


[GitHub] [netbeans] tmysik commented on pull request #2755: [NETBEANS-5350] Improved Fix Uses dialog

Posted by GitBox <gi...@apache.org>.
tmysik commented on pull request #2755:
URL: https://github.com/apache/netbeans/pull/2755#issuecomment-808201883


   @KacerCZ @junichi11 
   
   I would wait for Junichi for a couple of days and then merge; is that OK for you?
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org

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