aboutsummaryrefslogtreecommitdiff
path: root/src/gui/guiVolumeChange.cpp
diff options
context:
space:
mode:
authorElias Fleckenstein <eliasfleckenstein@web.de>2020-07-18 13:53:15 +0200
committerElias Fleckenstein <eliasfleckenstein@web.de>2020-07-18 13:53:15 +0200
commitffe3c2ae0db6fed0f2b08b71bfa69f3d3df3bb1f (patch)
treecc7d9f74a43215c5d8e3965a2bfc2aea5867a7a0 /src/gui/guiVolumeChange.cpp
parent45aa2516b2fc675df7049bc9ed713600c95b6423 (diff)
parent82731d0d3d8bfe9e56f89466991f13c037f3a61e (diff)
downloaddragonfireclient-ffe3c2ae0db6fed0f2b08b71bfa69f3d3df3bb1f.tar.xz
Update to minetest 5.4.0-dev
Diffstat (limited to 'src/gui/guiVolumeChange.cpp')
-rw-r--r--src/gui/guiVolumeChange.cpp9
1 files changed, 5 insertions, 4 deletions
diff --git a/src/gui/guiVolumeChange.cpp b/src/gui/guiVolumeChange.cpp
index 9428cde83..f17cfa986 100644
--- a/src/gui/guiVolumeChange.cpp
+++ b/src/gui/guiVolumeChange.cpp
@@ -38,9 +38,10 @@ const int ID_soundMuteButton = 266;
GUIVolumeChange::GUIVolumeChange(gui::IGUIEnvironment* env,
gui::IGUIElement* parent, s32 id,
- IMenuManager *menumgr
+ IMenuManager *menumgr, ISimpleTextureSource *tsrc
):
- GUIModalMenu(env, parent, id, menumgr)
+ GUIModalMenu(env, parent, id, menumgr),
+ m_tsrc(tsrc)
{
}
@@ -104,7 +105,7 @@ void GUIVolumeChange::regenerateGui(v2u32 screensize)
core::rect<s32> rect(0, 0, 80 * s, 30 * s);
rect = rect + v2s32(size.X / 2 - 80 * s / 2, size.Y / 2 + 55 * s);
const wchar_t *text = wgettext("Exit");
- GUIButton::addButton(Environment, rect, this, ID_soundExitButton, text);
+ GUIButton::addButton(Environment, rect, m_tsrc, this, ID_soundExitButton, text);
delete[] text;
}
{
@@ -170,7 +171,7 @@ bool GUIVolumeChange::OnEvent(const SEvent& event)
if (event.GUIEvent.EventType == gui::EGET_ELEMENT_FOCUS_LOST
&& isVisible()) {
if (!canTakeFocus(event.GUIEvent.Element)) {
- dstream << "GUIMainMenu: Not allowing focus change."
+ infostream << "GUIVolumeChange: Not allowing focus change."
<< std::endl;
// Returning true disables focus change
return true;