Projects >> labelPrinter >>44ab29363817784ab6e2253f74dbc0c6f1f20b53

Chunk
Conflicting content
public class JasperTemplateEntryForm extends BgcEntryForm implements
    SelectionListener {

<<<<<<< HEAD
    private static final String JASPER_EXTENSION = "*.jrxml"; //$NON-NLS-1$
    private static final I18n i18n = I18nFactory
        .getI18n(JasperTemplateEntryForm.class);

    public static final String ID =
        "edu.ualberta.med.biobank.labelprinter.forms.JasperTemplateEntryForm"; //$NON-NLS-1$
=======
    private static final String JASPER_EXTENSION = "*.jrxml";

    public static final String ID =
        "edu.ualberta.med.biobank.labelprinter.forms.JasperTemplateEntryForm";
>>>>>>> 3fa39947a3066b76a671609c157a114eaa1924ea

    private Button deleteButton = null;
    private Button newButton = null;
Solution content
public class JasperTemplateEntryForm extends BgcEntryForm implements
    SelectionListener {

    private static final I18n i18n = I18nFactory
        .getI18n(JasperTemplateEntryForm.class);

    private static final String JASPER_EXTENSION = "*.jrxml"; //$NON-NLS-1$

    public static final String ID =
        "edu.ualberta.med.biobank.labelprinter.forms.JasperTemplateEntryForm"; //$NON-NLS-1$

    private Button deleteButton = null;
    private Button newButton = null;
File
JasperTemplateEntryForm.java
Developer's decision
Combination
Kind of conflict
Attribute
Comment
Method invocation
Chunk
Conflicting content
    @Override
    protected void createFormContent() throws Exception {
        super.createFormContent();
<<<<<<< HEAD
        form.setText(i18n.tr("Jasper Configuration Templates"));
        form.setMessage(
            i18n.tr("Add Jasper configurations for different printer labels"),
=======
        form.setText("Jasper Configuration Templates");
        form.setMessage(
            "Add Jasper configurations for different printer labels",
>>>>>>> 3fa39947a3066b76a671609c157a114eaa1924ea
            IMessageProvider.NONE);
        page.setLayout(new GridLayout(1, false));
Solution content
    @Override
    protected void createFormContent() throws Exception {
        super.createFormContent();
        form.setText(i18n.tr("Jasper Configuration Templates"));
        form.setMessage(
            i18n.tr("Add Jasper configurations for different printer labels"),
            IMessageProvider.NONE);
        page.setLayout(new GridLayout(1, false));
File
JasperTemplateEntryForm.java
Developer's decision
Version 1
Kind of conflict
Method invocation
Chunk
Conflicting content
                    } else {
                        jasperNameText
<<<<<<< HEAD
                            .setText(i18n.tr("Please select a template"));
=======
                            .setText("Please select a template");
>>>>>>> 3fa39947a3066b76a671609c157a114eaa1924ea
                        jasperConfigText.setText("");
                        prevJasperName = null;
                    }
Solution content
                    } else {
                        jasperNameText
                            .setText(i18n.tr("Please select a template"));
                        jasperConfigText.setText("");
                        prevJasperName = null;
                    }
File
JasperTemplateEntryForm.java
Developer's decision
Version 1
Kind of conflict
Method invocation
Chunk
Conflicting content
=======
                            jasperTemplateList.remove(prevJasperName);

                            jasperNameText
<<<<<<< HEAD
                                .setText(i18n.tr("Please select a template"));
                                .setText("Please select a template");
>>>>>>> 3fa39947a3066b76a671609c157a114eaa1924ea
                            jasperConfigText.setText("");
                            prevJasperName = null;
Solution content
                            jasperTemplateList.remove(prevJasperName);

                            jasperNameText
                                .setText(i18n.tr("Please select a template"));
                            jasperConfigText.setText("");
                            prevJasperName = null;
File
JasperTemplateEntryForm.java
Developer's decision
Version 1
Kind of conflict
Method invocation
Chunk
Conflicting content
            } catch (Exception e1) {
                BgcPlugin
                    .openAsyncError(
<<<<<<< HEAD
                        i18n.tr("Template Delete Error"),
                        i18n.tr("Could not delete template. A printer template is using this jasper configuration."),
=======
                        "Template Delete Error",
                        "Could not delete template. A printer template is using this jasper configuration.",
>>>>>>> 3fa39947a3066b76a671609c157a114eaa1924ea
                        e1);
            }
        } else if (e.getSource() == browseButton) {
Solution content
            } catch (Exception e1) {
                BgcPlugin
                    .openAsyncError(
                        i18n.tr("Template Delete Error"),
                        i18n.tr("Could not delete template. A printer template is using this jasper configuration."),
                        e1);
            }
        } else if (e.getSource() == browseButton) {
File
JasperTemplateEntryForm.java
Developer's decision
Version 1
Kind of conflict
Method invocation
Chunk
Conflicting content
                }
            }
        } else {
<<<<<<< HEAD
            BgcPlugin.openAsyncError(i18n.tr("Invalid selection event"),
                i18n.tr("invalid selection source"));
=======
            BgcPlugin.openAsyncError("Invalid selection event",
                "invalid selection source");
>>>>>>> 3fa39947a3066b76a671609c157a114eaa1924ea
        }
    }
