Option: turnCorners: Difference between revisions
Jump to navigation
Jump to search
No edit summary |
(→Values) |
||
(2 intermediate revisions by the same user not shown) | |||
Line 13: | Line 13: | ||
{left-corner},{right-corner} | {left-corner},{right-corner} | ||
=== | ===Possible values=== | ||
<tt>bl,br</tt> or <tt>tl,tr</tt> or <tt>bl,tr</tt> | <tt>bl,br</tt> or <tt>tl,tr</tt> or <tt>bl,tr</tt> | ||
Line 22: | Line 22: | ||
setInterval(function() { | setInterval(function() { | ||
if (way==1) { | if (way==1) { | ||
$("#flipbook").turn("next"); | |||
if ($("#flipbook").turn("page")== $("#flipbook").turn("pages")) { | if ($("#flipbook").turn("page")== $("#flipbook").turn("pages")) { | ||
way = 2; | way = 2; | ||
$("#flipbook").turn("options", {turnCorners: "tl,tr"}); | $("#flipbook").turn("options", {turnCorners: "tl,tr"}); | ||
} | } | ||
} else { | } else { | ||
$("#flipbook").turn("previous"); | $("#flipbook").turn("previous"); | ||
Line 40: | Line 36: | ||
$("#flipbook").turn("options", {turnCorners: "bl,br"}); | $("#flipbook").turn("options", {turnCorners: "bl,br"}); | ||
} | } | ||
} | } | ||
}, 1000); | }, 1000); | ||
| | ||
Line 48: | Line 42: | ||
[http://jsfiddle.net/blasten/A9a7E/854/ See running] | [http://jsfiddle.net/blasten/A9a7E/854/ See running] | ||
<yambe:breadcrumb>Turn Options</yambe:breadcrumb> | <yambe:breadcrumb>Turn Options</yambe:breadcrumb> |
Latest revision as of 06:27, 26 November 2012
Sets the corners to be used when turning the page from methods like page, next or previous.
Type | Default value |
---|---|
String | bl,br |
Format
{left-corner},{right-corner}
Possible values
bl,br or tl,tr or bl,tr
Example
var way = 1; setInterval(function() { if (way==1) { $("#flipbook").turn("next"); if ($("#flipbook").turn("page")== $("#flipbook").turn("pages")) { way = 2; $("#flipbook").turn("options", {turnCorners: "tl,tr"}); } } else { $("#flipbook").turn("previous"); if ($("#flipbook").turn("page")==1) { way = 1; $("#flipbook").turn("options", {turnCorners: "bl,br"}); } } }, 1000);
<yambe:breadcrumb>Turn Options</yambe:breadcrumb>