Changeset 22822 in vbox for trunk/src/VBox/Frontends/VirtualBox/include/VBoxFBOverlay.h
- Timestamp:
- Sep 7, 2009 7:33:48 PM (15 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Frontends/VirtualBox/include/VBoxFBOverlay.h
r22817 r22822 1257 1257 1258 1258 1259 template <class T> 1260 class VBoxOverlayFrameBuffer : public T 1261 { 1262 public: 1263 VBoxOverlayFrameBuffer (class VBoxConsoleView *aView) 1264 : T(aView), 1265 mOverlay(aView, this) 1266 {} 1267 1268 1269 STDMETHOD(ProcessVHWACommand)(BYTE *pCommand) 1270 { 1271 return mOverlay.onVHWACommand((VBOXVHWACMD*)pCommand); 1272 } 1273 1274 void doProcessVHWACommand(QEvent * pEvent) 1275 { 1276 mOverlay.onVHWACommandEvent(pEvent); 1277 } 1278 1279 STDMETHOD(NotifyUpdate) (ULONG aX, ULONG aY, 1280 ULONG aW, ULONG aH) 1281 { 1282 if(mOverlay.onNotifyUpdate(aX, aY, aW, aH)) 1283 return S_OK; 1284 return T::NotifyUpdate(aX, aY, aW, aH); 1285 } 1286 1287 void paintEvent (QPaintEvent *pe) 1288 { 1289 QRect rect; 1290 VBOXFBOVERLAY_RESUT res = mOverlay.onPaintEvent(pe, &rect); 1291 switch(res) 1292 { 1293 case VBOXFBOVERLAY_MODIFIED: 1294 { 1295 QPaintEvent modified(rect); 1296 T::paintEvent(&modified); 1297 } break; 1298 case VBOXFBOVERLAY_UNTOUCHED: 1299 T::paintEvent(pe); 1300 break; 1301 } 1302 } 1303 1304 void resizeEvent (VBoxResizeEvent *re) 1305 { 1306 mOverlay.onResizeEvent(re); 1307 T::resizeEvent(re); 1308 mOverlay.onResizeEventPostprocess(re); 1309 } 1310 private: 1311 VBoxQGLOverlay mOverlay; 1312 }; 1313 1259 1314 #endif 1260 1315
Note:
See TracChangeset
for help on using the changeset viewer.