mirror of
https://github.com/Cockatrice/Cockatrice.git
synced 2026-04-27 07:48:01 -07:00
Add pricing from deckbrew.com
* the previous PriceUpdater class has become abstract * BLPPriceUpdater inherits the old code for blacklotusproject.com * DBPriceUpdater is a new implementation for deckbrew.com * add a setting to choose between the two
This commit is contained in:
parent
ec3690fd29
commit
922e98af67
7 changed files with 222 additions and 12 deletions
|
|
@ -644,7 +644,18 @@ void TabDeckEditor::setPriceTagFeatureEnabled(int enabled)
|
|||
void TabDeckEditor::actUpdatePrices()
|
||||
{
|
||||
aUpdatePrices->setDisabled(true);
|
||||
PriceUpdater *up = new PriceUpdater(deckModel->getDeckList());
|
||||
AbstractPriceUpdater *up;
|
||||
|
||||
switch(settingsCache->getPriceTagSource())
|
||||
{
|
||||
case 0:
|
||||
up = new BLPPriceUpdater(deckModel->getDeckList());
|
||||
break;
|
||||
case 1:
|
||||
up = new DBPriceUpdater(deckModel->getDeckList());
|
||||
break;
|
||||
}
|
||||
|
||||
connect(up, SIGNAL(finishedUpdate()), this, SLOT(finishedUpdatingPrices()));
|
||||
up->updatePrices();
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue