MCPcopy Create free account
hub / github.com/DescentDevelopers/Descent3 / ReplaceAll

Method ReplaceAll

editor/ScriptStudio.cpp:547–553  ·  view source on GitHub ↗

This will start from the beginning and replace all the occurences

Source from the content-addressed store, hash-verified

545
546// This will start from the beginning and replace all the occurences
547void CScriptStudio::ReplaceAll(char *find_word, char *replace_word) {
548 SetCurrentIndex(0);
549 m_LastWord = " ";
550 while (FindNext(find_word)) {
551 ReplaceSelected(replace_word);
552 }
553}
554
555// This only replaces the selected string with the replace_word
556void CScriptStudio::ReplaceCurrent(char *replace_word) { ReplaceSelected(replace_word); }

Callers 1

OnFindReplaceMethod · 0.45

Calls 1

SetCurrentIndexFunction · 0.85

Tested by

no test coverage detected