summaryrefslogtreecommitdiff
path: root/src/gui/windows
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2016-08-14 03:01:07 +0300
committerAndrei Karas <akaras@inbox.ru>2016-08-14 03:01:07 +0300
commitf3781554bf946a22ac307d1c8fe6154db05bbf2e (patch)
tree30bae5fdc65a5a1cf6eecb552f6380712fcf900f /src/gui/windows
parent12398ad6f56888be71e4575d90442b2172f9876d (diff)
downloadplus-f3781554bf946a22ac307d1c8fe6154db05bbf2e.tar.gz
plus-f3781554bf946a22ac307d1c8fe6154db05bbf2e.tar.bz2
plus-f3781554bf946a22ac307d1c8fe6154db05bbf2e.tar.xz
plus-f3781554bf946a22ac307d1c8fe6154db05bbf2e.zip
Add ability to load/save additional data for each shortcut in shortcuts window.
Diffstat (limited to 'src/gui/windows')
-rw-r--r--src/gui/windows/skilldialog.cpp13
-rw-r--r--src/gui/windows/skilldialog.h3
2 files changed, 12 insertions, 4 deletions
diff --git a/src/gui/windows/skilldialog.cpp b/src/gui/windows/skilldialog.cpp
index eed99542c..66ffb6378 100644
--- a/src/gui/windows/skilldialog.cpp
+++ b/src/gui/windows/skilldialog.cpp
@@ -615,7 +615,8 @@ void SkillDialog::widgetResized(const Event &event)
void SkillDialog::useItem(const int itemId,
const AutoTarget autoTarget,
- const int level) const
+ const int level,
+ const std::string &data) const
{
const std::map<int, SkillInfo*>::const_iterator
it = mSkills.find(itemId - SKILL_MIN_ID);
@@ -623,8 +624,14 @@ void SkillDialog::useItem(const int itemId,
return;
const SkillInfo *const info = (*it).second;
- // +++ need add skill level here
- useSkill(info, autoTarget, level);
+ if (data.empty())
+ {
+ useSkill(info, autoTarget, level);
+ }
+ else if (data.size() > 1)
+ {
+
+ }
}
void SkillDialog::updateTabSelection()
diff --git a/src/gui/windows/skilldialog.h b/src/gui/windows/skilldialog.h
index 5e53c7362..f12f9621b 100644
--- a/src/gui/windows/skilldialog.h
+++ b/src/gui/windows/skilldialog.h
@@ -117,7 +117,8 @@ class SkillDialog final : public Window,
void useItem(const int itemId,
const AutoTarget autoTarget,
- const int level) const;
+ const int level,
+ const std::string &data) const;
void updateTabSelection();