2023-02-05 17:46:02 +01:00
|
|
|
package action;
|
2022-06-19 21:01:30 +02:00
|
|
|
|
|
|
|
import java.awt.event.ActionEvent;
|
|
|
|
|
|
|
|
import javax.swing.AbstractAction;
|
|
|
|
import javax.swing.Action;
|
2022-12-12 11:49:47 +01:00
|
|
|
import javax.swing.ImageIcon;
|
2022-06-19 21:01:30 +02:00
|
|
|
|
|
|
|
import cXML.node;
|
2022-12-12 11:49:47 +01:00
|
|
|
import fenetres.create;
|
2022-06-19 21:01:30 +02:00
|
|
|
|
2023-02-05 17:46:02 +01:00
|
|
|
public class actEvalPasParagrapheVideToutesLesPagesNon extends AbstractAction{
|
2022-06-19 21:01:30 +02:00
|
|
|
{
|
2023-02-05 17:46:02 +01:00
|
|
|
putValue( Action.NAME, "Supprime évaluer l'absence de paragraphe vide dans toutes les pages" );
|
|
|
|
putValue( Action.SHORT_DESCRIPTION, "Supprime l'évaluation de l'absence de paragraphe vide dans toutes les pages." );
|
2022-12-12 11:49:47 +01:00
|
|
|
putValue( Action.SMALL_ICON, new ImageIcon(create.class.getResource("/resources/falsemini.png")) );
|
2022-06-19 21:01:30 +02:00
|
|
|
}
|
2023-02-05 17:46:02 +01:00
|
|
|
private static final long serialVersionUID = 1L;
|
|
|
|
|
2022-06-19 21:01:30 +02:00
|
|
|
@Override
|
|
|
|
public void actionPerformed(ActionEvent e) {
|
|
|
|
node nod = (node) fenetres.create.getSelectNode().getUserObject();
|
2022-12-29 20:58:04 +01:00
|
|
|
if(nod.getNomElt().equals("structurepage")) {
|
|
|
|
for(int i = 0 ; i < nod.getNodes().size();i++) {
|
2023-02-05 17:46:02 +01:00
|
|
|
nod.getNodes().get(i).supprimeAttribut("evalPasParagrapheVide");
|
2022-12-29 20:58:04 +01:00
|
|
|
}
|
|
|
|
}
|
2022-06-19 21:01:30 +02:00
|
|
|
fenetres.create.getTextNodeSelect().refreshAffichage(nod);
|
|
|
|
}
|
|
|
|
|
|
|
|
}
|