diff --git a/src/drivers/win/res.rc b/src/drivers/win/res.rc index 7ebe773e..a86ce93c 100644 --- a/src/drivers/win/res.rc +++ b/src/drivers/win/res.rc @@ -132,6 +132,8 @@ BEGIN MENUITEM "&Alternate A and B", MENU_ALTERNATE_AB MENUITEM SEPARATOR MENUITEM "Use &External Input", MENU_EXTERNAL_INPUT + MENUITEM SEPARATOR + MENUITEM "Text Hooker", ID_TOOLS_TEXTHOOKER END POPUP "&Debug" BEGIN @@ -1576,6 +1578,45 @@ BEGIN CONTROL "",IDC_LIST1,"SysListView32",LVS_REPORT | LVS_ALIGNLEFT | WS_BORDER | WS_TABSTOP,7,7,311,214 END +TEXTHOOKER DIALOGEX 0, 0, 456, 327 +STYLE DS_SETFONT | DS_MODALFRAME | DS_FIXEDSYS | WS_POPUP | WS_CAPTION | WS_SYSMENU +CAPTION "Text Hooker" +FONT 8, "MS Shell Dlg", 400, 0, 0x1 +BEGIN + GROUPBOX "Selection Window",1,0,0,183,164,0,WS_EX_NOPARENTNOTIFY + EDITTEXT 102,207,13,216,94,ES_MULTILINE | ES_AUTOVSCROLL | ES_WANTRETURN | NOT WS_BORDER | WS_VSCROLL,WS_EX_NOPARENTNOTIFY | WS_EX_CLIENTEDGE + GROUPBOX "Hooked Text",103,200,0,229,131,0,WS_EX_NOPARENTNOTIFY + PUSHBUTTON "Load Table",104,3,169,60,14,0,WS_EX_NOPARENTNOTIFY + PUSHBUTTON "Clear Selection",105,67,169,60,14,0,WS_EX_NOPARENTNOTIFY + PUSHBUTTON "Pause",106,67,190,60,14,0,WS_EX_NOPARENTNOTIFY + PUSHBUTTON "Snap",107,130,169,60,35,0,WS_EX_NOPARENTNOTIFY + PUSHBUTTON "Clear Buffer",108,208,111,60,14,0,WS_EX_NOPARENTNOTIFY + EDITTEXT 111,5,249,115,14,ES_AUTOHSCROLL | NOT WS_BORDER,WS_EX_NOPARENTNOTIFY | WS_EX_CLIENTEDGE + PUSHBUTTON "Save Selection",112,130,249,60,14,0,WS_EX_NOPARENTNOTIFY + PUSHBUTTON "Save Table",113,3,190,60,14,0,WS_EX_NOPARENTNOTIFY + PUSHBUTTON "Load Selection",114,130,268,60,14,0,WS_EX_NOPARENTNOTIFY + GROUPBOX "Translated Text",115,200,140,229,117,0,WS_EX_NOPARENTNOTIFY + EDITTEXT 116,207,156,214,95,ES_MULTILINE | ES_AUTOVSCROLL | ES_WANTRETURN | NOT WS_BORDER | WS_VSCROLL,WS_EX_NOPARENTNOTIFY | WS_EX_CLIENTEDGE + PUSHBUTTON "Excite.co.jp",117,281,111,60,14,0,WS_EX_NOPARENTNOTIFY + LTEXT "Scanline:",118,5,210,50,8,0,WS_EX_NOPARENTNOTIFY + LTEXT "Update every x frames:",119,68,210,79,8,0,WS_EX_NOPARENTNOTIFY + EDITTEXT 120,5,220,52,14,ES_AUTOHSCROLL | NOT WS_BORDER,WS_EX_NOPARENTNOTIFY | WS_EX_CLIENTEDGE + EDITTEXT 121,68,220,52,14,ES_AUTOHSCROLL | NOT WS_BORDER,WS_EX_NOPARENTNOTIFY | WS_EX_CLIENTEDGE + PUSHBUTTON "Trim",122,351,111,60,14 + COMBOBOX 109,5,269,115,100,CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP + LTEXT "Japanese:",-1,5,283,47,9 + EDITTEXT 131,5,292,115,14,ES_AUTOHSCROLL + LTEXT "English:",-1,130,283,47,9 + EDITTEXT 132,130,292,115,14,ES_AUTOHSCROLL + PUSHBUTTON "Add Definition",133,253,292,60,14 + CONTROL "Selection Window",341,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,324,261,80,9 + CONTROL "Word Substitution",342,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,324,274,80,9 + LTEXT "(han)dakuten mark position:",-1,324,286,92,8 + CONTROL "Above",343,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,324,297,37,10 + CONTROL "Right",344,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,363,297,33,10 + LTEXT "New Selection Name:",-1,5,240,68,8 +END + ///////////////////////////////////////////////////////////////////////////// // @@ -1592,6 +1633,14 @@ BEGIN TOPMARGIN, 7 BOTTOMMARGIN, 243 END + + TEXTHOOKER, DIALOG + BEGIN + LEFTMARGIN, 7 + RIGHTMARGIN, 449 + TOPMARGIN, 7 + BOTTOMMARGIN, 320 + END END #endif // APSTUDIO_INVOKED diff --git a/src/drivers/win/resource.h b/src/drivers/win/resource.h index 86585c25..196f91c7 100644 --- a/src/drivers/win/resource.h +++ b/src/drivers/win/resource.h @@ -130,6 +130,8 @@ #define IDD_DIALOG2 115 #define LBL_CLEAR_AH 116 #define IDC_CHECK_LOG_UPDATE_WINDOW 116 +#define IDD_DIALOG3 120 +#define TEXTHOOKER 120 #define CHECK_SOUND_8BIT 122 #define CHECK_SOUND_GLOBAL_FOCUS 124 #define CHECK_SOUND_ENABLED 126 @@ -535,6 +537,7 @@ #define MENU_DELETEFRAME 40155 #define MENU_DELETEFRAMES 40156 #define MENU_STRAY_INSERTFRAMES 40157 +#define ID_TOOLS_TEXTHOOKER 40158 #define MW_ValueLabel2 65423 #define MW_ValueLabel1 65426 #define GUI_BOT_DEBUG 65436 @@ -544,8 +547,8 @@ // #ifdef APSTUDIO_INVOKED #ifndef APSTUDIO_READONLY_SYMBOLS -#define _APS_NEXT_RESOURCE_VALUE 118 -#define _APS_NEXT_COMMAND_VALUE 40158 +#define _APS_NEXT_RESOURCE_VALUE 121 +#define _APS_NEXT_COMMAND_VALUE 40159 #define _APS_NEXT_CONTROL_VALUE 1133 #define _APS_NEXT_SYMED_VALUE 101 #endif diff --git a/src/drivers/win/window.cpp b/src/drivers/win/window.cpp index 7310b25f..7e3d9ce8 100644 --- a/src/drivers/win/window.cpp +++ b/src/drivers/win/window.cpp @@ -50,7 +50,7 @@ #include "oldmovie.h" #include "movie.h" #include "7zip.h" - +#include "texthook.h" #include "guiconfig.h" #include "timing.h" #include "palette.h" @@ -1151,6 +1151,10 @@ LRESULT FAR PASCAL AppWndProc(HWND hWnd,UINT msg,WPARAM wParam,LPARAM lParam) FCEUD_AviStop(); break; + case ID_TOOLS_TEXTHOOKER: + DoTextHooker(); + break; + case MENU_ABOUT: // About menu was selected ShowAboutBox(); diff --git a/vc8/fceux.vcproj b/vc8/fceux.vcproj index 282f3214..6a555715 100644 --- a/vc8/fceux.vcproj +++ b/vc8/fceux.vcproj @@ -181,7 +181,7 @@ /> + + + + @@ -1474,7 +1482,7 @@ > @@ -1483,7 +1491,7 @@ >