Un groupe "permanent" pour init des variables:
if (init1 != 11) { init1=11;//
initialisation
// =======INIT BP CHOIX============
_root.bpr1_text=1; // initialise le
bouton radio 1; raz des autres
_root.bpr2_text=0;
_root.bpr3_text=0;
_root.bpr4_text=0; // si 4 boutons
_root.bpr5_text=0; // si 5 boutons.....
_root.bp_radio_text=1;
// =======INIT BP COCHES============
_root.bpc1_text=0; // initialise les
boutons a cocher
_root.bpc2_text=0;
_root.bpc3_text=0;
_root.bpc4_text=0;
} // FIN INIT
Un groupe "BP_choix" pour les
boutons radio (avec prog):
3 groupes: (bpr1 - bpr2 - bpr3- .......)
1/une variable pour récupérer le choix (_root.bp_text) 2/groupe "bpr1" :
-au temps 0:
un stop , et une image bpradio0.jpg (un rond vide)
-au temps 10:
un stop , et une image bpradio1.jpg (un rond avec un point) -un bouton 4 états:
état normal : une image bpradio0.jpg (un rond vide)
état survolé : une image bpradio0.jpg (un rond vide)
état appuyé :une image bpradio1.jpg (un rond avec un point) action état appuyé:
_root.bpr1_text=1; //
met variable bp1 à 1
_root.bpr2_text=0; // raz des autres
_root.bpr3_text=0;
_root.bpr4_text=0; // si 4 boutons
_root.bpr5_text=0; // si 5 boutons.....
_root.bp_radio_text=1; // affiche le choix 3/un groupe "permanent" pour récup var et affiche bouton:
if (_root.bpr1_text==1){
// la variable est a 1
gotogroup(->/bp_choix/bpr1,10);
stopGroup(->/bp_choix/bpr1);
} // fin si bp = 1
if (_root.bpr1_text==0){ // la variable est
a 0
gotogroup(->/bp_choix/bpr1,0);
stopGroup(->/bp_choix/bpr1);
} // fin si bp = 0
idem pour les autres boutons, changer
les variables
====================================== Un groupe "BP_radio" pour les
boutons radio (sans prog):
1 groupe: "bp_radio"
un stop à chaque temps. au temps 0:
un cadre invisible sur clic nommé "BP_choix1":
goto(0);
un cadre invisible sur clic nommé "BP_choix2": goto(1);
un cadre invisible sur clic nommé "BP_choix3": goto(2);
une image bpradio1.jpg nommée "bp1_temps0"
une image bpradio0.jpg nommée "bp2_temps0"
une image bpradio0.jpg nommée "bp3_temps0" au temps 1: une image bpradio0.jpg nommée "bp1_temps1"
une image bpradio1.jpg nommée "bp2_temps1"
une image bpradio0.jpg nommée "bp3_temps1" au temps 2: une image bpradio0.jpg nommée "bp1_temps2"
une image bpradio0.jpg nommée "bp2_temps2"
une image bpradio1.jpg nommée "bp3_temps2"
l'état se récupère sur la barre de temps
Un groupe "BP_coches" pour les
boutons a cocher:
4 groupes: (bpc1 - bpc2 - bpc3- bpc4.......) 1/groupe "bpc1" :
-au temps 0:
un stop , et une image bpcoche0.jpg (un rond vide)
-au temps 10:
un stop , et une image bpcoche1.jpg (un rond avec un point) 2/un bouton"cadre invisible" sur clic souris: (un
bouton bascule ou flip/flop)
if ( _root.bpc1_text==1) {
// si variable a 1 ,mettre a 0
_root.bpc1_text=0;
goto(10); // aller au temps 10 pour
afficher l'image cochée
}else{ // si variable a 0 ,mettre a 1
_root.bpc1_text=1;
goto(0); // aller au temps 0 pour afficher
l'image non cochée
} 3/une variable pour afficher état 0 ou 1 du bouton coché
_root.bpc1_text
idem pour les autres boutons, changer
les variables