backends: Add argument for best scale on MetaCursorSprite::prepare-at
Instead of letting implementations poke backend internals from various places, give that information right away. Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/1403>
This commit is contained in:

committed by
Marge Bot

parent
7a2a2445c3
commit
e721fde259
@ -179,11 +179,12 @@ meta_cursor_sprite_get_texture_transform (MetaCursorSprite *sprite)
|
||||
}
|
||||
|
||||
void
|
||||
meta_cursor_sprite_prepare_at (MetaCursorSprite *sprite,
|
||||
int x,
|
||||
int y)
|
||||
meta_cursor_sprite_prepare_at (MetaCursorSprite *sprite,
|
||||
float best_scale,
|
||||
int x,
|
||||
int y)
|
||||
{
|
||||
g_signal_emit (sprite, signals[PREPARE_AT], 0, x, y);
|
||||
g_signal_emit (sprite, signals[PREPARE_AT], 0, best_scale, x, y);
|
||||
}
|
||||
|
||||
void
|
||||
@ -226,7 +227,8 @@ meta_cursor_sprite_class_init (MetaCursorSpriteClass *klass)
|
||||
G_SIGNAL_RUN_LAST,
|
||||
0,
|
||||
NULL, NULL, NULL,
|
||||
G_TYPE_NONE, 2,
|
||||
G_TYPE_NONE, 3,
|
||||
G_TYPE_FLOAT,
|
||||
G_TYPE_INT,
|
||||
G_TYPE_INT);
|
||||
signals[TEXTURE_CHANGED] = g_signal_new ("texture-changed",
|
||||
|
Reference in New Issue
Block a user