Store preferences in a File

This commit is contained in:
urnenfeld 2010-05-22 14:18:11 +00:00
parent 8e956baea7
commit f45da3af40
3 changed files with 18 additions and 11 deletions

View File

@ -40,6 +40,7 @@ Application Caya :
AccountDialog.cpp AccountDialog.cpp
AccountListItem.cpp AccountListItem.cpp
AccountView.cpp AccountView.cpp
CayaPreferences.cpp
PreferencesDialog.cpp PreferencesDialog.cpp
PreferencesAccounts.cpp PreferencesAccounts.cpp
PreferencesBehavior.cpp PreferencesBehavior.cpp

View File

@ -34,6 +34,7 @@
#include "CayaConstants.h" #include "CayaConstants.h"
#include "CayaMessages.h" #include "CayaMessages.h"
#include "CayaProtocolMessages.h" #include "CayaProtocolMessages.h"
#include "CayaPreferences.h"
#include "CayaResources.h" #include "CayaResources.h"
#include "CayaUtils.h" #include "CayaUtils.h"
#include "NotifyMessage.h" #include "NotifyMessage.h"
@ -119,6 +120,7 @@ MainWindow::QuitRequested()
{ {
fListView->MakeEmpty(); fListView->MakeEmpty();
fServer->Quit(); fServer->Quit();
CayaPreferences::Get()->Save();
be_app->PostMessage(B_QUIT_REQUESTED); be_app->PostMessage(B_QUIT_REQUESTED);
return true; return true;
} }

View File

@ -0,0 +1,4 @@
#include "CayaPreferences.h"
template<> const char* CayaPreferences::fFolder = "Caya";
template<> const char* CayaPreferences::fFilename = "preferences";