on dragwindow dwhichmiaw tell the stage set mpt to point ( the mouseh , the mousev ) set origrect to the rect of dwhichmiaw repeat while the mousedown set newpt to point ( the mouseh , the mousev ) set deltapt to newpt - mpt set newrect to offset (origrect, getat (deltapt, 1 ), ? getat (deltapt, 2 )) set the rect of dwhichmiaw to newrect tell dwhichmiaw to updatestage updatestage end repeat end tell end