MCPcopy Create free account
hub / github.com/dhewm/dhewm3 / ExtractFileName

Method ExtractFileName

neo/idlib/Str.cpp:968–980  ·  view source on GitHub ↗

==================== idStr::ExtractFileName ==================== */

Source from the content-addressed store, hash-verified

966====================
967*/
968void idStr::ExtractFileName( idStr &dest ) const {
969 int pos;
970
971 //
972 // back up until a \ or the start
973 //
974 pos = Length() - 1;
975 while( ( pos > 0 ) && !isDirSeparator( ( *this )[ pos - 1 ] ) ) {
976 pos--;
977 }
978
979 Right( Length() - pos, dest );
980}
981
982/*
983====================

Callers 8

Map_LoadFileFunction · 0.80
HandleInitDialogMethod · 0.80
OnLButtonUpMethod · 0.80
OnPasteMethod · 0.80
GetPackStatusMethod · 0.80
OpenFileReadFlagsMethod · 0.80
HandleDownloadsMethod · 0.80
WriteTypeInfoMethod · 0.80

Calls 1

isDirSeparatorFunction · 0.85

Tested by

no test coverage detected