ReadConfigValue( SettingIndex ); } } return 0; } int RegisterConfigInteger( int SectionIndex, int Index, char *Name, int *IntValuePtr, void ( Callback ) ( int ) ) { if ( ( SectionIndex >= 0 ) && ( SectionIndex < SectionCount ) ) { int SettingIndex; if ( ( SettingIndex =
int RegisterConfigDouble(int SectionIndex, int Index, char *Name, double *DoubleValuePtr, void (Callback)(int)) { if ((SectionIndex >= 0) && (SectionIndex < SectionCount)) { int SettingIndex; if ((SettingIndex = FindSettingIndex(SectionIndex, Index, Name)) >= 0) { Settings[SettingIndex].SectionIndex = SectionIndex; Settings[SettingIndex].Index = Index; strcpy(Settings[SettingIndex].ValueName, Name); Settings[SettingIndex].SettingType = stDouble; Settings[SettingIndex].DoubleValuePtr = DoubleValuePtr; Settings[SettingIndex].Callback = Callback; ReadConfigValue(SettingIndex); } } return 0; }
int RegisterConfigBoolean(int SectionIndex, int Index, char *Name, int *BoolValuePtr, void (Callback)(int)) { if ((SectionIndex >= 0) && (SectionIndex < SectionCount)) { int SettingIndex; if ((SettingIndex = FindSettingIndex(SectionIndex, Index, Name)) >= 0) { Settings[SettingIndex].SectionIndex = SectionIndex; Settings[SettingIndex].Index = Index; strcpy(Settings[SettingIndex].ValueName, Name); Settings[SettingIndex].SettingType = stBoolean; Settings[SettingIndex].IntValuePtr = BoolValuePtr; Settings[SettingIndex].Callback = Callback; return ReadConfigValue(SettingIndex); } } return 0; }