From: <man...@us...> - 2013-06-27 16:17:37
|
Revision: 2417 http://sourceforge.net/p/modplug/code/2417 Author: manxorist Date: 2013-06-27 16:17:29 +0000 (Thu, 27 Jun 2013) Log Message: ----------- [Ref] Remove unused BUILD_TUNINGBASE_AS_TEMPLATE and associated code. Modified Paths: -------------- trunk/OpenMPT/mptrack/Draw_pat.cpp trunk/OpenMPT/soundlib/tuning.cpp trunk/OpenMPT/soundlib/tuning.h trunk/OpenMPT/soundlib/tuningCollection.cpp trunk/OpenMPT/soundlib/tuningbase.cpp trunk/OpenMPT/soundlib/tuningbase.h Modified: trunk/OpenMPT/mptrack/Draw_pat.cpp =================================================================== --- trunk/OpenMPT/mptrack/Draw_pat.cpp 2013-06-27 15:00:03 UTC (rev 2416) +++ trunk/OpenMPT/mptrack/Draw_pat.cpp 2013-06-27 16:17:29 UTC (rev 2417) @@ -403,7 +403,7 @@ { if(pTuning) { // Drawing custom note names - std::string noteStr = pTuning->GetNoteName(static_cast<CTuningBase::NOTEINDEXTYPE>(note-NOTE_MIDDLEC)); + std::string noteStr = pTuning->GetNoteName(static_cast<CTuning::NOTEINDEXTYPE>(note-NOTE_MIDDLEC)); if(noteStr.size() < 3) noteStr.resize(3, ' '); Modified: trunk/OpenMPT/soundlib/tuning.cpp =================================================================== --- trunk/OpenMPT/soundlib/tuning.cpp 2013-06-27 15:00:03 UTC (rev 2416) +++ trunk/OpenMPT/soundlib/tuning.cpp 2013-06-27 16:17:29 UTC (rev 2417) @@ -28,10 +28,10 @@ namespace CTuningS11n { void ReadStr(std::istream& iStrm, std::string& str, const size_t); - void ReadNoteMap(std::istream& iStrm, CTuningBase::NOTENAMEMAP& m, const size_t); + void ReadNoteMap(std::istream& iStrm, CTuning::NOTENAMEMAP& m, const size_t); void ReadRatioTable(std::istream& iStrm, std::vector<CTuningRTI::RATIOTYPE>& v, const size_t); - void WriteNoteMap(std::ostream& oStrm, const CTUNINGBASE::NOTENAMEMAP& m); + void WriteNoteMap(std::ostream& oStrm, const CTuning::NOTENAMEMAP& m); void WriteStr(std::ostream& oStrm, const std::string& str); struct RatioWriter @@ -371,7 +371,7 @@ } -CTuningBase* CTuningRTI::Deserialize(std::istream& iStrm) +CTuning* CTuningRTI::Deserialize(std::istream& iStrm) //-------------------------------------------------- { if(iStrm.fail()) @@ -380,7 +380,7 @@ CTuningRTI* pTuning = new CTuningRTI; srlztn::Ssb ssb(iStrm); - ssb.BeginRead("CTB244RTI", (CTuningBase::GetVersion() << 24) + GetVersion()); + ssb.BeginRead("CTB244RTI", (CTuning::GetVersion() << 24) + GetVersion()); ssb.ReadItem(pTuning->m_TuningName, "0", 1, ReadStr); ssb.ReadItem(pTuning->m_EditMask, "1"); ssb.ReadItem(pTuning->m_TuningType, "2"); @@ -467,7 +467,7 @@ } -CTUNINGBASE::SERIALIZATION_RETURN_TYPE CTuningRTI::Serialize(std::ostream& outStrm) const +CTuning::SERIALIZATION_RETURN_TYPE CTuningRTI::Serialize(std::ostream& outStrm) const //---------------------------------------------------------------------------------- { srlztn::Ssb ssb(outStrm); @@ -519,7 +519,7 @@ } -void ReadNoteMap(std::istream& iStrm, CTuningBase::NOTENAMEMAP& m, const size_t) +void ReadNoteMap(std::istream& iStrm, CTuning::NOTENAMEMAP& m, const size_t) //---------------------------------------------------------------------------------- { uint64 val; @@ -559,12 +559,12 @@ } -void WriteNoteMap(std::ostream& oStrm, const CTUNINGBASE::NOTENAMEMAP& m) +void WriteNoteMap(std::ostream& oStrm, const CTuning::NOTENAMEMAP& m) //--------------------------------------------------------------------------- { srlztn::WriteAdaptive1248(oStrm, m.size()); - CTUNINGBASE::NNM_CITER iter = m.begin(); - CTUNINGBASE::NNM_CITER end = m.end(); + CTuning::NNM_CITER iter = m.begin(); + CTuning::NNM_CITER end = m.end(); for(; iter != end; iter++) { srlztn::Binarywrite<int16>(oStrm, iter->first); Modified: trunk/OpenMPT/soundlib/tuning.h =================================================================== --- trunk/OpenMPT/soundlib/tuning.h 2013-06-27 15:00:03 UTC (rev 2416) +++ trunk/OpenMPT/soundlib/tuning.h 2013-06-27 16:17:29 UTC (rev 2417) @@ -12,12 +12,7 @@ #include "tuningbase.h" -#ifdef BUILD_TUNINGBASE_AS_TEMPLATE - typedef CTuningBase<int16, uint16, float32, int32, uint32> CTuning; - //If changing RATIOTYPE, serialization methods may need modifications. -#else - typedef CTuningBase CTuning; -#endif +typedef CTuningBase CTuning; @@ -63,7 +58,7 @@ virtual STEPINDEXTYPE GetStepDistance(const NOTEINDEXTYPE& noteFrom, const STEPINDEXTYPE& stepDistFrom, const NOTEINDEXTYPE& noteTo, const STEPINDEXTYPE& stepDistTo) const {return GetStepDistance(noteFrom, noteTo) + stepDistTo - stepDistFrom;} - static CTuningBase* Deserialize(std::istream& inStrm); + static CTuning* Deserialize(std::istream& inStrm); static uint32 GetVersion() {return s_SerializationVersion;} Modified: trunk/OpenMPT/soundlib/tuningCollection.cpp =================================================================== --- trunk/OpenMPT/soundlib/tuningCollection.cpp 2013-06-27 15:00:03 UTC (rev 2416) +++ trunk/OpenMPT/soundlib/tuningCollection.cpp 2013-06-27 16:17:29 UTC (rev 2417) @@ -31,10 +31,10 @@ namespace CTuningS11n { - void WriteNoteMap(std::ostream& oStrm, const CTUNINGBASE::NOTENAMEMAP& m); + void WriteNoteMap(std::ostream& oStrm, const CTuning::NOTENAMEMAP& m); void ReadStr(std::istream& iStrm, std::string& str, const size_t); - void ReadNoteMap(std::istream& iStrm, CTuningBase::NOTENAMEMAP& m, const size_t); + void ReadNoteMap(std::istream& iStrm, CTuning::NOTENAMEMAP& m, const size_t); void ReadRatioTable(std::istream& iStrm, std::vector<CTuningRTI::RATIOTYPE>& v, const size_t); void WriteStr(std::ostream& oStrm, const std::string& str); Modified: trunk/OpenMPT/soundlib/tuningbase.cpp =================================================================== --- trunk/OpenMPT/soundlib/tuningbase.cpp 2013-06-27 15:00:03 UTC (rev 2416) +++ trunk/OpenMPT/soundlib/tuningbase.cpp 2013-06-27 16:17:29 UTC (rev 2417) @@ -9,33 +9,30 @@ #include "stdafx.h" -#define TUNINGBASE_CPP #include "tuningbase.h" #include "../common/serialization_utils.h" -#ifdef TUNINGBASE_H -TEMPLATEDEC -const char* CTUNINGBASE::s_TuningDescriptionGeneral = "No ratio restrictions"; +const char* CTuningBase::s_TuningDescriptionGeneral = "No ratio restrictions"; -TEMPLATEDEC -const char* CTUNINGBASE::s_TuningDescriptionGroupGeometric = "Ratio of ratios with distance of 'groupsize' is constant."; -TEMPLATEDEC -const char* CTUNINGBASE::s_TuningDescriptionGeometric = "Ratio of successive ratios is constant."; +const char* CTuningBase::s_TuningDescriptionGroupGeometric = "Ratio of ratios with distance of 'groupsize' is constant."; -TEMPLATEDEC -const char* CTUNINGBASE::s_TuningTypeStrGeneral = "\"General\""; -TEMPLATEDEC -const char* CTUNINGBASE::s_TuningTypeStrGroupGeometric = "\"GroupGeometric\""; +const char* CTuningBase::s_TuningDescriptionGeometric = "Ratio of successive ratios is constant."; -TEMPLATEDEC -const char* CTUNINGBASE::s_TuningTypeStrGeometric = "\"Geometric\""; -TEMPLATEDEC -const TYPENAME CTUNINGBASE::SERIALIZATION_VERSION CTUNINGBASE::s_SerializationVersion(5); +const char* CTuningBase::s_TuningTypeStrGeneral = "\"General\""; + + +const char* CTuningBase::s_TuningTypeStrGroupGeometric = "\"GroupGeometric\""; + + +const char* CTuningBase::s_TuningTypeStrGeometric = "\"Geometric\""; + + +const CTuningBase::SERIALIZATION_VERSION CTuningBase::s_SerializationVersion(5); /* Version history: 4->5: Lots of changes, finestep interpretation revamp, fileformat revamp. @@ -44,48 +41,48 @@ */ -TEMPLATEDEC -const TYPENAME CTUNINGBASE::SERIALIZATION_RETURN_TYPE CTUNINGBASE::SERIALIZATION_SUCCESS = false; -TEMPLATEDEC -const TYPENAME CTUNINGBASE::SERIALIZATION_RETURN_TYPE CTUNINGBASE::SERIALIZATION_FAILURE = true; +const CTuningBase::SERIALIZATION_RETURN_TYPE CTuningBase::SERIALIZATION_SUCCESS = false; -TEMPLATEDEC -const TCHAR CTUNINGBASE::s_FileExtension[5] = MPT_TEXT(".tun"); -TEMPLATEDEC -const TYPENAME CTUNINGBASE::EDITMASK CTUNINGBASE::EM_RATIOS = 1; //1b -TEMPLATEDEC -const TYPENAME CTUNINGBASE::EDITMASK CTUNINGBASE::EM_NOTENAME = 1 << 1; //10b -TEMPLATEDEC -const TYPENAME CTUNINGBASE::EDITMASK CTUNINGBASE::EM_TYPE = 1 << 2; //100b -TEMPLATEDEC -const TYPENAME CTUNINGBASE::EDITMASK CTUNINGBASE::EM_NAME = 1 << 3; //1000b -TEMPLATEDEC -const TYPENAME CTUNINGBASE::EDITMASK CTUNINGBASE::EM_FINETUNE = 1 << 4; //10000b -TEMPLATEDEC -const TYPENAME CTUNINGBASE::EDITMASK CTUNINGBASE::EM_VALIDITYRANGE = 1 << 5; //100000b +const CTuningBase::SERIALIZATION_RETURN_TYPE CTuningBase::SERIALIZATION_FAILURE = true; -TEMPLATEDEC -const TYPENAME CTUNINGBASE::EDITMASK CTUNINGBASE::EM_ALLOWALL = 0xFFFF; //All editing allowed. -TEMPLATEDEC -const TYPENAME CTUNINGBASE::EDITMASK CTUNINGBASE::EM_EDITMASK = 0x8000; //Whether to allow modifications to editmask. -TEMPLATEDEC -const TYPENAME CTUNINGBASE::EDITMASK CTUNINGBASE::EM_CONST = 0x8000; //All editing except changing const status disable. -TEMPLATEDEC -const TYPENAME CTUNINGBASE::EDITMASK CTUNINGBASE::EM_CONST_STRICT = 0; //All bits are zero - even the const status can't be changed. +const TCHAR CTuningBase::s_FileExtension[5] = MPT_TEXT(".tun"); -TEMPLATEDEC -const TYPENAME CTUNINGBASE::TUNINGTYPE CTUNINGBASE::TT_GENERAL = 0; //0...00b -TEMPLATEDEC -const TYPENAME CTUNINGBASE::TUNINGTYPE CTUNINGBASE::TT_GROUPGEOMETRIC = 1; //0...10b -TEMPLATEDEC -const TYPENAME CTUNINGBASE::TUNINGTYPE CTUNINGBASE::TT_GEOMETRIC = 3; //0...11b +const CTuningBase::EDITMASK CTuningBase::EM_RATIOS = 1; //1b -TEMPLATEDEC -void CTUNINGBASE::TuningCopy(CTuningBase& to, const CTuningBase& from, const bool allowExactnamecopy) +const CTuningBase::EDITMASK CTuningBase::EM_NOTENAME = 1 << 1; //10b + +const CTuningBase::EDITMASK CTuningBase::EM_TYPE = 1 << 2; //100b + +const CTuningBase::EDITMASK CTuningBase::EM_NAME = 1 << 3; //1000b + +const CTuningBase::EDITMASK CTuningBase::EM_FINETUNE = 1 << 4; //10000b + +const CTuningBase::EDITMASK CTuningBase::EM_VALIDITYRANGE = 1 << 5; //100000b + + +const CTuningBase::EDITMASK CTuningBase::EM_ALLOWALL = 0xFFFF; //All editing allowed. + +const CTuningBase::EDITMASK CTuningBase::EM_EDITMASK = 0x8000; //Whether to allow modifications to editmask. + +const CTuningBase::EDITMASK CTuningBase::EM_CONST = 0x8000; //All editing except changing const status disable. + +const CTuningBase::EDITMASK CTuningBase::EM_CONST_STRICT = 0; //All bits are zero - even the const status can't be changed. + + + +const CTuningBase::TUNINGTYPE CTuningBase::TT_GENERAL = 0; //0...00b + +const CTuningBase::TUNINGTYPE CTuningBase::TT_GROUPGEOMETRIC = 1; //0...10b + +const CTuningBase::TUNINGTYPE CTuningBase::TT_GEOMETRIC = 3; //0...11b + + + +void CTuningBase::TuningCopy(CTuningBase& to, const CTuningBase& from, const bool allowExactnamecopy) //------------------------------------------------------------------------------------ { if(!to.MayEdit(EM_ALLOWALL)) @@ -116,8 +113,8 @@ } -TEMPLATEDEC -bool CTUNINGBASE::SetRatio(const NOTEINDEXTYPE& s, const RATIOTYPE& r) + +bool CTuningBase::SetRatio(const NOTEINDEXTYPE& s, const RATIOTYPE& r) //----------------------------------------------------------------- { if(MayEdit(EM_RATIOS)) @@ -133,8 +130,8 @@ } -TEMPLATEDEC -TYPENAME CTUNINGBASE::USTEPINDEXTYPE CTUNINGBASE::SetFineStepCount(const USTEPINDEXTYPE& fs) + +CTuningBase::USTEPINDEXTYPE CTuningBase::SetFineStepCount(const USTEPINDEXTYPE& fs) //------------------------------------------------------- { VRPAIR vrp = GetValidityRange(); @@ -152,8 +149,8 @@ } } -TEMPLATEDEC -TYPENAME CTUNINGBASE::TUNINGTYPE CTUNINGBASE::GetTuningType(const char* str) + +CTuningBase::TUNINGTYPE CTuningBase::GetTuningType(const char* str) //-------------------------------------------------------------------------- { if(!strcmp(str, s_TuningTypeStrGroupGeometric)) @@ -164,8 +161,8 @@ return TT_GENERAL; } -TEMPLATEDEC -std::string CTUNINGBASE::GetTuningTypeStr(const TUNINGTYPE& tt) + +std::string CTuningBase::GetTuningTypeStr(const TUNINGTYPE& tt) //---------------------------------------------------------------- { if(tt == TT_GENERAL) @@ -179,16 +176,16 @@ -TEMPLATEDEC -TYPENAME CTUNINGBASE::NOTESTR CTUNINGBASE::GetNoteName(const NOTEINDEXTYPE& x) const + +CTuningBase::NOTESTR CTuningBase::GetNoteName(const NOTEINDEXTYPE& x) const //----------------------------------------------------------------------- { if(!IsValidNote(x)) return ""; else return ProGetNoteName(x); } -TEMPLATEDEC -TYPENAME CTUNINGBASE::NOTESTR CTUNINGBASE::ProGetNoteName(const NOTEINDEXTYPE& x) const + +CTuningBase::NOTESTR CTuningBase::ProGetNoteName(const NOTEINDEXTYPE& x) const //------------------------------------------------------------------------------------- { NNM_CITER i = m_NoteNameMap.find(x); @@ -199,8 +196,8 @@ } -TEMPLATEDEC -bool CTUNINGBASE::IsOfType(const TUNINGTYPE& type) const + +bool CTuningBase::IsOfType(const TUNINGTYPE& type) const //---------------------------------------------------- { if(type == TT_GENERAL) @@ -219,8 +216,8 @@ return false; } -TEMPLATEDEC -bool CTUNINGBASE::SetNoteName(const NOTEINDEXTYPE& n, const std::string& str) + +bool CTuningBase::SetNoteName(const NOTEINDEXTYPE& n, const std::string& str) //----------------------------------------------------------------------- { if(MayEdit(EM_NOTENAME)) @@ -233,8 +230,8 @@ -TEMPLATEDEC -bool CTUNINGBASE::ClearNoteName(const NOTEINDEXTYPE& n, const bool eraseAll) + +bool CTuningBase::ClearNoteName(const NOTEINDEXTYPE& n, const bool eraseAll) //------------------------------------------------------- { if(MayEdit(EM_NOTENAME)) @@ -258,8 +255,8 @@ } -TEMPLATEDEC -bool CTUNINGBASE::Multiply(const RATIOTYPE& r) + +bool CTuningBase::Multiply(const RATIOTYPE& r) //--------------------------------------------------- { if(r <= 0 || !MayEdit(EM_RATIOS)) @@ -276,8 +273,8 @@ return false; } -TEMPLATEDEC -bool CTUNINGBASE::CreateGroupGeometric(const NOTEINDEXTYPE& s, const RATIOTYPE& r, const NOTEINDEXTYPE& startindex) + +bool CTuningBase::CreateGroupGeometric(const NOTEINDEXTYPE& s, const RATIOTYPE& r, const NOTEINDEXTYPE& startindex) //------------------------------------------------------------- { if(s < 1 || r <= 0 || startindex < GetValidityRange().first) @@ -290,8 +287,8 @@ return CreateGroupGeometric(v, r, GetValidityRange(), startindex); } -TEMPLATEDEC -bool CTUNINGBASE::CreateGroupGeometric(const std::vector<RATIOTYPE>& v, const RATIOTYPE& r, const VRPAIR vr, const NOTEINDEXTYPE ratiostartpos) + +bool CTuningBase::CreateGroupGeometric(const std::vector<RATIOTYPE>& v, const RATIOTYPE& r, const VRPAIR vr, const NOTEINDEXTYPE ratiostartpos) //------------------------------------------------------------------------------------------ { if(MayEdit(EM_RATIOS) && @@ -315,8 +312,8 @@ } -TEMPLATEDEC -bool CTUNINGBASE::CreateGeometric(const UNOTEINDEXTYPE& s, const RATIOTYPE& r, const VRPAIR vr) + +bool CTuningBase::CreateGeometric(const UNOTEINDEXTYPE& s, const RATIOTYPE& r, const VRPAIR vr) //------------------------------------------------------------------- { if(MayEdit(EM_RATIOS) && @@ -339,8 +336,8 @@ -TEMPLATEDEC -bool CTUNINGBASE::ChangeGroupsize(const NOTEINDEXTYPE& s) + +bool CTuningBase::ChangeGroupsize(const NOTEINDEXTYPE& s) //--------------------------------------------------- { if(!MayEdit(EM_RATIOS) || s < 1) @@ -356,8 +353,8 @@ } -TEMPLATEDEC -bool CTUNINGBASE::ChangeGroupRatio(const RATIOTYPE& r) + +bool CTuningBase::ChangeGroupRatio(const RATIOTYPE& r) //--------------------------------------------------- { if(!MayEdit(EM_RATIOS) || r <= 0) @@ -373,8 +370,8 @@ } -TEMPLATEDEC -const char* CTUNINGBASE::GetTuningTypeDescription(const TUNINGTYPE& type) + +const char* CTuningBase::GetTuningTypeDescription(const TUNINGTYPE& type) //--------------------------------------------------------------------------------------- { if(type == TT_GENERAL) @@ -386,8 +383,8 @@ return "Unknown"; } -TEMPLATEDEC -TYPENAME CTUNINGBASE::VRPAIR CTUNINGBASE::SetValidityRange(const VRPAIR& vrp) + +CTuningBase::VRPAIR CTuningBase::SetValidityRange(const VRPAIR& vrp) //---------------------------------------------------------------------------------------- { if(vrp.second < vrp.first) return GetValidityRange(); @@ -401,8 +398,8 @@ } -TEMPLATEDEC -bool CTUNINGBASE::SetType(const TUNINGTYPE& tt) + +bool CTuningBase::SetType(const TUNINGTYPE& tt) //---------------------------------------------- { //Note: This doesn't check whether the tuning ratios @@ -424,8 +421,8 @@ } -TEMPLATEDEC -bool CTUNINGBASE::DeserializeOLD(std::istream& inStrm) + +bool CTuningBase::DeserializeOLD(std::istream& inStrm) //------------------------------------------------ { char begin[8]; @@ -472,6 +469,3 @@ return SERIALIZATION_SUCCESS; } - -#endif - Modified: trunk/OpenMPT/soundlib/tuningbase.h =================================================================== --- trunk/OpenMPT/soundlib/tuningbase.h 2013-06-27 15:00:03 UTC (rev 2416) +++ trunk/OpenMPT/soundlib/tuningbase.h 2013-06-27 16:17:29 UTC (rev 2417) @@ -10,16 +10,7 @@ #pragma once -//#define BUILD_TUNINGBASE_AS_TEMPLATE -#if defined(TUNINGBASE_CPP) && defined(BUILD_TUNINGBASE_AS_TEMPLATE) - //Not including this file for tuningbase.cpp when building as template. -#else - -#ifndef TUNINGBASE_H -#define TUNINGBASE_H - - #include <string> #include <vector> #include <cmath> @@ -33,30 +24,7 @@ namespace srlztn {class Ssb;} -#ifdef BUILD_TUNINGBASE_AS_TEMPLATE - #define CLASSTEMPLATEDEC template<class TNOTEINDEXTYPE = int16, class TUNOTEINDEXTYPE = uint16, class TRATIOTYPE = float32, class TSTEPINDEXTYPE = int32, class TUSTEPINDEXTYPE = uint32> - #define TEMPLATEDEC template<class A, class B, class C, class D, class E> - #define TYPENAME typename - #define CTUNINGBASE CTuningBase<A, B, C, D, E> -#else - #define CLASSTEMPLATEDEC - typedef int16 TNOTEINDEXTYPE; - typedef uint16 TUNOTEINDEXTYPE; - typedef float32 TRATIOTYPE; - typedef int32 TSTEPINDEXTYPE; - typedef uint32 TUSTEPINDEXTYPE; - #define TYPENAME - #define TEMPLATEDEC - #define CTUNINGBASE CTuningBase -#endif - -#ifndef BYTE - typedef unsigned char BYTE; -#endif - - //Tuning baseclass; basic functionality is to map note to ratio. -CLASSTEMPLATEDEC class CTuningBase //=============== { @@ -70,11 +38,11 @@ public: //BEGIN TYPEDEFS: - typedef TNOTEINDEXTYPE NOTEINDEXTYPE; - typedef TUNOTEINDEXTYPE UNOTEINDEXTYPE; - typedef TRATIOTYPE RATIOTYPE; - typedef TSTEPINDEXTYPE STEPINDEXTYPE; - typedef TUSTEPINDEXTYPE USTEPINDEXTYPE; + typedef int16 NOTEINDEXTYPE; + typedef uint16 UNOTEINDEXTYPE; + typedef float32 RATIOTYPE; //If changing RATIOTYPE, serialization methods may need modifications. + typedef int32 STEPINDEXTYPE; + typedef uint32 USTEPINDEXTYPE; typedef void (*MESSAGEHANDLER)(const char*, const char*); typedef int16 SERIALIZATION_VERSION; @@ -89,8 +57,8 @@ typedef std::string NOTESTR; typedef std::map<NOTEINDEXTYPE, NOTESTR> NOTENAMEMAP; - typedef TYPENAME NOTENAMEMAP::iterator NNM_ITER; - typedef TYPENAME NOTENAMEMAP::const_iterator NNM_CITER; + typedef NOTENAMEMAP::iterator NNM_ITER; + typedef NOTENAMEMAP::const_iterator NNM_CITER; //END TYPEDEFS @@ -294,8 +262,8 @@ private: CTuningBase(CTuningBase&) {} CTuningBase& operator=(const CTuningBase&) {return *this;} - static void ReadNotenamemapPair(std::istream& iStrm, TYPENAME NOTENAMEMAP::value_type& val, const size_t); - static void WriteNotenamemappair(std::ostream& oStrm, const TYPENAME NOTENAMEMAP::value_type& val, const size_t); + static void ReadNotenamemapPair(std::istream& iStrm, NOTENAMEMAP::value_type& val, const size_t); + static void WriteNotenamemappair(std::ostream& oStrm, const NOTENAMEMAP::value_type& val, const size_t); public: static const char* s_TuningDescriptionGeneral; @@ -317,22 +285,22 @@ #define USTEPINDEXTYPE_MAX (std::numeric_limits<USTEPINDEXTYPE>::max)() -TEMPLATEDEC -inline const char* CTUNINGBASE::GetTuningTypeDescription() const + +inline const char* CTuningBase::GetTuningTypeDescription() const //---------------------------------------------------------------------- { return GetTuningTypeDescription(GetType()); } -TEMPLATEDEC -inline void CTUNINGBASE::SetName(const std::string& s) + +inline void CTuningBase::SetName(const std::string& s) //----------------------------------------------- { if(MayEdit(EM_NAME)) m_TuningName = s; } -TEMPLATEDEC -inline bool CTUNINGBASE::IsStepCountRangeSufficient(USTEPINDEXTYPE fs, VRPAIR vrp) + +inline bool CTuningBase::IsStepCountRangeSufficient(USTEPINDEXTYPE fs, VRPAIR vrp) //------------------------------------------------------------------ { if(vrp.first == STEPINDEXTYPE_MIN && vrp.second == STEPINDEXTYPE_MAX) return true; @@ -340,8 +308,8 @@ else return true; } -TEMPLATEDEC -inline bool CTUNINGBASE::SetEditMask(const EDITMASK& em) + +inline bool CTuningBase::SetEditMask(const EDITMASK& em) //------------------------------------------------------ { if(MayEdit(EM_EDITMASK)) @@ -350,12 +318,3 @@ return true; } - - -#if defined(BUILD_TUNINGBASE_AS_TEMPLATE) - #include "tuningbase.cpp" -#endif - -#endif -#endif - This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |