btnTrigger.setPreferredSize(new Dimension(300, 30));
btnTrigger.addActionListener(new ActionListener() {
@Override
public void actionPerformed(ActionEvent ae) {
if (trigger != null) {
Command c = new Command();
c.setName("Edit a trigger");
c.setReceiver("app.actuators.nlautomationseditor.nlautomationseditor.in");
c.setProperty("editor", "trigger");
c.setProperty("editable",
trigger.getName()); //the default choice
c.setReplyTimeout(Integer.MAX_VALUE);
Command reply = Freedomotic.sendCommand(c);
String newTrigger = reply.getProperty("edited");
if (newTrigger != null) {
btnTrigger.setName(TriggerPersistence.getTrigger(newTrigger).getName());
}