summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/gui/widgets/setupbuttonitem.cpp4
-rw-r--r--src/gui/widgets/setupbuttonitem.h1
-rw-r--r--src/gui/widgets/setupitem.cpp12
-rw-r--r--src/gui/widgets/setuptouchitem.cpp1
-rw-r--r--src/gui/widgets/tabs/setup_other.cpp2
5 files changed, 12 insertions, 8 deletions
diff --git a/src/gui/widgets/setupbuttonitem.cpp b/src/gui/widgets/setupbuttonitem.cpp
index 7551adaf6..4875355ff 100644
--- a/src/gui/widgets/setupbuttonitem.cpp
+++ b/src/gui/widgets/setupbuttonitem.cpp
@@ -29,11 +29,12 @@
#include "debug.h"
SetupButtonItem::SetupButtonItem(const std::string &restrict text,
+ const std::string &restrict description,
const std::string &restrict actionEventId,
SetupTabScroll *restrict const parent,
const std::string &restrict eventName,
ActionListener *const listener) :
- SetupItem(text, "", "", parent, eventName, false),
+ SetupItem(text, description, "", parent, eventName, false),
mHorizont(nullptr),
mButton(nullptr)
{
@@ -68,6 +69,7 @@ void SetupButtonItem::rereadValue()
void SetupButtonItem::createControls()
{
mHorizont = new HorizontContainer(this, 32, 2);
+ mHorizont->setToolTip(mDescription);
// TRANSLATORS: setup item button
mHorizont->add(mWidget);
diff --git a/src/gui/widgets/setupbuttonitem.h b/src/gui/widgets/setupbuttonitem.h
index 0909f4056..53da7c853 100644
--- a/src/gui/widgets/setupbuttonitem.h
+++ b/src/gui/widgets/setupbuttonitem.h
@@ -31,6 +31,7 @@ class SetupButtonItem final : public SetupItem
{
public:
SetupButtonItem(const std::string &restrict text,
+ const std::string &restrict description,
const std::string &restrict actionEventId,
SetupTabScroll *restrict const parent,
const std::string &restrict eventName,
diff --git a/src/gui/widgets/setupitem.cpp b/src/gui/widgets/setupitem.cpp
index 04f818451..a8bded351 100644
--- a/src/gui/widgets/setupitem.cpp
+++ b/src/gui/widgets/setupitem.cpp
@@ -360,9 +360,9 @@ void SetupItemTextField::createControls()
if (mUseBase64)
mValue = decodeBase64String(mValue);
mHorizont = new HorizontContainer(this, 32, 2);
+ mHorizont->setToolTip(mDescription);
mLabel = new Label(this, mText);
- mLabel->setToolTip(mDescription);
mTextField = new TextField(this, mValue, true, mParent, mEventName);
// TRANSLATORS: setup item button
mButton = new Button(this, _("Edit"), mEventName + "_EDIT", mParent);
@@ -493,9 +493,9 @@ void SetupItemIntTextField::createControls()
{
load();
mHorizont = new HorizontContainer(this, 32, 2);
+ mHorizont->setToolTip(mDescription);
mLabel = new Label(this, mText);
- mLabel->setToolTip(mDescription);
mTextField = new IntTextField(this, atoi(mValue.c_str()),
mMin, mMax, true, 30);
mTextField->setActionEventId(mEventName);
@@ -677,9 +677,9 @@ void SetupItemDropDown::createControls()
{
load();
mHorizont = new HorizontContainer(this, 32, 2);
+ mHorizont->setToolTip(mDescription);
mLabel = new Label(this, mText);
- mLabel->setToolTip(mDescription);
mDropDown = new DropDown(this, mModel);
mDropDown->setActionEventId(mEventName);
mDropDown->addActionListener(mParent);
@@ -777,9 +777,9 @@ void SetupItemSlider::createControls()
{
load();
mHorizont = new HorizontContainer(this, 32, 2);
+ mHorizont->setToolTip(mDescription);
mLabel = new Label(this, mText);
- mLabel->setToolTip(mDescription);
mSlider = new Slider(this, mMin, mMax, mStep);
mSlider->setActionEventId(mEventName);
mSlider->addActionListener(mParent);
@@ -905,11 +905,11 @@ void SetupItemSlider2::createControls()
{
load();
mHorizont = new HorizontContainer(this, 32, 2);
+ mHorizont->setToolTip(mDescription);
const int width = getMaxWidth();
mLabel = new Label(this, mText);
- mLabel->setToolTip(mDescription);
mLabel2 = new Label(this, "");
mLabel2->setWidth(width);
mSlider = new Slider(this, mMin, mMax, mStep);
@@ -1074,9 +1074,9 @@ void SetupItemSliderList::createControls()
{
load();
mHorizont = new HorizontContainer(this, 32, 2);
+ mHorizont->setToolTip(mDescription);
mLabel = new Label(this, mText);
- mLabel->setToolTip(mDescription);
mSlider = new SliderList(this, mModel);
mSlider->postInit(mParent, mEventName);
mSlider->setSelectedString(mValue);
diff --git a/src/gui/widgets/setuptouchitem.cpp b/src/gui/widgets/setuptouchitem.cpp
index 3c8238fd0..73228bad6 100644
--- a/src/gui/widgets/setuptouchitem.cpp
+++ b/src/gui/widgets/setuptouchitem.cpp
@@ -92,6 +92,7 @@ void SetupActionDropDown::createControls()
load();
mHorizont = new HorizontContainer(this, 32, 2);
+ mHorizont->setToolTip(mDescription);
mLabel = new Label(this, mText);
mDropDown = new DropDown(this, mModel);
diff --git a/src/gui/widgets/tabs/setup_other.cpp b/src/gui/widgets/tabs/setup_other.cpp
index 0b8bc6448..6e350ea7c 100644
--- a/src/gui/widgets/tabs/setup_other.cpp
+++ b/src/gui/widgets/tabs/setup_other.cpp
@@ -374,7 +374,7 @@ Setup_Other::Setup_Other(const Widget2 *const widget) :
"logInput", this, "logInputEvent");
// TRANSLATORS: settings option
- new SetupButtonItem(_("Upload log file"), "upload",
+ new SetupButtonItem(_("Upload log file"), "", "upload",
this, "uploadLog", &uploadListener);
// TRANSLATORS: settings option