summaryrefslogtreecommitdiff
path: root/dash
diff options
authorMarco Trevisan (Treviño) <mail@3v1n0.net>2013-10-21 21:14:44 +0200
committerMarco Trevisan (Treviño) <mail@3v1n0.net>2013-10-21 21:14:44 +0200
commit33f78b121aefa626c984677575da5f6415acf97e (patch)
treed0baefd72c6e6228b2140bd7eb7f03b1773ac33e /dash
parent66ece3cd310c368aaf9bb9afbf427d67b587d4e7 (diff)
DashController: check for invalid (null) keybindings
(bzr r3566.4.27)
Diffstat (limited to 'dash')
-rw-r--r--dash/DashController.cpp7
1 files changed, 5 insertions, 2 deletions
diff --git a/dash/DashController.cpp b/dash/DashController.cpp
index 2cbad4206..59f4d3616 100644
--- a/dash/DashController.cpp
+++ b/dash/DashController.cpp
@@ -387,9 +387,12 @@ void Controller::OnActivateRequest(GVariant* variant)
gboolean Controller::CheckShortcutActivation(const char* key_string)
{
+ if (!key_string)
+ return false;
+
EnsureDash();
- std::string scope_id = view_->GetIdForShortcutActivation(std::string(key_string));
- if (scope_id != "")
+ std::string scope_id = view_->GetIdForShortcutActivation(key_string);
+ if (!scope_id.empty())
{
WindowManager& wm = WindowManager::Default();
if (wm.IsScaleActive())