From fed29d9ddc3b8372b9c3fe8bffe221a5a55e5ce9 Mon Sep 17 00:00:00 2001 From: Stijn Buys Date: Tue, 5 Oct 2010 14:38:14 +0000 Subject: updated inventory window, listview seletion sounds, modelview zoom factor --- src/ui/button.cc | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'src/ui/button.cc') diff --git a/src/ui/button.cc b/src/ui/button.cc index ddcc72d..6cbb51e 100644 --- a/src/ui/button.cc +++ b/src/ui/button.cc @@ -85,7 +85,9 @@ bool Button::on_keypress(const int key, const unsigned int modifier) { if (key == 512 + SDL_BUTTON_LEFT) { if (enabled()) { - core::cmd() << button_command << std::endl; + if (button_command.size()) { + core::cmd() << button_command << std::endl; + } audio::play("ui/button"); emit(EventButtonClicked); -- cgit v1.2.3