Updated Parameter cast to pass in DeckImport Constructor

DeckImport will now get an instance of the CDeckEditor rather than the more generic ACEditorBase.
This is to allow more refined access to methods. Also, all lives in forge-gui-desktop, therefore there should be no conflict with mobile app ui.

Signed-off-by: leriomaggio <valeriomaggio@gmail.com>
This commit is contained in:
leriomaggio
2021-10-02 08:25:47 +01:00
parent 08ca0bf175
commit f065d460c3

View File

@@ -119,8 +119,8 @@ public enum CCurrentDeck implements ICDoc {
* Opens dialog for importing a deck from a different MTG software.
*/
@SuppressWarnings({ "unchecked", "rawtypes" })
private <TItem extends InventoryItem, TModel extends DeckBase> void importDeck() {
final ACEditorBase<TItem, TModel> ed = (ACEditorBase<TItem, TModel>)
private <TModel extends DeckBase> void importDeck() {
final CDeckEditor<TModel> ed = (CDeckEditor<TModel>)
CDeckEditorUI.SINGLETON_INSTANCE.getCurrentEditorController();
final DeckImport dImport = new DeckImport(ed);
dImport.setModalityType(ModalityType.APPLICATION_MODAL);