Skip to content

Commit 0a97cd0

Browse files
authored
[GEN][ZH] Show the System Maps tab in World Builder without RTS_DEBUG (#1191)
1 parent 53c4a78 commit 0a97cd0

File tree

4 files changed

+12
-48
lines changed

4 files changed

+12
-48
lines changed

Generals/Code/Tools/WorldBuilder/src/OpenMap.cpp

Lines changed: 3 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -33,11 +33,7 @@ OpenMap::OpenMap(TOpenMapInfo *pInfo, CWnd* pParent /*=NULL*/)
3333
m_pInfo(pInfo)
3434
{
3535
m_pInfo->browse = false;
36-
#if defined(RTS_DEBUG)
3736
m_usingSystemDir = ::AfxGetApp()->GetProfileInt(MAP_OPENSAVE_PANEL_SECTION, "UseSystemDir", TRUE);
38-
#else
39-
m_usingSystemDir = FALSE;
40-
#endif
4137

4238
//{{AFX_DATA_INIT(OpenMap)
4339
// NOTE: the ClassWizard will add member initialization here
@@ -110,9 +106,7 @@ void OpenMap::OnOK()
110106
void OpenMap::populateMapListbox( Bool systemMaps )
111107
{
112108
m_usingSystemDir = systemMaps;
113-
#if defined(RTS_DEBUG)
114109
::AfxGetApp()->WriteProfileInt(MAP_OPENSAVE_PANEL_SECTION, "UseSystemDir", m_usingSystemDir);
115-
#endif
116110

117111
HANDLE hFindFile = 0;
118112
WIN32_FIND_DATA findData;
@@ -190,12 +184,9 @@ BOOL OpenMap::OnInitDialog()
190184
if (pUserMaps != NULL)
191185
pUserMaps->SetCheck( !m_usingSystemDir );
192186

193-
#if !defined(RTS_DEBUG)
194-
if (pSystemMaps)
195-
pSystemMaps->ShowWindow( FALSE );
196-
if (pUserMaps)
197-
pUserMaps->ShowWindow( FALSE );
198-
#endif
187+
// TheSuperHackers @tweak Originally World Builder has hidden the System Maps tab button in Release builds,
188+
// perhaps with the intention to only show User Maps to community users. However, World Builder did release
189+
// as a Debug build and always had the System Maps tab, therefore this now shows it always for simplicity.
199190

200191
populateMapListbox( m_usingSystemDir );
201192

Generals/Code/Tools/WorldBuilder/src/SaveMap.cpp

Lines changed: 3 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -32,11 +32,7 @@ SaveMap::SaveMap(TSaveMapInfo *pInfo, CWnd* pParent /*=NULL*/)
3232
: CDialog(SaveMap::IDD, pParent),
3333
m_pInfo(pInfo)
3434
{
35-
#if defined(RTS_DEBUG)
3635
m_pInfo->usingSystemDir = m_usingSystemDir = ::AfxGetApp()->GetProfileInt(MAP_OPENSAVE_PANEL_SECTION, "UseSystemDir", TRUE);
37-
#else
38-
m_pInfo->usingSystemDir = m_usingSystemDir = FALSE;
39-
#endif
4036

4137
//{{AFX_DATA_INIT(SaveMap)
4238
// NOTE: the ClassWizard will add member initialization here
@@ -121,9 +117,7 @@ void SaveMap::OnBrowse()
121117
void SaveMap::populateMapListbox( Bool systemMaps )
122118
{
123119
m_pInfo->usingSystemDir = m_usingSystemDir = systemMaps;
124-
#if defined(RTS_DEBUG)
125120
::AfxGetApp()->WriteProfileInt(MAP_OPENSAVE_PANEL_SECTION, "UseSystemDir", m_usingSystemDir);
126-
#endif
127121

128122
HANDLE hFindFile = 0;
129123
WIN32_FIND_DATA findData;
@@ -225,12 +219,9 @@ BOOL SaveMap::OnInitDialog()
225219
if (pUserMaps != NULL)
226220
pUserMaps->SetCheck( !m_usingSystemDir );
227221

228-
#if !defined(RTS_DEBUG)
229-
if (pSystemMaps)
230-
pSystemMaps->ShowWindow( FALSE );
231-
if (pUserMaps)
232-
pUserMaps->ShowWindow( FALSE );
233-
#endif
222+
// TheSuperHackers @tweak Originally World Builder has hidden the System Maps tab button in Release builds,
223+
// perhaps with the intention to only show User Maps to community users. However, World Builder did release
224+
// as a Debug build and always had the System Maps tab, therefore this now shows it always for simplicity.
234225

235226
populateMapListbox( m_usingSystemDir );
236227

GeneralsMD/Code/Tools/WorldBuilder/src/OpenMap.cpp

Lines changed: 3 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -33,11 +33,7 @@ OpenMap::OpenMap(TOpenMapInfo *pInfo, CWnd* pParent /*=NULL*/)
3333
m_pInfo(pInfo)
3434
{
3535
m_pInfo->browse = false;
36-
#if defined(RTS_DEBUG)
3736
m_usingSystemDir = ::AfxGetApp()->GetProfileInt(MAP_OPENSAVE_PANEL_SECTION, "UseSystemDir", TRUE);
38-
#else
39-
m_usingSystemDir = FALSE;
40-
#endif
4137

4238
//{{AFX_DATA_INIT(OpenMap)
4339
// NOTE: the ClassWizard will add member initialization here
@@ -110,9 +106,7 @@ void OpenMap::OnOK()
110106
void OpenMap::populateMapListbox( Bool systemMaps )
111107
{
112108
m_usingSystemDir = systemMaps;
113-
#if defined(RTS_DEBUG)
114109
::AfxGetApp()->WriteProfileInt(MAP_OPENSAVE_PANEL_SECTION, "UseSystemDir", m_usingSystemDir);
115-
#endif
116110

117111
HANDLE hFindFile = 0;
118112
WIN32_FIND_DATA findData;
@@ -190,12 +184,9 @@ BOOL OpenMap::OnInitDialog()
190184
if (pUserMaps != NULL)
191185
pUserMaps->SetCheck( !m_usingSystemDir );
192186

193-
#if !defined(RTS_DEBUG)
194-
if (pSystemMaps)
195-
pSystemMaps->ShowWindow( FALSE );
196-
if (pUserMaps)
197-
pUserMaps->ShowWindow( FALSE );
198-
#endif
187+
// TheSuperHackers @tweak Originally World Builder has hidden the System Maps tab button in Release builds,
188+
// perhaps with the intention to only show User Maps to community users. However, World Builder did release
189+
// as a Debug build and always had the System Maps tab, therefore this now shows it always for simplicity.
199190

200191
populateMapListbox( m_usingSystemDir );
201192

GeneralsMD/Code/Tools/WorldBuilder/src/SaveMap.cpp

Lines changed: 3 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -32,11 +32,7 @@ SaveMap::SaveMap(TSaveMapInfo *pInfo, CWnd* pParent /*=NULL*/)
3232
: CDialog(SaveMap::IDD, pParent),
3333
m_pInfo(pInfo)
3434
{
35-
#if defined(RTS_DEBUG)
3635
m_pInfo->usingSystemDir = m_usingSystemDir = ::AfxGetApp()->GetProfileInt(MAP_OPENSAVE_PANEL_SECTION, "UseSystemDir", TRUE);
37-
#else
38-
m_pInfo->usingSystemDir = m_usingSystemDir = FALSE;
39-
#endif
4036

4137
//{{AFX_DATA_INIT(SaveMap)
4238
// NOTE: the ClassWizard will add member initialization here
@@ -121,9 +117,7 @@ void SaveMap::OnBrowse()
121117
void SaveMap::populateMapListbox( Bool systemMaps )
122118
{
123119
m_pInfo->usingSystemDir = m_usingSystemDir = systemMaps;
124-
#if defined(RTS_DEBUG)
125120
::AfxGetApp()->WriteProfileInt(MAP_OPENSAVE_PANEL_SECTION, "UseSystemDir", m_usingSystemDir);
126-
#endif
127121

128122
HANDLE hFindFile = 0;
129123
WIN32_FIND_DATA findData;
@@ -225,12 +219,9 @@ BOOL SaveMap::OnInitDialog()
225219
if (pUserMaps != NULL)
226220
pUserMaps->SetCheck( !m_usingSystemDir );
227221

228-
#if !defined(RTS_DEBUG)
229-
if (pSystemMaps)
230-
pSystemMaps->ShowWindow( FALSE );
231-
if (pUserMaps)
232-
pUserMaps->ShowWindow( FALSE );
233-
#endif
222+
// TheSuperHackers @tweak Originally World Builder has hidden the System Maps tab button in Release builds,
223+
// perhaps with the intention to only show User Maps to community users. However, World Builder did release
224+
// as a Debug build and always had the System Maps tab, therefore this now shows it always for simplicity.
234225

235226
populateMapListbox( m_usingSystemDir );
236227

0 commit comments

Comments
 (0)