iTunes display shelf: ===================== Display Shelf Link: http://blogs.sun.com/chrisoliver/resource/DisplayShelf.f3.txt trigger on DisplayShelf.angle = value { updateLayout(); } trigger on DisplayShelf.selectedIndex[old] = value { if (old == -1) { currentPosition = value; updateLayoutLater(); return; } operation easeOutCubic(time, begin, change, duration) { var r = time / duration - 1; return (change * (r * r * r + 1) + begin); } operation easeOutQuad(t, b, c, d) { t /= d; return -c *t*(t-2) + b; } var dx = value - old; var absDx = Math.abs(dx); var duration = if absDx == 1 then 1000 else 1400; var ease = if absDx == 1 then easeOutCubic else easeOutQuad; for (i in [1..100]) (dur duration linear while selectedIndex == value) { var c = ease(i, old, dx, 100); if (c <> currentPosition) { currentPosition = c; updateLayout(); } } } ========================================================================== TiltingPane Link: http://blogs.sun.com/chrisoliver/resource/TiltingPane.f3.txt trigger on TiltingPane.contentWidth = value { if (content.currentWidth > 0 and content.currentHeight > 0) { do later { contentView.content = makeContent(content, angle); } } } ========================================================================== ScrollBar Link: http://blogs.sun.com/chrisoliver/resource/ITunesScrollBar.f3.txt trigger on (newValue = pressHover) { if (newValue) { var n = selection-1; if (n >= 0) { selection = [n..0] dur n*autorepeat linear while pressHover; } } }