1. Mark cheat affected address range in RAM search and RAM watch.
2. RAM Watch now can give separator a name. 3. Reconstruct watch manage logic, removed IDD_PROMPT.
This commit is contained in:
parent
3f6475c268
commit
99636689d7
|
@ -136,6 +136,14 @@ void FCEU_PowerCheats()
|
||||||
RebuildSubCheats();
|
RebuildSubCheats();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
int FCEU_CalcCheatAffectedBytes(uint32 address, uint32 size) {
|
||||||
|
int count = 0;
|
||||||
|
for (int i = 0; i < numsubcheats && count < size; ++i)
|
||||||
|
if (SubCheats[i].addr >= address && SubCheats[i].addr < address + size)
|
||||||
|
++count;
|
||||||
|
return count;
|
||||||
|
}
|
||||||
|
|
||||||
static int AddCheatEntry(char *name, uint32 addr, uint8 val, int compare, int status, int type);
|
static int AddCheatEntry(char *name, uint32 addr, uint8 val, int compare, int status, int type);
|
||||||
static void CheatMemErr(void)
|
static void CheatMemErr(void)
|
||||||
{
|
{
|
||||||
|
|
11
src/cheat.h
11
src/cheat.h
|
@ -5,6 +5,8 @@ void FCEU_LoadGameCheats(FILE *override);
|
||||||
void FCEU_FlushGameCheats(FILE *override, int nosave);
|
void FCEU_FlushGameCheats(FILE *override, int nosave);
|
||||||
void FCEU_ApplyPeriodicCheats(void);
|
void FCEU_ApplyPeriodicCheats(void);
|
||||||
void FCEU_PowerCheats(void);
|
void FCEU_PowerCheats(void);
|
||||||
|
int FCEU_CalcCheatAffectedBytes(uint32 address, uint32 size);
|
||||||
|
|
||||||
|
|
||||||
int FCEU_CheatGetByte(uint32 A);
|
int FCEU_CheatGetByte(uint32 A);
|
||||||
void FCEU_CheatSetByte(uint32 A, uint8 V);
|
void FCEU_CheatSetByte(uint32 A, uint8 V);
|
||||||
|
@ -28,4 +30,11 @@ struct CHEATF {
|
||||||
int compare; /* -1 for no compare. */
|
int compare; /* -1 for no compare. */
|
||||||
int type; /* 0 for replace, 1 for substitute(GG). */
|
int type; /* 0 for replace, 1 for substitute(GG). */
|
||||||
int status;
|
int status;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
|
#define CalcAddressRangeCheatCount(count, address, size) \
|
||||||
|
count = 0; \
|
||||||
|
for (int i = 0; i < numsubcheats && count < size; ++i) \
|
||||||
|
if (SubCheats[i].addr >= address && SubCheats[i].addr < address + size) \
|
||||||
|
++count;
|
||||||
|
|
|
@ -1053,9 +1053,21 @@ void DisableAllCheats()
|
||||||
|
|
||||||
void UpdateCheatWindowRelatedWindow()
|
void UpdateCheatWindowRelatedWindow()
|
||||||
{
|
{
|
||||||
|
// hex editor
|
||||||
if (hMemView)
|
if (hMemView)
|
||||||
UpdateColorTable(); //if the memory viewer is open then update any blue freeze locations in it as well
|
UpdateColorTable(); //if the memory viewer is open then update any blue freeze locations in it as well
|
||||||
extern HWND RamSearchHWnd;
|
extern HWND RamSearchHWnd;
|
||||||
|
|
||||||
|
// ram search
|
||||||
if (RamSearchHWnd)
|
if (RamSearchHWnd)
|
||||||
RedrawWindow(GetDlgItem(RamSearchHWnd, IDC_RAMLIST), NULL, NULL, RDW_INVALIDATE); // if ram search is open then update the ram list.
|
RedrawWindow(GetDlgItem(RamSearchHWnd, IDC_RAMLIST), NULL, NULL, RDW_INVALIDATE); // if ram search is open then update the ram list.
|
||||||
|
|
||||||
|
// ram watch
|
||||||
|
extern void UpdateWatchCheats();
|
||||||
|
UpdateWatchCheats();
|
||||||
|
extern HWND RamWatchHWnd;
|
||||||
|
if (RamWatchHWnd)
|
||||||
|
RedrawWindow(GetDlgItem(RamWatchHWnd, IDC_WATCHLIST), NULL, NULL, RDW_INVALIDATE); // update the data in watch list to the newest.
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
|
@ -17,4 +17,4 @@ extern std::vector<uint16> FrozenAddresses;
|
||||||
|
|
||||||
void DisableAllCheats();
|
void DisableAllCheats();
|
||||||
|
|
||||||
void UpdateCheatWindowRelatedWindow();
|
void UpdateCheatWindowRelatedWindow();
|
||||||
|
|
|
@ -423,10 +423,7 @@ void ItemIndexToVirtualRegion(unsigned int itemIndex, MemoryRegion& virtualRegio
|
||||||
virtualRegion.virtualIndex = region->virtualIndex + bytesWithinRegion;
|
virtualRegion.virtualIndex = region->virtualIndex + bytesWithinRegion;
|
||||||
virtualRegion.itemIndex = itemIndex;
|
virtualRegion.itemIndex = itemIndex;
|
||||||
|
|
||||||
virtualRegion.cheatCount = 0;
|
virtualRegion.cheatCount = FCEU_CalcCheatAffectedBytes(virtualRegion.hardwareAddress, virtualRegion.size);
|
||||||
for (int i = 0; i < numsubcheats && virtualRegion.cheatCount <= virtualRegion.size; ++i)
|
|
||||||
if (SubCheats[i].addr >= virtualRegion.hardwareAddress && SubCheats[i].addr < virtualRegion.hardwareAddress + virtualRegion.size)
|
|
||||||
++virtualRegion.cheatCount;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
template<typename stepType, typename compareType>
|
template<typename stepType, typename compareType>
|
||||||
|
@ -995,7 +992,6 @@ bool WriteValueAtHardwareAddress(HWAddressType address, unsigned int value, unsi
|
||||||
int ResultCount=0;
|
int ResultCount=0;
|
||||||
bool AutoSearch=false;
|
bool AutoSearch=false;
|
||||||
bool AutoSearchAutoRetry=false;
|
bool AutoSearchAutoRetry=false;
|
||||||
LRESULT CALLBACK PromptWatchNameProc(HWND, UINT, WPARAM, LPARAM);
|
|
||||||
void UpdatePossibilities(int rs_possible, int regions);
|
void UpdatePossibilities(int rs_possible, int regions);
|
||||||
|
|
||||||
|
|
||||||
|
@ -2185,9 +2181,12 @@ void init_list_box(HWND Box, const char* Strs[], int numColumns, int *columnWidt
|
||||||
{
|
{
|
||||||
LVCOLUMN Col;
|
LVCOLUMN Col;
|
||||||
Col.mask = LVCF_FMT | LVCF_ORDER | LVCF_SUBITEM | LVCF_TEXT | LVCF_WIDTH;
|
Col.mask = LVCF_FMT | LVCF_ORDER | LVCF_SUBITEM | LVCF_TEXT | LVCF_WIDTH;
|
||||||
Col.fmt = LVCFMT_RIGHT;
|
|
||||||
for (int i = 0; i < numColumns; i++)
|
for (int i = 0; i < numColumns; i++)
|
||||||
{
|
{
|
||||||
|
if (i == 1)
|
||||||
|
Col.fmt = LVCFMT_RIGHT;
|
||||||
|
else
|
||||||
|
Col.fmt = LVCFMT_LEFT;
|
||||||
Col.iOrder = i;
|
Col.iOrder = i;
|
||||||
Col.iSubItem = i;
|
Col.iSubItem = i;
|
||||||
Col.pszText = (LPSTR)(Strs[i]);
|
Col.pszText = (LPSTR)(Strs[i]);
|
||||||
|
|
|
@ -48,7 +48,7 @@ HWND RamWatchHWnd;
|
||||||
#define gamefilename GetRomName()
|
#define gamefilename GetRomName()
|
||||||
#define hWnd hAppWnd
|
#define hWnd hAppWnd
|
||||||
#define hInst fceu_hInstance
|
#define hInst fceu_hInstance
|
||||||
static char Str_Tmp [1024];
|
// static char Str_Tmp [1024];
|
||||||
|
|
||||||
void init_list_box(HWND Box, const char* Strs[], int numColumns, int *columnWidths); //initializes the ram search and/or ram watch listbox
|
void init_list_box(HWND Box, const char* Strs[], int numColumns, int *columnWidths); //initializes the ram search and/or ram watch listbox
|
||||||
|
|
||||||
|
@ -105,15 +105,22 @@ bool InsertWatch(const AddressWatcher& Watch, char *Comment)
|
||||||
AddressWatcher& NewWatch = rswatches[i];
|
AddressWatcher& NewWatch = rswatches[i];
|
||||||
NewWatch = Watch;
|
NewWatch = Watch;
|
||||||
//if (NewWatch.comment) free(NewWatch.comment);
|
//if (NewWatch.comment) free(NewWatch.comment);
|
||||||
NewWatch.comment = (char *) malloc(strlen(Comment)+2);
|
if (NewWatch.comment == NULL)
|
||||||
NewWatch.CurValue = GetCurrentValue(NewWatch);
|
NewWatch.comment = (char *)malloc(strlen(Comment) + 2);
|
||||||
|
else
|
||||||
|
NewWatch.comment = (char *)realloc(NewWatch.comment, strlen(Comment) + 2);
|
||||||
strcpy(NewWatch.comment, Comment);
|
strcpy(NewWatch.comment, Comment);
|
||||||
|
|
||||||
|
NewWatch.CurValue = GetCurrentValue(NewWatch);
|
||||||
|
extern int FCEU_CalcCheatAffectedBytes(uint32, uint32);
|
||||||
|
NewWatch.Cheats = FCEU_CalcCheatAffectedBytes(NewWatch.Address, WatchSizeConv(NewWatch));
|
||||||
ListView_SetItemCount(GetDlgItem(RamWatchHWnd,IDC_WATCHLIST),WatchCount);
|
ListView_SetItemCount(GetDlgItem(RamWatchHWnd,IDC_WATCHLIST),WatchCount);
|
||||||
RWfileChanged=true;
|
RWfileChanged=true;
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/*
|
||||||
LRESULT CALLBACK PromptWatchNameProc(HWND hDlg, UINT uMsg, WPARAM wParam, LPARAM lParam) //Gets the description of a watched address
|
LRESULT CALLBACK PromptWatchNameProc(HWND hDlg, UINT uMsg, WPARAM wParam, LPARAM lParam) //Gets the description of a watched address
|
||||||
{
|
{
|
||||||
RECT r;
|
RECT r;
|
||||||
|
@ -168,7 +175,7 @@ LRESULT CALLBACK PromptWatchNameProc(HWND hDlg, UINT uMsg, WPARAM wParam, LPARAM
|
||||||
|
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
*/
|
||||||
bool InsertWatch(const AddressWatcher& Watch, HWND parent)
|
bool InsertWatch(const AddressWatcher& Watch, HWND parent)
|
||||||
{
|
{
|
||||||
if(!VerifyWatchNotAlreadyAdded(Watch))
|
if(!VerifyWatchNotAlreadyAdded(Watch))
|
||||||
|
@ -183,7 +190,7 @@ bool InsertWatch(const AddressWatcher& Watch, HWND parent)
|
||||||
|
|
||||||
rswatches[WatchCount] = Watch;
|
rswatches[WatchCount] = Watch;
|
||||||
rswatches[WatchCount].CurValue = GetCurrentValue(rswatches[WatchCount]);
|
rswatches[WatchCount].CurValue = GetCurrentValue(rswatches[WatchCount]);
|
||||||
DialogBox(hInst, MAKEINTRESOURCE(IDD_PROMPT), parent, (DLGPROC) PromptWatchNameProc);
|
DialogBoxParam(hInst, MAKEINTRESOURCE(IDD_EDITWATCH), parent, (DLGPROC) EditWatchProc, (LPARAM)WatchCount);
|
||||||
|
|
||||||
return WatchCount > prevWatchCount;
|
return WatchCount > prevWatchCount;
|
||||||
}
|
}
|
||||||
|
@ -242,7 +249,7 @@ bool AskSave()
|
||||||
//returns false only if a save was attempted but failed or was cancelled
|
//returns false only if a save was attempted but failed or was cancelled
|
||||||
if (RWfileChanged)
|
if (RWfileChanged)
|
||||||
{
|
{
|
||||||
int answer = MessageBox(MESSAGEBOXPARENT, "Save Changes?", "Ram Watch", MB_YESNOCANCEL);
|
int answer = MessageBox(MESSAGEBOXPARENT, "Save Changes?", "Ram Watch", MB_YESNOCANCEL | MB_ICONQUESTION);
|
||||||
if(answer == IDYES)
|
if(answer == IDYES)
|
||||||
if(!QuickSaveWatches())
|
if(!QuickSaveWatches())
|
||||||
return false;
|
return false;
|
||||||
|
@ -402,6 +409,7 @@ void OpenRWRecentFile(int memwRFileNumber)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
char Str_Tmp[1024];
|
||||||
strcpy(currentWatch,x);
|
strcpy(currentWatch,x);
|
||||||
strcpy(Str_Tmp,currentWatch);
|
strcpy(Str_Tmp,currentWatch);
|
||||||
|
|
||||||
|
@ -409,7 +417,7 @@ void OpenRWRecentFile(int memwRFileNumber)
|
||||||
FILE *WatchFile = fopen(Str_Tmp,"rb");
|
FILE *WatchFile = fopen(Str_Tmp,"rb");
|
||||||
if (!WatchFile)
|
if (!WatchFile)
|
||||||
{
|
{
|
||||||
int answer = MessageBox(MESSAGEBOXPARENT,"Error opening file.","ERROR",MB_OKCANCEL);
|
int answer = MessageBox(MESSAGEBOXPARENT,"Error opening file.","ERROR",MB_OKCANCEL | MB_ICONERROR);
|
||||||
if (answer == IDOK)
|
if (answer == IDOK)
|
||||||
{
|
{
|
||||||
rw_recent_files[rnum][0] = '\0'; //Clear file from list
|
rw_recent_files[rnum][0] = '\0'; //Clear file from list
|
||||||
|
@ -425,6 +433,7 @@ void OpenRWRecentFile(int memwRFileNumber)
|
||||||
Temp.Address = 0; // default values
|
Temp.Address = 0; // default values
|
||||||
Temp.Size = 'b';
|
Temp.Size = 'b';
|
||||||
Temp.Type = 'h';
|
Temp.Type = 'h';
|
||||||
|
Temp.comment = NULL;
|
||||||
char mode;
|
char mode;
|
||||||
fgets(Str_Tmp,1024,WatchFile);
|
fgets(Str_Tmp,1024,WatchFile);
|
||||||
sscanf(Str_Tmp,"%c%*s",&mode);
|
sscanf(Str_Tmp,"%c%*s",&mode);
|
||||||
|
@ -536,6 +545,7 @@ int Change_File_S(char *Dest, const char *Dir, const char *Titre, const char *Fi
|
||||||
|
|
||||||
bool Save_Watches()
|
bool Save_Watches()
|
||||||
{
|
{
|
||||||
|
char Str_Tmp[1024];
|
||||||
string initdir = FCEU_GetPath(FCEUMKF_MEMW);
|
string initdir = FCEU_GetPath(FCEUMKF_MEMW);
|
||||||
const char* slash = max(strrchr(gamefilename, '|'), max(strrchr(gamefilename, '\\'), strrchr(gamefilename, '/')));
|
const char* slash = max(strrchr(gamefilename, '|'), max(strrchr(gamefilename, '\\'), strrchr(gamefilename, '/')));
|
||||||
strcpy(Str_Tmp,slash ? slash+1 : gamefilename);
|
strcpy(Str_Tmp,slash ? slash+1 : gamefilename);
|
||||||
|
@ -566,26 +576,25 @@ bool Save_Watches()
|
||||||
|
|
||||||
bool QuickSaveWatches()
|
bool QuickSaveWatches()
|
||||||
{
|
{
|
||||||
if (RWfileChanged==false) return true; //If file has not changed, no need to save changes
|
if (RWfileChanged==false) return true; //If file has not changed, no need to save changes
|
||||||
if (currentWatch[0] == NULL) //If there is no currently loaded file, run to Save as and then return
|
if (currentWatch[0] == NULL) //If there is no currently loaded file, run to Save as and then return
|
||||||
|
return Save_Watches();
|
||||||
|
|
||||||
|
char Str_Tmp[1024];
|
||||||
|
strcpy(Str_Tmp,currentWatch);
|
||||||
|
FILE *WatchFile = fopen(Str_Tmp,"w+b");
|
||||||
|
fputc('\n',WatchFile);
|
||||||
|
sprintf(Str_Tmp,"%d\n",WatchCount);
|
||||||
|
fputs(Str_Tmp,WatchFile);
|
||||||
|
const char DELIM = '\t';
|
||||||
|
for (int i = 0; i < WatchCount; i++)
|
||||||
{
|
{
|
||||||
return Save_Watches();
|
sprintf(Str_Tmp,"%05X%c%04X%c%c%c%c%c%d%c%s\n",i,DELIM,rswatches[i].Address,DELIM,rswatches[i].Size,DELIM,rswatches[i].Type,DELIM,rswatches[i].WrongEndian,DELIM,rswatches[i].comment);
|
||||||
}
|
|
||||||
|
|
||||||
strcpy(Str_Tmp,currentWatch);
|
|
||||||
FILE *WatchFile = fopen(Str_Tmp,"w+b");
|
|
||||||
fputc('\n',WatchFile);
|
|
||||||
sprintf(Str_Tmp,"%d\n",WatchCount);
|
|
||||||
fputs(Str_Tmp,WatchFile);
|
fputs(Str_Tmp,WatchFile);
|
||||||
const char DELIM = '\t';
|
}
|
||||||
for (int i = 0; i < WatchCount; i++)
|
fclose(WatchFile);
|
||||||
{
|
RWfileChanged=false;
|
||||||
sprintf(Str_Tmp,"%05X%c%04X%c%c%c%c%c%d%c%s\n",i,DELIM,rswatches[i].Address,DELIM,rswatches[i].Size,DELIM,rswatches[i].Type,DELIM,rswatches[i].WrongEndian,DELIM,rswatches[i].comment);
|
return true;
|
||||||
fputs(Str_Tmp,WatchFile);
|
|
||||||
}
|
|
||||||
fclose(WatchFile);
|
|
||||||
RWfileChanged=false;
|
|
||||||
return true;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
bool Load_Watches(bool clear, const char* filename)
|
bool Load_Watches(bool clear, const char* filename)
|
||||||
|
@ -594,7 +603,7 @@ bool Load_Watches(bool clear, const char* filename)
|
||||||
FILE* WatchFile = fopen(filename,"rb");
|
FILE* WatchFile = fopen(filename,"rb");
|
||||||
if (!WatchFile)
|
if (!WatchFile)
|
||||||
{
|
{
|
||||||
MessageBox(MESSAGEBOXPARENT,"Error opening file.","ERROR",MB_OK);
|
MessageBox(MESSAGEBOXPARENT,"Error opening file.","ERROR",MB_OK | MB_ICONERROR);
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
if(clear)
|
if(clear)
|
||||||
|
@ -612,6 +621,7 @@ bool Load_Watches(bool clear, const char* filename)
|
||||||
Temp.Size = 'b';
|
Temp.Size = 'b';
|
||||||
Temp.Type = 'h';
|
Temp.Type = 'h';
|
||||||
char mode;
|
char mode;
|
||||||
|
char Str_Tmp[1024];
|
||||||
fgets(Str_Tmp,1024,WatchFile);
|
fgets(Str_Tmp,1024,WatchFile);
|
||||||
sscanf(Str_Tmp,"%c%*s",&mode);
|
sscanf(Str_Tmp,"%c%*s",&mode);
|
||||||
int WatchAdd;
|
int WatchAdd;
|
||||||
|
@ -656,6 +666,7 @@ bool Load_Watches(bool clear, const char* filename)
|
||||||
|
|
||||||
bool Load_Watches(bool clear)
|
bool Load_Watches(bool clear)
|
||||||
{
|
{
|
||||||
|
char Str_Tmp[1024];
|
||||||
string initdir = FCEU_GetPath(FCEUMKF_MEMW);
|
string initdir = FCEU_GetPath(FCEUMKF_MEMW);
|
||||||
const char* slash = max(strrchr(gamefilename, '|'), max(strrchr(gamefilename, '\\'), strrchr(gamefilename, '/')));
|
const char* slash = max(strrchr(gamefilename, '|'), max(strrchr(gamefilename, '\\'), strrchr(gamefilename, '/')));
|
||||||
strcpy(Str_Tmp,slash ? slash+1 : gamefilename);
|
strcpy(Str_Tmp,slash ? slash+1 : gamefilename);
|
||||||
|
@ -714,133 +725,144 @@ void RefreshWatchListSelectedItemControlStatus(HWND hDlg)
|
||||||
|
|
||||||
LRESULT CALLBACK EditWatchProc(HWND hDlg, UINT uMsg, WPARAM wParam, LPARAM lParam) //Gets info for a RAM Watch, and then inserts it into the Watch List
|
LRESULT CALLBACK EditWatchProc(HWND hDlg, UINT uMsg, WPARAM wParam, LPARAM lParam) //Gets info for a RAM Watch, and then inserts it into the Watch List
|
||||||
{
|
{
|
||||||
RECT r;
|
|
||||||
RECT r2;
|
|
||||||
int dx1, dy1, dx2, dy2;
|
|
||||||
static int index;
|
static int index;
|
||||||
static char s,t = s = 0;
|
|
||||||
|
|
||||||
switch(uMsg)
|
switch(uMsg)
|
||||||
{
|
{
|
||||||
case WM_INITDIALOG:
|
case WM_INITDIALOG:
|
||||||
//Clear_Sound_Buffer();
|
{
|
||||||
|
RECT r;
|
||||||
|
GetWindowRect(hWnd, &r);
|
||||||
|
SetWindowPos(hDlg, NULL, r.left, r.top, NULL, NULL, SWP_NOSIZE | SWP_NOZORDER | SWP_SHOWWINDOW);
|
||||||
|
|
||||||
|
index = (int)lParam;
|
||||||
|
AddressWatcher* watcher = &rswatches[index];
|
||||||
|
if (watcher->Type != 'S') {
|
||||||
|
char Str_Tmp[1024];
|
||||||
|
sprintf(Str_Tmp, "%04X", watcher->Address);
|
||||||
|
SetDlgItemText(hDlg, IDC_EDIT_COMPAREADDRESS, Str_Tmp);
|
||||||
|
switch (watcher->Size)
|
||||||
|
{
|
||||||
|
case 'b':
|
||||||
|
SendDlgItemMessage(hDlg, IDC_1_BYTE, BM_SETCHECK, BST_CHECKED, 0);
|
||||||
|
break;
|
||||||
|
case 'w':
|
||||||
|
SendDlgItemMessage(hDlg, IDC_2_BYTES, BM_SETCHECK, BST_CHECKED, 0);
|
||||||
|
break;
|
||||||
|
case 'd':
|
||||||
|
SendDlgItemMessage(hDlg, IDC_4_BYTES, BM_SETCHECK, BST_CHECKED, 0);
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
switch (watcher->Type)
|
||||||
|
{
|
||||||
|
case 's':
|
||||||
|
SendDlgItemMessage(hDlg, IDC_SIGNED, BM_SETCHECK, BST_CHECKED, 0);
|
||||||
|
break;
|
||||||
|
case 'u':
|
||||||
|
SendDlgItemMessage(hDlg, IDC_UNSIGNED, BM_SETCHECK, BST_CHECKED, 0);
|
||||||
|
break;
|
||||||
|
case 'h':
|
||||||
|
SendDlgItemMessage(hDlg, IDC_HEX, BM_SETCHECK, BST_CHECKED, 0);
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
} else
|
||||||
|
SetDlgItemText(hDlg, IDC_EDIT_COMPAREADDRESS, "---------");
|
||||||
|
|
||||||
GetWindowRect(hWnd, &r);
|
if (watcher->comment != NULL)
|
||||||
dx1 = (r.right - r.left) / 2;
|
SetDlgItemText(hDlg, IDC_PROMPT_EDIT, watcher->comment);
|
||||||
dy1 = (r.bottom - r.top) / 2;
|
|
||||||
|
|
||||||
GetWindowRect(hDlg, &r2);
|
if (watcher->Type == 'S' || GetParent(hDlg) == RamSearchHWnd)
|
||||||
dx2 = (r2.right - r2.left) / 2;
|
{
|
||||||
dy2 = (r2.bottom - r2.top) / 2;
|
EnableWindow(GetDlgItem(hDlg, IDC_SPECIFICADDRESS), FALSE);
|
||||||
|
EnableWindow(GetDlgItem(hDlg, IDC_DATATYPE_GROUPBOX), FALSE);
|
||||||
//SetWindowPos(hDlg, NULL, max(0, r.left + (dx1 - dx2)), max(0, r.top + (dy1 - dy2)), NULL, NULL, SWP_NOSIZE | SWP_NOZORDER | SWP_SHOWWINDOW);
|
EnableWindow(GetDlgItem(hDlg, IDC_DATASIZE_GROUPBOX), FALSE);
|
||||||
SetWindowPos(hDlg, NULL, r.left, r.top, NULL, NULL, SWP_NOSIZE | SWP_NOZORDER | SWP_SHOWWINDOW);
|
EnableWindow(GetDlgItem(hDlg, IDC_EDIT_COMPAREADDRESS), FALSE);
|
||||||
index = (int)lParam;
|
EnableWindow(GetDlgItem(hDlg, IDC_SIGNED), FALSE);
|
||||||
sprintf(Str_Tmp,"%04X",rswatches[index].Address);
|
EnableWindow(GetDlgItem(hDlg, IDC_UNSIGNED), FALSE);
|
||||||
SetDlgItemText(hDlg,IDC_EDIT_COMPAREADDRESS,Str_Tmp);
|
EnableWindow(GetDlgItem(hDlg, IDC_HEX), FALSE);
|
||||||
if (rswatches[index].comment != NULL)
|
EnableWindow(GetDlgItem(hDlg, IDC_1_BYTE), FALSE);
|
||||||
SetDlgItemText(hDlg,IDC_PROMPT_EDIT,rswatches[index].comment);
|
EnableWindow(GetDlgItem(hDlg, IDC_2_BYTES), FALSE);
|
||||||
s = rswatches[index].Size;
|
EnableWindow(GetDlgItem(hDlg, IDC_4_BYTES), FALSE);
|
||||||
t = rswatches[index].Type;
|
SetFocus(GetDlgItem(hDlg, IDC_PROMPT_EDIT));
|
||||||
switch (s)
|
}
|
||||||
{
|
|
||||||
case 'b':
|
|
||||||
SendDlgItemMessage(hDlg, IDC_1_BYTE, BM_SETCHECK, BST_CHECKED, 0);
|
|
||||||
break;
|
|
||||||
case 'w':
|
|
||||||
SendDlgItemMessage(hDlg, IDC_2_BYTES, BM_SETCHECK, BST_CHECKED, 0);
|
|
||||||
break;
|
|
||||||
case 'd':
|
|
||||||
SendDlgItemMessage(hDlg, IDC_4_BYTES, BM_SETCHECK, BST_CHECKED, 0);
|
|
||||||
break;
|
|
||||||
default:
|
|
||||||
s = 0;
|
|
||||||
break;
|
|
||||||
}
|
}
|
||||||
switch (t)
|
|
||||||
{
|
|
||||||
case 's':
|
|
||||||
SendDlgItemMessage(hDlg, IDC_SIGNED, BM_SETCHECK, BST_CHECKED, 0);
|
|
||||||
break;
|
|
||||||
case 'u':
|
|
||||||
SendDlgItemMessage(hDlg, IDC_UNSIGNED, BM_SETCHECK, BST_CHECKED, 0);
|
|
||||||
break;
|
|
||||||
case 'h':
|
|
||||||
SendDlgItemMessage(hDlg, IDC_HEX, BM_SETCHECK, BST_CHECKED, 0);
|
|
||||||
break;
|
|
||||||
default:
|
|
||||||
t = 0;
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case WM_COMMAND:
|
case WM_COMMAND:
|
||||||
switch(LOWORD(wParam))
|
switch(LOWORD(wParam))
|
||||||
{
|
{
|
||||||
case IDC_SIGNED:
|
|
||||||
t='s';
|
|
||||||
return true;
|
|
||||||
case IDC_UNSIGNED:
|
|
||||||
t='u';
|
|
||||||
return true;
|
|
||||||
case IDC_HEX:
|
|
||||||
t='h';
|
|
||||||
return true;
|
|
||||||
case IDC_1_BYTE:
|
|
||||||
s = 'b';
|
|
||||||
return true;
|
|
||||||
case IDC_2_BYTES:
|
|
||||||
s = 'w';
|
|
||||||
return true;
|
|
||||||
case IDC_4_BYTES:
|
|
||||||
s = 'd';
|
|
||||||
return true;
|
|
||||||
case IDOK:
|
case IDOK:
|
||||||
{
|
{
|
||||||
if (s && t)
|
char Str_Tmp[1024];
|
||||||
|
// a normal watch, copy it to a temporary one
|
||||||
|
AddressWatcher watcher = rswatches[index];
|
||||||
|
if (watcher.comment != NULL)
|
||||||
|
watcher.comment = strcpy((char*)malloc(strlen(watcher.comment) + 2), watcher.comment);
|
||||||
|
|
||||||
|
// It's from ram watch window, not a separator
|
||||||
|
if (RamWatchHWnd && RamWatchHWnd == GetParent(hDlg) && watcher.Type != 'S')
|
||||||
{
|
{
|
||||||
AddressWatcher Temp;
|
GetDlgItemText(hDlg, IDC_PROMPT_EDIT, Str_Tmp, 1024);
|
||||||
Temp.Size = s;
|
|
||||||
Temp.Type = t;
|
// type
|
||||||
Temp.WrongEndian = false; //replace this when I get little endian working properly
|
if (SendDlgItemMessage(hDlg, IDC_SIGNED, BM_GETCHECK, 0, 0) == BST_CHECKED)
|
||||||
GetDlgItemText(hDlg,IDC_EDIT_COMPAREADDRESS,Str_Tmp,1024);
|
watcher.Type = 's';
|
||||||
|
else if (SendDlgItemMessage(hDlg, IDC_UNSIGNED, BM_GETCHECK, 0, 0) == BST_CHECKED)
|
||||||
|
watcher.Type = 'u';
|
||||||
|
else if (SendDlgItemMessage(hDlg, IDC_HEX, BM_GETCHECK, 0, 0) == BST_CHECKED)
|
||||||
|
watcher.Type = 'h';
|
||||||
|
else {
|
||||||
|
MessageBox(hDlg, "Type must be specified.", "Error", MB_OK | MB_ICONERROR);
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
|
// size
|
||||||
|
if (SendDlgItemMessage(hDlg, IDC_1_BYTE, BM_GETCHECK, 0, 0) == BST_CHECKED)
|
||||||
|
watcher.Size = 'b';
|
||||||
|
else if (SendDlgItemMessage(hDlg, IDC_2_BYTES, BM_GETCHECK, 0, 0) == BST_CHECKED)
|
||||||
|
watcher.Size = 'w';
|
||||||
|
else if (SendDlgItemMessage(hDlg, IDC_4_BYTES, BM_GETCHECK, 0, 0) == BST_CHECKED)
|
||||||
|
watcher.Size = 'd';
|
||||||
|
else {
|
||||||
|
MessageBox(hDlg, "Size must be specified.", "Error", MB_OK | MB_ICONERROR);
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
|
// address
|
||||||
|
GetDlgItemText(hDlg, IDC_EDIT_COMPAREADDRESS, Str_Tmp, 1024);
|
||||||
char *addrstr = Str_Tmp;
|
char *addrstr = Str_Tmp;
|
||||||
if (strlen(Str_Tmp) > 8) addrstr = &(Str_Tmp[strlen(Str_Tmp) - 9]);
|
if (strlen(Str_Tmp) > 8)
|
||||||
for(int i = 0; addrstr[i]; i++) {if(toupper(addrstr[i]) == 'O') addrstr[i] = '0';}
|
addrstr = &Str_Tmp[strlen(Str_Tmp) - 9];
|
||||||
sscanf(addrstr,"%04X",&(Temp.Address));
|
for (int i = 0; addrstr[i]; ++i)
|
||||||
|
if (toupper(addrstr[i]) == 'O')
|
||||||
|
addrstr[i] = '0';
|
||||||
|
sscanf(addrstr, "%04X", &watcher.Address);
|
||||||
|
|
||||||
if((Temp.Address & ~0xFFFFFF) == ~0xFFFFFF)
|
if ((watcher.Address & ~0xFFFFFF) == ~0xFFFFFF)
|
||||||
Temp.Address &= 0xFFFFFF;
|
watcher.Address &= 0xFFFFFF;
|
||||||
|
|
||||||
if(IsHardwareAddressValid(Temp.Address))
|
if (!IsHardwareAddressValid(watcher.Address))
|
||||||
{
|
{
|
||||||
GetDlgItemText(hDlg,IDC_PROMPT_EDIT,Str_Tmp,80);
|
MessageBox(hDlg, "Invalid Address.", "Error", MB_OK | MB_ICONERROR);
|
||||||
if (index < WatchCount) RemoveWatch(index);
|
return true;
|
||||||
InsertWatch(Temp,Str_Tmp);
|
|
||||||
if(RamWatchHWnd)
|
|
||||||
{
|
|
||||||
ListView_SetItemCount(GetDlgItem(RamWatchHWnd,IDC_WATCHLIST),WatchCount);
|
|
||||||
}
|
|
||||||
EndDialog(hDlg, true);
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
MessageBox(hDlg,"Invalid Address","ERROR",MB_OK);
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else
|
|
||||||
{
|
// comment
|
||||||
strcpy(Str_Tmp,"Error:");
|
GetDlgItemText(hDlg, IDC_PROMPT_EDIT, Str_Tmp, 80);
|
||||||
if (!s)
|
|
||||||
strcat(Str_Tmp," Size must be specified.");
|
// finallly update the watch list
|
||||||
if (!t)
|
if (index < WatchCount)
|
||||||
strcat(Str_Tmp," Type must be specified.");
|
// it's a watch editing operation, and the dialog is from Ram Watch Window, remove then insert;
|
||||||
MessageBox(hDlg,Str_Tmp,"ERROR",MB_OK);
|
RemoveWatch(index);
|
||||||
}
|
InsertWatch(watcher, Str_Tmp);
|
||||||
RWfileChanged=true;
|
if (RamWatchHWnd)
|
||||||
|
ListView_SetItemCount(GetDlgItem(RamWatchHWnd, IDC_WATCHLIST), WatchCount);
|
||||||
|
EndDialog(hDlg, true);
|
||||||
|
|
||||||
|
RWfileChanged = true;
|
||||||
return true;
|
return true;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
@ -1037,9 +1059,13 @@ LRESULT CALLBACK RamWatchProc(HWND hDlg, UINT uMsg, WPARAM wParam, LPARAM lParam
|
||||||
switch (Item->item.iSubItem)
|
switch (Item->item.iSubItem)
|
||||||
{
|
{
|
||||||
case 0:
|
case 0:
|
||||||
sprintf(num,"%04X",rswatches[iNum].Address);
|
{
|
||||||
|
int size = WatchSizeConv(rswatches[iNum]);
|
||||||
|
int addr = rswatches[iNum].Address;
|
||||||
|
sprintf(num, rswatches[iNum].Type == 'S' ? "------" : size > 1 ? "%04X-%04X" : "%04X", addr, addr + size - 1);
|
||||||
Item->item.pszText = num;
|
Item->item.pszText = num;
|
||||||
return true;
|
return true;
|
||||||
|
}
|
||||||
case 1: {
|
case 1: {
|
||||||
int i = rswatches[iNum].CurValue;
|
int i = rswatches[iNum].CurValue;
|
||||||
int t = rswatches[iNum].Type;
|
int t = rswatches[iNum].Type;
|
||||||
|
@ -1072,6 +1098,42 @@ LRESULT CALLBACK RamWatchProc(HWND hDlg, UINT uMsg, WPARAM wParam, LPARAM lParam
|
||||||
SetWindowLong(hDlg, DWL_MSGRESULT, ListView_GetSelectionMark(GetDlgItem(hDlg,IDC_WATCHLIST)));
|
SetWindowLong(hDlg, DWL_MSGRESULT, ListView_GetSelectionMark(GetDlgItem(hDlg,IDC_WATCHLIST)));
|
||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
|
case NM_CUSTOMDRAW:
|
||||||
|
{
|
||||||
|
LPNMCUSTOMDRAW nmcd = (LPNMCUSTOMDRAW)lParam;
|
||||||
|
switch (nmcd->dwDrawStage)
|
||||||
|
{
|
||||||
|
case CDDS_ITEMPREPAINT:
|
||||||
|
{
|
||||||
|
LPNMLVCUSTOMDRAW lplvcd = (LPNMLVCUSTOMDRAW)lParam;
|
||||||
|
if (rswatches[nmcd->dwItemSpec].Type == 'S')
|
||||||
|
lplvcd->clrTextBk = RGB(247, 187, 67);
|
||||||
|
else
|
||||||
|
switch (rswatches[nmcd->dwItemSpec].Cheats)
|
||||||
|
{
|
||||||
|
default:
|
||||||
|
case 0:
|
||||||
|
SetWindowLong(hDlg, DWL_MSGRESULT, CDRF_DODEFAULT);
|
||||||
|
return TRUE;
|
||||||
|
case 1:
|
||||||
|
lplvcd->clrTextBk = RGB(216, 203, 253); break;
|
||||||
|
case 2:
|
||||||
|
lplvcd->clrTextBk = RGB(195, 186, 253); break;
|
||||||
|
case 3:
|
||||||
|
lplvcd->clrTextBk = RGB(176, 139, 252); break;
|
||||||
|
case 4:
|
||||||
|
lplvcd->clrTextBk = RGB(175, 94, 253);
|
||||||
|
lplvcd->clrText = RGB(255, 255, 255); break; // use a more visual color in dark background
|
||||||
|
}
|
||||||
|
SetWindowLong(hDlg, DWL_MSGRESULT, CDRF_NEWFONT);
|
||||||
|
}
|
||||||
|
break;
|
||||||
|
case CDDS_PREPAINT:
|
||||||
|
SetWindowLong(hDlg, DWL_MSGRESULT, CDRF_NOTIFYITEMDRAW);
|
||||||
|
}
|
||||||
|
return TRUE;
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -1114,16 +1176,16 @@ LRESULT CALLBACK RamWatchProc(HWND hDlg, UINT uMsg, WPARAM wParam, LPARAM lParam
|
||||||
watchIndex = ListView_GetSelectionMark(GetDlgItem(hDlg,IDC_WATCHLIST));
|
watchIndex = ListView_GetSelectionMark(GetDlgItem(hDlg,IDC_WATCHLIST));
|
||||||
if(watchIndex != -1)
|
if(watchIndex != -1)
|
||||||
{
|
{
|
||||||
if(rswatches[watchIndex].Size == 'S') return true;
|
DialogBoxParam(hInst, MAKEINTRESOURCE(IDD_EDITWATCH), hDlg, (DLGPROC) EditWatchProc,(LPARAM)watchIndex);
|
||||||
DialogBoxParam(hInst, MAKEINTRESOURCE(IDD_EDITWATCH), hDlg, (DLGPROC) EditWatchProc,(LPARAM) watchIndex);
|
|
||||||
SetFocus(GetDlgItem(hDlg,IDC_WATCHLIST));
|
SetFocus(GetDlgItem(hDlg,IDC_WATCHLIST));
|
||||||
}
|
}
|
||||||
return true;
|
return true;
|
||||||
case IDC_C_WATCH:
|
case IDC_C_WATCH:
|
||||||
rswatches[WatchCount].Address = rswatches[WatchCount].WrongEndian = 0;
|
rswatches[WatchCount].Address = 0;
|
||||||
|
rswatches[WatchCount].WrongEndian = 0;
|
||||||
rswatches[WatchCount].Size = 'b';
|
rswatches[WatchCount].Size = 'b';
|
||||||
rswatches[WatchCount].Type = 's';
|
rswatches[WatchCount].Type = 's';
|
||||||
DialogBoxParam(hInst, MAKEINTRESOURCE(IDD_EDITWATCH), hDlg, (DLGPROC) EditWatchProc,(LPARAM) WatchCount);
|
DialogBoxParam(hInst, MAKEINTRESOURCE(IDD_EDITWATCH), hDlg, (DLGPROC) EditWatchProc,(LPARAM)WatchCount);
|
||||||
SetFocus(GetDlgItem(hDlg,IDC_WATCHLIST));
|
SetFocus(GetDlgItem(hDlg,IDC_WATCHLIST));
|
||||||
return true;
|
return true;
|
||||||
case IDC_C_WATCH_DUPLICATE:
|
case IDC_C_WATCH_DUPLICATE:
|
||||||
|
@ -1134,18 +1196,21 @@ LRESULT CALLBACK RamWatchProc(HWND hDlg, UINT uMsg, WPARAM wParam, LPARAM lParam
|
||||||
rswatches[WatchCount].WrongEndian = rswatches[watchIndex].WrongEndian;
|
rswatches[WatchCount].WrongEndian = rswatches[watchIndex].WrongEndian;
|
||||||
rswatches[WatchCount].Size = rswatches[watchIndex].Size;
|
rswatches[WatchCount].Size = rswatches[watchIndex].Size;
|
||||||
rswatches[WatchCount].Type = rswatches[watchIndex].Type;
|
rswatches[WatchCount].Type = rswatches[watchIndex].Type;
|
||||||
DialogBoxParam(hInst, MAKEINTRESOURCE(IDD_EDITWATCH), hDlg, (DLGPROC) EditWatchProc,(LPARAM) WatchCount);
|
rswatches[WatchCount].comment = strcpy((char*)malloc(strlen(rswatches[watchIndex].comment) + 2), rswatches[watchIndex].comment);
|
||||||
|
DialogBoxParam(hInst, MAKEINTRESOURCE(IDD_EDITWATCH), hDlg, (DLGPROC) EditWatchProc,WatchCount);
|
||||||
SetFocus(GetDlgItem(hDlg,IDC_WATCHLIST));
|
SetFocus(GetDlgItem(hDlg,IDC_WATCHLIST));
|
||||||
}
|
}
|
||||||
return true;
|
return true;
|
||||||
|
|
||||||
case IDC_C_WATCH_SEPARATE:
|
case IDC_C_WATCH_SEPARATE:
|
||||||
AddressWatcher separator;
|
rswatches[WatchCount].Address = 0;
|
||||||
separator.Address = 0;
|
rswatches[WatchCount].WrongEndian = false;
|
||||||
separator.WrongEndian = false;
|
rswatches[WatchCount].Size = 'S';
|
||||||
separator.Size = 'S';
|
rswatches[WatchCount].Type = 'S';
|
||||||
separator.Type = 'S';
|
|
||||||
InsertWatch(separator, "----------------------------");
|
DialogBoxParam(hInst, MAKEINTRESOURCE(IDD_EDITWATCH), hDlg, (DLGPROC)EditWatchProc, (LPARAM)WatchCount);
|
||||||
|
|
||||||
|
// InsertWatch(separator, "----------------------------");
|
||||||
SetFocus(GetDlgItem(hDlg,IDC_WATCHLIST));
|
SetFocus(GetDlgItem(hDlg,IDC_WATCHLIST));
|
||||||
return true;
|
return true;
|
||||||
|
|
||||||
|
@ -1245,6 +1310,7 @@ LRESULT CALLBACK RamWatchProc(HWND hDlg, UINT uMsg, WPARAM wParam, LPARAM lParam
|
||||||
}
|
}
|
||||||
|
|
||||||
UpdateCheatsAdded();
|
UpdateCheatsAdded();
|
||||||
|
UpdateCheatWindowRelatedWindow();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
|
@ -1287,6 +1353,7 @@ LRESULT CALLBACK RamWatchProc(HWND hDlg, UINT uMsg, WPARAM wParam, LPARAM lParam
|
||||||
|
|
||||||
case WM_DROPFILES:
|
case WM_DROPFILES:
|
||||||
{
|
{
|
||||||
|
char Str_Tmp[1024];
|
||||||
HDROP hDrop = (HDROP)wParam;
|
HDROP hDrop = (HDROP)wParam;
|
||||||
DragQueryFile(hDrop, 0, Str_Tmp, 1024);
|
DragQueryFile(hDrop, 0, Str_Tmp, 1024);
|
||||||
DragFinish(hDrop);
|
DragFinish(hDrop);
|
||||||
|
@ -1296,3 +1363,10 @@ LRESULT CALLBACK RamWatchProc(HWND hDlg, UINT uMsg, WPARAM wParam, LPARAM lParam
|
||||||
|
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// TODO: This function may be too slow when both cheats and watches are near the max limit.
|
||||||
|
void UpdateWatchCheats() {
|
||||||
|
extern int FCEU_CalcCheatAffectedBytes(uint32, uint32);
|
||||||
|
for (int i = 0; i < WatchCount; ++i)
|
||||||
|
rswatches[i].Cheats = FCEU_CalcCheatAffectedBytes(rswatches[i].Address, WatchSizeConv(rswatches[i]));
|
||||||
|
}
|
|
@ -26,6 +26,7 @@ struct AddressWatcher
|
||||||
bool WrongEndian;
|
bool WrongEndian;
|
||||||
char Size; //'d' = 4 bytes, 'w' = 2 bytes, 'b' = 1 byte, and 'S' means it's a separator.
|
char Size; //'d' = 4 bytes, 'w' = 2 bytes, 'b' = 1 byte, and 'S' means it's a separator.
|
||||||
char Type;//'s' = signed integer, 'u' = unsigned, 'h' = hex, 'S' = separator
|
char Type;//'s' = signed integer, 'u' = unsigned, 'h' = hex, 'S' = separator
|
||||||
|
short Cheats; // how many bytes are affected by cheat
|
||||||
};
|
};
|
||||||
#define MAX_WATCH_COUNT 256
|
#define MAX_WATCH_COUNT 256
|
||||||
extern AddressWatcher rswatches[MAX_WATCH_COUNT];
|
extern AddressWatcher rswatches[MAX_WATCH_COUNT];
|
||||||
|
@ -41,8 +42,13 @@ bool InsertWatch(const AddressWatcher& Watch, HWND parent=NULL); // asks user fo
|
||||||
void Update_RAM_Watch();
|
void Update_RAM_Watch();
|
||||||
bool Load_Watches(bool clear, const char* filename);
|
bool Load_Watches(bool clear, const char* filename);
|
||||||
void RWAddRecentFile(const char *filename);
|
void RWAddRecentFile(const char *filename);
|
||||||
|
void UpdateWatchCheats();
|
||||||
|
|
||||||
LRESULT CALLBACK RamWatchProc(HWND hDlg, UINT uMsg, WPARAM wParam, LPARAM lParam);
|
LRESULT CALLBACK RamWatchProc(HWND hDlg, UINT uMsg, WPARAM wParam, LPARAM lParam);
|
||||||
|
LRESULT CALLBACK EditWatchProc(HWND hDlg, UINT uMsg, WPARAM wParam, LPARAM lParam);
|
||||||
extern HWND RamWatchHWnd;
|
extern HWND RamWatchHWnd;
|
||||||
|
|
||||||
|
#define WatchSizeConv(watch) (watch.Type == 'S' ? 0 : watch.Size == 'd' ? 4 : watch.Size == 'w' ? 2 : watch.Size == 'b' ? 1 : 0)
|
||||||
|
#define SizeConvWatch(size) (size == 4 ? 'd' : size == 2 ? 'w' : size == 1 : 'b' : 0)
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|
File diff suppressed because it is too large
Load Diff
|
@ -195,7 +195,6 @@
|
||||||
#define IDD_RAMSEARCH 154
|
#define IDD_RAMSEARCH 154
|
||||||
#define IDD_RAMWATCH 155
|
#define IDD_RAMWATCH 155
|
||||||
#define IDD_EDITWATCH 156
|
#define IDD_EDITWATCH 156
|
||||||
#define IDD_PROMPT 157
|
|
||||||
#define IDR_RWACCELERATOR 158
|
#define IDR_RWACCELERATOR 158
|
||||||
#define IDD_LUA 159
|
#define IDD_LUA 159
|
||||||
#define IDB_BITMAP0 163
|
#define IDB_BITMAP0 163
|
||||||
|
@ -789,6 +788,8 @@
|
||||||
#define IDC_AUTOSAVE_PERIOD_MINUTES_TEXT 1307
|
#define IDC_AUTOSAVE_PERIOD_MINUTES_TEXT 1307
|
||||||
#define IDC_VBLANK_SCANLINES_TEXT 1308
|
#define IDC_VBLANK_SCANLINES_TEXT 1308
|
||||||
#define IDC_EXTRA_SCANLINES_TEXT 1309
|
#define IDC_EXTRA_SCANLINES_TEXT 1309
|
||||||
|
#define IDC_DATASIZE_GROUPBOX 1310
|
||||||
|
#define IDC_DATATYPE_GROUPBOX 1311
|
||||||
#define MENU_NETWORK 40040
|
#define MENU_NETWORK 40040
|
||||||
#define MENU_PALETTE 40041
|
#define MENU_PALETTE 40041
|
||||||
#define MENU_SOUND 40042
|
#define MENU_SOUND 40042
|
||||||
|
@ -1282,9 +1283,9 @@
|
||||||
//
|
//
|
||||||
#ifdef APSTUDIO_INVOKED
|
#ifdef APSTUDIO_INVOKED
|
||||||
#ifndef APSTUDIO_READONLY_SYMBOLS
|
#ifndef APSTUDIO_READONLY_SYMBOLS
|
||||||
#define _APS_NEXT_RESOURCE_VALUE 302
|
#define _APS_NEXT_RESOURCE_VALUE 303
|
||||||
#define _APS_NEXT_COMMAND_VALUE 40600
|
#define _APS_NEXT_COMMAND_VALUE 40600
|
||||||
#define _APS_NEXT_CONTROL_VALUE 1310
|
#define _APS_NEXT_CONTROL_VALUE 1312
|
||||||
#define _APS_NEXT_SYMED_VALUE 101
|
#define _APS_NEXT_SYMED_VALUE 101
|
||||||
#endif
|
#endif
|
||||||
#endif
|
#endif
|
||||||
|
|
Loading…
Reference in New Issue