可以不用设定边界,通过判断动态面板的X/Y位置判断是否需要弹回
建立动态面板 obj,我们只以纵向(模拟手机)拖动举个例子——
动态面板 obj 拖动时:
case 1 为垂直拖动
动态面板 obj 拖动结束时(需要判断):
case 1 if ture [[this.Y]] > 0
移动 obj 到 0,0
case 2 if ture [[this.Y]] < [[window.Height-this.Height]]
移动 obj 到 0,[[window.Height-this.Height]]
可以试一下