package _VisualDVM.Passes.All;
import _VisualDVM.Global;
import _VisualDVM.Passes.Project.FilesMassPass;
import _VisualDVM.ProjectData.Files.DBProjectFile;
import _VisualDVM.ProjectData.Files.LanguageStyle;
public class SetSelectedFilesStyle extends FilesMassPass<LanguageStyle> {
    @Override
    protected boolean canStart(Object... args) throws Exception {
        if (super.canStart(args)) {
            target = (LanguageStyle) args[0];
            return true;
        }
        return false;
    }
    @Override
    protected void operation(DBProjectFile file) {
        file.UpdateStyle(target);
        if (Global.mainModule.HasFile() && file.file.equals(Global.mainModule.getFile().file))
            file.form.ShowStyle();
    }
}
