Commit 9e35fe89 authored by Aron Helser's avatar Aron Helser
Browse files

WIP testing native file dialog

parent b3dbfda5
......@@ -39,6 +39,7 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#include "pqTestUtility.h"
#include <QApplication>
#include <QFileDialog>
//-----------------------------------------------------------------------------
pqTestingReaction::pqTestingReaction(QAction* parentObject, Mode mode, Qt::ConnectionType type)
: Superclass(parentObject, type)
......@@ -92,13 +93,14 @@ void pqTestingReaction::playTest()
filters += "Python Files (*.py);;";
#endif
filters += "All Files (*)";
pqFileDialog fileDialog(
nullptr, pqCoreUtilities::mainWidget(), tr("Play Test"), QString(), filters);
QFileDialog fileDialog(
pqCoreUtilities::mainWidget(), tr("Play Test"), QString(), filters);
// fileDialog.setOptions(QFileDialog::DontUseNativeDialog);
fileDialog.setObjectName("ToolsPlayTestDialog");
fileDialog.setFileMode(pqFileDialog::ExistingFile);
fileDialog.setFileMode(QFileDialog::ExistingFile);
if (fileDialog.exec() == QDialog::Accepted)
{
pqTestingReaction::playTest(fileDialog.getSelectedFiles()[0]);
pqTestingReaction::playTest(fileDialog.selectedFiles()[0]);
}
}
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment