public void update(final AnActionEvent e) {
   super.update(e);
   final PatternDialectProvider provider =
       PatternDialectProvider.getInstance(mySettings.SCOPE_TYPE);
   e.getPresentation().setText(provider.getDisplayName());
   e.getPresentation().setIcon(provider.getIcon());
 }
 @NotNull
 protected DefaultActionGroup createPopupActionGroup(final JComponent button) {
   final DefaultActionGroup group = new DefaultActionGroup();
   for (final PatternDialectProvider provider :
       Extensions.getExtensions(PatternDialectProvider.EP_NAME)) {
     group.add(
         new AnAction(provider.getDisplayName()) {
           public void actionPerformed(final AnActionEvent e) {
             mySettings.SCOPE_TYPE = provider.getShortName();
             DependencyUISettings.getInstance().SCOPE_TYPE = provider.getShortName();
             rebuild();
           }
         });
   }
   return group;
 }