[英]QFileDialog doesn't work with tags in OSX and Qt 5.7
I need fileDialog
to work properly with tags. 我需要
fileDialog
才能正常使用标签。 On OSX, when I try to click on tag - this code removes all files from file dialog, so I can't pick them. 在OSX上,当我尝试单击标记时 - 此代码从文件对话框中删除所有文件,因此我无法选择它们。
Looks like I found solution Option::DontResolveSymlinks
but it doesn't work either. 看起来我找到了解决方案
Option::DontResolveSymlinks
但它也不起作用。
Update: if filter is "Any (\\*.\\*)"
it shows folders, in other cases it doesn't. 更新:如果过滤器为
"Any (\\*.\\*)"
则显示文件夹,在其他情况下则不显示。 Like it disables files to be chosen - I already came up with workaround, but hope there is a solution. 就像它禁用了要选择的文件一样 - 我已经想出了解决方法,但希望有一个解决方案。
QStringList filenames = QFileDialog::getOpenFileNames(nullptr,
caption,
lastDirPath,
filter,
nullptr,
QFileDialog::Option::DontResolveSymlinks);
Update: added screen to describe what "tag" is 更新:添加屏幕以描述“标签”是什么
I have found a resolve for the mac file open hang, based on the previous answer. 基于之前的答案,我已经找到了解决mac文件打开挂起的问题。
QStringList filenames = QFileDialog::getOpenFileNames(nullptr,
caption,
lastDirPath,
filter,
nullptr,
QFileDialog::Option::DontUseNativeDialog)
The mac file dialog is not used, it looks more UNIX like, but it now works. 没有使用mac文件对话框,它看起来更像UNIX,但它现在有效。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.