Skip to content

Commit

Permalink
insert and edit mode of snippet list
Browse files Browse the repository at this point in the history
  • Loading branch information
erinata committed Oct 19, 2011
1 parent 72e5bcb commit 05b6057
Show file tree
Hide file tree
Showing 9 changed files with 142 additions and 78 deletions.
1 change: 1 addition & 0 deletions Changelog.txt
Expand Up @@ -5,6 +5,7 @@ changelog (for developer use only, include unreleased versions)
****** Added: more informative save snippet confirmation message
****** Changed: remove spaces in insertion dialog hint
****** Fixed: snippet editor not openning when live update show no snippet
****** Added: Insert and edit mode

0.5.45.1
****** multiple scopes support
Expand Down
9 changes: 6 additions & 3 deletions Config/PluginConfig.h
Expand Up @@ -35,7 +35,7 @@
//#include "Version.h"

// Config file content
#define CONFIG_INT_COUNT 14
#define CONFIG_INT_COUNT 15
#define CONFIG_TEXT_COUNT 3

#define SNIPPET_LIST_ORDER_TAG_TYPE 0
Expand All @@ -52,6 +52,7 @@
#define USE_NPP_SHORTKEY 11
#define FALLBACK_TAB 12
#define INSERTION_DIALOG_STATE 13
#define INSERT_MODE 14


#define CUSTOM_SCOPE 0
Expand All @@ -73,7 +74,8 @@ const int configIntDefault[CONFIG_INT_COUNT] =
1, // FORCE_MULTI_PASTE
1, // USE_NPP_SHORTKEY
0, // FALLBACK_TAB
0 // INSERTION_DIALOG_STATE
0, // INSERTION_DIALOG_STATE
1 // INSERT_MODE


};
Expand All @@ -93,7 +95,8 @@ const TCHAR configIntNames[CONFIG_INT_COUNT][MAX_PATH] =
TEXT("force_multipaste"),
TEXT("use_npp_shortkey"),
TEXT("fallback_tab"),
TEXT("insertion_dialog_state")
TEXT("insertion_dialog_state"),
TEXT("insert_mode")

};

