右侧信息弹窗使用PropertyAnimation来控制窗体的opacity透明度和Y坐标 就能够实现弹窗效果了git
PropertyAnimation{ id: hideAnimation target: subWindow properties:"opacity" from: 1.0 to: 0.0 duration: 300 onStopped: { subWindow.visible = false; } } PropertyAnimation{ id: downAnimation target: subWindow properties:"y" from: root.y to: root.y + 24 duration: 300 }
须要完整代码请访问QtQuickExamplesgithub
做者 | 郑天佐 |
---|---|
278969898 | |
主页 | http://www.camelstudio.cn/ |
邮箱 | camelsoft@163.com |
博客 | http://blog.csdn.net/zhengtianzuo06/ |
github | https://github.com/zhengtianzuo |
QQ群 | 199672080 |