Deck Load Mods and Movable Tabs

Changes:
Deck Load - Default to all types *.*
Decklist - Strip "|edition" from .dec formats that include a pipe and
the edition after the card name
Tab_Supervisor - Make tabs movable (able to rearrange tabs)
This commit is contained in:
jfreake 2014-01-08 11:54:02 -04:00
parent 95c6058dc3
commit 67c4d089be
3 changed files with 9 additions and 4 deletions

View file

@ -4,9 +4,9 @@
#include "decklist.h"
const QStringList DeckLoader::fileNameFilters = QStringList()
<< QObject::tr("All files (*.*)")
<< QObject::tr("Cockatrice decks (*.cod)")
<< QObject::tr("Plain text decks (*.dec *.mwDeck)")
<< QObject::tr("All files (*.*)");
<< QObject::tr("Plain text decks (*.dec *.mwDeck)");
DeckLoader::DeckLoader()
: DeckList(),
@ -94,8 +94,8 @@ bool DeckLoader::saveToFile(const QString &fileName, FileFormat fmt)
DeckLoader::FileFormat DeckLoader::getFormatFromNameFilter(const QString &selectedNameFilter)
{
switch (fileNameFilters.indexOf(selectedNameFilter)) {
case 0: return CockatriceFormat;
case 1: return PlainTextFormat;
case 1: return CockatriceFormat;
case 2: return PlainTextFormat;
}
return PlainTextFormat;
}