Solution content
                }
            }
        } else {
            BgcPlugin.openAsyncError(i18n.tr("Invalid selection event"),
                i18n.tr("invalid selection source"));
        }
    }
File
JasperTemplateEntryForm.java
Developer's decision
Version 1
Kind of conflict
Method invocation
Chunk
Conflicting content
public class LabelTemplateEntryForm extends BgcEntryForm implements
    SelectionListener {

<<<<<<< HEAD
    private static final String CBSR_CONFIG_NAME = "CBSR"; //$NON-NLS-1$
    private static final I18n i18n = I18nFactory
        .getI18n(LabelTemplateEntryForm.class);
    private static final String PRINTER_DEFAULT_NAME = i18n.tr("default"); //$NON-NLS-1$

    public static final String ID =
        "edu.ualberta.med.biobank.labelprinter.forms.TemplateEntryForm"; //$NON-NLS-1$
=======
    private static final String CBSR_CONFIG_NAME = "CBSR";

    private static final String PRINTER_DEFAULT_NAME = "default";

    public static final String ID =
        "edu.ualberta.med.biobank.labelprinter.forms.TemplateEntryForm";
>>>>>>> 3fa39947a3066b76a671609c157a114eaa1924ea

    private Button deleteButton = null;
    private Button copyButton = null;
Solution content
public class LabelTemplateEntryForm extends BgcEntryForm implements
    SelectionListener {

    private static final I18n i18n = I18nFactory
        .getI18n(LabelTemplateEntryForm.class);

    private static final String CBSR_CONFIG_NAME = "CBSR"; //$NON-NLS-1$

    private static final String PRINTER_DEFAULT_NAME = i18n.tr("default"); //$NON-NLS-1$

    public static final String ID =
        "edu.ualberta.med.biobank.labelprinter.forms.TemplateEntryForm"; //$NON-NLS-1$

    private Button deleteButton = null;
    private Button copyButton = null;
File
LabelTemplateEntryForm.java
Developer's decision
Combination
Kind of conflict
Attribute
Comment
Method invocation
Chunk
Conflicting content
                    } else {
                        prevTemplateName = null;
                        templateNameText
<<<<<<< HEAD
                            .setText(i18n.tr("Please select a template"));
=======
                            .setText("Please select a template");
>>>>>>> 3fa39947a3066b76a671609c157a114eaa1924ea
                        printerNameText.setText("");
                        printerNameText.setEnabled(false);
                        jasperConfigText.setText("");
Solution content
                    } else {
                        prevTemplateName = null;
                        templateNameText
                            .setText(i18n.tr("Please select a template"));
                        printerNameText.setText("");
                        printerNameText.setEnabled(false);
                        jasperConfigText.setText("");
File
LabelTemplateEntryForm.java
Developer's decision
Version 1
Kind of conflict
Method invocation
Chunk
Conflicting content
                BgcPlugin.openAsyncError("Tree Editor",
            try {
                configTree.resetEditor();
            } catch (TreeException e1) {
<<<<<<< HEAD
                BgcPlugin.openAsyncError(i18n.tr("Tree Editor"),
                    i18n.tr("Failed to reset tree editor"));
=======
                    "Failed to reset tree editor");
>>>>>>> 3fa39947a3066b76a671609c157a114eaa1924ea
            }

            if (prevTemplateName != null) {
Solution content
            try {
                configTree.resetEditor();
            } catch (TreeException e1) {
                BgcPlugin.openAsyncError(i18n.tr("Tree Editor"),
                    i18n.tr("Failed to reset tree editor"));
            }

            if (prevTemplateName != null) {
File
LabelTemplateEntryForm.java
Developer's decision
Version 1
Kind of conflict
Method invocation
Chunk
Conflicting content
        } else if (e.getSource() == deleteButton) {
            deleteButtonSelected(e);
        } else {
<<<<<<< HEAD
            BgcPlugin.openAsyncError(i18n.tr("Invalid selection event"),
                i18n.tr("invalid selection source"));
=======
            BgcPlugin.openAsyncError("Invalid selection event",
                "invalid selection source");
>>>>>>> 3fa39947a3066b76a671609c157a114eaa1924ea
        }
    }
Solution content
        } else if (e.getSource() == deleteButton) {
            deleteButtonSelected(e);
        } else {
            BgcPlugin.openAsyncError(i18n.tr("Invalid selection event"),
                i18n.tr("invalid selection source"));
        }
    }
File
LabelTemplateEntryForm.java
Developer's decision
Version 1
Kind of conflict
Method invocation
Chunk
Conflicting content
                            .getDefaultConfiguration());
                    }

<<<<<<< HEAD
                    try {
                        templateStore.addTemplate(ct);
                    } catch (Exception e1) {
                        BgcPlugin
                            .openAsyncError(
                                i18n.tr("Cannot Add Template"),
                                i18n.tr("Failed to add template to the template store."));
                        return;
                    }

=======
                    templateStore.addTemplate(ct);
>>>>>>> 3fa39947a3066b76a671609c157a114eaa1924ea
                    templateNamesList.add(ct.getName());
                    templatesNamesSelectLast();
                    templateNamesList.redraw();
Solution content
                            .getDefaultConfiguration());
                    }

                    templateStore.addTemplate(ct);
                    templateNamesList.add(ct.getName());
                    templatesNamesSelectLast();
                    templateNamesList.redraw();
File
LabelTemplateEntryForm.java
Developer's decision
Version 2
Kind of conflict
Method invocation
Try statement
Chunk
Conflicting content
                return;

            StringInputDialog dialog = new StringInputDialog(
<<<<<<< HEAD
                i18n.tr("Cloned Template Name"),
                i18n.tr("What is the name of the cloned template?"),
                i18n.tr("Name"), shell);
=======
                "Cloned Template Name",
                "What is the name of the cloned template?",
                "Name", shell);
>>>>>>> 3fa39947a3066b76a671609c157a114eaa1924ea
            dialog.setValue(prevTemplateName + " copy");

            if (dialog.open() == Dialog.OK) {
Solution content
                return;

            StringInputDialog dialog = new StringInputDialog(
                i18n.tr("Cloned Template Name"),
                i18n.tr("What is the name of the cloned template?"),
                i18n.tr("Name"), shell);
            dialog.setValue(prevTemplateName + " copy");

            if (dialog.open() == Dialog.OK) {
File
LabelTemplateEntryForm.java
Developer's decision
Version 1
Kind of conflict
Attribute
Method invocation
Chunk
Conflicting content
        plt = new PrinterLabelTemplateWrapper(SessionManager.getAppService());
    }

<<<<<<< HEAD
    @SuppressWarnings("nls")
=======
    public Template(PrinterLabelTemplateWrapper plTemplate) {
        plt = plTemplate;
    }

>>>>>>> 3fa39947a3066b76a671609c157a114eaa1924ea
    @Override
    public Template clone() {
        Template clone = new Template();
Solution content
    @Override
        plt = new PrinterLabelTemplateWrapper(SessionManager.getAppService());
    }

    public Template(PrinterLabelTemplateWrapper plTemplate) {
        plt = plTemplate;
    }


    @SuppressWarnings("nls")
    public Template clone() {
        Template clone = new Template();
File
Template.java
Developer's decision
Concatenation
Kind of conflict
Annotation
Method declaration
Chunk
Conflicting content
        try {
            clone.setJasperTemplate(this.getJasperTemplate());
        } catch (Exception e1) {
<<<<<<< HEAD
            logger
                .error(i18n.tr("Error: Failed to clone jasper template."), e1);
=======
            logger.error("Error: Failed to clone jasper template.", e1);
>>>>>>> 3fa39947a3066b76a671609c157a114eaa1924ea
            return null;
        }
Solution content
        try {
            clone.setJasperTemplate(this.getJasperTemplate());
        } catch (Exception e1) {
            logger
                .error(i18n.tr("Error: Failed to clone jasper template."), e1);
            return null;
        }
File
Template.java
Developer's decision
Version 1
Kind of conflict
Method invocation
Chunk
Conflicting content
            try {
                clone.setConfiguration(newConfig);
            } catch (JAXBException e) {
<<<<<<< HEAD
                logger.error(i18n.tr("Error: Failed to clone configuration."),
                    e);
=======
                logger.error("Error: Failed to clone configuration.", e);
>>>>>>> 3fa39947a3066b76a671609c157a114eaa1924ea
                return null;
            }
        }
Solution content
            try {
                clone.setConfiguration(newConfig);
            } catch (JAXBException e) {
                logger.error(i18n.tr("Error: Failed to clone configuration."),
                    e);
                return null;
            }
        }
File
Template.java
Developer's decision
Version 1
Kind of conflict
Method invocation
Chunk
Conflicting content
                plt.setId(id);

            } catch (Exception e) {
<<<<<<< HEAD
                logger
                    .error(
                        i18n.tr("Error: Failed to persit key-updated configuration"),
                        e);
=======
                logger.error(
                    "Error: Failed to persit key-updated configuration", e);
>>>>>>> 3fa39947a3066b76a671609c157a114eaa1924ea
                return null;
            }
        }
Solution content
                plt.setId(id);

            } catch (Exception e) {
                logger
                    .error(
                        i18n.tr("Error: Failed to persit key-updated configuration"),
                        e);
                return null;
            }
        }
File
Template.java
Developer's decision
Version 1
Kind of conflict
Method invocation