fbd-dev-sound: Be less verbose on missing sound files
This is quite common so don't fill the logs at normal debug levels but be more specific about what is missing.
This commit is contained in:
+7
-1
@@ -142,7 +142,13 @@ on_sound_play_finished_callback (GSoundContext *ctx,
|
||||
GError *err = NULL;
|
||||
|
||||
if (!gsound_context_play_full_finish (ctx, res, &err)) {
|
||||
g_warning ("Failed to play sound: %s", err->message);
|
||||
if (err->domain == GSOUND_ERROR && err->code == GSOUND_ERROR_NOTFOUND) {
|
||||
g_debug ("Failed to find sound '%s'", fbd_feedback_sound_get_effect (data->feedback));
|
||||
} else {
|
||||
g_warning ("Failed to play sound '%s': %s",
|
||||
fbd_feedback_sound_get_effect (data->feedback),
|
||||
err->message);
|
||||
}
|
||||
}
|
||||
|
||||
(*data->callback)(data->feedback);
|
||||
|
||||
Reference in New Issue
Block a user