[Windows] Fix driver version detection of AMD RDNA+ GPU on Windows 10
[xbmc.git] / xbmc / windowing / osx / WinEventsOSX.mm
blob61fc8768a74a4e4133a5ca730434c556e554d616
1 /*
2  *  Copyright (C) 2011-2018 Team Kodi
3  *  This file is part of Kodi - https://kodi.tv
4  *
5  *  SPDX-License-Identifier: GPL-2.0-or-later
6  *  See LICENSES/README.md for more information.
7  */
9 #include "WinEventsOSX.h"
11 #import "WinEventsOSXImpl.h"
13 struct CWinEventsOSXImplWrapper
15   CWinEventsOSXImpl* callbackClass;
18 CWinEventsOSX::CWinEventsOSX() : CThread("CWinEventsOSX")
20   m_eventsImplWrapper = std::make_unique<CWinEventsOSXImplWrapper>();
21   m_eventsImplWrapper->callbackClass = [CWinEventsOSXImpl new];
22   Create();
25 CWinEventsOSX::~CWinEventsOSX()
27   m_bStop = true;
28   StopThread(true);
31 void CWinEventsOSX::MessagePush(XBMC_Event* newEvent)
33   [m_eventsImplWrapper->callbackClass MessagePush:newEvent];
36 size_t CWinEventsOSX::GetQueueSize()
38   return [m_eventsImplWrapper->callbackClass GetQueueSize];
41 bool CWinEventsOSX::MessagePump()
43   return [m_eventsImplWrapper->callbackClass MessagePump];
46 void CWinEventsOSX::enableInputEvents()
48   return [m_eventsImplWrapper->callbackClass enableInputEvents];
51 void CWinEventsOSX::disableInputEvents()
53   return [m_eventsImplWrapper->callbackClass disableInputEvents];
56 void CWinEventsOSX::signalMouseEntered()
58   return [m_eventsImplWrapper->callbackClass signalMouseEntered];
61 void CWinEventsOSX::signalMouseExited()
63   return [m_eventsImplWrapper->callbackClass signalMouseExited];
66 void CWinEventsOSX::SendInputEvent(NSEvent* nsEvent)
68   [m_eventsImplWrapper->callbackClass ProcessInputEvent:nsEvent];