NEW:enable 3dMouse detect in .conf
JIRA: 5830 Change-Id: I8731e0244d2f551130c84bcfbbb46967ae6b19cd
This commit is contained in:
parent
6d621816c9
commit
a3c72a88c1
|
@ -144,11 +144,13 @@ static std::string format_device_string(int vid, int pid)
|
|||
static std::string detect_attached_device()
|
||||
{
|
||||
std::string ret;
|
||||
|
||||
// Initialize the hidapi library
|
||||
int res = hid_init();
|
||||
if (res != 0)
|
||||
BOOST_LOG_TRIVIAL(error) << "Unable to initialize hidapi library";
|
||||
else if (wxGetApp().app_config->get("skip_3dmouse_detect") == "true") {
|
||||
BOOST_LOG_TRIVIAL(info) << "do not detect 3d Mouse";
|
||||
}
|
||||
else {
|
||||
// Enumerates devices
|
||||
hid_device_info* devices = hid_enumerate(0, 0);
|
||||
|
@ -821,7 +823,7 @@ void Mouse3DController::run()
|
|||
|
||||
bool Mouse3DController::connect_device()
|
||||
{
|
||||
if (m_stop)
|
||||
if (m_stop || wxGetApp().app_config->get("skip_3dmouse_detect") == "true")
|
||||
return false;
|
||||
|
||||
{
|
||||
|
|
Loading…
Reference in New Issue