SWT 怎么做出右下脚慢慢升出shell的效果??就象QQ系统消息那样...

zhang4138151 2008-02-21 04:38:30
谢谢!~~
...全文
63 3 打赏 收藏 转发到动态 举报
写回复
用AI写文章
3 条回复
切换为时间正序
请发表友善的回复…
发表回复
zhang4138151 2008-02-23
  • 打赏
  • 举报
回复
呵呵 自己想出来了 效果不错

import org.eclipse.swt.*;
import org.eclipse.swt.custom.*;
import org.eclipse.swt.graphics.*;
import org.eclipse.swt.layout.*;
import org.eclipse.swt.widgets.*;

public class yidong {
public static void main(String[] args)
{
final Display display = Display.getDefault();
final Shell shell = new Shell();
//shell.setSize(296, 255);
shell.setText("移动窗口 练习");
shell.setLayout(new RowLayout());



int x=0;
for(int i=100;i>=0;i--){
x=i*2;//控制速度
shell.setBounds(820,x+600,200,200);
shell.open();
shell.layout();
shell.setVisible(true);
shell.layout();
}

while (!shell.isDisposed()) {
if (!display.readAndDispatch())
display.sleep();
}
}
}

HellMoxi 2008-02-22
  • 打赏
  • 举报
回复
PANAL坐标移动???
daxiang_zhang 2008-02-22
  • 打赏
  • 举报
回复
帮顶,我也想知道

62,623

社区成员

发帖
与我相关
我的任务
社区描述
Java 2 Standard Edition
社区管理员
  • Java SE
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