Decouple <cstddef>

This commit is contained in:
Martin Natano
2023-04-19 23:04:25 +02:00
parent 093675cdc3
commit 78fb2e9fc3
171 changed files with 2012 additions and 1786 deletions
+7 -5
View File
@@ -8,21 +8,23 @@
#include "NotesLoaderKSF.h"
#include "RageUtil.h"
#include <cstddef>
void NotesLoader::GetMainAndSubTitlesFromFullTitle( const RString &sFullTitle, RString &sMainTitleOut, RString &sSubTitleOut )
{
const RString sLeftSeps[] = { "\t", " -", " ~", " (", " [" };
for( unsigned i=0; i<ARRAYLEN(sLeftSeps); i++ )
{
size_t iBeginIndex = sFullTitle.find( sLeftSeps[i] );
std::size_t iBeginIndex = sFullTitle.find( sLeftSeps[i] );
if( iBeginIndex == std::string::npos )
continue;
sMainTitleOut = sFullTitle.Left( (int) iBeginIndex );
sSubTitleOut = sFullTitle.substr( iBeginIndex+1, sFullTitle.size()-iBeginIndex+1 );
return;
}
sMainTitleOut = sFullTitle;
sSubTitleOut = "";
sMainTitleOut = sFullTitle;
sSubTitleOut = "";
};
bool NotesLoader::LoadFromDir( const RString &sPath, Song &out, std::set<RString> &BlacklistedImages, bool load_autosave )
@@ -67,7 +69,7 @@ bool NotesLoader::LoadFromDir( const RString &sPath, Song &out, std::set<RString
/*
* (c) 2001-2004,2007 Chris Danford, Glenn Maynard, Steve Checkoway
* All rights reserved.
*
*
* Permission is hereby granted, free of charge, to any person obtaining a
* copy of this software and associated documentation files (the
* "Software"), to deal in the Software without restriction, including
@@ -77,7 +79,7 @@ bool NotesLoader::LoadFromDir( const RString &sPath, Song &out, std::set<RString
* copyright notice(s) and this permission notice appear in all copies of
* the Software and that both the above copyright notice(s) and this
* permission notice appear in supporting documentation.
*
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
* OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT OF