//
//  app_settings.h - application wide settings container class header file
//
//  $Id: app_settings.h 54 2014-04-11 01:06:56Z brian $ 
//
//  Copyright (c) 2014 by Precision Micro Control Corp. All rights reserved.
//
#ifndef APP_SETTINGS_H
#define APP_SETTINGS_H

/// <summary>
/// Application settings container object
/// </summary>
class AppSettings {
public:
	AppSettings(void) : m_id(0) {}
	~AppSettings(void) {}

	/// <summary>Get the controller ID.</summary>
	/// <returns>Current controller ID.</returns>
    short int					ControllerID(void) { m_id; }
	/// <summary>Set the controller ID.</summary>
	/// <param name="id">New controller ID.</param>
	void						ControllerID(short int id) { m_id = id; }

	/// <summary>Get the INI file name and path.</summary>
	/// <returns>Current INI file name/path.</returns>
	CString&					IniFile(void) { return m_ini_file; }
	/// <summary>Set the INI file name and path.</summary>
	/// <param name="ini">New INI file name/path.</param>
	void						IniFile(char* ini) { m_ini_file = CString(ini); }
	/// <summary>Set the INI file name and path.</summary>
	/// <param name="ini">New INI file name/path.</param>
	void						IniFile(CString ini) { m_ini_file = ini; }
	/// <summary>Restore the application settings (and position the main window).</summary>
	/// <param name="hWnd">Main window handle.</param>
	void						Restore(HWND hWnd);
	/// <summary>Save the application settings (including main window position).</summary>
	/// <param name="hWnd">Main window handle.</param>
	void						Save(HWND hWnd);

private:
	short int					m_id;					///< controller ID
	CString						m_ini_file;				///< ini file and path 
};

#endif			// APP_SETTINGS_H

