After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 782152 - A few minor clean up patches
A few minor clean up patches
Status: RESOLVED FIXED
Product: mutter
Classification: Core
Component: general
unspecified
Other All
: Normal normal
: ---
Assigned To: mutter-maint
mutter-maint
Depends on:
Blocks:
 
 
Reported: 2017-05-04 06:37 UTC by Jonas Ådahl
Modified: 2017-05-24 03:34 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
backend: Move out some code from post_init() (4.56 KB, patch)
2017-05-04 06:37 UTC, Jonas Ådahl
committed Details | Review
input-settings: Minor structural cleanup (8.29 KB, patch)
2017-05-04 06:37 UTC, Jonas Ådahl
committed Details | Review
backend: Couple of whitespace fixes (1.17 KB, patch)
2017-05-04 06:38 UTC, Jonas Ådahl
committed Details | Review

Description Jonas Ådahl 2017-05-04 06:37:36 UTC
Took these fly by clean up patches out of another branch to make that one smaller.
Comment 1 Jonas Ådahl 2017-05-04 06:37:43 UTC
Created attachment 351025 [details] [review]
backend: Move out some code from post_init()

meta_backend_real_post_init() had some open coded initialization with
some unexpected interdependencies. Split these up and move them to their
own functions in order to make meta_backend_real_post_init() a bit more
readable.
Comment 2 Jonas Ådahl 2017-05-04 06:37:57 UTC
Created attachment 351026 [details] [review]
input-settings: Minor structural cleanup

Let the backend implementations create their own input settings
backend, as is done with other backend specific special purpose
backends. Also use the macro for declaring the GType.
Comment 3 Jonas Ådahl 2017-05-04 06:38:10 UTC
Created attachment 351027 [details] [review]
backend: Couple of whitespace fixes
Comment 4 Carlos Garnacho 2017-05-23 14:12:51 UTC
Comment on attachment 351025 [details] [review]
backend: Move out some code from post_init()

Looks good!
Comment 5 Carlos Garnacho 2017-05-23 14:17:23 UTC
Review of attachment 351026 [details] [review]:

Makes sense indeed. Just one nit.

::: src/backends/x11/meta-backend-x11.c
@@ +456,3 @@
+meta_backend_x11_create_input_settings (MetaBackend *backend)
+{
+  return g_object_new (META_TYPE_INPUT_SETTINGS_X11, NULL);

The older code didn't create a MetaInputSettings in the case running a nested compositor. We probably should be doing the same, as the nested compositor does not "own" the XI2 device properties.
Comment 6 Carlos Garnacho 2017-05-23 14:18:02 UTC
Comment on attachment 351027 [details] [review]
backend: Couple of whitespace fixes

LGTM
Comment 7 Jonas Ådahl 2017-05-24 02:31:36 UTC
(In reply to Carlos Garnacho from comment #5)
> Review of attachment 351026 [details] [review] [review]:
> 
> Makes sense indeed. Just one nit.
> 
> ::: src/backends/x11/meta-backend-x11.c
> @@ +456,3 @@
> +meta_backend_x11_create_input_settings (MetaBackend *backend)
> +{
> +  return g_object_new (META_TYPE_INPUT_SETTINGS_X11, NULL);
> 
> The older code didn't create a MetaInputSettings in the case running a
> nested compositor. We probably should be doing the same, as the nested
> compositor does not "own" the XI2 device properties.

True. I'll move it to the CM X11 backend.
Comment 8 Jonas Ådahl 2017-05-24 03:33:57 UTC
Attachment 351025 [details] pushed as 755755a - backend: Move out some code from post_init()
Attachment 351026 [details] pushed as 81e99c2 - input-settings: Minor structural cleanup
Attachment 351027 [details] pushed as efc1907 - backend: Couple of whitespace fixes