MCPcopy Index your code
hub / github.com/AppleWin/AppleWin / CmdBookmarkSave

Function CmdBookmarkSave

source/Debugger/Debug.cpp:725–758  ·  view source on GitHub ↗

===========================================================================

Source from the content-addressed store, hash-verified

723
724//===========================================================================
725Update_t CmdBookmarkSave (int nArgs)
726{
727 g_ConfigState.Reset();
728
729 ConfigSave_PrepareHeader( PARAM_CAT_BOOKMARKS, CMD_BOOKMARK_CLEAR );
730
731 int iBookmark = 0;
732 while (iBookmark < MAX_BOOKMARKS)
733 {
734 if (g_aBookmarks[ iBookmark ].bSet)
735 {
736 g_ConfigState.PushLineFormat( "%s %x %04X\n"
737 , g_aCommands[ CMD_BOOKMARK_ADD ].m_sName
738 , iBookmark
739 , g_aBookmarks[ iBookmark ].nAddress
740 );
741 }
742 iBookmark++;
743 }
744
745 if (nArgs)
746 {
747 if (! (g_aArgs[ 1 ].bType & TYPE_QUOTED_2))
748 return Help_Arg_1( CMD_BOOKMARK_SAVE );
749
750 if (ConfigSave_BufferToDisk( g_aArgs[ 1 ].sArg, CONFIG_SAVE_FILE_CREATE ))
751 {
752 ConsoleBufferPush( "Saved." );
753 return ConsoleUpdate();
754 }
755 }
756
757 return UPDATE_CONSOLE_DISPLAY;
758}
759
760
761

Callers 1

CmdConfigSaveFunction · 0.85

Calls 7

ConfigSave_PrepareHeaderFunction · 0.85
Help_Arg_1Function · 0.85
ConfigSave_BufferToDiskFunction · 0.85
PushLineFormatMethod · 0.80
ConsoleBufferPushFunction · 0.70
ConsoleUpdateFunction · 0.70
ResetMethod · 0.45

Tested by

no test coverage detected