MCPcopy Create free account
hub / github.com/AppleWin/AppleWin / GetCloneMenuItem

Method GetCloneMenuItem

source/Configuration/PageAdvanced.cpp:246–275  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

244}
245
246int CPageAdvanced::GetCloneMenuItem(void)
247{
248 const eApple2Type type = m_PropertySheetHelper.GetConfigNew().m_Apple2Type;
249 const bool bIsClone = IsClone(type);
250 if (!bIsClone)
251 return MENUITEM_CLONEMIN;
252
253 int nMenuItem = MENUITEM_CLONEMIN;
254 switch (type)
255 {
256 case A2TYPE_CLONE: // Set as generic clone type from Config page
257 {
258 // Need to set a real clone type & CPU in case the user never touches the clone menu
259 nMenuItem = MENUITEM_CLONEMIN;
260 const eApple2Type NewCloneType = GetCloneType(MENUITEM_CLONEMIN);
261 m_PropertySheetHelper.GetConfigNew().m_Apple2Type = GetCloneType(NewCloneType);
262 m_PropertySheetHelper.GetConfigNew().m_CpuType = ProbeMainCpuDefault(NewCloneType);
263 }
264 break;
265 case A2TYPE_PRAVETS82: nMenuItem = MENUITEM_PRAVETS82; break;
266 case A2TYPE_PRAVETS8M: nMenuItem = MENUITEM_PRAVETS8M; break;
267 case A2TYPE_PRAVETS8A: nMenuItem = MENUITEM_PRAVETS8A; break;
268 case A2TYPE_TK30002E: nMenuItem = MENUITEM_TK30002E; break;
269 case A2TYPE_BASE64A: nMenuItem = MENUITEM_BASE64A; break;
270 default: // New clone needs adding here?
271 _ASSERT(0);
272 }
273
274 return nMenuItem;
275}
276
277void CPageAdvanced::InitFreezeDlgButton(HWND hWnd)
278{

Callers

nothing calls this directly

Calls 2

IsCloneFunction · 0.85
ProbeMainCpuDefaultFunction · 0.85

Tested by

no test coverage detected