mirror of
https://gitlab.uni-freiburg.de/opensourcevdi/spice
synced 2026-08-06 21:12:12 +00:00
reds: use SpiceMouseMode for RedsState::mouse_mode
Make easier to understant the value to use in the code. Signed-off-by: Frediano Ziglio <fziglio@redhat.com> Acked-by: Jonathon Jongsma <jjongsma@redhat.com>
This commit is contained in:
parent
930a1196e3
commit
1026a89b78
@ -110,7 +110,7 @@ typedef struct RedNotifyPipeItem {
|
||||
|
||||
typedef struct RedMouseModePipeItem {
|
||||
RedPipeItem base;
|
||||
int current_mode;
|
||||
SpiceMouseMode current_mode;
|
||||
int is_client_mouse_allowed;
|
||||
} RedMouseModePipeItem;
|
||||
|
||||
@ -331,7 +331,7 @@ void main_channel_client_push_agent_data(MainChannelClient *mcc, uint8_t* data,
|
||||
|
||||
static RedPipeItem *main_init_item_new(int connection_id,
|
||||
int display_channels_hint,
|
||||
int current_mouse_mode,
|
||||
SpiceMouseMode current_mouse_mode,
|
||||
int is_client_mouse_allowed,
|
||||
int multi_media_time,
|
||||
int ram_hint)
|
||||
@ -350,7 +350,7 @@ static RedPipeItem *main_init_item_new(int connection_id,
|
||||
|
||||
void main_channel_client_push_init(MainChannelClient *mcc,
|
||||
int display_channels_hint,
|
||||
int current_mouse_mode,
|
||||
SpiceMouseMode current_mouse_mode,
|
||||
int is_client_mouse_allowed,
|
||||
int multi_media_time,
|
||||
int ram_hint)
|
||||
|
||||
@ -69,7 +69,7 @@ void main_channel_client_start_net_test(MainChannelClient *mcc, int test_rate);
|
||||
// and calling from main.
|
||||
void main_channel_client_push_init(MainChannelClient *mcc,
|
||||
int display_channels_hint,
|
||||
int current_mouse_mode,
|
||||
SpiceMouseMode current_mouse_mode,
|
||||
int is_client_mouse_allowed,
|
||||
int multi_media_time,
|
||||
int ram_hint);
|
||||
@ -125,7 +125,7 @@ enum {
|
||||
};
|
||||
|
||||
typedef struct MainMouseModeItemInfo {
|
||||
int current_mode;
|
||||
SpiceMouseMode current_mode;
|
||||
int is_client_mouse_allowed;
|
||||
} MainMouseModeItemInfo;
|
||||
|
||||
|
||||
@ -84,7 +84,7 @@ static void main_channel_push_channels(MainChannelClient *mcc)
|
||||
red_channel_client_pipe_add_type(rcc, RED_PIPE_ITEM_TYPE_MAIN_CHANNELS_LIST);
|
||||
}
|
||||
|
||||
void main_channel_push_mouse_mode(MainChannel *main_chan, int current_mode,
|
||||
void main_channel_push_mouse_mode(MainChannel *main_chan, SpiceMouseMode current_mode,
|
||||
int is_client_mouse_allowed)
|
||||
{
|
||||
MainMouseModeItemInfo info = {
|
||||
|
||||
@ -61,7 +61,8 @@ RedClient *main_channel_get_client_by_link_id(MainChannel *main_chan, uint32_t l
|
||||
MainChannelClient *main_channel_link(MainChannel *, RedClient *client,
|
||||
RedsStream *stream, uint32_t link_id, int migration,
|
||||
RedChannelCapabilities *caps);
|
||||
void main_channel_push_mouse_mode(MainChannel *main_chan, int current_mode, int is_client_mouse_allowed);
|
||||
void main_channel_push_mouse_mode(MainChannel *main_chan, SpiceMouseMode current_mode,
|
||||
int is_client_mouse_allowed);
|
||||
void main_channel_push_agent_connected(MainChannel *main_chan);
|
||||
void main_channel_push_agent_disconnected(MainChannel *main_chan);
|
||||
void main_channel_push_multi_media_time(MainChannel *main_chan, int time);
|
||||
|
||||
@ -101,7 +101,7 @@ struct RedsState {
|
||||
GList *mig_target_clients;
|
||||
|
||||
GList *channels;
|
||||
int mouse_mode;
|
||||
SpiceMouseMode mouse_mode;
|
||||
int is_client_mouse_allowed;
|
||||
int dispatcher_allows_client_mouse;
|
||||
MonitorMode monitor_mode;
|
||||
|
||||
@ -304,7 +304,7 @@ static void reds_on_sv_change(RedsState *reds);
|
||||
static void reds_on_vc_change(RedsState *reds);
|
||||
static void reds_on_vm_stop(RedsState *reds);
|
||||
static void reds_on_vm_start(RedsState *reds);
|
||||
static void reds_set_mouse_mode(RedsState *reds, uint32_t mode);
|
||||
static void reds_set_mouse_mode(RedsState *reds, SpiceMouseMode mode);
|
||||
static uint32_t reds_qxl_ram_size(RedsState *reds);
|
||||
static int calc_compression_level(RedsState *reds);
|
||||
|
||||
@ -596,12 +596,12 @@ bool reds_config_get_playback_compression(RedsState *reds)
|
||||
return reds->config->playback_compression;
|
||||
}
|
||||
|
||||
int reds_get_mouse_mode(RedsState *reds)
|
||||
SpiceMouseMode reds_get_mouse_mode(RedsState *reds)
|
||||
{
|
||||
return reds->mouse_mode;
|
||||
}
|
||||
|
||||
static void reds_set_mouse_mode(RedsState *reds, uint32_t mode)
|
||||
static void reds_set_mouse_mode(RedsState *reds, SpiceMouseMode mode)
|
||||
{
|
||||
QXLInstance *qxl;
|
||||
|
||||
|
||||
@ -48,7 +48,7 @@ uint32_t reds_get_mm_time(void);
|
||||
void reds_register_channel(RedsState *reds, RedChannel *channel);
|
||||
void reds_unregister_channel(RedsState *reds, RedChannel *channel);
|
||||
RedChannel *reds_find_channel(RedsState *reds, uint32_t type, uint32_t id);
|
||||
int reds_get_mouse_mode(RedsState *reds); // used by inputs_channel
|
||||
SpiceMouseMode reds_get_mouse_mode(RedsState *reds); // used by inputs_channel
|
||||
gboolean reds_config_get_agent_mouse(const RedsState *reds); // used by inputs_channel
|
||||
int reds_has_vdagent(RedsState *reds); // used by inputs channel
|
||||
bool reds_config_get_playback_compression(RedsState *reds); // used by playback channel
|
||||
|
||||
Loading…
Reference in New Issue
Block a user