Changeset 35722 in vbox for trunk/src/VBox/Frontends/VBoxSDL
- Timestamp:
- Jan 26, 2011 4:37:16 PM (14 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Frontends/VBoxSDL/VBoxSDL.cpp
r35666 r35722 245 245 } 246 246 247 HRESULT init() 248 { 249 return S_OK; 250 } 251 252 void uninit() 253 { 254 } 255 247 256 STDMETHOD(HandleEvent)(VBoxEventType_T aType, IEvent * aEvent) 248 257 { … … 287 296 288 297 virtual ~VBoxSDLEventListener() 298 { 299 } 300 301 HRESULT init() 302 { 303 return S_OK; 304 } 305 306 void uninit() 289 307 { 290 308 } … … 347 365 348 366 virtual ~VBoxSDLConsoleEventListener() 367 { 368 } 369 370 HRESULT init() 371 { 372 return S_OK; 373 } 374 375 void uninit() 349 376 { 350 377 } … … 772 799 uint32_t memorySize = 0; 773 800 uint32_t vramSize = 0; 774 IEventListener *pVBoxClientListener = NULL;775 IEventListener *pVBoxListener = NULL;776 VBoxSDLConsoleEventListenerImpl *pConsoleListener = NULL;801 ComPtr<IEventListener> pVBoxClientListener; 802 ComPtr<IEventListener> pVBoxListener; 803 ComObjPtr<VBoxSDLConsoleEventListenerImpl> pConsoleListener; 777 804 778 805 bool fFullscreen = false; … … 1834 1861 ComPtr<IEventSource> pES; 1835 1862 CHECK_ERROR(pVirtualBoxClient, COMGETTER(EventSource)(pES.asOutParam())); 1836 pVBoxClientListener = new VBoxSDLClientEventListenerImpl(); 1863 ComObjPtr<VBoxSDLClientEventListenerImpl> listener; 1864 listener.createObject(); 1865 listener->init(new VBoxSDLClientEventListener()); 1866 pVBoxClientListener = listener; 1837 1867 com::SafeArray<VBoxEventType_T> eventTypes; 1838 1868 eventTypes.push_back(VBoxEventType_OnVBoxSVCAvailabilityChanged); … … 1844 1874 ComPtr<IEventSource> pES; 1845 1875 CHECK_ERROR(pVirtualBox, COMGETTER(EventSource)(pES.asOutParam())); 1846 pVBoxListener = new VBoxSDLEventListenerImpl(); 1876 ComObjPtr<VBoxSDLEventListenerImpl> listener; 1877 listener.createObject(); 1878 listener->init(new VBoxSDLEventListener()); 1879 pVBoxListener = listener; 1847 1880 com::SafeArray<VBoxEventType_T> eventTypes; 1848 1881 eventTypes.push_back(VBoxEventType_OnExtraDataChanged); … … 1854 1887 ComPtr<IEventSource> pES; 1855 1888 CHECK_ERROR(gpConsole, COMGETTER(EventSource)(pES.asOutParam())); 1856 pConsoleListener = new VBoxSDLConsoleEventListenerImpl(); 1889 pConsoleListener.createObject(); 1890 pConsoleListener->init(new VBoxSDLConsoleEventListener()); 1857 1891 com::SafeArray<VBoxEventType_T> eventTypes; 1858 1892 eventTypes.push_back(VBoxEventType_OnMousePointerShapeChanged);
Note:
See TracChangeset
for help on using the changeset viewer.