mirror of
https://github.com/wesnoth/wesnoth
synced 2025-05-21 21:05:52 +00:00
add tooltips to disabled copy buttons, if no clipboard support
This commit is contained in:
parent
5cafdf979a
commit
b95c16f506
@ -389,6 +389,7 @@ void taddon_description::pre_show(CVideo& /*video*/, twindow& window)
|
||||
|
||||
if (!desktop::clipboard::available()) {
|
||||
url_copy_button.set_active(false);
|
||||
url_copy_button.set_tooltip(_("Clipboard support not found, contact your packager."));
|
||||
}
|
||||
} else {
|
||||
url_go_button.set_active(false);
|
||||
|
@ -36,6 +36,7 @@
|
||||
#include "../../resources.hpp"
|
||||
#include "../../team.hpp"
|
||||
#include "../../replay.hpp"
|
||||
#include "gettext.hpp"
|
||||
|
||||
#include <vector>
|
||||
#include <boost/bind.hpp>
|
||||
@ -412,6 +413,7 @@ public:
|
||||
boost::ref(window)));
|
||||
if (!desktop::clipboard::available()) {
|
||||
model_.copy_button->set_active(false);
|
||||
model_.copy_button->set_tooltip(_("Clipboard support not found, contact your packager."));
|
||||
}
|
||||
|
||||
model_.page_label = &find_widget<tcontrol>(&window, "page_label", false);
|
||||
|
@ -94,6 +94,7 @@ void tgame_cache_options::pre_show(CVideo& video, twindow& window)
|
||||
this));
|
||||
if (!desktop::clipboard::available()) {
|
||||
copy.set_active(false);
|
||||
copy.set_tooltip(_("Clipboard support not found, contact your packager."));
|
||||
}
|
||||
|
||||
tbutton& browse = find_widget<tbutton>(&window, "browse", false);
|
||||
|
@ -28,6 +28,8 @@
|
||||
#include "gui/widgets/window.hpp"
|
||||
#include "serialization/string_utils.hpp"
|
||||
|
||||
#include "gettext.hpp"
|
||||
|
||||
#include <boost/bind.hpp>
|
||||
|
||||
namespace gui2
|
||||
@ -114,6 +116,7 @@ void tgame_paths::pre_show(CVideo& /*video*/, twindow& window)
|
||||
|
||||
if(!desktop::clipboard::available()) {
|
||||
copy_w.set_active(false);
|
||||
copy_w.set_tooltip(_("Clipboard support not found, contact your packager."));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -690,6 +690,7 @@ public:
|
||||
boost::ref(window)));
|
||||
if (!desktop::clipboard::available()) {
|
||||
model_.copy_button->set_active(false);
|
||||
model_.copy_button->set_tooltip(_("Clipboard support not found, contact your packager."));
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -85,6 +85,7 @@ void tscreenshot_notification::pre_show(CVideo& /*video*/, twindow& window)
|
||||
|
||||
if (!desktop::clipboard::available()) {
|
||||
copy_b.set_active(false);
|
||||
copy_b.set_tooltip(_("Clipboard support not found, contact your packager."));
|
||||
}
|
||||
|
||||
tbutton& open_b = find_widget<tbutton>(&window, "open", false);
|
||||
|
@ -20,7 +20,6 @@
|
||||
#include "addon/manager.hpp"
|
||||
#include "desktop/clipboard.hpp"
|
||||
#include "filesystem.hpp"
|
||||
#include "gettext.hpp"
|
||||
#include "gui/auxiliary/find_widget.tpp"
|
||||
#include "gui/widgets/button.hpp"
|
||||
#include "gui/widgets/control.hpp"
|
||||
@ -28,6 +27,8 @@
|
||||
#include "gui/widgets/window.hpp"
|
||||
#include "serialization/string_utils.hpp"
|
||||
|
||||
#include "gettext.hpp"
|
||||
|
||||
#include <boost/bind.hpp>
|
||||
|
||||
namespace
|
||||
@ -220,6 +221,7 @@ void twml_error::pre_show(CVideo& /*video*/, twindow& window)
|
||||
|
||||
if (!desktop::clipboard::available()) {
|
||||
copy_button.set_active(false);
|
||||
copy_button.set_tooltip(_("Clipboard support not found, contact your packager."));
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user