summaryrefslogtreecommitdiff
path: root/src/gui/widgets
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2012-03-29 03:51:37 +0300
committerAndrei Karas <akaras@inbox.ru>2012-03-29 03:52:16 +0300
commit3bf4e26b1319295532bb4396cbd6406d85cbcae0 (patch)
tree80a4303b29aafa21683e90e45798283a482bf1d1 /src/gui/widgets
parent7f607a0f58a9eba53237955c06bf445c71d57b6c (diff)
downloadmanaverse-3bf4e26b1319295532bb4396cbd6406d85cbcae0.tar.gz
manaverse-3bf4e26b1319295532bb4396cbd6406d85cbcae0.tar.bz2
manaverse-3bf4e26b1319295532bb4396cbd6406d85cbcae0.tar.xz
manaverse-3bf4e26b1319295532bb4396cbd6406d85cbcae0.zip
Replace vectors with strings to short names.
Diffstat (limited to 'src/gui/widgets')
-rw-r--r--src/gui/widgets/chattab.h4
-rw-r--r--src/gui/widgets/guildchattab.cpp2
-rw-r--r--src/gui/widgets/guildchattab.h2
-rw-r--r--src/gui/widgets/namesmodel.h8
-rw-r--r--src/gui/widgets/whispertab.cpp2
-rw-r--r--src/gui/widgets/whispertab.h2
6 files changed, 10 insertions, 10 deletions
diff --git a/src/gui/widgets/chattab.h b/src/gui/widgets/chattab.h
index d67f56b54..d11a85138 100644
--- a/src/gui/widgets/chattab.h
+++ b/src/gui/widgets/chattab.h
@@ -28,6 +28,8 @@
#include "gui/widgets/browserbox.h"
#include "gui/widgets/tab.h"
+#include "utils/stringvector.h"
+
#include "localconsts.h"
class ScrollArea;
@@ -175,7 +177,7 @@ class ChatTab : public Tab
virtual void handleCommand(const std::string &msg);
- virtual void getAutoCompleteList(std::vector<std::string>&) const
+ virtual void getAutoCompleteList(StringVect&) const
{}
void addRow(std::string &line);
diff --git a/src/gui/widgets/guildchattab.cpp b/src/gui/widgets/guildchattab.cpp
index bad34cfb3..9fed16e92 100644
--- a/src/gui/widgets/guildchattab.cpp
+++ b/src/gui/widgets/guildchattab.cpp
@@ -113,7 +113,7 @@ void GuildChatTab::showHelp()
chatLog(_("/kick > Kick some one from the guild you are in"));
}
-void GuildChatTab::getAutoCompleteList(std::vector<std::string> &names) const
+void GuildChatTab::getAutoCompleteList(StringVect &names) const
{
if (!guildManager)
return;
diff --git a/src/gui/widgets/guildchattab.h b/src/gui/widgets/guildchattab.h
index e729844f4..358c1f1d4 100644
--- a/src/gui/widgets/guildchattab.h
+++ b/src/gui/widgets/guildchattab.h
@@ -49,7 +49,7 @@ class GuildChatTab : public ChatTab
protected:
void handleInput(const std::string &msg);
- void getAutoCompleteList(std::vector<std::string> &names) const;
+ void getAutoCompleteList(StringVect &names) const;
};
#endif
diff --git a/src/gui/widgets/namesmodel.h b/src/gui/widgets/namesmodel.h
index dc694fc46..e1dbf0a89 100644
--- a/src/gui/widgets/namesmodel.h
+++ b/src/gui/widgets/namesmodel.h
@@ -21,12 +21,10 @@
#ifndef GUI_WIDGETS_NAMESMODEL_H
#define GUI_WIDGETS_NAMESMODEL_H
-//#include "guichanfwd.h"
+#include "utils/stringvector.h"
#include <guichan/listmodel.hpp>
-#include <vector>
-
class NamesModel : public gcn::ListModel
{
public:
@@ -38,14 +36,14 @@ class NamesModel : public gcn::ListModel
virtual std::string getElementAt(int i);
- std::vector<std::string> &getNames()
+ StringVect &getNames()
{ return mNames; }
size_t size()
{ return mNames.size(); }
protected:
- std::vector<std::string> mNames;
+ StringVect mNames;
};
#endif
diff --git a/src/gui/widgets/whispertab.cpp b/src/gui/widgets/whispertab.cpp
index 625c8a392..007002e21 100644
--- a/src/gui/widgets/whispertab.cpp
+++ b/src/gui/widgets/whispertab.cpp
@@ -166,7 +166,7 @@ void WhisperTab::saveToLogFile(std::string &msg)
chatLogger->log(getNick(), msg);
}
-void WhisperTab::getAutoCompleteList(std::vector<std::string> &names) const
+void WhisperTab::getAutoCompleteList(StringVect &names) const
{
names.push_back(mNick);
}
diff --git a/src/gui/widgets/whispertab.h b/src/gui/widgets/whispertab.h
index 72d407ac2..226ebaf40 100644
--- a/src/gui/widgets/whispertab.h
+++ b/src/gui/widgets/whispertab.h
@@ -46,7 +46,7 @@ class WhisperTab : public ChatTab
void saveToLogFile(std::string &msg);
- void getAutoCompleteList(std::vector<std::string> &names) const;
+ void getAutoCompleteList(StringVect &names) const;
protected:
friend class ChatWindow;