Skip to content

Commit

Permalink
Move cron list editor to almond-util
Browse files Browse the repository at this point in the history
  • Loading branch information
trixon committed Apr 14, 2017
1 parent 2faf17b commit ee35b20
Show file tree
Hide file tree
Showing 5 changed files with 19 additions and 220 deletions.

This file was deleted.

Expand Up @@ -16,17 +16,17 @@
<Layout>
<DimensionLayout dim="0">
<Group type="103" groupAlignment="0" attributes="0">
<Component id="cronPanel" alignment="0" max="32767" attributes="0"/>
<Component id="cronListPanel" alignment="0" pref="202" max="32767" attributes="0"/>
</Group>
</DimensionLayout>
<DimensionLayout dim="1">
<Group type="103" groupAlignment="0" attributes="0">
<Component id="cronPanel" alignment="0" pref="88" max="32767" attributes="0"/>
<Component id="cronListPanel" alignment="0" max="32767" attributes="0"/>
</Group>
</DimensionLayout>
</Layout>
<SubComponents>
<Component class="se.trixon.jota.client.ui.editor.module.job.CronEditorPanel" name="cronPanel">
<Component class="se.trixon.almond.util.swing.dialogs.cron.CronListPanel" name="cronListPanel">
</Component>
</SubComponents>
</Form>
@@ -1,4 +1,4 @@
/*
/*
* Copyright 2017 Patrik Karlsson.
*
* Licensed under the Apache License, Version 2.0 (the "License");
Expand All @@ -15,8 +15,8 @@
*/
package se.trixon.jota.client.ui.editor.module.job;

import se.trixon.jota.shared.job.Job;
import se.trixon.almond.util.Dict;
import se.trixon.jota.shared.job.Job;

/**
*
Expand All @@ -34,14 +34,14 @@ public JobCronPanel() {

@Override
public void loadJob(Job job) {
cronPanel.setCronActive(job.isCronActive());
cronPanel.setCronItems(job.getCronItems());
cronListPanel.setActive(job.isCronActive());
cronListPanel.setCronItems(job.getCronItems());
}

@Override
public Job saveJob(Job job) {
job.setCronActive(cronPanel.isCronActive());
job.setCronItems(cronPanel.getCronItems());
job.setCronActive(cronListPanel.isActive());
job.setCronItems(cronListPanel.getCronItems());

return job;
}
Expand All @@ -51,30 +51,28 @@ private void init() {
}

/**
* This method is called from within the constructor to initialize the form.
* WARNING: Do NOT modify this code. The content of this method is always
* regenerated by the Form Editor.
* This method is called from within the constructor to initialize the form. WARNING: Do NOT
* modify this code. The content of this method is always regenerated by the Form Editor.
*/
@SuppressWarnings("unchecked")
// <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
private void initComponents() {

cronPanel = new se.trixon.jota.client.ui.editor.module.job.CronEditorPanel();
cronListPanel = new se.trixon.almond.util.swing.dialogs.cron.CronListPanel();

javax.swing.GroupLayout layout = new javax.swing.GroupLayout(this);
this.setLayout(layout);
layout.setHorizontalGroup(
layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
.addComponent(cronPanel, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
.addComponent(cronListPanel, javax.swing.GroupLayout.DEFAULT_SIZE, 202, Short.MAX_VALUE)
);
layout.setVerticalGroup(
layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
.addComponent(cronPanel, javax.swing.GroupLayout.DEFAULT_SIZE, 88, Short.MAX_VALUE)
.addComponent(cronListPanel, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
);
}// </editor-fold>//GEN-END:initComponents


// Variables declaration - do not modify//GEN-BEGIN:variables
private se.trixon.jota.client.ui.editor.module.job.CronEditorPanel cronPanel;
private se.trixon.almond.util.swing.dialogs.cron.CronListPanel cronListPanel;
// End of variables declaration//GEN-END:variables
}
@@ -1,4 +1,4 @@
#
#
# Copyright 2017 Patrik Karlsson.
#
# Licensed under the Apache License, Version 2.0 (the "License");
Expand All @@ -12,11 +12,7 @@
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
#
CronPanel.message.remove=Schedule trigger ''%s'' is about to be removed.
CronPanel.message.removeAll=All schedule triggers are about to be removed.
CronPanel.title.remove=Remove schedule trigger
CronPanel.title.removeAll=Remove all schedule triggers
#
JobPanel.afterFailurePanel.header=Run after last task, if any failed
JobPanel.afterPanel.header=Run after last task
JobPanel.afterSuccessPanel.header=Run after last task, if all ok
Expand Down
@@ -1,4 +1,4 @@
#
#
# Copyright 2017 Patrik Karlsson.
#
# Licensed under the Apache License, Version 2.0 (the "License");
Expand All @@ -12,7 +12,7 @@
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
#
#
JobPanel.afterFailurePanel.header=K\u00f6r efter sista uppgiften, om n\u00e5gon misslyckades
JobPanel.afterPanel.header=K\u00f6r efter sista uppgiften
JobPanel.afterSuccessPanel.header=K\u00f6r efter sista uppgiften, om alla lyckades
Expand All @@ -31,7 +31,3 @@ TasksPanel.message.remove=Uppgiften ''%s'' kommer att tas bort.
TasksPanel.message.removeAll=Alla uppgifter kommer att tas bort.
TasksPanel.title.remove=Ta bort uppgift
TasksPanel.title.removeAll=Ta bort alla uppgifter
CronPanel.title.remove=Ta bort schemautl\u00f6sare
CronPanel.title.removeAll=Ta bort alla schemautl\u00f6sare
CronPanel.message.remove=Schemautl\u00f6saren ''%s'' kommer att tas bort.
CronPanel.message.removeAll=Alla schemautl\u00f6sare kommer att tas bort.

0 comments on commit ee35b20

Please sign in to comment.