updated save dialog to take file path from command line instead it had in settings
--HG-- branch : develop
This commit is contained in:
parent
7c6cd2e4a0
commit
8fabf871d8
|
@ -122,6 +122,20 @@ QString DialogSaveLayout::MakeHelpFormatList()
|
||||||
return out;
|
return out;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
//---------------------------------------------------------------------------------------------------------------------
|
||||||
|
void DialogSaveLayout::SetFullPath(const QString &cmdFileName)
|
||||||
|
{
|
||||||
|
QFileInfo fn(cmdFileName);
|
||||||
|
fn.makeAbsolute();
|
||||||
|
auto p = fn.dir().absolutePath();
|
||||||
|
auto n = fn.fileName()+"_";
|
||||||
|
QTextStream sout(stdout);
|
||||||
|
|
||||||
|
sout << tr("Output full path: ") << fn.filePath() << "\n";
|
||||||
|
ui->lineEditPath->setText(p);
|
||||||
|
ui->lineEditFileName->setText(n);
|
||||||
|
}
|
||||||
|
|
||||||
//---------------------------------------------------------------------------------------------------------------------
|
//---------------------------------------------------------------------------------------------------------------------
|
||||||
DialogSaveLayout::~DialogSaveLayout()
|
DialogSaveLayout::~DialogSaveLayout()
|
||||||
{
|
{
|
||||||
|
|
|
@ -93,7 +93,7 @@ public:
|
||||||
QString Formate() const;
|
QString Formate() const;
|
||||||
void SelectFormate(const size_t formate);
|
void SelectFormate(const size_t formate);
|
||||||
static QString MakeHelpFormatList();
|
static QString MakeHelpFormatList();
|
||||||
|
void SetFullPath(const QString& cmdFileName);
|
||||||
public slots:
|
public slots:
|
||||||
void Save();
|
void Save();
|
||||||
void ShowExample();
|
void ShowExample();
|
||||||
|
|
|
@ -3482,6 +3482,7 @@ void MainWindow::DoExport(const VCommandLinePtr &expParams)
|
||||||
PrepareDetailsForLayout(details);
|
PrepareDetailsForLayout(details);
|
||||||
LayoutSettings(*settings.get());
|
LayoutSettings(*settings.get());
|
||||||
DialogSaveLayout dialog(scenes.size(), expParams->OptExportPath(), this);
|
DialogSaveLayout dialog(scenes.size(), expParams->OptExportPath(), this);
|
||||||
|
dialog.SetFullPath(expParams->OptExportPath());
|
||||||
dialog.SelectFormate(expParams->OptExportType());
|
dialog.SelectFormate(expParams->OptExportType());
|
||||||
ExportLayout(dialog);
|
ExportLayout(dialog);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue
Block a user