Botón Atrás

  • mtolgao
  • Newbie
  • Newbie
  • No Avatar
  • Registrado: Ago 22, 2009
  • Mensajes: 7
  • Status: Offline

Nota Agosto 22nd, 2009, 8:12 am

Hola,

En un post ( flash-forum/back-button-previous-frame-t30698.html Solución digitalMedias), he leído, y me gustaría preguntarle algo. ¿Cómo es posible combinar gotoAndStop (backFrame), y _root.page = backFrame; _root.play ();? Porque me gustaría hacer algo como esto con la forma de contacto. http://tolga.ozses.net/yeniProje.swf . No quiero volver solo, quiero hacer esto sin problemas (es decir, cuando hago clic en el botón Atrás (Geri botón en la parte Iletisim), el formulario de contacto debería moverse a la derecha y el marco anterior debe mover desde el botón) . Esto es lo que sucede en el resto de botones en el momento. Espero que me hice claro.

Saludos cordiales,
  • Anonymous
  • Bot
  • No Avatar
  • Registrado: 25 Feb 2008
  • Mensajes: ?
  • Loc: Ozzuland
  • Status: Online

Nota Agosto 22nd, 2009, 8:12 am

  • IceCold
  • Guru
  • Guru
  • Avatar de Usuario
  • Registrado: Nov 05, 2004
  • Mensajes: 1254
  • Loc: Ro
  • Status: Offline

Nota Agosto 24th, 2009, 2:49 am

Código: [ Select ]
 
var goBack = false;
onEnterFrame = function()
{
   if (goBack)
   {
      backFrame--; gotoAndStop(backFrame);
      if (stopCondition)
         goBack = false;
   }
}
 
myButton.onRelease = function () { goBack = true; }
 
  1.  
  2. var goBack = false;
  3. onEnterFrame = function()
  4. {
  5.    if (goBack)
  6.    {
  7.       backFrame--; gotoAndStop(backFrame);
  8.       if (stopCondition)
  9.          goBack = false;
  10.    }
  11. }
  12.  
  13. myButton.onRelease = function () { goBack = true; }
  14.  

stopCondition es cualquier condición que desea que la animación de nuevo a parar. Por ejemplo, un marco: si (_root.currentframe == frameX)
“True mastery transcede any particular art. It stems from mastery of oneself - the ability, developed throgh self-discipline, to be calm, fully aware, and complety in tune with oneself and the surroundings. Then, and only then, can a person know himself. ”
  • mtolgao
  • Newbie
  • Newbie
  • No Avatar
  • Registrado: Ago 22, 2009
  • Mensajes: 7
  • Status: Offline

Nota Agosto 24th, 2009, 6:23 am

Perdone, pero soy un principiante en flash. ¿Puede usted decirme dónde ingresar el código? El botón de retroceso, o un marco? Además, es este AS2 o AS3? Probablemente debería haber mencionado que el código se supone que AS2.

Saludos cordiales,
  • IceCold
  • Guru
  • Guru
  • Avatar de Usuario
  • Registrado: Nov 05, 2004
  • Mensajes: 1254
  • Loc: Ro
  • Status: Offline

Nota Agosto 25th, 2009, 2:14 am

esto es AS2, y es necesario colocar el código en un fotograma clave (sólo asegúrate de que el botón aparece en la línea de tiempo cuando se está en ese fotograma clave).
También asegúrese de introducir el nombre de instancia para el botón (ya sea el nombre de la myButton ejemplo, o el nombre que quieras, pero luego myButton cambio en el código proporcionado con el nombre que ha introducido). Ah, y un pequeño error me visto, me corrige ahora, se
if (stopCondition) backFrame = false; -> debería ser GoBack = false;
“True mastery transcede any particular art. It stems from mastery of oneself - the ability, developed throgh self-discipline, to be calm, fully aware, and complety in tune with oneself and the surroundings. Then, and only then, can a person know himself. ”

Publicar Información

  • Total de mensajes en este tema: 4 mensajes
  • Usuarios navegando por este Foro: No hay usuarios registrados visitando el Foro y 55 invitados
  • No puede abrir nuevos temas en este Foro
  • No puede responder a temas en este Foro
  • No puede editar sus mensajes en este Foro
  • No puede borrar sus mensajes en este Foro
  • No puede enviar adjuntos en este Foro
 
 

© 2011 Unmelted, LLC. Ozzu® es una marca registrada de Unmelted, LLC