settings.h

00001 #ifndef __SETTINGS_H__
00002 #define __SETTINGS_H__
00003 
00004 #include <util/settings.h>
00005 
00006 using namespace os;
00007 
00012 class AppSettings : public Settings
00013 {
00014 public:
00015         
00019         bool GetPassive()
00020         {
00021                 return( GetBool( "passive", true ) );
00022         }
00023         
00027         status_t SetPassive( bool bPassive )
00028         {
00029                 return( SetBool( "passive", bPassive ) );
00030         }
00031         
00035         int GetMaxConnections()
00036         {
00037                 return( GetInt32( "max_connections", 2 ) );
00038         }
00039         
00044         status_t SetMaxConnections( int nMax )
00045         {
00046                 return( SetInt32( "max_connections", nMax ) );
00047         }
00048         
00052         bool GetSaveHistory()
00053         {
00054                 return( GetBool( "save_history", true ) );
00055         }
00056         
00060         status_t SetSaveHistory( bool bSave )
00061         {
00062                 return( SetBool( "save_history", bSave ) ); 
00063         }
00064         
00068         Rect GetMainWindowFrame()
00069         {
00070                 return( GetRect( "main_frame", Rect(0,0,0,0) ) );
00071         }
00072         
00076         status_t SetMainWindowFrame( const Rect& cFrame )
00077         {
00078                 return( SetRect( "main_frame", cFrame ) );
00079         }
00080 
00084         Rect GetProgressWindowFrame()
00085         {
00086                 return( GetRect( "progress_frame", Rect(0,0,0,0) ) );
00087         }
00088         
00092         status_t SetProgressWindowFrame( const Rect& cFrame )
00093         {
00094                 return( SetRect( "progress_frame", cFrame ) );
00095         }
00096         
00100         bool GetDebugMode()
00101         {
00102                 return( GetBool( "debug", false ) );
00103         }
00104         
00108         status_t SetDebugMode( bool bDebug )
00109         {
00110                 return( SetBool( "debug", bDebug ) );
00111         }
00112 };
00113 
00114 
00115 #endif  /* __SETTINGS_H__ */
00116 

Generated on Fri Jan 2 17:22:49 2009 for Transferrer by  doxygen 1.5.1