[mutter] input-mapper: Remove unnecessary return value
- From: Georges Basile Stavracas Neto <gbsneto src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [mutter] input-mapper: Remove unnecessary return value
- Date: Tue, 28 May 2019 14:44:43 +0000 (UTC)
commit 033ce2d9560c7c606cedf196382620585be98b23
Author: Florian Müllner <fmuellner gnome org>
Date: Mon May 27 19:59:53 2019 +0000
input-mapper: Remove unnecessary return value
Since commit ae6d9e35bd, there is a fallback to META_MATCH_IS_BUILTIN,
so the condition for returning FALSE is never met.
https://gitlab.gnome.org/GNOME/mutter/merge_requests/598
src/backends/meta-input-mapper.c | 15 +++------------
1 file changed, 3 insertions(+), 12 deletions(-)
---
diff --git a/src/backends/meta-input-mapper.c b/src/backends/meta-input-mapper.c
index acc9b1618..fc4f3bd59 100644
--- a/src/backends/meta-input-mapper.c
+++ b/src/backends/meta-input-mapper.c
@@ -353,7 +353,7 @@ find_builtin_output (MetaInputMapper *mapper,
return panel != NULL;
}
-static gboolean
+static void
guess_candidates (MetaInputMapper *mapper,
MetaMapperInputInfo *input,
DeviceCandidates *info)
@@ -387,15 +387,7 @@ guess_candidates (MetaInputMapper *mapper,
find_builtin_output (mapper, &info->candidates[META_MATCH_IS_BUILTIN]);
}
- if (best < N_OUTPUT_MATCHES)
- {
- info->best = best;
- return TRUE;
- }
- else
- {
- return FALSE;
- }
+ info->best = best;
}
static void
@@ -408,8 +400,7 @@ mapping_helper_add (MappingHelper *helper,
info.input = input;
- if (!guess_candidates (mapper, input, &info))
- return;
+ guess_candidates (mapper, input, &info);
for (i = 0; i < helper->device_maps->len; i++)
{
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]