Fixed debugger mouse click not checking if in debug mode

This commit is contained in:
mpohoreski 2006-07-09 15:43:17 +00:00
parent ecac78cccf
commit c5f66c59bb
2 changed files with 11 additions and 1 deletions

View File

@ -43,7 +43,7 @@ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
// TODO: COLOR LOAD ["filename"]
// See Debugger_Changelong.txt for full details
const int DEBUGGER_VERSION = MAKE_VERSION(2,5,7,5);
const int DEBUGGER_VERSION = MAKE_VERSION(2,5,7,6);
// Public _________________________________________________________________________________________
@ -9157,6 +9157,9 @@ void DebuggerCursorNext()
//===========================================================================
void DebuggerMouseClick( int x, int y )
{
if (g_nAppMode != MODE_DEBUG)
return;
int nFontWidth = g_aFontConfig[ FONT_DISASM_DEFAULT ]._nFontWidthAvg;
int nFontHeight = g_aFontConfig[ FONT_DISASM_DEFAULT ]._nLineHeight ;

View File

@ -404,6 +404,13 @@ bool _6502_CalcRelativeOffset( int nOpcode, int nBaseAddress, int nTargetAddress
//===========================================================================
int _6502_GetOpmodeOpbytes ( const int iAddress, int & iOpmode_, int & nOpbytes_ )
{
#if _DEBUG
if (! g_aOpcodes)
{
MessageBox( g_hFrameWindow, "Debugger not properly initialized", "ERROR", MB_OK );
}
#endif
int iOpcode_ = *(mem + iAddress);
iOpmode_ = g_aOpcodes[ iOpcode_ ].nAddressMode;
nOpbytes_ = g_aOpmodes[ iOpmode_ ].m_nBytes;