diff --git a/data/org.sigxcpu.feedbackd.gschema.xml b/data/org.sigxcpu.feedbackd.gschema.xml
index 84615e0..857144d 100644
--- a/data/org.sigxcpu.feedbackd.gschema.xml
+++ b/data/org.sigxcpu.feedbackd.gschema.xml
@@ -39,7 +39,7 @@
'sm.puri.OSK0']
List of apps that can override the feedback level
- Apps listed here can override the configured feedack level by
+ Apps listed here can override the configured global feedback level by
setting the 'important' hint on the submitted event.
diff --git a/doc/feedbackd.rst b/doc/feedbackd.rst
index 005a09a..a44f648 100644
--- a/doc/feedbackd.rst
+++ b/doc/feedbackd.rst
@@ -51,8 +51,8 @@ These gsettings are used by ``feedbackd``:
- `profile`: The current overall feedback profile. Valid values are
`full`, `quiet` and `silent`.
- - `allow-important`: List of apps that can override the feedback level
- (useful for e.g. allowing the alarm clock to also emit sound when
+ - `allow-important`: List of apps that can override the global feedback
+ level (useful for e.g. allowing the alarm clock to also emit sound when
device is in silent mode).
- `prefer-flash`: Prefer camera flash over status LED
- `theme`: The feedback theme to use. This can be used to override
diff --git a/libfeedback/lfb-event.c b/libfeedback/lfb-event.c
index 21eeda3..3057cdb 100644
--- a/libfeedback/lfb-event.c
+++ b/libfeedback/lfb-event.c
@@ -687,7 +687,7 @@ lfb_event_end_feedback_async (LfbEvent *self,
* @self: The event
* @timeout: The timeout
*
- * Tells the feedback server to end feedack after #timeout seconds.
+ * Tells the feedback server to end feedback after #timeout seconds.
* The value -1 indicates to not set a timeout and let feedbacks stop
* on their own while 0 indicates to loop all feedbacks endlessly.
* They must be stopped via [method@LfbEvent.end_feedback] in this case.
@@ -817,7 +817,7 @@ lfb_event_get_feedback_profile (LfbEvent *self)
*
* Tells the feedback server that the sender deems this to be an
* important event. A feedback server might allow the sender to
- * override the current feedback level when this is set.
+ * override the current global feedback level when this is set.
*/
void
lfb_event_set_important (LfbEvent *self, gboolean important)
diff --git a/src/fbd-feedback-manager.c b/src/fbd-feedback-manager.c
index 5b1e34c..bc12a4e 100644
--- a/src/fbd-feedback-manager.c
+++ b/src/fbd-feedback-manager.c
@@ -371,7 +371,7 @@ parse_hints (GVariant *hints,
/**
* add_event_feedbacks:
*
- * Add the suitable feedacks to the event.
+ * Add the suitable feedbacks to the event.
*
* Returns: `TRUE` if at least on feedback was added.
*/
@@ -758,10 +758,11 @@ fbd_feedback_manager_get_effective_level (FbdFeedbackManager *self,
app_level = app_get_feedback_level (app_id);
can_important = app_is_important (self, app_id);
- if (important && can_important)
- level = want_level;
- else
+ if (important && can_important) {
+ level = MIN (want_level, app_level);
+ } else {
level = get_max_level (self->level, app_level, want_level);
+ }
return level;
}