summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--plugins/NewStory/src/history_control.cpp10
1 files changed, 7 insertions, 3 deletions
diff --git a/plugins/NewStory/src/history_control.cpp b/plugins/NewStory/src/history_control.cpp
index 5a44e50107..419161855f 100644
--- a/plugins/NewStory/src/history_control.cpp
+++ b/plugins/NewStory/src/history_control.cpp
@@ -33,6 +33,11 @@ struct NewstoryListData : public MZeroedObject
HWND hwnd;
HWND hwndEditBox;
+ void OnContextMenu(int index)
+ {
+ ItemData* item = items.get(index, ItemData::ELM_DATA);
+ }
+
void BeginEditItem(int index)
{
if (hwndEditBox)
@@ -924,9 +929,8 @@ LRESULT CALLBACK NewstoryListWndProc(HWND hwnd, UINT msg, WPARAM wParam, LPARAM
case WM_CONTEXTMENU:
{
- HMENU menu = LoadMenu(g_plugin.getInst(), MAKEINTRESOURCE(IDR_POPUPS));
- HMENU submenu = GetSubMenu(menu, 2);
- TranslateMenu(submenu);
+ int index = SendMessage(hwnd, NSM_GETITEMFROMPIXEL, LOWORD(lParam), HIWORD(lParam));
+ data->OnContextMenu(index);
}
break;
}