summaryrefslogtreecommitdiff
path: root/src/gui/setup_other.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/gui/setup_other.cpp')
-rw-r--r--src/gui/setup_other.cpp15
1 files changed, 15 insertions, 0 deletions
diff --git a/src/gui/setup_other.cpp b/src/gui/setup_other.cpp
index 41a6c41ab..e7ddfcef0 100644
--- a/src/gui/setup_other.cpp
+++ b/src/gui/setup_other.cpp
@@ -63,6 +63,7 @@
#define ACTION_AUTO_SHOP "auto shop"
#define ACTION_SHOW_MOB_HP "show mob hp"
#define ACTION_SHOW_OWN_HP "show own hp"
+#define ACTION_SHOW_JOB_EXP "show job exp"
Setup_Other::Setup_Other():
mShowMonstersTakedDamage(config.getBoolValue("showMonstersTakedDamage")),
@@ -88,6 +89,7 @@ Setup_Other::Setup_Other():
mAutoShop(config.getBoolValue("autoShop")),
mShowMobHP(config.getBoolValue("showMobHP")),
mShowOwnHP(config.getBoolValue("showOwnHP")),
+ mShowJobExp(config.getBoolValue("showJobExp")),
mEditDialog(0)
{
setName(_("Misc"));
@@ -183,6 +185,10 @@ Setup_Other::Setup_Other():
mShowOwnHP,
this, ACTION_SHOW_OWN_HP);
+ mShowJobExpCheckBox = new CheckBox(_("Show job exp messages"),
+ mShowJobExp,
+ this, ACTION_SHOW_JOB_EXP);
+
// Do the layout
LayoutHelper h(this);
ContainerPlacer place = h.getPlacer(0, 0);
@@ -198,6 +204,7 @@ Setup_Other::Setup_Other():
place(12, 5, mAutoShopCheckBox, 10);
place(12, 6, mShowMobHPCheckBox, 10);
place(12, 7, mShowOwnHPCheckBox, 10);
+ place(12, 8, mShowJobExpCheckBox, 10);
place(0, 3, mFloorItemsHighlightCheckBox, 12);
place(0, 4, mHighlightAttackRangeCheckBox, 12);
place(0, 5, mHighlightMonsterAttackRangeCheckBox, 12);
@@ -330,6 +337,10 @@ void Setup_Other::action(const gcn::ActionEvent &event)
{
mShowOwnHP = mShowOwnHPCheckBox->isSelected();
}
+ else if (event.getId() == ACTION_SHOW_JOB_EXP)
+ {
+ mShowJobExp = mShowJobExpCheckBox->isSelected();
+ }
}
void Setup_Other::cancel()
@@ -402,6 +413,9 @@ void Setup_Other::cancel()
mShowOwnHP = config.getBoolValue("showOwnHP");
mShowOwnHPCheckBox->setSelected(mShowOwnHP);
+
+ mShowJobExp = config.getBoolValue("showJobExp");
+ mShowJobExpCheckBox->setSelected(mShowJobExp);
}
void Setup_Other::apply()
@@ -429,6 +443,7 @@ void Setup_Other::apply()
config.setValue("autoShop", mAutoShop);
config.setValue("showMobHP", mShowMobHP);
config.setValue("showOwnHP", mShowOwnHP);
+ config.setValue("showJobExp", mShowJobExp);
logger->setDebugLog(mDebugLog);
}