mirror of
https://github.com/libretro/RetroArch
synced 2025-03-02 19:13:34 +00:00
Get rid of some getters
This commit is contained in:
parent
f4c5852cfa
commit
2a5751ca0e
@ -426,10 +426,6 @@ void *video_driver_get_ptr(void)
|
||||
return VIDEO_DRIVER_GET_PTR_INTERNAL(video_st);
|
||||
}
|
||||
|
||||
void *video_driver_get_data(void)
|
||||
{
|
||||
return video_driver_st.data;
|
||||
}
|
||||
|
||||
video_driver_t *hw_render_context_driver(
|
||||
enum retro_hw_context_type type, int major, int minor)
|
||||
@ -1212,11 +1208,6 @@ bool video_display_server_get_flags(gfx_ctx_flags_t *flags)
|
||||
return true;
|
||||
}
|
||||
|
||||
bool video_driver_started_fullscreen(void)
|
||||
{
|
||||
video_driver_state_t *video_st = &video_driver_st;
|
||||
return video_st->started_fullscreen;
|
||||
}
|
||||
|
||||
bool video_driver_is_threaded(void)
|
||||
{
|
||||
|
@ -1056,8 +1056,6 @@ void *video_driver_get_ptr(void);
|
||||
|
||||
video_driver_state_t *video_state_get_ptr(void);
|
||||
|
||||
void *video_driver_get_data(void);
|
||||
|
||||
bool video_driver_set_rotation(unsigned rotation);
|
||||
|
||||
bool video_driver_set_video_mode(unsigned width,
|
||||
@ -1299,8 +1297,6 @@ float video_driver_get_refresh_rate(void);
|
||||
bool video_driver_has_widgets(void);
|
||||
#endif
|
||||
|
||||
bool video_driver_started_fullscreen(void);
|
||||
|
||||
bool video_driver_is_threaded(void);
|
||||
|
||||
bool video_context_driver_get_flags(gfx_ctx_flags_t *flags);
|
||||
|
@ -23,6 +23,7 @@
|
||||
#include <features/features_cpu.h>
|
||||
#include <string/stdstring.h>
|
||||
|
||||
#include "video_driver.h"
|
||||
#include "video_thread_wrapper.h"
|
||||
#include "font_driver.h"
|
||||
|
||||
@ -1343,8 +1344,8 @@ bool video_thread_font_init(const void **font_driver, void **font_handle,
|
||||
bool is_threaded)
|
||||
{
|
||||
thread_packet_t pkt;
|
||||
thread_video_t *thr = (thread_video_t*)
|
||||
video_driver_get_data();
|
||||
video_driver_state_t *video_st = video_state_get_ptr();
|
||||
thread_video_t *thr = video_st ? (thread_video_t*)video_st->data : NULL;
|
||||
|
||||
if (!thr)
|
||||
return false;
|
||||
@ -1368,7 +1369,8 @@ unsigned video_thread_texture_load(void *data,
|
||||
custom_command_method_t func)
|
||||
{
|
||||
thread_packet_t pkt;
|
||||
thread_video_t *thr = (thread_video_t*)video_driver_get_data();
|
||||
video_driver_state_t *video_st = video_state_get_ptr();
|
||||
thread_video_t *thr = video_st ? (thread_video_t*)video_st->data : NULL;
|
||||
|
||||
if (!thr)
|
||||
return 0;
|
||||
|
@ -4947,6 +4947,8 @@ static void ui_companion_qt_toggle(void *data, bool force)
|
||||
|
||||
if (ui_companion_toggle || force)
|
||||
{
|
||||
video_driver_state_t *video_st = video_state_get_ptr();
|
||||
|
||||
if (mouse_grabbed)
|
||||
command_event(CMD_EVENT_GRAB_MOUSE_TOGGLE, NULL);
|
||||
video_driver_show_mouse();
|
||||
@ -4958,7 +4960,8 @@ static void ui_companion_qt_toggle(void *data, bool force)
|
||||
win_handle->qtWindow->raise();
|
||||
win_handle->qtWindow->show();
|
||||
|
||||
if (video_driver_started_fullscreen())
|
||||
if ( video_st
|
||||
&& video_st->started_fullscreen)
|
||||
win_handle->qtWindow->lower();
|
||||
|
||||
if (!already_started)
|
||||
|
Loading…
x
Reference in New Issue
Block a user