Topic: Grab and drag scrolling
Can anyone offer assistance or provide an example/source for touch-based text scrolling on the Chumby?
Here's an example of what I'd like to achieve: http://www.chumby.com/guide/widget/Lib%C3%A9ration
Thanks!
You are not logged in. Please login or register.
chumbysphere forum → Flash/Widget → Grab and drag scrolling
Can anyone offer assistance or provide an example/source for touch-based text scrolling on the Chumby?
Here's an example of what I'd like to achieve: http://www.chumby.com/guide/widget/Lib%C3%A9ration
Thanks!
on (press) use:
movieclip.startDrag
on (release) use:
movieclip.stopDrag
By looking at the difference in values _ymouse you can see how much was scrolled.
matt
I was hoping to use the ansi scroller as a starting point but I can't figure out how to display dynamic text instead of an image.
The ansi scroller source is available here: http://www.chumby.com/guide/widget/ANSI%20ScrollerAny thoughts would be greatly appreciated as I have a new widget I'm about ready to release.
Edit: Nevermind, I got it working.
Thanks.. I need that too..
MyridoM
I'll be posting the source to my widget at some point within the next few days. I had to tweak the ansiscroller code to work when the height of the text was less than the height of the screen, figure out some embedded font issues, and setup offsets for my interface.
If you want to play around with it now, the easiest way to get a "proof of concept" working is to download the original ansiscroller.fla and replace the following:
proxy = attachMovie....
with something similar to:
var format = new TextFormat();
format.align = "left";
format.font = "Arial";
format.size = 14;
var proxy = this.createEmptyMovieClip("proxy", 1);
var details = proxy.createTextField("details", 2, 0, 0, 320, 240);
proxy.details.type = "dynamic";
proxy.details.multiline = true;
proxy.details.selectable = false;
proxy.details.wordWrap = true;
proxy.details.html = true;
proxy.details.autoSize = true;
proxy.details.variable = "htmlContent";
proxy.details.htmlText = "<b>Testing 1 2 3</b><br>afafalkfja<br>askafldjadfs<br>adfasfdasfA<br>asdfafaf<br>asdfadasdf<br>asdfafaf<br>adsfasdf<br>adsfafasd<br>asfasfasf<br>asdfasfasf<br>asdfasfdasf<br>asdfafasdf<br>Asdfafasdf<br>Asdfafasfsaf<br>asdfasfdasfa<Br>Asdfasfasf<br>afdaf";
proxy.details.setTextFormat(format);
I've posted the sources to the Package Tracker widget here: http://www.cyphergate.com/package-tracker.zip
Can you talk me through, in plain english, how this drag scroll works?
do I have to set up my movie a particular way? thanks!
chumbysphere forum → Flash/Widget → Grab and drag scrolling
Powered by PunBB, supported by Informer Technologies, Inc.