From c920fe38a19013b99f3f74e48da9724fb053c212 Mon Sep 17 00:00:00 2001 From: Ash Wolf Date: Sun, 9 Jul 2023 20:59:16 +0100 Subject: support building from VC++ IDE, add resources --- src/T2MainWindow.cpp | 22 +++++++++++++--------- 1 file changed, 13 insertions(+), 9 deletions(-) (limited to 'src/T2MainWindow.cpp') diff --git a/src/T2MainWindow.cpp b/src/T2MainWindow.cpp index 096859a..4de25d7 100644 --- a/src/T2MainWindow.cpp +++ b/src/T2MainWindow.cpp @@ -1,17 +1,19 @@ +#include "StdAfx.h" #include "DbgEventList.h" #include "DbgIPS.h" #include "DbgStepRun.h" #include "T2.h" #include "T2CtrlPalette.h" -#include "T2DLL.h" +#include "T2DLL/T2DLL.h" #include "T2MainWindow.h" #include "T2MsgWindow.h" -#include "T2SoundPlayer.h" -#include "T2ToolWindow.h" +#include "T2DLL/T2SoundPlayer.h" +#include "T2DLL/T2ToolWindow.h" #include "T2TowerDoc.h" #include "T2TowerMainView.h" -#include "T2WorldDef.h" -#include "UT2Coordinate.h" +#include "T2DLL/T2WorldDef.h" +#include "T2DLL/UT2Coordinate.h" +#include "Resource.h" #ifdef _DEBUG #define new DEBUG_NEW @@ -23,6 +25,7 @@ static char THIS_FILE[] = __FILE__; IMPLEMENT_DYNCREATE(T2MainWindow, CFrameWnd) BEGIN_MESSAGE_MAP(T2MainWindow, CFrameWnd) + //{{AFX_MSG_MAP(T2MainWindow) ON_WM_CREATE() ON_WM_DESTROY() ON_WM_CLOSE() @@ -32,9 +35,10 @@ BEGIN_MESSAGE_MAP(T2MainWindow, CFrameWnd) ON_WM_ERASEBKGND() ON_WM_ACTIVATE() ON_WM_ACTIVATEAPP() - ON_COMMAND(0x8018, OnCmdDebugEvent) - ON_UPDATE_COMMAND_UI(0x8018, OnUpdateCmdDebugEvent) - ON_COMMAND(0x8023, OnCmdDebugMode) + ON_COMMAND(ID_DBG_EVENT, OnCmdDebugEvent) + ON_UPDATE_COMMAND_UI(ID_DBG_EVENT, OnUpdateCmdDebugEvent) + ON_COMMAND(ID_DBG_MODE, OnCmdDebugMode) + //}}AFX_MSG_MAP END_MESSAGE_MAP() T2MainWindow::T2MainWindow() { @@ -630,7 +634,7 @@ afx_msg void T2MainWindow::OnClose() { afx_msg void T2MainWindow::OnCmdDebugMode() { HMENU oldMenu = ::GetMenu(*this); - HMENU newMenu = LoadMenu(AfxGetInstanceHandle(), MAKEINTRESOURCE(130)); + HMENU newMenu = LoadMenu(AfxGetInstanceHandle(), MAKEINTRESOURCE(IDR_DEBUG_MENU)); m_hMenuDefault = newMenu; ::SetMenu(*this, newMenu); DestroyMenu(oldMenu); -- cgit v1.2.3