Changeset 51542 in vbox for trunk/src/VBox/Frontends/VBoxHeadless
- Timestamp:
- Jun 5, 2014 7:35:49 AM (11 years ago)
- svn:sync-xref-src-repo-rev:
- 94189
- Location:
- trunk/src/VBox/Frontends/VBoxHeadless
- Files:
-
- 4 deleted
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Frontends/VBoxHeadless/Makefile.kmk
r51504 r51542 46 46 VBoxHeadless_DEFS += $(if $(VBOX_WITH_VPX),VBOX_WITH_VPX,) 47 47 VBoxHeadless_SOURCES = VBoxHeadless.cpp 48 VBoxHeadless_SOURCES += Framebuffer.cpp49 48 ifdef VBOX_WITH_GUEST_PROPS 50 49 VBoxHeadless_DEFS += VBOX_WITH_GUEST_PROPS -
trunk/src/VBox/Frontends/VBoxHeadless/VBoxHeadless.cpp
r51505 r51542 5 5 6 6 /* 7 * Copyright (C) 2006-201 2Oracle Corporation7 * Copyright (C) 2006-2014 Oracle Corporation 8 8 * 9 9 * This file is part of VirtualBox Open Source Edition (OSE), as … … 53 53 #include <signal.h> 54 54 #endif 55 56 #include "Framebuffer.h"57 58 #include "NullFramebuffer.h"59 55 60 56 //////////////////////////////////////////////////////////////////////////////// … … 635 631 static CComModule _Module; 636 632 #endif 637 638 ComPtr<IDisplay> display;639 633 640 634 /** … … 966 960 CHECK_ERROR_BREAK(console, COMGETTER(Machine)(machine.asOutParam())); 967 961 962 ComPtr<IDisplay> display; 968 963 CHECK_ERROR_BREAK(console, COMGETTER(Display)(display.asOutParam())); 969 964 … … 978 973 } 979 974 #endif /* defined(VBOX_WITH_VPX) */ 980 ULONG cMonitors = 1;981 machine->COMGETTER(MonitorCount)(&cMonitors);982 983 unsigned uScreenId;984 for (uScreenId = 0; uScreenId < cMonitors; uScreenId++)985 {986 VRDPFramebuffer *pVRDPFramebuffer = new VRDPFramebuffer();987 if (!pVRDPFramebuffer)988 {989 RTPrintf("Error: could not create framebuffer object %d\n", uScreenId);990 break;991 }992 pVRDPFramebuffer->AddRef();993 display->AttachFramebuffer(uScreenId, pVRDPFramebuffer);994 }995 if (uScreenId < cMonitors)996 {997 break;998 }999 1000 // fill in remaining slots with null framebuffers1001 for (uScreenId = 0; uScreenId < cMonitors; uScreenId++)1002 {1003 ComPtr<IFramebuffer> fb;1004 HRESULT hrc2 = display->QueryFramebuffer(uScreenId,1005 fb.asOutParam());1006 if (hrc2 == S_OK && fb.isNull())1007 {1008 NullFB *pNullFB = new NullFB();1009 pNullFB->AddRef();1010 pNullFB->init();1011 display->AttachFramebuffer(uScreenId, pNullFB);1012 }1013 }1014 975 1015 976 /* get the machine debugger (isn't necessarily available) */ … … 1279 1240 while (0); 1280 1241 1281 display.setNull();1282 1283 1242 /* 1284 1243 * Get the machine state. … … 1405 1364 } 1406 1365 #endif /* !VBOX_WITH_HARDENING */ 1407 1408 #ifdef VBOX_WITH_XPCOM1409 NS_DECL_CLASSINFO(NullFB)1410 NS_IMPL_THREADSAFE_ISUPPORTS1_CI(NullFB, IFramebuffer)1411 #endif
Note:
See TracChangeset
for help on using the changeset viewer.