URL btnIconResourceUrl = getClass().getClassLoader().getResource(
ActivityLabel.getSVGIconPath(this.getClass(), "new"));
if(btnIconResourceUrl != null) {
SvgBatikResizableIcon btnSVGIcon = SvgBatikResizableIcon.getSvgIcon(
btnIconResourceUrl, new Dimension(32, 32));
JCommandButton btn = new JCommandButton(
GlobalContext.getLocalizedMessage("pd.menu.new", "New"),
btnSVGIcon);
btn.addActionListener( new ActionListener(){
public void actionPerformed(ActionEvent e) {
loadDesign(ProcessDefinition.create());
}
});
band.addGalleryButton(btn, RibbonElementPriority.MEDIUM);
}
btnIconResourceUrl = getClass().getClassLoader().getResource(
ActivityLabel.getSVGIconPath(this.getClass(), "open"));
if(btnIconResourceUrl != null) {
SvgBatikResizableIcon btnSVGIcon = SvgBatikResizableIcon.getSvgIcon(
btnIconResourceUrl, new Dimension(32, 32));
JCommandButton btn = new JCommandButton(
GlobalContext.getLocalizedMessage("pd.menu.open", "Open"),
btnSVGIcon);
btn.addActionListener( new ActionListener(){
public void actionPerformed(ActionEvent e) {
loadDesign();
}
});
band.addGalleryButton(btn, RibbonElementPriority.MEDIUM);
}
btnIconResourceUrl = getClass().getClassLoader().getResource(
ActivityLabel.getSVGIconPath(this.getClass(), "save"));
if(btnIconResourceUrl != null) {
SvgBatikResizableIcon btnSVGIcon = SvgBatikResizableIcon.getSvgIcon(
btnIconResourceUrl, new Dimension(32, 32));
JCommandButton btn = new JCommandButton(
GlobalContext.getLocalizedMessage("pd.menu.save", "Save"),
btnSVGIcon);
btn.addActionListener( new ActionListener(){
public void actionPerformed(ActionEvent e) {
saveDesign(false);
}
});
band.addGalleryButton(btn, RibbonElementPriority.MEDIUM);
}
btnIconResourceUrl = getClass().getClassLoader().getResource(
ActivityLabel.getSVGIconPath(this.getClass(), "save_as"));
if(btnIconResourceUrl != null) {
SvgBatikResizableIcon btnSVGIcon = SvgBatikResizableIcon.getSvgIcon(
btnIconResourceUrl, new Dimension(32, 32));
JCommandButton btn = new JCommandButton(
GlobalContext.getLocalizedMessage("pd.menu.saveas", "Save As"),
btnSVGIcon);
btn.addActionListener( new ActionListener(){
public void actionPerformed(ActionEvent e) {
saveDesign(true);
}
});
band.addGalleryButton(btn, RibbonElementPriority.MEDIUM);
}
btnIconResourceUrl = getClass().getClassLoader().getResource(
ActivityLabel.getSVGIconPath(this.getClass(), "save_to_server"));
if(btnIconResourceUrl != null) {
SvgBatikResizableIcon btnSVGIcon = SvgBatikResizableIcon.getSvgIcon(
btnIconResourceUrl, new Dimension(32, 32));
JCommandButton btn = new JCommandButton(
GlobalContext.getLocalizedMessage("pd.menu.savetoserver", "Save to server"),
btnSVGIcon);
btn.addActionListener( new ActionListener(){
public void actionPerformed(ActionEvent e) {
saveDesignToServer();
}
});
band.addGalleryButton(btn, RibbonElementPriority.MEDIUM);
}
btnIconResourceUrl = getClass().getClassLoader().getResource(
ActivityLabel.getSVGIconPath(this.getClass(), "import_from_bpel"));
if(btnIconResourceUrl != null) {
SvgBatikResizableIcon btnSVGIcon = SvgBatikResizableIcon.getSvgIcon(
btnIconResourceUrl, new Dimension(32, 32));
JCommandButton btn = new JCommandButton(
GlobalContext.getLocalizedMessage("pd.menu.importtobpel", "Import from BPEL"),
btnSVGIcon);
btn.addActionListener( new ActionListener(){
public void actionPerformed(ActionEvent e) {
importBPEL();
}
});
band.addGalleryButton(btn, RibbonElementPriority.MEDIUM);
}
btnIconResourceUrl = getClass().getClassLoader().getResource(
ActivityLabel.getSVGIconPath(this.getClass(), "expose_webservices"));
if(btnIconResourceUrl != null) {
SvgBatikResizableIcon btnSVGIcon = SvgBatikResizableIcon.getSvgIcon(
btnIconResourceUrl, new Dimension(32, 32));
JCommandButton btn = new JCommandButton(
GlobalContext.getLocalizedMessage(
"pd.menu.exposeaswebservice", "Expose WebServices"),
btnSVGIcon);
btn.addActionListener( new ActionListener(){
public void actionPerformed(ActionEvent e) {
generateServiceClass();
}
});
band.addGalleryButton(btn, RibbonElementPriority.MEDIUM);
}
btnIconResourceUrl = getClass().getClassLoader().getResource(
ActivityLabel.getSVGIconPath(this.getClass(), "generate_partner_process"));
if(btnIconResourceUrl != null) {
SvgBatikResizableIcon btnSVGIcon = SvgBatikResizableIcon.getSvgIcon(
btnIconResourceUrl, new Dimension(32, 32));
JCommandButton btn = new JCommandButton(
GlobalContext.getLocalizedMessage(
"pd.menu.generatepartnerprocess", "Generate Partener Process"),
btnSVGIcon);
btn.addActionListener( new ActionListener(){
public void actionPerformed(ActionEvent e) {
generatePartnerProcess();
}
});
band.addGalleryButton(btn, RibbonElementPriority.MEDIUM);
}
btnIconResourceUrl = getClass().getClassLoader().getResource(
ActivityLabel.getSVGIconPath(this.getClass(), "print"));
if(btnIconResourceUrl != null) {
SvgBatikResizableIcon btnSVGIcon = SvgBatikResizableIcon.getSvgIcon(
btnIconResourceUrl, new Dimension(32, 32));
JCommandButton btn = new JCommandButton(
GlobalContext.getLocalizedMessage("pd.menu.print", "Print"),
btnSVGIcon);
btn.addActionListener( new ActionListener(){
public void actionPerformed(ActionEvent e) {
printDesign();
}
});
band.addGalleryButton(btn, RibbonElementPriority.MEDIUM);