diff options
author | George Hazan <ghazan@miranda.im> | 2020-05-04 16:11:14 +0300 |
---|---|---|
committer | George Hazan <ghazan@miranda.im> | 2020-05-04 16:11:14 +0300 |
commit | fa125faeee5c0021bb7f6ec9d182e7612561ff34 (patch) | |
tree | 3dc61080289702c1769749d854bbf6bde0eb9651 | |
parent | 055bae23041ae6817c9595714b80a0e0fdd77867 (diff) |
first working version of popup menu
-rw-r--r-- | plugins/NewStory/res/resource.rc | 15 | ||||
-rw-r--r-- | plugins/NewStory/src/history_control.cpp | 7 | ||||
-rw-r--r-- | plugins/NewStory/src/resource.h | 2 | ||||
-rw-r--r-- | plugins/TabSRMM/src/resource.h | 1 |
4 files changed, 9 insertions, 16 deletions
diff --git a/plugins/NewStory/res/resource.rc b/plugins/NewStory/res/resource.rc index 4172d75491..8d0d0adabf 100644 --- a/plugins/NewStory/res/resource.rc +++ b/plugins/NewStory/res/resource.rc @@ -385,25 +385,14 @@ BEGIN POPUP "" BEGIN MENUITEM "Copy", ID_CONTEXT_COPY + MENUITEM SEPARATOR + MENUITEM "Edit", ID_CONTEXT_EDIT MENUITEM "Delete", ID_CONTEXT_DELETE, GRAYED MENUITEM SEPARATOR MENUITEM "Select all", ID_CONTEXT_SELECTALL END END - -///////////////////////////////////////////////////////////////////////////// -// -// Accelerator -// - -IDR_ACCEL ACCELERATORS -BEGIN - "C", IDA_COPY, VIRTKEY, CONTROL, NOINVERT - "F", IDA_SEARCH, VIRTKEY, CONTROL, NOINVERT -END - - #ifdef APSTUDIO_INVOKED ///////////////////////////////////////////////////////////////////////////// // diff --git a/plugins/NewStory/src/history_control.cpp b/plugins/NewStory/src/history_control.cpp index 6e1f2dbd83..56dbaa9edc 100644 --- a/plugins/NewStory/src/history_control.cpp +++ b/plugins/NewStory/src/history_control.cpp @@ -50,8 +50,13 @@ struct NewstoryListData : public MZeroedObject int ret = TrackPopupMenu(GetSubMenu(hMenu, 0), TPM_RETURNCMD, pt.x, pt.y, 0, hwnd, nullptr); switch(ret) { case ID_CONTEXT_COPY: + SendMessage(hwnd, NSM_COPY, 0, 0); break; - + + case ID_CONTEXT_EDIT: + BeginEditItem(index); + break; + case ID_CONTEXT_DELETE: break; diff --git a/plugins/NewStory/src/resource.h b/plugins/NewStory/src/resource.h index 0b4511f7f1..9d2340ba58 100644 --- a/plugins/NewStory/src/resource.h +++ b/plugins/NewStory/src/resource.h @@ -9,7 +9,6 @@ #define IDR_CONTEXTMENU 106 #define IDD_MESSAGE 112 #define IDR_POPUPS 113 -#define IDR_ACCEL 114 #define IDD_CALENDARTOOL 118 #define IDD_FILTERMODE 123 #define ICO_NEWSTORY 127 @@ -124,6 +123,7 @@ #define ID_FILTER_AUTO 40022 #define ID_LOGOPTIONS_TEMPLATES 40023 #define ID_LOGOPTIONS_OPTIONS 40024 +#define ID_CONTEXT_EDIT 40025 #define ID_CONTEXT_DELETE 40026 #define ID_CONTEXT_SELECTALL 40027 #define ID_CONTEXT_CANCEL 40028 diff --git a/plugins/TabSRMM/src/resource.h b/plugins/TabSRMM/src/resource.h index 59b1b504ba..aa34e55036 100644 --- a/plugins/TabSRMM/src/resource.h +++ b/plugins/TabSRMM/src/resource.h @@ -46,7 +46,6 @@ #define IDD_MSGCONTAINER 276
#define IDD_OPT_TABBEDMSG 277
#define IDD_POPUP_OPT 278
-#define IDR_ACCEL 283
#define IDR_TABCONTEXT 286
#define IDD_SELECTCONTAINER 299
#define IDD_CONTAINEROPTIONS 300
|