ID:1752439
 
Code:
    UpdateGraveyardWindow(mob/A)
A << output(null, "duelListViewer.cards")
var/i = 0
for(var/obj/card/B in A.graveyard)
winset(A, "duelListViewer.cards","current-cell=[++i]")
A << output(B, "duelListViewer.cards")


Problem description:
duelListViewer will not clear if the new list to be viewed length is 0. For example, If I want to view another list in the same window and the list is blank, the current list active will not clear.
To clear a grid set it's cells property to a size of "0x0" (or just "0" if is-list is set).

In your case, you'd be better off setting it to the expected size, as otherwise it may flicker when updating:
    UpdateGraveyardWindow(mob/A)
var/i = 0
for(var/obj/card/B in A.graveyard)
A << output(B, "duelListViewer.cards:[++i]")
winset(A, "duelListViewer.cards","cells=[i]")


I also updated your output() usage to specify the cell directly, to avoid an extra winset() call. You can read more about this syntax In the Skin Guide.