mirror of
https://github.com/baldurk/renderdoc.git
synced 2026-08-15 02:56:50 +00:00
Revert "Set default extensions for most save files"
This reverts commit 6f21bacd82.
This commit is contained in:
committed by
Baldur Karlsson
parent
378d934018
commit
427b7f8553
@@ -537,12 +537,11 @@ QString RDDialog::getExecutableFileName(QWidget *parent, const QString &caption,
|
||||
}
|
||||
|
||||
QString RDDialog::getSaveFileName(QWidget *parent, const QString &caption, const QString &dir,
|
||||
const QString &filter, const QString &defaultExt,
|
||||
QString *selectedFilter, QFileDialog::Options options)
|
||||
const QString &filter, QString *selectedFilter,
|
||||
QFileDialog::Options options)
|
||||
{
|
||||
QFileDialog fd(parent, caption, dir, filter);
|
||||
fd.setAcceptMode(QFileDialog::AcceptSave);
|
||||
fd.setDefaultSuffix(defaultExt);
|
||||
fd.setOptions(options);
|
||||
show(&fd);
|
||||
|
||||
|
||||
@@ -877,7 +877,6 @@ struct RDDialog
|
||||
|
||||
static QString getSaveFileName(QWidget *parent = NULL, const QString &caption = QString(),
|
||||
const QString &dir = QString(), const QString &filter = QString(),
|
||||
const QString &defaultExt = QString(),
|
||||
QString *selectedFilter = NULL,
|
||||
QFileDialog::Options options = QFileDialog::Options());
|
||||
};
|
||||
|
||||
@@ -857,7 +857,7 @@ void CaptureDialog::on_toggleGlobal_clicked()
|
||||
void CaptureDialog::on_saveSettings_clicked()
|
||||
{
|
||||
QString filename = RDDialog::getSaveFileName(this, tr("Save Settings As"), QString(),
|
||||
tr("Capture settings (*.cap)"), lit("cap"));
|
||||
tr("Capture settings (*.cap)"));
|
||||
|
||||
if(!filename.isEmpty())
|
||||
{
|
||||
|
||||
@@ -353,9 +353,8 @@ void PerformanceCounterSelection::SetSelectedCounters(const QList<GPUCounter> &c
|
||||
|
||||
void PerformanceCounterSelection::Save()
|
||||
{
|
||||
QString filename =
|
||||
RDDialog::getSaveFileName(this, tr("Save File"), QDir::homePath(),
|
||||
tr("Performance Counter Settings (*.json)"), lit("json"));
|
||||
QString filename = RDDialog::getSaveFileName(this, tr("Save File"), QDir::homePath(),
|
||||
tr("Performance Counter Settings (*.json)"));
|
||||
|
||||
if(filename.isEmpty())
|
||||
return;
|
||||
|
||||
@@ -526,8 +526,8 @@ void TextureSaveDialog::on_browse_clicked()
|
||||
|
||||
QString *selectedFilter = NULL;
|
||||
|
||||
QString filename = RDDialog::getSaveFileName(this, tr("Save Texture As"), QString(), filter,
|
||||
QString(), selectedFilter);
|
||||
QString filename =
|
||||
RDDialog::getSaveFileName(this, tr("Save Texture As"), QString(), filter, selectedFilter);
|
||||
|
||||
QFileInfo checkFile(filename);
|
||||
if(!filename.isEmpty())
|
||||
|
||||
@@ -571,8 +571,8 @@ QString MainWindow::GetSavePath()
|
||||
dir = m_LastSaveCapturePath;
|
||||
}
|
||||
|
||||
QString filename = RDDialog::getSaveFileName(this, tr("Save Capture As"), dir,
|
||||
tr("Capture Files (*.rdc)"), lit("rdc"));
|
||||
QString filename =
|
||||
RDDialog::getSaveFileName(this, tr("Save Capture As"), dir, tr("Capture Files (*.rdc)"));
|
||||
|
||||
if(!filename.isEmpty())
|
||||
{
|
||||
|
||||
@@ -511,7 +511,7 @@ void PythonShell::on_openScript_clicked()
|
||||
void PythonShell::on_saveScript_clicked()
|
||||
{
|
||||
QString filename = RDDialog::getSaveFileName(this, tr("Save Python Script"), QString(),
|
||||
tr("Python scripts (*.py)"), lit("py"));
|
||||
tr("Python scripts (*.py)"));
|
||||
|
||||
if(!filename.isEmpty())
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user