mirror of
https://github.com/RetroShare/RetroShare.git
synced 2025-05-25 01:01:40 -04:00
reworked settings
now there is only one global object for loading and saving settings RshareSettings *Settings; the class RSettings can be used too, but it is not prefered, because the default settings has no affect git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@2964 b45a01b8-16f6-495d-af2f-9b41ad6348cc
This commit is contained in:
parent
e68e6b54ef
commit
6baf56285b
39 changed files with 336 additions and 390 deletions
|
@ -68,15 +68,14 @@ void OnlineToaster::chatButtonSlot() {
|
|||
}
|
||||
|
||||
void OnlineToaster::play(){
|
||||
RshareSettings settings;
|
||||
settings.beginGroup("Sound");
|
||||
settings.beginGroup("SoundFilePath");
|
||||
QString OnlineSound= settings.value("User_go_Online","").toString();
|
||||
settings.endGroup();
|
||||
settings.beginGroup("Enable");
|
||||
bool flag= settings.value("User_go_Online",false).toBool();
|
||||
settings.endGroup();
|
||||
settings.endGroup();
|
||||
Settings->beginGroup("Sound");
|
||||
Settings->beginGroup("SoundFilePath");
|
||||
QString OnlineSound = Settings->value("User_go_Online","").toString();
|
||||
Settings->endGroup();
|
||||
Settings->beginGroup("Enable");
|
||||
bool flag = Settings->value("User_go_Online",false).toBool();
|
||||
Settings->endGroup();
|
||||
Settings->endGroup();
|
||||
if(!OnlineSound.isEmpty()&&flag)
|
||||
if(QSound::isAvailable())
|
||||
QSound::play(OnlineSound);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue