[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Swftools-common] rfxview updated for mouse scrolling.
From: |
Ian Wilkinson |
Subject: |
Re: [Swftools-common] rfxview updated for mouse scrolling. |
Date: |
Tue, 04 Nov 2008 18:24:28 +0000 |
User-agent: |
Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.7.5) Gecko/20041217 |
Matthias Kramm wrote:
On Tue, Nov 04, 2008 at 11:05:30AM +0000, Ian Wilkinson <address@hidden> wrote:
I can't produce a diff as I don't have the tools, but as it's only
actionscript I can send it over it you are interested.
Yes, we're interested. Feel free to send the ActionScript.
Hi,
I've attached the code to this message, just place it after the
dragrefresh = setInterval(refreshDrag, 20);
If it's not formatted correctly let me know, so I can fix it and I
shouldn't do it again (hopefully!)
Are there any other changes you were planning to make to it that I might
be able to implement?
While I've got your attention I'd like to ask a couple of quick questions;
The documentation for both swfc and the sc file format seems either a
little out of date or incomplete. Is there a reference somewhere to
exactly what commands can be put in a sc file and what the parameters
are each command?
The swifty package in CVS is not mentioned on the swftools site, nor can
google find any reference to it, other than the mailing list. I believe
it to be a GUI for producing sc files, if so what state is it in, how do
you go about running it (I have no experience with Tcl/Tk).
Many thanks,
Ian.
--
x10 via Web or Wap?
http://www.sgtwilko.f9.co.uk/bluelava/
//Arbitary amount to move page by when mouse scrolling, but feels about
right on all pdfs I've tested
var pageMove=40;
var mouseListener = new Object(); //Create mouseListener to trap scroll
events.
mouseListener.onMouseWheel = function(delta) {
if (delta>0) { //Scrolling up
if (swf._y>=top){ //Either not zoomed, or at top of page
if(pagenr > 1) {
pagenr = pagenr - 1;
swf._y=top-scrollyrange; //Goto bottom of page.
setPageNr();
}
} else if ((top-(swf._y+pageMove))<0){ //don't over run the top
swf._y=top;
} else {
swf._y=swf._y+pageMove;
}
} else { //Scrolling down
if (swf._y<=(top-scrollyrange+1)) { //flash maths is always out,
so as long as we're within 1px of value we're at the bottom.
if(pagenr < swf._totalframes) {
pagenr = pagenr + 1;
swf._y=top; //goto top of new page
setPageNr();
}
} else if ((top-(swf._y-pageMove))>(scrollyrange)){ //Don't
overrun the bottom.
swf._y=top-scrollyrange;
} else {
swf._y=swf._y-pageMove;
}
}
swfpos2scrollbars(); //update the scrollbars to show new scroll pos,
if changed.
};
Mouse.addListener(mouseListener); //Attach mouseListener
- [Swftools-common] rfxview updated for mouse scrolling., Ian Wilkinson, 2008/11/04
- Re: [Swftools-common] rfxview updated for mouse scrolling., Matthias Kramm, 2008/11/04
- Re: [Swftools-common] rfxview updated for mouse scrolling.,
Ian Wilkinson <=
- Re: [Swftools-common] rfxview updated for mouse scrolling., Matthias Kramm, 2008/11/04
- Re: [Swftools-common] rfxview updated for mouse scrolling., peter kostov, 2008/11/05
- Re: [Swftools-common] rfxview updated for mouse scrolling., Ian Wilkinson, 2008/11/05
- Re: [Swftools-common] rfxview updated for mouse scrolling., peter kostov, 2008/11/05
- Re: [Swftools-common] rfxview updated for mouse scrolling., Matthias Kramm, 2008/11/06