aboutsummaryrefslogtreecommitdiff
path: root/c/main.cpp
diff options
context:
space:
mode:
authorJohn Ankarström <john@ankarstrom.se>2022-08-24 13:14:12 +0200
committerJohn Ankarström <john@ankarstrom.se>2022-08-24 13:14:12 +0200
commit15a09ae4bd7cc686d1be6735b4e72cf490776f11 (patch)
tree1bef2467cbe2ad32410481fc45072e5a88a4a171 /c/main.cpp
parent7e353754aa3aeb6a795104fc641924e21014d00b (diff)
downloadEpisodeBrowser-15a09ae4bd7cc686d1be6735b4e72cf490776f11.tar.gz
Re-enable screenwriter limit.
Diffstat (limited to 'c/main.cpp')
-rw-r--r--c/main.cpp14
1 files changed, 6 insertions, 8 deletions
diff --git a/c/main.cpp b/c/main.cpp
index 8916860..5935ee1 100644
--- a/c/main.cpp
+++ b/c/main.cpp
@@ -221,7 +221,7 @@ LRESULT CALLBACK HandleMsg(const HWND hWnd, const UINT uMsg, const WPARAM wParam
/* Set menu item checkmarks according to saved settings. */
CheckMenuItem(GetMenu(hWnd), IDM_VIEW_WATCHED, g_cfg.bViewWatched? MF_CHECKED: MF_UNCHECKED);
CheckMenuItem(GetMenu(hWnd), IDM_VIEW_TV_ORIGINAL, g_cfg.bViewTVOriginal? MF_CHECKED: MF_UNCHECKED);
- CheckMenuItem(GetMenu(hWnd), IDM_VIEW_OTHERS, g_cfg.limitScreenwriter[0]? MF_UNCHECKED: MF_CHECKED);
+ CheckMenuItem(GetMenu(hWnd), IDM_VIEW_OTHERS, g_cfg.limitToScreenwriter[0]? MF_UNCHECKED: MF_CHECKED);
return 0;
case WM_CLOSE:
@@ -319,7 +319,7 @@ LRESULT CALLBACK HandleMsg(const HWND hWnd, const UINT uMsg, const WPARAM wParam
/*IDM_VIEW_TV_ORIGINAL*/(g_cfg.bViewTVOriginal?
L"Click to hide TV original episodes.":
L"Click to show TV original episodes."),
- /*IDM_VIEW_OTHERS*/(g_cfg.limitScreenwriter?
+ /*IDM_VIEW_OTHERS*/(g_cfg.limitToScreenwriter?
L"Click to hide episodes by other screenwriters.":
L"Click to show episodes by other screenwriters.")
};
@@ -420,16 +420,14 @@ void HandleMainMenu(const HWND hWnd, const WORD command)
break;
case IDM_VIEW_OTHERS:
- if (g_cfg.limitScreenwriter[0]) { /* Show episodes by all screenwriters. */
+ if (g_cfg.limitToScreenwriter[0]) { /* Show episodes by all screenwriters. */
CheckMenuItem(GetMenu(hWnd), IDM_VIEW_OTHERS, MF_CHECKED);
- g_cfg.limitScreenwriter[0] = 0;
+ g_cfg.limitToScreenwriter[0] = 0;
} else { /* Hide episodes by other screenwriters than current. */
- Mark m;
- WcharPtr s;
LVITEM lvi = {LVIF_PARAM, -1};
if (g_elv->FindNextItem(&lvi, LVNI_FOCUSED)
- && Pl("episode_data","episode_datum",lvi.lParam,"Screenwriter",&s)) {
- Wcscpy(g_cfg.limitScreenwriter, s);
+ && g_fvDlv.At(lvi.lParam-1).screenwriter[0]) {
+ Wcscpy(g_cfg.limitToScreenwriter, g_fvDlv.At(lvi.lParam-1).screenwriter);
CheckMenuItem(GetMenu(hWnd), IDM_VIEW_OTHERS, MF_UNCHECKED);
}
}