<commit_before>package eu.modelwriter.configuration.alloy2emf;

import org.eclipse.core.runtime.Platform;
import org.eclipse.jface.wizard.IWizardPage;
import org.eclipse.swt.SWT;
import org.eclipse.swt.events.SelectionAdapter;
import org.eclipse.swt.events.SelectionEvent;
import org.eclipse.swt.events.SelectionListener;
import org.eclipse.swt.layout.GridData;
import org.eclipse.swt.layout.GridLayout;
import org.eclipse.swt.widgets.Button;
import org.eclipse.swt.widgets.Composite;
import org.eclipse.swt.widgets.FileDialog;
import org.eclipse.swt.widgets.Label;

public class FinishPage extends AlloyToEMFWizardPage {

  private boolean backButtonEnabled = true;
  private Composite container;
  private Button checkbox;

  protected FinishPage() {
    super("lastpage");
    setTitle("Finish");
  }

  @Override
  public void createControl(Composite parent) {
    container = new Composite(parent, SWT.NULL);
    container.setLayout(new GridLayout(2, false));
    for (String alias : alloyToEMF.getAliases()) {
      Label label = new Label(container, SWT.NONE);
      label.setLayoutData(new GridData(SWT.LEFT, SWT.TOP, false, false));
      label.setText("Select save location for " + alias + " \n");
      Button button = new Button(container, SWT.PUSH);
      button.setLayoutData(new GridData(SWT.RIGHT, SWT.TOP, true, false));
      button.setText("Browse");
      button.addSelectionListener(new SelectionListener() {

        @Override
        public void widgetSelected(SelectionEvent e) {
          FileDialog fd = new FileDialog(button.getShell(), SWT.SAVE);
          fd.setText("Save");
          fd.setFileName(alias + ".xmi");
          fd.setFilterPath(Platform.getLocation().toString());
          String selectedPath = fd.open();
          if (selectedPath != null) {
            selectedPath = selectedPath.replace(Platform.getLocation().toString(), "");
            label.setText("Select save location for " + alias + " \n\"" + selectedPath + "\"");
            label.getParent().layout();
            alloyToEMF.setSaveLocation(alias, selectedPath);
            getContainer().updateButtons();
          }
        }

        @Override
        public void widgetDefaultSelected(SelectionEvent e) {}
      });
    }
    checkbox = new Button(container, SWT.CHECK);
    checkbox.setLayoutData(new GridData(SWT.LEFT, SWT.TOP, false, false));<commit_msg>Minor fix<commit_after>package eu.modelwriter.configuration.alloy2emf;

import org.eclipse.core.runtime.Platform;
import org.eclipse.jface.wizard.IWizardPage;
import org.eclipse.swt.SWT;
import org.eclipse.swt.events.SelectionAdapter;
import org.eclipse.swt.events.SelectionEvent;
import org.eclipse.swt.events.SelectionListener;
import org.eclipse.swt.layout.GridData;
import org.eclipse.swt.layout.GridLayout;
import org.eclipse.swt.widgets.Button;
import org.eclipse.swt.widgets.Composite;
import org.eclipse.swt.widgets.FileDialog;
import org.eclipse.swt.widgets.Label;

public class FinishPage extends AlloyToEMFWizardPage {

  private boolean backButtonEnabled = true;
  private Composite container;
  private Button checkbox;

  protected FinishPage() {
    super("lastpage");
    setTitle("Finish");
  }

  @Override
  public void createControl(Composite parent) {
    container = new Composite(parent, SWT.NULL);
    container.setLayout(new GridLayout(2, false));
    for (String alias : alloyToEMF.getAliases()) {
      Label label = new Label(container, SWT.NONE);
      label.setLayoutData(new GridData(SWT.LEFT, SWT.TOP, false, false));
      label.setText("Select save location for " + alias + " \n");
      Button button = new Button(container, SWT.PUSH);
      button.setLayoutData(new GridData(SWT.RIGHT, SWT.TOP, true, false));
      button.setText("Browse");
      button.addSelectionListener(new SelectionListener() {

        @Override
        public void widgetSelected(SelectionEvent e) {
          FileDialog fd = new FileDialog(button.getShell(), SWT.SAVE);
          fd.setText("Save");
          fd.setFileName(alias + ".xmi");
          fd.setFilterPath(Platform.getLocation().toString());
          String selectedPath = fd.open();
          if (selectedPath != null) {
            selectedPath = selectedPath.replace(Platform.getLocation().toOSString(), "");
            label.setText("Select save location for " + alias + " \n\"" + selectedPath + "\"");
            label.getParent().layout();
            alloyToEMF.setSaveLocation(alias, selectedPath);
            getContainer().updateButtons();
          }
        }

        @Override
        public void widgetDefaultSelected(SelectionEvent e) {}
      });
    }
    checkbox = new Button(container, SWT.CHECK);
    checkbox.setLayoutData(new GridData(SWT.LEFT, SWT.TOP, false, false));
{'fraction_non_alphanumeric': 0.12257792754844145, 'fraction_numerical': 0.0008424599831508003, 'mean_word_length': 3.454971857410882, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '4159101', 'n_tokens_mistral': 1391, 'n_tokens_neox': 1366, 'n_words': 274}