Ciao a tutti,
questo è il mio primo post. Scrivo perché incontro un problema che non riesco a risolvere...
Ho preparato un documento in HTML5, con un effetto page-flip gestito in java.
Il problema è che attivanto il mouse per girare pagina, se all'interno della mia "section" ho un link, non lo riesco ad attivare perché al click del mouse parte il "pageflip", cioè si sfoglia la pagina.
Queste le righe interessate, disattivando una qualunque delle funzioni riportate il link nella "section" funziona... lascio anche le righe di discrizione che possono essere utili... grazie in anticipo per l'aiuto
Lorenzo
function mouseMoveHandler( event ) {
// Offset mouse position so that the top of the book spine is 0,0
mouse.x = event.clientX - book.offsetLeft - ( BOOK_WIDTH / 2 );
mouse.y = event.clientY - book.offsetTop;
}
function mouseDownHandler( event ) {
// Make sure the mouse pointer is inside of the book
if (Math.abs(mouse.x) < PAGE_WIDTH) {
if (mouse.x < 0 && page - 1 >= 0) {
// We are on the left side, drag the previous page
flips[page - 1].dragging = true;
}
else if (mouse.x > 0 && page + 1 < flips.length) {
// We are on the right side, drag the current page
flips[page].dragging = true;
}
}

Rispondi quotando