Expand Down
7 changes: 6 additions & 1 deletion Dialogs/Dialog.h
Expand Up @@ -1211,12 +1211,17 @@
#define psh1 0x0400
#define _WIN32_IE_IE401 0x0401
#define psh2 0x0401
#define IDC_RADIO_INSERT 1025
#define psh3 0x0402
#define IDC_STATIC_TEXT4 1026
#define psh4 0x0403
#define IDC_STATIC_TEXT5 1027
#define IDC_RADIO_EDIT 1027
#define psh5 0x0404
#define IDC_STATIC_TEXT6 1028
#define psh6 0x0405
#define IDC_GETMOE 1029
#define IDC_GETMORE 1029
#define psh7 0x0406
#define psh8 0x0407
#define psh9 0x0408
Expand Down Expand Up @@ -1552,7 +1557,7 @@
#ifndef APSTUDIO_READONLY_SYMBOLS
#define _APS_NEXT_RESOURCE_VALUE 101
#define _APS_NEXT_COMMAND_VALUE 40001
#define _APS_NEXT_CONTROL_VALUE 1022
#define _APS_NEXT_CONTROL_VALUE 1030
#define _APS_NEXT_SYMED_VALUE 101
#endif
#endif
26 changes: 14 additions & 12 deletions Dialogs/Dialog.rc
Expand Up @@ -56,28 +56,30 @@ EXSTYLE WS_EX_TRANSPARENT
CAPTION "FingerText"
FONT 10, "Consolas", 0, 0, 0x0
BEGIN
LISTBOX IDC_SNIPPET_LIST,3,339,158,68,LBS_USETABSTOPS | LBS_NOINTEGRALHEIGHT | NOT WS_BORDER | WS_VSCROLL | WS_HSCROLL | WS_TABSTOP,WS_EX_CLIENTEDGE
LISTBOX IDC_SNIPPET_LIST,3,277,158,130,LBS_USETABSTOPS | LBS_NOINTEGRALHEIGHT | NOT WS_BORDER | WS_VSCROLL | WS_HSCROLL | WS_TABSTOP,WS_EX_CLIENTEDGE
PUSHBUTTON "New Snippet",IDC_NEW,7,153,58,11
PUSHBUTTON "Edit Selected",IDC_EDIT,7,165,60,10
PUSHBUTTON "Save Selected",IDC_SAVE,68,165,58,9
PUSHBUTTON "Delete Selected",IDC_DELETE,9,174,59,11
PUSHBUTTON "Save Current Snippet",IDC_SAVE,68,165,58,10
PUSHBUTTON "Delete Selected",IDC_DELETE,2,176,66,9
EDITTEXT IDC_PREVIEW_EDIT,5,75,155,12,ES_READONLY | NOT WS_TABSTOP,WS_EX_TRANSPARENT
EDITTEXT ID_SNIPSHOW_EDIT,5,87,155,63,ES_MULTILINE | ES_READONLY | NOT WS_TABSTOP,WS_EX_CLIENTEDGE
PUSHBUTTON "Create Snippet From Selection",IDC_CREATESELECTION,3,212,80,12,BS_MULTILINE
PUSHBUTTON "Insert Selected Snippet",IDC_INSERT,2,226,80,13,BS_MULTILINE
PUSHBUTTON "Create Snippet From Selection",IDC_CREATESELECTION,3,212,80,12
LTEXT "Preview",IDC_STATIC_TEXT,5,63,127,8
PUSHBUTTON "Switch To Snippet Editor",IDC_OPENEDITOR,5,240,78,14
PUSHBUTTON "Close Editor",IDC_CLOSEEDITOR,91,240,50,14
PUSHBUTTON "Switch To Snippet Editor",IDC_OPENEDITOR,5,240,78,9
PUSHBUTTON "Close Editor",IDC_CLOSEEDITOR,91,240,50,10
PUSHBUTTON "Import ftd File",IDC_IMPORTFILE,7,186,64,9
PUSHBUTTON "Export Current List",IDC_EXPORT,2,198,75,10
PUSHBUTTON "Export All",IDC_EXPORTALL,77,199,51,9
PUSHBUTTON "Delete All",IDC_DELETEALL,69,174,71,9
PUSHBUTTON "Delete All",IDC_DELETEALL,69,176,71,9
EDITTEXT IDC_FILTER,7,44,124,14,ES_AUTOHSCROLL
LTEXT "Filter",IDC_STATIC_TEXT2,7,33,127,8
LTEXT "Filter",IDC_STATIC_TEXT2,7,33,55,8
PUSHBUTTON "Import from URL",IDC_IMPORTURL,75,186,62,10
LTEXT "Snippet Management",IDC_STATIC_TEXT3,6,24,127,8
LTEXT "Snippet List (Double Click to Insert)",IDC_STATIC_TEXT4,6,4,156,9
LTEXT "Snippet List (Double Click to Edit)",IDC_STATIC_TEXT5,2,14,156,9
LTEXT "Snippet Management",IDC_STATIC_TEXT3,6,19,72,8
LTEXT "Snippet List",IDC_STATIC_TEXT4,86,27,52,9
CONTROL "Insert",IDC_RADIO_INSERT,"Button",BS_AUTORADIOBUTTON,16,260,40,10
CONTROL "Edit",IDC_RADIO_EDIT,"Button",BS_AUTORADIOBUTTON,79,260,32,10
LTEXT "Snippet List (Double Click to Edit)",IDC_STATIC_TEXT6,54,37,99,9
PUSHBUTTON "Download more snippets (coming soon)",IDC_GETMORE,6,227,50,14
END

IDD_INSERTION_DLG DIALOGEX 0, 0, 319, 221
Expand Down

0 comments on commit 05b6057

Please sign in to comment.