Bonjour à tous.
Voilà j'ai fait un diaporama d'image gerer avec un scrollbar horizotale, mais j'aimerai que le scrollbar s'adapte a la taille de ma fenetre pour ce faire j'ai mis ce code sur mon bouton "poignee"
diaporama.scroller.poignee.onPress = function(){
diaporama.scroller.poignee.startDrag(false,0,0,1115,0);
};
diaporama.scroller.poignee.onRelease = function(){
diaporama.scroller.poignee.stopDrag()
}
diaporama.scroller.poignee.onReleaseOutside = function(){
diaporama.scroller.poignee.stopDrag()
}
diaporama.scroller.poignee.onEnterFrame = function() {
targetX = -(diaporama.scroller.poignee._x) *7.9;
};
mais la taille de mon "rail" sur lequel se deplace mon bouton ne varie pas en fonction de la taille de la fenetre...
En cherchant sur internet, je suis tomber sur Stage.width mais je ne sais po comment l'adapté a mon exemple...
Merci de votre aide.
Afficher la suite