Merge branch 'translation' of git://cockatrice.git.sourceforge.net/gitroot/cockatrice/cockatrice
This commit is contained in:
commit
d2c03496e7
7 changed files with 1009 additions and 989 deletions
|
@ -1,3 +1,4 @@
|
|||
#!/usr/bin/env xdg-open
|
||||
[Desktop Entry]
|
||||
Version=1.0
|
||||
Type=Application
|
||||
|
|
|
@ -134,12 +134,14 @@ void TabDeckStorage::actUpload()
|
|||
if (localDirModel->isDir(curLeft))
|
||||
return;
|
||||
QString filePath = localDirModel->filePath(curLeft);
|
||||
QFile deckFile(filePath);
|
||||
QFileInfo deckFileInfo(deckFile);
|
||||
DeckList *deck = new DeckList;
|
||||
if (!deck->loadFromFile(filePath, DeckList::CockatriceFormat))
|
||||
return;
|
||||
if (deck->getName().isEmpty()) {
|
||||
bool ok;
|
||||
QString deckName = QInputDialog::getText(this, tr("Enter deck name"), tr("This decklist does not have a name.\nPlease enter a name:"), QLineEdit::Normal, tr("Unnamed deck"), &ok);
|
||||
QString deckName = QInputDialog::getText(this, tr("Enter deck name"), tr("This decklist does not have a name.\nPlease enter a name:"), QLineEdit::Normal, deckFileInfo.completeBaseName(), &ok);
|
||||
if (!ok)
|
||||
return;
|
||||
if (deckName.isEmpty())
|
||||
|
|
|
@ -344,6 +344,7 @@ bool WndDeckEditor::actSaveDeckAs()
|
|||
dialog.setConfirmOverwrite(true);
|
||||
dialog.setDefaultSuffix("cod");
|
||||
dialog.setNameFilters(DeckList::fileNameFilters);
|
||||
dialog.selectFile(deckModel->getDeckList()->getName());
|
||||
if (!dialog.exec())
|
||||
return false;
|
||||
|
||||
|
|
File diff suppressed because it is too large
Load diff
File diff suppressed because it is too large
Load diff
File diff suppressed because it is too large
Load diff
File diff suppressed because it is too large
Load diff
Loading…
Reference in a new issue