package action; import java.awt.event.ActionEvent; import javax.swing.AbstractAction; import javax.swing.Action; import cXML.node; public class actSupprimeTitre extends AbstractAction{ /** * */ private static final long serialVersionUID = 1L; { putValue( Action.NAME, "Supprimer le titre" ); putValue( Action.SHORT_DESCRIPTION, "Supprime le titre" ); } @Override public void actionPerformed(ActionEvent e) { node nod = (node) fenetres.create.getSelectNode().getUserObject(); if(nod.getAttributs().get("titre")!=null) { nod.supprimeAttribut("titre"); } if(nod.getAttributs().get("titre1")!=null) { nod.supprimeAttribut("titre1"); } if(nod.getAttributs().get("titre2")!=null) { nod.supprimeAttribut("titre2"); } if(nod.getAttributs().get("titre3")!=null) { nod.supprimeAttribut("titre3"); } fenetres.create.getTextNodeSelect().refreshAffichage(nod); } }