basic export packages UI (doesn't export the smzip yet)
This commit is contained in:
@@ -14,7 +14,7 @@ void AnnouncerManager::GetAnnouncerNames( vector<RString>& AddTo )
|
||||
{
|
||||
GetDirListing( ANNOUNCERS_DIR+"*", AddTo, true );
|
||||
|
||||
StripCvs( AddTo );
|
||||
StripCvsAndSvn( AddTo );
|
||||
|
||||
// strip out the empty announcer folder
|
||||
for( int i=AddTo.size()-1; i>=0; i-- )
|
||||
|
||||
@@ -87,7 +87,7 @@ const RString SBE_StretchNoLoop = "StretchNoLoop";
|
||||
const RString SBE_StretchRewind = "StretchRewind";
|
||||
const RString SBT_CrossFade = "CrossFade";
|
||||
|
||||
static void StripCvs( vector<RString> &vsPathsToStrip, vector<RString> &vsNamesToStrip )
|
||||
static void StripCvsAndSvn( vector<RString> &vsPathsToStrip, vector<RString> &vsNamesToStrip )
|
||||
{
|
||||
ASSERT( vsPathsToStrip.size() == vsNamesToStrip.size() );
|
||||
for( unsigned i=0; i<vsNamesToStrip.size(); i++ )
|
||||
@@ -123,7 +123,7 @@ void BackgroundUtil::GetBackgroundEffects( const RString &_sName, vector<RString
|
||||
FOREACH_CONST( RString, vsPathsOut, s )
|
||||
vsNamesOut.push_back( GetFileNameWithoutExtension(*s) );
|
||||
|
||||
StripCvs( vsPathsOut, vsNamesOut );
|
||||
StripCvsAndSvn( vsPathsOut, vsNamesOut );
|
||||
}
|
||||
|
||||
void BackgroundUtil::GetBackgroundTransitions( const RString &_sName, vector<RString> &vsPathsOut, vector<RString> &vsNamesOut )
|
||||
@@ -140,7 +140,7 @@ void BackgroundUtil::GetBackgroundTransitions( const RString &_sName, vector<RSt
|
||||
FOREACH_CONST( RString, vsPathsOut, s )
|
||||
vsNamesOut.push_back( GetFileNameWithoutExtension(*s) );
|
||||
|
||||
StripCvs( vsPathsOut, vsNamesOut );
|
||||
StripCvsAndSvn( vsPathsOut, vsNamesOut );
|
||||
}
|
||||
|
||||
void BackgroundUtil::GetSongBGAnimations( const Song *pSong, const RString &sMatch, vector<RString> &vsPathsOut, vector<RString> &vsNamesOut )
|
||||
@@ -159,7 +159,7 @@ void BackgroundUtil::GetSongBGAnimations( const Song *pSong, const RString &sMat
|
||||
FOREACH_CONST( RString, vsPathsOut, s )
|
||||
vsNamesOut.push_back( Basename(*s) );
|
||||
|
||||
StripCvs( vsPathsOut, vsNamesOut );
|
||||
StripCvsAndSvn( vsPathsOut, vsNamesOut );
|
||||
}
|
||||
|
||||
void BackgroundUtil::GetSongMovies( const Song *pSong, const RString &sMatch, vector<RString> &vsPathsOut, vector<RString> &vsNamesOut )
|
||||
@@ -180,7 +180,7 @@ void BackgroundUtil::GetSongMovies( const Song *pSong, const RString &sMatch, ve
|
||||
FOREACH_CONST( RString, vsPathsOut, s )
|
||||
vsNamesOut.push_back( Basename(*s) );
|
||||
|
||||
StripCvs( vsPathsOut, vsNamesOut );
|
||||
StripCvsAndSvn( vsPathsOut, vsNamesOut );
|
||||
}
|
||||
|
||||
void BackgroundUtil::GetSongBitmaps( const Song *pSong, const RString &sMatch, vector<RString> &vsPathsOut, vector<RString> &vsNamesOut )
|
||||
@@ -202,7 +202,7 @@ void BackgroundUtil::GetSongBitmaps( const Song *pSong, const RString &sMatch, v
|
||||
FOREACH_CONST( RString, vsPathsOut, s )
|
||||
vsNamesOut.push_back( Basename(*s) );
|
||||
|
||||
StripCvs( vsPathsOut, vsNamesOut );
|
||||
StripCvsAndSvn( vsPathsOut, vsNamesOut );
|
||||
}
|
||||
|
||||
static void GetFilterToFileNames( const RString sBaseDir, const Song *pSong, set<RString> &vsPossibleFileNamesOut )
|
||||
@@ -246,7 +246,7 @@ void BackgroundUtil::GetGlobalBGAnimations( const Song *pSong, const RString &sM
|
||||
FOREACH_CONST( RString, vsPathsOut, s )
|
||||
vsNamesOut.push_back( Basename(*s) );
|
||||
|
||||
StripCvs( vsPathsOut, vsNamesOut );
|
||||
StripCvsAndSvn( vsPathsOut, vsNamesOut );
|
||||
}
|
||||
|
||||
void BackgroundUtil::GetGlobalRandomMovies(
|
||||
@@ -326,7 +326,7 @@ found_files:
|
||||
RString sName = s->Right( s->size() - RANDOMMOVIES_DIR.size() - 1 );
|
||||
vsNamesOut.push_back( sName );
|
||||
}
|
||||
StripCvs( vsPathsOut, vsNamesOut );
|
||||
StripCvsAndSvn( vsPathsOut, vsNamesOut );
|
||||
}
|
||||
|
||||
void BackgroundUtil::BakeAllBackgroundChanges( Song *pSong )
|
||||
|
||||
@@ -26,7 +26,7 @@ CharacterManager::CharacterManager()
|
||||
|
||||
vector<RString> as;
|
||||
GetDirListing( CHARACTERS_DIR "*", as, true, true );
|
||||
StripCvs( as );
|
||||
StripCvsAndSvn( as );
|
||||
|
||||
bool FoundDefault = false;
|
||||
for( unsigned i=0; i<as.size(); i++ )
|
||||
|
||||
@@ -14,15 +14,15 @@
|
||||
#include "XmlFileUtil.h"
|
||||
#include "Sprite.h"
|
||||
#include <map>
|
||||
#include "SpecialFiles.h"
|
||||
|
||||
|
||||
NoteSkinManager* NOTESKIN = NULL; // global object accessable from anywhere in the program
|
||||
|
||||
|
||||
const RString NOTESKINS_DIR = "NoteSkins/";
|
||||
const RString GAME_COMMON_NOTESKIN_NAME = "common";
|
||||
const RString GAME_BASE_NOTESKIN_NAME = "default";
|
||||
const RString GLOBAL_BASE_DIR = NOTESKINS_DIR + GAME_COMMON_NOTESKIN_NAME + "/";
|
||||
const RString GLOBAL_BASE_DIR = SpecialFiles::NOTESKINS_DIR + GAME_COMMON_NOTESKIN_NAME + "/";
|
||||
static map<RString,RString> g_PathCache;
|
||||
|
||||
struct NoteSkinData
|
||||
@@ -72,11 +72,11 @@ void NoteSkinManager::RefreshNoteSkinData( const Game* pGame )
|
||||
// clear path cache
|
||||
g_PathCache.clear();
|
||||
|
||||
RString sBaseSkinFolder = NOTESKINS_DIR + pGame->m_szName + "/";
|
||||
RString sBaseSkinFolder = SpecialFiles::NOTESKINS_DIR + pGame->m_szName + "/";
|
||||
vector<RString> asNoteSkinNames;
|
||||
GetDirListing( sBaseSkinFolder + "*", asNoteSkinNames, true );
|
||||
|
||||
StripCvs( asNoteSkinNames );
|
||||
StripCvsAndSvn( asNoteSkinNames );
|
||||
|
||||
g_mapNameToData.clear();
|
||||
for( unsigned j=0; j<asNoteSkinNames.size(); j++ )
|
||||
@@ -109,7 +109,7 @@ void NoteSkinManager::LoadNoteSkinDataRecursive( const RString &sNoteSkinName_,
|
||||
++iDepth;
|
||||
ASSERT_M( iDepth < 20, "Circular NoteSkin fallback references detected." );
|
||||
|
||||
RString sDir = NOTESKINS_DIR + m_pCurGame->m_szName + "/" + sNoteSkinName + "/";
|
||||
RString sDir = SpecialFiles::NOTESKINS_DIR + m_pCurGame->m_szName + "/" + sNoteSkinName + "/";
|
||||
if( !FILEMAN->IsADirectory(sDir) )
|
||||
{
|
||||
sDir = GLOBAL_BASE_DIR + sNoteSkinName + "/";
|
||||
@@ -231,9 +231,9 @@ void NoteSkinManager::GetAllNoteSkinNamesForGame( const Game *pGame, vector<RStr
|
||||
}
|
||||
else
|
||||
{
|
||||
RString sBaseSkinFolder = NOTESKINS_DIR + pGame->m_szName + "/";
|
||||
RString sBaseSkinFolder = SpecialFiles::NOTESKINS_DIR + pGame->m_szName + "/";
|
||||
GetDirListing( sBaseSkinFolder + "*", AddTo, true );
|
||||
StripCvs( AddTo );
|
||||
StripCvsAndSvn( AddTo );
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -1159,10 +1159,10 @@ RString URLEncode( const RString &sStr )
|
||||
|
||||
static bool CVSOrSVN( const RString& s )
|
||||
{
|
||||
return s.Right(3).CompareNoCase("CVS") == 0 || s == ".svn";
|
||||
return s.Right(3).EqualsNoCase("CVS") || s.Right(4) == ".svn";
|
||||
}
|
||||
|
||||
void StripCvs( vector<RString> &vs )
|
||||
void StripCvsAndSvn( vector<RString> &vs )
|
||||
{
|
||||
RemoveIf( vs, CVSOrSVN );
|
||||
}
|
||||
|
||||
@@ -486,7 +486,7 @@ bool BeginsWith( const RString &sTestThis, const RString &sBeginning );
|
||||
bool EndsWith( const RString &sTestThis, const RString &sEnding );
|
||||
RString URLEncode( const RString &sStr );
|
||||
|
||||
void StripCvs( vector<RString> &vs ); // remove all items that end in "cvs"
|
||||
void StripCvsAndSvn( vector<RString> &vs ); // remove all items that end in "cvs"
|
||||
|
||||
RString DerefRedir( const RString &sPath );
|
||||
bool GetFileContents( const RString &sPath, RString &sOut, bool bOneLine = false );
|
||||
|
||||
@@ -0,0 +1,140 @@
|
||||
#include "global.h"
|
||||
#include "ScreenOptionsExportPackage.h"
|
||||
#include "ScreenManager.h"
|
||||
#include "RageLog.h"
|
||||
#include "GameState.h"
|
||||
#include "CommonMetrics.h"
|
||||
#include "ScreenPrompt.h"
|
||||
#include "ScreenMiniMenu.h"
|
||||
#include "OptionRowHandler.h"
|
||||
#include "LocalizedString.h"
|
||||
#include "SpecialFiles.h"
|
||||
#include "SpecialFiles.h"
|
||||
#include "ScreenPrompt.h"
|
||||
|
||||
REGISTER_SCREEN_CLASS( ScreenOptionsExportPackage );
|
||||
|
||||
void ScreenOptionsExportPackage::Init()
|
||||
{
|
||||
ScreenOptions::Init();
|
||||
|
||||
SetNavigation( NAV_THREE_KEY_MENU );
|
||||
SetInputMode( INPUTMODE_SHARE_CURSOR );
|
||||
}
|
||||
|
||||
void ScreenOptionsExportPackage::BeginScreen()
|
||||
{
|
||||
// Fill m_vsPossibleDirsToExport
|
||||
{
|
||||
// Add themes
|
||||
{
|
||||
GetDirListing( SpecialFiles::THEMES_DIR + "*", m_vsPossibleDirsToExport, true, true );
|
||||
}
|
||||
|
||||
// Add NoteSkins
|
||||
{
|
||||
vector<RString> vs;
|
||||
GetDirListing( SpecialFiles::NOTESKINS_DIR + "*", vs, true, true );
|
||||
FOREACH_CONST( RString, vs, s )
|
||||
GetDirListing( *s + "*", m_vsPossibleDirsToExport, true, true );
|
||||
}
|
||||
|
||||
// Add courses. Only support courses that are in a group folder. Support for courses not in a group folder should be phased out.
|
||||
{
|
||||
vector<RString> vs;
|
||||
GetDirListing( SpecialFiles::COURSES_DIR + "*", vs, true, true );
|
||||
FOREACH_CONST( RString, vs, s )
|
||||
{
|
||||
m_vsPossibleDirsToExport.push_back( *s );
|
||||
GetDirListing( *s + "/*", m_vsPossibleDirsToExport, true, true );
|
||||
}
|
||||
}
|
||||
|
||||
// Add songs
|
||||
{
|
||||
vector<RString> vs;
|
||||
GetDirListing( SpecialFiles::SONGS_DIR + "*", vs, true, true );
|
||||
FOREACH_CONST( RString, vs, s )
|
||||
{
|
||||
m_vsPossibleDirsToExport.push_back( *s );
|
||||
GetDirListing( *s + "/*", m_vsPossibleDirsToExport, true, true );
|
||||
}
|
||||
}
|
||||
|
||||
StripCvsAndSvn( m_vsPossibleDirsToExport );
|
||||
}
|
||||
|
||||
|
||||
|
||||
vector<OptionRowHandler*> OptionRowHandlers;
|
||||
FOREACH_CONST( RString, m_vsPossibleDirsToExport, s )
|
||||
{
|
||||
OptionRowHandler *pHand = OptionRowHandlerUtil::MakeNull();
|
||||
OptionRowDefinition &def = pHand->m_Def;
|
||||
def.m_layoutType = LAYOUT_SHOW_ALL_IN_ROW;
|
||||
def.m_bAllowThemeTitle = false;
|
||||
def.m_bAllowThemeItems = false;
|
||||
def.m_bAllowExplanation = false;
|
||||
def.m_sName = *s;
|
||||
def.m_sExplanationName = "# files, # MB, # subdirs";
|
||||
|
||||
def.m_vsChoices.push_back( "" );
|
||||
OptionRowHandlers.push_back( pHand );
|
||||
}
|
||||
ScreenOptions::InitMenu( OptionRowHandlers );
|
||||
|
||||
ScreenOptions::BeginScreen();
|
||||
}
|
||||
|
||||
void ScreenOptionsExportPackage::ProcessMenuStart( const InputEventPlus &input )
|
||||
{
|
||||
if( IsTransitioning() )
|
||||
return;
|
||||
|
||||
int iCurRow = m_iCurrentRow[GAMESTATE->m_MasterPlayerNumber];
|
||||
OptionRow &row = *m_pRows[iCurRow];
|
||||
RString sDirToExport = row.GetRowDef().m_sName;
|
||||
|
||||
|
||||
bool bSuccess = true; // DoExport();
|
||||
if( bSuccess )
|
||||
ScreenPrompt::Prompt( SM_None, ssprintf("Exported '%s' to the desktop", sDirToExport.c_str()) );
|
||||
else
|
||||
ScreenPrompt::Prompt( SM_None, "Failed to export package" );
|
||||
}
|
||||
|
||||
void ScreenOptionsExportPackage::ImportOptions( int iRow, const vector<PlayerNumber> &vpns )
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
void ScreenOptionsExportPackage::ExportOptions( int iRow, const vector<PlayerNumber> &vpns )
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
|
||||
/*
|
||||
* (c) 2002-2004 Chris Danford
|
||||
* 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
|
||||
* without limitation the rights to use, copy, modify, merge, publish,
|
||||
* distribute, and/or sell copies of the Software, and to permit persons to
|
||||
* whom the Software is furnished to do so, provided that the above
|
||||
* 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
|
||||
* THIRD PARTY RIGHTS. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR HOLDERS
|
||||
* INCLUDED IN THIS NOTICE BE LIABLE FOR ANY CLAIM, OR ANY SPECIAL INDIRECT
|
||||
* OR CONSEQUENTIAL DAMAGES, OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS
|
||||
* OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
|
||||
* OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
|
||||
* PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
@@ -0,0 +1,49 @@
|
||||
#ifndef ScreenOptionsExportPackage_H
|
||||
#define ScreenOptionsExportPackage_H
|
||||
|
||||
#include "ScreenOptions.h"
|
||||
#include "ScreenMiniMenu.h"
|
||||
|
||||
class Course;
|
||||
|
||||
class ScreenOptionsExportPackage : public ScreenOptions
|
||||
{
|
||||
public:
|
||||
void Init();
|
||||
virtual void BeginScreen();
|
||||
|
||||
protected:
|
||||
virtual void ImportOptions( int iRow, const vector<PlayerNumber> &vpns );
|
||||
virtual void ExportOptions( int iRow, const vector<PlayerNumber> &vpns );
|
||||
|
||||
virtual void ProcessMenuStart( const InputEventPlus &input );
|
||||
|
||||
vector<RString> m_vsPossibleDirsToExport;
|
||||
};
|
||||
|
||||
#endif
|
||||
|
||||
/*
|
||||
* (c) 2003-2004 Chris Danford
|
||||
* 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
|
||||
* without limitation the rights to use, copy, modify, merge, publish,
|
||||
* distribute, and/or sell copies of the Software, and to permit persons to
|
||||
* whom the Software is furnished to do so, provided that the above
|
||||
* 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
|
||||
* THIRD PARTY RIGHTS. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR HOLDERS
|
||||
* INCLUDED IN THIS NOTICE BE LIABLE FOR ANY CLAIM, OR ANY SPECIAL INDIRECT
|
||||
* OR CONSEQUENTIAL DAMAGES, OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS
|
||||
* OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
|
||||
* OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
|
||||
* PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
@@ -34,13 +34,11 @@
|
||||
#include "TitleSubstitution.h"
|
||||
#include "TrailUtil.h"
|
||||
#include "UnlockManager.h"
|
||||
|
||||
#include "SpecialFiles.h"
|
||||
|
||||
SongManager* SONGMAN = NULL; // global and accessable from anywhere in our program
|
||||
|
||||
const RString SONGS_DIR = "/Songs/";
|
||||
const RString ADDITIONAL_SONGS_DIR = "/AdditionalSongs/";
|
||||
const RString COURSES_DIR = "/Courses/";
|
||||
const RString ADDITIONAL_COURSES_DIR = "/AdditionalCourses/";
|
||||
const RString EDIT_SUBDIR = "Edits/";
|
||||
|
||||
@@ -100,9 +98,9 @@ void SongManager::InitAll( LoadingWindow *ld )
|
||||
static LocalizedString RELOADING ( "SongManager", "Reloading..." );
|
||||
void SongManager::Reload( bool bAllowFastLoad, LoadingWindow *ld )
|
||||
{
|
||||
FILEMAN->FlushDirCache( SONGS_DIR );
|
||||
FILEMAN->FlushDirCache( SpecialFiles::SONGS_DIR );
|
||||
FILEMAN->FlushDirCache( ADDITIONAL_SONGS_DIR );
|
||||
FILEMAN->FlushDirCache( COURSES_DIR );
|
||||
FILEMAN->FlushDirCache( SpecialFiles::COURSES_DIR );
|
||||
FILEMAN->FlushDirCache( ADDITIONAL_COURSES_DIR );
|
||||
FILEMAN->FlushDirCache( EDIT_SUBDIR );
|
||||
|
||||
@@ -135,7 +133,7 @@ void SongManager::Reload( bool bAllowFastLoad, LoadingWindow *ld )
|
||||
void SongManager::InitSongsFromDisk( LoadingWindow *ld )
|
||||
{
|
||||
RageTimer tm;
|
||||
LoadStepManiaSongDir( SONGS_DIR, ld );
|
||||
LoadStepManiaSongDir( SpecialFiles::SONGS_DIR, ld );
|
||||
|
||||
const bool bOldVal = PREFSMAN->m_bFastLoad;
|
||||
PREFSMAN->m_bFastLoad.Set( PREFSMAN->m_bFastLoadAdditionalSongs );
|
||||
@@ -206,7 +204,7 @@ void SongManager::LoadStepManiaSongDir( RString sDir, LoadingWindow *ld )
|
||||
vector<RString> arrayGroupDirs;
|
||||
GetDirListing( sDir+"*", arrayGroupDirs, true );
|
||||
SortRStringArray( arrayGroupDirs );
|
||||
StripCvs( arrayGroupDirs );
|
||||
StripCvsAndSvn( arrayGroupDirs );
|
||||
|
||||
FOREACH_CONST( RString, arrayGroupDirs, s ) // foreach dir in /Songs/
|
||||
{
|
||||
@@ -217,7 +215,7 @@ void SongManager::LoadStepManiaSongDir( RString sDir, LoadingWindow *ld )
|
||||
// Find all Song folders in this group directory
|
||||
vector<RString> arraySongDirs;
|
||||
GetDirListing( sDir+sGroupDirName + "/*", arraySongDirs, true, true );
|
||||
StripCvs( arraySongDirs );
|
||||
StripCvsAndSvn( arraySongDirs );
|
||||
SortRStringArray( arraySongDirs );
|
||||
|
||||
LOG->Trace("Attempting to load %i songs from \"%s\"", int(arraySongDirs.size()),
|
||||
@@ -688,7 +686,7 @@ void SongManager::InitCoursesFromDisk( LoadingWindow *ld )
|
||||
LOG->Trace( "Loading courses." );
|
||||
|
||||
vector<RString> vsCourseDirs;
|
||||
vsCourseDirs.push_back( COURSES_DIR );
|
||||
vsCourseDirs.push_back( SpecialFiles::COURSES_DIR );
|
||||
vsCourseDirs.push_back( ADDITIONAL_COURSES_DIR );
|
||||
|
||||
vector<RString> vsCourseGroupNames;
|
||||
@@ -696,11 +694,11 @@ void SongManager::InitCoursesFromDisk( LoadingWindow *ld )
|
||||
{
|
||||
// Find all group directories in Courses dir
|
||||
GetDirListing( *sDir + "*", vsCourseGroupNames, true, true );
|
||||
StripCvs( vsCourseGroupNames );
|
||||
StripCvsAndSvn( vsCourseGroupNames );
|
||||
}
|
||||
|
||||
// Search for courses both in COURSES_DIR and in subdirectories
|
||||
vsCourseGroupNames.push_back( COURSES_DIR );
|
||||
vsCourseGroupNames.push_back( SpecialFiles::COURSES_DIR );
|
||||
SortRStringArray( vsCourseGroupNames );
|
||||
|
||||
FOREACH_CONST( RString, vsCourseGroupNames, sCourseGroup ) // for each dir in /Courses/
|
||||
@@ -1090,7 +1088,7 @@ void SongManager::GetCoursesInGroup( vector<Course*> &AddTo, const RString &sCou
|
||||
bool SongManager::GetExtraStageInfoFromCourse( bool bExtra2, RString sPreferredGroup, Song*& pSongOut, Steps*& pStepsOut )
|
||||
{
|
||||
const RString sCourseSuffix = sPreferredGroup + (bExtra2 ? "/extra2.crs" : "/extra1.crs");
|
||||
RString sCoursePath = SONGS_DIR + sCourseSuffix;
|
||||
RString sCoursePath = SpecialFiles::SONGS_DIR + sCourseSuffix;
|
||||
|
||||
/* Couldn't find course in DWI path or alternative song folders */
|
||||
if( !DoesFileExist(sCoursePath) )
|
||||
|
||||
@@ -15,6 +15,9 @@ const RString SpecialFiles::BASE_THEME_NAME = "default";
|
||||
const RString SpecialFiles::DEFAULTS_INI_PATH = "Data/Defaults.ini";
|
||||
const RString SpecialFiles::STATIC_INI_PATH = "Data/Static.ini";
|
||||
const RString SpecialFiles::TYPE_TXT_FILE = "Data/Type.txt";
|
||||
const RString SpecialFiles::SONGS_DIR = "Songs/";
|
||||
const RString SpecialFiles::COURSES_DIR = "Courses/";
|
||||
const RString SpecialFiles::NOTESKINS_DIR = "NoteSkins/";
|
||||
|
||||
|
||||
/*
|
||||
|
||||
@@ -18,6 +18,9 @@ namespace SpecialFiles
|
||||
extern const RString DEFAULTS_INI_PATH;
|
||||
extern const RString STATIC_INI_PATH;
|
||||
extern const RString TYPE_TXT_FILE;
|
||||
extern const RString SONGS_DIR;
|
||||
extern const RString COURSES_DIR;
|
||||
extern const RString NOTESKINS_DIR;
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
@@ -621,6 +621,14 @@
|
||||
RelativePath=".\ScreenOptionsEditWorkout.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\ScreenOptionsExportPackage.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\ScreenOptionsExportPackage.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\ScreenOptionsManageCourses.cpp"
|
||||
>
|
||||
|
||||
@@ -179,7 +179,7 @@ ThemeManager::~ThemeManager()
|
||||
void ThemeManager::GetThemeNames( vector<RString>& AddTo )
|
||||
{
|
||||
GetDirListing( SpecialFiles::THEMES_DIR + "*", AddTo, true );
|
||||
StripCvs( AddTo );
|
||||
StripCvsAndSvn( AddTo );
|
||||
}
|
||||
|
||||
void ThemeManager::GetSelectableThemeNames( vector<RString>& AddTo )
|
||||
|
||||
@@ -53,7 +53,7 @@ BOOL LanguagesDlg::OnInitDialog()
|
||||
|
||||
vector<RString> vs;
|
||||
GetDirListing( SpecialFiles::THEMES_DIR+"*", vs, true );
|
||||
StripCvs( vs );
|
||||
StripCvsAndSvn( vs );
|
||||
FOREACH_CONST( RString, vs, s )
|
||||
m_listThemes.AddString( *s );
|
||||
if( !vs.empty() )
|
||||
|
||||
Reference in New Issue
Block a user