#22002/3/1 3:34:39
1.在dir中放置需要的移动条
2.把下面的行为脚本托给该移动条,ok
---------------------------------------------
---------------------------------------------
--这是用来移动无标题栏的窗口
--1999-1999 v1.0.1
--程序设计:陈建新
-- 1999.8.14 改正窗口冲突而引发的错误
----------------------------
property mpoint
property xa
property xb
property anxia,biaozhi
property buer
--位置建立初始化
on mousedown me
wrect=(the activewindow).rect --得到窗口坐标
--保持与舞台的鼠标绝对值
tell the stage
mpoint=the mouseloc
end tell
--取得窗口的左上角与右下角的point
xa=point(getat(wrect,1),getat(wrect,2))
xb=point(getat(wrect,3),getat(wrect,4))
--
if buer=false then
anxia=true
biaozhi=true
else
repeat while the mousedown --连续按住鼠标并拖动窗口
yidong(me)
end repeat
end if
--
end
on mouseup me
anxia=false
biaozhi=false
end
on exitframe me
if anxia=true and biaozhi=true and the mousedown then yidong(me)
end
on yidong me
tell the stage
myi=the mouseloc-mpoint
end tell
wpoint=xa+myi
wbpoint=xb+myi
(the activewindow).rect=rect(wpoint,wbpoint)
end
on getBehaviorTooltip me
return "窗口自定义移动代码"
end
on getPropertyDescriptionList me
p_list = [:]
addProp p_list,#buer,[ #comment: "是否要拖尾效果:",#format:#boolean,#default:false]
return p_list
end
----------------------------------------------
实现透明窗口很简单
window(x).windowtype=member(yy)
注:member(yy)是一幅1位黑白图,就是遮罩,白色部分透空。