Fix style on inline methods in PoorMan.

This commit is contained in:
Alex Wilson 2012-07-16 13:31:51 +12:00
parent c5a09a88e9
commit 0a96da93d1
3 changed files with 136 additions and 60 deletions

View File

@ -18,23 +18,41 @@ class PoorManLoggingView: public BView {
public:
PoorManLoggingView(const char* name);
void SetLogConsoleValue(bool state)
{ if (state)
fLogConsole->SetValue(B_CONTROL_ON);
else fLogConsole->SetValue(B_CONTROL_OFF); }
bool LogConsoleValue()
{ return (fLogConsole->Value() == B_CONTROL_ON)
? true : false; }
void SetLogFileValue(bool state)
{ if (state) fLogFile->SetValue(B_CONTROL_ON);
else fLogFile->SetValue(B_CONTROL_OFF); }
bool LogFileValue()
{ return (fLogFile->Value() == B_CONTROL_ON)
? true : false; }
const char* LogFileName()
{ return fLogFileName->Text(); }
void SetLogFileName(const char* log)
{ fLogFileName->SetText(log); }
void SetLogConsoleValue(bool state)
{
if (state)
fLogConsole->SetValue(B_CONTROL_ON);
else
fLogConsole->SetValue(B_CONTROL_OFF);
}
bool LogConsoleValue()
{
return (fLogConsole->Value() == B_CONTROL_ON);
}
void SetLogFileValue(bool state)
{
if (state)
fLogFile->SetValue(B_CONTROL_ON);
else
fLogFile->SetValue(B_CONTROL_OFF);
}
bool LogFileValue()
{
return (fLogFile->Value() == B_CONTROL_ON);
}
const char* LogFileName()
{
return fLogFileName->Text();
}
void SetLogFileName(const char* log)
{
fLogFileName->SetText(log);
}
private:
// Logging Tab

View File

@ -18,20 +18,38 @@ class PoorManSiteView: public BView {
public:
PoorManSiteView(const char *name);
void SetSendDirValue(bool state)
{ if (state) fSendDir->SetValue(B_CONTROL_ON);
else fSendDir->SetValue(B_CONTROL_OFF); }
bool SendDirValue()
{ return (fSendDir->Value() == B_CONTROL_ON)
? true : false; }
const char* IndexFileName()
{ return fIndexFileName->Text(); }
void SetIndexFileName(const char* name)
{ fIndexFileName->SetText(name); }
const char* WebDir()
{ return fWebDir->Text(); }
void SetWebDir(const char* dir)
{ fWebDir->SetText(dir); }
void SetSendDirValue(bool state)
{
if (state)
fSendDir->SetValue(B_CONTROL_ON);
else
fSendDir->SetValue(B_CONTROL_OFF);
}
bool SendDirValue()
{
return (fSendDir->Value() == B_CONTROL_ON);
}
const char* IndexFileName()
{
return fIndexFileName->Text();
}
void SetIndexFileName(const char* name)
{
fIndexFileName->SetText(name);
}
const char* WebDir()
{
return fWebDir->Text();
}
void SetWebDir(const char* dir)
{
fWebDir->SetText(dir);
}
private:
// Site Tab

View File

@ -60,35 +60,75 @@ public:
// -------------------------------------------
// Preferences and Settings
// Site Tab
bool DirListFlag()
{ return fDirListFlag; }
void SetDirListFlag(bool flag)
{ fDirListFlag = flag; }
const char* IndexFileName()
{ return fIndexFileName.String(); }
void SetIndexFileName(const char* str)
{ fIndexFileName.SetTo(str); }
const char* WebDir()
{ return fWebDirectory.String(); }
void SetWebDir(const char* str)
{ fWebDirectory.SetTo(str); }
// Logging Tab
bool LogConsoleFlag()
{ return fLogConsoleFlag; }
void SetLogConsoleFlag(bool flag)
{ fLogConsoleFlag = flag; }
bool LogFileFlag()
{ return fLogFileFlag; }
void SetLogFileFlag(bool flag)
{ fLogFileFlag = flag; }
const char* LogPath()
{ return fLogPath.String(); }
void SetLogPath(const char* str);
// Advanced Tab
int16 MaxConnections()
{ return fMaxConnections; }
void SetMaxConnections(int16 num)
{ fMaxConnections = num; }
bool DirListFlag()
{
return fDirListFlag;
}
void SetDirListFlag(bool flag)
{
fDirListFlag = flag;
}
const char* IndexFileName()
{
return fIndexFileName.String();
}
void SetIndexFileName(const char* str)
{
fIndexFileName.SetTo(str);
}
const char* WebDir()
{
return fWebDirectory.String();
}
void SetWebDir(const char* str)
{
fWebDirectory.SetTo(str);
}
// Logging Tab
bool LogConsoleFlag()
{
return fLogConsoleFlag;
}
void SetLogConsoleFlag(bool flag)
{
fLogConsoleFlag = flag;
}
bool LogFileFlag()
{
return fLogFileFlag;
}
void SetLogFileFlag(bool flag)
{
fLogFileFlag = flag;
}
const char* LogPath()
{
return fLogPath.String();
}
void SetLogPath(const char* str);
// Advanced Tab
int16 MaxConnections()
{
return fMaxConnections;
}
void SetMaxConnections(int16 num)
{
fMaxConnections = num;
}
private:
// -------------------------------------------