主题 : Re:qtopia-2.2.0-FriendlyARM中使用QFileDialog出错: error: no method 'QFileDialog::getOneFileName' 复制链接 | 浏览器收藏 | 打印
创新改变世界,技术驱动中国
级别: 论坛版主
UID: 7752
精华: 2
发帖: 55
金钱: 570 两
威望: 276 点
综合积分: 150 分
注册时间: 2009-07-27
最后登录: 2010-03-30
楼主  发表于: 2009-09-12 10:04

 Re:qtopia-2.2.0-FriendlyARM中使用QFileDialog出错: error: no method 'QFileDialog::getOneFileName'

在友善提供的qtopia-2.2.0-FriendlyARM的x86-qtopia中,编程使用qfiledialog类,在编译时会提示错误error: no method 'qfiledialog::getonefilename()'或其他提示qfiledialog未定义的错误。之前我也很不理解,为什么qtopia-2.2.0会不支持自己提供的类,但之后我想到,可能问题出在友善提供的编译x86-qtopia的build脚本上,在查找了相关资料,在网上发现了一个老外给出的解释,原文如下:
RE: compile error: no method `QFileDialog::getSaveFileName'
QFileDialog is not included in the Qt/E configuration for Qtopia. You can use FileSelector or FileManager class in Qtopia. 即QFileDialog不包括在Qte配置中,在友善的脚本中加入了-qte,所以就不能使用QFileDialog
[ 此帖被hxfirefox在2009-09-12 10:48重新编辑 ]
*無鈳取玳
级别: 论坛版主
UID: 27
精华: 12
发帖: 5398
金钱: 40120 两
威望: 17929 点
综合积分: 11036 分
注册时间: 2008-01-16
最后登录: 2014-11-22
1楼  发表于: 2009-09-12 10:13

 Re:qtopia-2.2.0-FriendlyARM中使用qfiledialog出错: error: no method 'qfiledialog::getonefilen ..

换个更清楚的题目:)
"If you have an apple and I have an apple and we exchange apples, then you and I will
still each have one apple. But if you have an idea and I have an idea and we exchange
these ideas, then each of us will have two ideas."
创新改变世界,技术驱动中国
级别: 论坛版主
UID: 7752
精华: 2
发帖: 55
金钱: 570 两
威望: 276 点
综合积分: 150 分
注册时间: 2009-07-27
最后登录: 2010-03-30
2楼  发表于: 2009-09-12 10:47

 回 1楼(kasim) 的帖子

有道理,谢谢版主
级别: 新手上路
UID: 7451
精华: 1
发帖: 21
金钱: 230 两
威望: 200 点
综合积分: 62 分
注册时间: 2009-07-15
最后登录: 2017-09-13
3楼  发表于: 2009-09-14 11:25

 Re:Re:qtopia-2.2.0-FriendlyARM中使用QFileDialog出错: error: no method 'QFileDialog::getOneFi ..

原来如此!感谢解惑。