diff options
Diffstat (limited to 'c/episodelistview.c')
-rw-r--r-- | c/episodelistview.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/c/episodelistview.c b/c/episodelistview.c index 1113b47..f1cc819 100644 --- a/c/episodelistview.c +++ b/c/episodelistview.c @@ -166,10 +166,11 @@ s: ListView_SetItemState(HElv, -1, LVIF_STATE, LVIS_SELECTED); void ElvUpdate() { - int i, iEpisode, iEpisodes, iEpisodeSelected[2048], iItem, iItemTopNew; + int i, iEpisode, iEpisodes, iItem, iItemTopNew; LVITEM lviEpisode, lviSelected, lviTop; LVFINDINFO lvfi; term_t t; + static int iEpisodeSelected[2048]; lviEpisode.mask = LVIF_TEXT|LVIF_PARAM; @@ -243,7 +244,7 @@ ElvUpdate() for (i = 0; iEpisodeSelected[i]; i++) { int iSel; lvfi.lParam = iEpisodeSelected[i]; - if ((iSel = ListView_FindItem(HElv, -1, &lvfi)) == -1) break; + if ((iSel = ListView_FindItem(HElv, -1, &lvfi)) == -1) continue; ListView_SetItemState(HElv, iSel, LVIS_SELECTED, LVIS_SELECTED); } |