diff options
author | Andrei Karas <akaras@inbox.ru> | 2016-08-14 03:01:07 +0300 |
---|---|---|
committer | Andrei Karas <akaras@inbox.ru> | 2016-08-14 03:01:07 +0300 |
commit | f3781554bf946a22ac307d1c8fe6154db05bbf2e (patch) | |
tree | 30bae5fdc65a5a1cf6eecb552f6380712fcf900f /src/gui/windows/skilldialog.cpp | |
parent | 12398ad6f56888be71e4575d90442b2172f9876d (diff) | |
download | manaplus-f3781554bf946a22ac307d1c8fe6154db05bbf2e.tar.gz manaplus-f3781554bf946a22ac307d1c8fe6154db05bbf2e.tar.bz2 manaplus-f3781554bf946a22ac307d1c8fe6154db05bbf2e.tar.xz manaplus-f3781554bf946a22ac307d1c8fe6154db05bbf2e.zip |
Add ability to load/save additional data for each shortcut in shortcuts window.
Diffstat (limited to 'src/gui/windows/skilldialog.cpp')
-rw-r--r-- | src/gui/windows/skilldialog.cpp | 13 |
1 files changed, 10 insertions, 3 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() |