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:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]
For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists