Event: change: Difference between revisions
Jump to navigation
Jump to search
(Created page with "{| class="wikitable" |- ! Default action |- | To turn the page |}") |
No edit summary |
||
(One intermediate revision by the same user not shown) | |||
Line 1: | Line 1: | ||
This event is triggered before changing the current zoom of the flipbook | |||
{| class="wikitable" | |||
|- | |||
! scope="col"| Argument | |||
! scope="col"| Type | |||
! scope="col"| Description | |||
|- | |||
| event | |||
| Object | |||
| Event Object | |||
|- | |||
| zoom | |||
| Number | |||
| New zoom | |||
|} | |||
{| class="wikitable" | {| class="wikitable" | ||
|- | |- | ||
! Default action | ! Default action | ||
|- | |- | ||
| To | | To change the zoom | ||
|} | |} | ||
Example: | |||
<pre class="javascript"> | |||
$("#zoom-view").bind("zoom.change", function(event, newZoom) { | |||
// Disable the flipbook to zoom out | |||
if (newZoom<=1) { | |||
event.preventDefault(); | |||
} | |||
}); | |||
</pre> | |||
<yambe:breadcrumb>Zoom Events</yambe:breadcrumb> |
Latest revision as of 22:21, 3 August 2012
This event is triggered before changing the current zoom of the flipbook
Argument | Type | Description |
---|---|---|
event | Object | Event Object |
zoom | Number | New zoom |
Default action |
---|
To change the zoom |
Example:
$("#zoom-view").bind("zoom.change", function(event, newZoom) { // Disable the flipbook to zoom out if (newZoom<=1) { event.preventDefault(); } });
<yambe:breadcrumb>Zoom Events</yambe:breadcrumb>