summaryrefslogtreecommitdiff
path: root/plugins/media-keys
diff options
context:
space:
mode:
authorStefan Tauner <[email protected]>2012-05-03 15:27:26 +0200
committerStefan Tauner <[email protected]>2012-05-03 15:27:26 +0200
commit559fc8f95855dfe81dbafe9d3587b63cdec7b9dc (patch)
treeacecea403f07d43e416f4224ba986d7969cc378b /plugins/media-keys
parent2275e121531db04c158811cc06b04a63b6d05979 (diff)
downloadmate-settings-daemon-559fc8f95855dfe81dbafe9d3587b63cdec7b9dc.tar.bz2
mate-settings-daemon-559fc8f95855dfe81dbafe9d3587b63cdec7b9dc.tar.xz
media-keys: fix the "calculator key"
try to find mate-calc, fall back to gcalctool if it is not found. Signed-off-by: Stefan Tauner <[email protected]>
Diffstat (limited to 'plugins/media-keys')
-rw-r--r--plugins/media-keys/msd-media-keys-manager.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/plugins/media-keys/msd-media-keys-manager.c b/plugins/media-keys/msd-media-keys-manager.c
index e7310c6..1ace064 100644
--- a/plugins/media-keys/msd-media-keys-manager.c
+++ b/plugins/media-keys/msd-media-keys-manager.c
@@ -1050,7 +1050,13 @@ do_action (MsdMediaKeysManager *manager,
do_media_action (manager);
break;
case CALCULATOR_KEY:
- execute (manager, "gcalctool", FALSE, FALSE);
+ if ((cmd = g_find_program_in_path ("mate-calc"))) {
+ execute (manager, "mate-calc", FALSE, FALSE);
+ } else {
+ execute (manager, "gcalctool", FALSE, FALSE);
+ }
+
+ g_free (cmd);
break;
case PLAY_KEY:
return do_multimedia_player_action (manager, "Play");