[Wayland-bugs] [Bug 744932] Wrong (ultra tiny/small) cursor size on HiDPI screen
mutter (GNOME Bugzilla)
bugzilla at gnome.org
Fri Apr 10 14:54:36 PDT 2015
https://bugzilla.gnome.org/show_bug.cgi?id=744932
Owen Taylor <otaylor at redhat.com> changed:
What |Removed |Added
----------------------------------------------------------------------------
Attachment #299282|none |needs-work
status| |
--- Comment #30 from Owen Taylor <otaylor at redhat.com> ---
Review of attachment 299282:
If the point of the refactoring is to get to a clean design, there are elements
of this patch that feel off to me
::: src/frontends/meta-cursor.c
@@ +156,2 @@
MetaCursorSprite *
+meta_cursor_sprite_new (void)
meta_foo_new() should create a MetaFoo, not a MetaFoo or a subclass. This is
something like meta_create_cursor_sprite().
@@ +160,3 @@
+ return g_object_new (META_TYPE_CURSOR_SPRITE_WAYLAND, NULL);
+ else
+ return g_object_new (META_TYPE_CURSOR_SPRITE, NULL);
Hmm, I think this reflects confusion whether MetaCursorSprite is a frontend or
a backend object. If it's genuinely a "frontend" object, then when creating it
we should always know what protocol we are creating it for. And
meta_cursor_sprite_from_theme() would be a third subclass independent of the
backend.
Obviously every transformation of frontend to backend isn't going to be
possible - e.g., creating an X cursor for a Wayland surface - but I don't think
that's a big problem - you just need to have the code somewhere that knows what
can be transformed to what.
::: src/frontends/wayland/meta-cursor-wayland.c
@@ +66,3 @@
+ MetaCursorSpriteWayland *self;
+
+ self = META_CURSOR_SPRITE_WAYLAND (meta_cursor_sprite_new ());
This doesn't make sense to me - this *has* to be a MetaCursorSpriteWayland, so
just create one.
--
You are receiving this mail because:
You are on the CC list for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freedesktop.org/archives/wayland-bugs/attachments/20150410/e2e41d45/attachment.html>
More information about the wayland-bugs
mailing list