aboutsummaryrefslogtreecommitdiff
path: root/c/listview.c
diff options
context:
space:
mode:
Diffstat (limited to 'c/listview.c')
-rw-r--r--c/listview.c14
1 files changed, 14 insertions, 0 deletions
diff --git a/c/listview.c b/c/listview.c
index 7039e89..3025297 100644
--- a/c/listview.c
+++ b/c/listview.c
@@ -47,6 +47,20 @@ LvProc(HWND hLv, UINT uMsg, WPARAM wParam, LPARAM lParam)
return TRUE;
}
break;
+ case WM_GETDLGCODE: /* Open episode on Enter. */
+ {
+ LRESULT lResult;
+ extern HWND HElv;
+ extern LPLVITEM LpLviElvSelection;
+ if (hLv != HElv) break;
+ lResult = CallWindowProc(LvPrevProc, hLv, uMsg, wParam, lParam);
+ if (lParam && ((MSG *)lParam)->message == WM_KEYDOWN
+ && ((MSG *)lParam)->wParam == VK_RETURN) {
+ lResult &= ~DLGC_WANTMESSAGE;
+ ElvEnter(LpLviElvSelection);
+ }
+ return lResult;
+ }
}
return CallWindowProc(LvPrevProc, hLv, uMsg, wParam, lParam);