Changeset 98839 in vbox
- Timestamp:
- Mar 6, 2023 12:20:33 PM (21 months ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Frontends/VirtualBox/src/runtime/UIFrameBuffer.cpp
r98838 r98839 556 556 private: 557 557 558 #ifdef Q_OS_WIN558 #ifdef VBOX_WS_WIN 559 559 ComPtr<IUnknown> m_pUnkMarshaler; 560 #endif /* Q_OS_WIN */560 #endif 561 561 /** Identifier returned by AttachFramebuffer. Used in DetachFramebuffer. */ 562 562 QUuid m_uFramebufferId; … … 1106 1106 LogRel2(("GUI: UIFrameBufferPrivate::init %p\n", this)); 1107 1107 1108 /* Assign mahine-view: */ 1109 m_pMachineView = pMachineView; 1110 1111 /* Assign index: */ 1112 m_uScreenId = m_pMachineView->screenId(); 1113 1114 /* Cache window ID: */ 1115 m_iWinId = (m_pMachineView && m_pMachineView->viewport()) ? (LONG64)m_pMachineView->viewport()->winId() : 0; 1116 1117 #ifdef VBOX_WS_X11 1118 /* Sync Qt and X11 Server (see xTracker #7547). */ 1119 XSync(NativeWindowSubsystem::X11GetDisplay(), false); 1120 #endif 1108 /* Fetch passed view: */ 1109 setView(pMachineView); 1121 1110 1122 1111 /* Assign display: */ 1123 m_comDisplay = m_pMachineView->ui session()->display();1112 m_comDisplay = m_pMachineView->uimachine()->uisession()->display(); 1124 1113 1125 1114 /* Initialize critical-section: */ … … 1127 1116 AssertRC(rc); 1128 1117 1129 /* Connect handlers: */1130 if (m_pMachineView)1131 prepareConnections();1132 1133 #ifdef VBOX_GUI_WITH_QTGLFRAMEBUFFER1134 /* Decide if we are going to use GL to draw the guest screen: */1135 if (isGLWidgetSupported())1136 m_pGLWidget = new GLWidget(m_pMachineView->viewport(), this);1137 #endif1138 1139 1118 /* Resize/rescale frame-buffer to the default size: */ 1140 1119 performResize(640, 480); 1141 1120 performRescale(); 1142 1121 1143 #ifdef Q_OS_WIN1122 #ifdef VBOX_WS_WIN 1144 1123 CoCreateFreeThreadedMarshaler(this, m_pUnkMarshaler.asOutParam()); 1145 #endif /* Q_OS_WIN */ 1124 #endif 1125 1146 1126 return S_OK; 1147 1127 } … … 1167 1147 /* Reassign machine-view: */ 1168 1148 m_pMachineView = pMachineView; 1149 /* Reassign index: */ 1150 m_uScreenId = m_pMachineView ? m_pMachineView->screenId() : 0; 1169 1151 /* Recache window ID: */ 1170 1152 m_iWinId = (m_pMachineView && m_pMachineView->viewport()) ? (LONG64)m_pMachineView->viewport()->winId() : 0; 1171 1153 1172 1154 #ifdef VBOX_WS_X11 1173 /* Sync Qt and X11 Server (see xTracker #7547). */1155 /* Resync Qt and X11 Server (see xTracker #7547). */ 1174 1156 XSync(NativeWindowSubsystem::X11GetDisplay(), false); 1175 1157 #endif 1176 1158 1177 /* Connect new handlers: */1159 /* Reconnect new handlers: */ 1178 1160 if (m_pMachineView) 1179 1161 prepareConnections();
Note:
See TracChangeset
for help on using the changeset viewer.