Tally List : mailing list management, archiving, and analysis
click for archive home
 
Archive of:
Authorware
MacroMedia AuthorWare
 
home
24 hour view
quick stats
weekly updates
 
all tallylists
corporate solutions
archive your favorite
help / feedback


Search the Tallylist search by keyword:

About Authorware :
product's home
product's list home
 
  Archived TallyList / Authorware: 
Subject: Re: A5:dragging presentation window
George Hawrysch (17p/+0r)     Posted: Tuesday 10 Apr 2001
This post: 41 views, +0 rating

Here is one fairly simple method of dragging a window around on the screen.

1. Set up window with initial dimensions of your choice and resize the window to those dimensions:

aini:=100 --Depth bini:=300 --Width ResizeWindow(bini, aini) -- width, depth

2. Place a hotspot over the object or area you wish to act as the dragging "handle" (for example, a window's title bar).

3. This hotspot (set to single click) activates a map icon which contains three icons, as follows:

a) A calc that captures the X and Y coordinates where the single click occurs

xini:=ClickX yini:=ClickY

b) A decision icon that repeats sequentially until ~MouseDown

c) A calc icon off the decision icon. This needs contain only a single line of code:

MoveWindow(WindowTop-(yini-CursorY)-38, WindowLeft-(xini-CursorX))

That's it. The constant "38" in that final line of code is a "jump factor." Without it, the window will jump 38 pixels vertically when you initially click inside the hotspot. What's more, this behavior is different depending on whether the file is packaged or not. So it's probably better to use a custom variable instead of a constant and control it with something like

if FileType(FileLocation^FileName)=2 then jFac:=38 else jFac:=0

Frankly I don't understand this jumping effect. If anyone has any insight into it, I'd love to see an explanation. But the method does work. If anyone would like an example file, just let me know.

George Hawrysch

On Mon, 9 Apr 2001, Danny Engelman wrote:

> Been struggling with this way to long. > > Does anyone have code to drag the presentation around the screen? > So if the user clicks on a graphic inside the presentation and drag the mouse > the whole presentation window has to move (MoveWindow) > > > -- > Danny Engelman <Danny@FlashFactory.nl> > eLearning developer > FlashFactory.NL > > -- > The AWARE List > http://www.e-media.nl/aware/index.html > > Search the Archives > http://www.e-media.nl/aware/search.html > > Netiquette: > - Use descriptive subject fields > - Use subject prefixes (A5 , A5Mac , A5Web , KO , UCD , OT) > > > >

-- The AWARE List http://www.e-media.nl/aware/index.html

Search the Archives http://www.e-media.nl/aware/search.html

Netiquette: - Use descriptive subject fields - Use subject prefixes (A5 , A5Mac , A5Web , KO , UCD , OT)


Similar Subject Line Posts (+/- two weeks of this post)
Re: A5:dragging presentation window  10 Apr 2001   (31 v/ +0 r)
Re: A5:dragging presentation window  10 Apr 2001 (this post)   (41 v/ +0 r)
Re: A5:dragging presentation window  09 Apr 2001   (25 v/ +0 r)
Re: A5:dragging presentation window  09 Apr 2001   (21 v/ +0 r)
A5:dragging presentation window  09 Apr 2001   (19 v/ +0 r)
 

Send a reply to the Authorware list!
click to send a reply! NOTE: Many lists will reject your post unless you have already registered with them. Also - don't forget the right account to send from (for those with multiple emails!)

Feedback: If this post was exceptionally helpful, please help by giving this post a positive review.

 

TallyList : copyright Ububik - 2000