summaryrefslogtreecommitdiff
path: root/src/commandhandler.cpp
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2011-08-11 21:25:16 +0300
committerAndrei Karas <akaras@inbox.ru>2011-08-11 23:43:48 +0300
commit44e80c70513022b6c378f64d6bf5d25dda7b0e7f (patch)
treeacbdb6be0ba4377d908c017f593832589acb444f /src/commandhandler.cpp
parent69c4bf1494b19ca3b3333effff83086b0f0b87fd (diff)
downloadmv-44e80c70513022b6c378f64d6bf5d25dda7b0e7f.tar.gz
mv-44e80c70513022b6c378f64d6bf5d25dda7b0e7f.tar.bz2
mv-44e80c70513022b6c378f64d6bf5d25dda7b0e7f.tar.xz
mv-44e80c70513022b6c378f64d6bf5d25dda7b0e7f.zip
Fix saving opened tabs state.
Diffstat (limited to 'src/commandhandler.cpp')
-rw-r--r--src/commandhandler.cpp16
1 files changed, 14 insertions, 2 deletions
diff --git a/src/commandhandler.cpp b/src/commandhandler.cpp
index b87dcf583..dc9a4d1bf 100644
--- a/src/commandhandler.cpp
+++ b/src/commandhandler.cpp
@@ -403,8 +403,14 @@ void CommandHandler::handleMsg(const std::string &args, ChatTab *tab)
void CommandHandler::handleQuery(const std::string &args, ChatTab *tab)
{
- if (chatWindow && chatWindow->addWhisperTab(args, true))
- return;
+ if (chatWindow)
+ {
+ if (chatWindow->addWhisperTab(args, true))
+ {
+ chatWindow->saveState();
+ return;
+ }
+ }
tab->chatLog(strprintf(_("Cannot create a whisper tab for nick \"%s\"! "
"It either already exists, or is you."),
@@ -736,14 +742,20 @@ void CommandHandler::handleCloseAll(const std::string &args A_UNUSED,
ChatTab *tab A_UNUSED)
{
if (chatWindow)
+ {
chatWindow->removeAllWhispers();
+ chatWindow->saveState();
+ }
}
void CommandHandler::handleIgnoreAll(const std::string &args A_UNUSED,
ChatTab *tab A_UNUSED)
{
if (chatWindow)
+ {
chatWindow->ignoreAllWhispers();
+ chatWindow->saveState();
+ }
}
void CommandHandler::handleOutfit(const std::string &args,