Alow raw input driver to be used with Direct3D

This commit is contained in:
Zoran Vuckovic 2017-05-19 19:36:14 +02:00
parent 65fd5c406b
commit 2eb7499b64

View File

@ -25,10 +25,12 @@
#endif
#include <compat/strl.h>
#include <string/stdstring.h>
#include "../drivers/d3d.h"
#include "../common/win32_common.h"
#include "../../configuration.h"
#include "../../verbosity.h"
#include "../../ui/ui_companion_driver.h"
@ -187,6 +189,19 @@ static void gfx_ctx_d3d_input_driver(void *data,
*input = xinput ? (const input_driver_t*)&input_xinput : NULL;
*input_data = xinput;
#else
settings_t *settings = config_get_ptr();
if (string_is_equal_fast(settings->arrays.input_driver, "raw", 4))
{
*input_data = input_winraw.init(name);
if (*input_data)
{
*input = &input_winraw;
dinput = NULL;
return;
}
}
dinput = input_dinput.init(name);
*input = dinput ? &input_dinput : NULL;
*input_data = dinput;