Changeset 97976 in vbox
- Timestamp:
- Jan 4, 2023 11:56:32 AM (2 years ago)
- svn:sync-xref-src-repo-rev:
- 155067
- Location:
- trunk/src/VBox/Frontends/VirtualBox/src/runtime
- Files:
-
- 7 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Frontends/VirtualBox/src/runtime/UIFrameBuffer.cpp
r97512 r97976 1491 1491 /* Determine if supported: */ 1492 1492 *pfSupported = TRUE; 1493 QSize screenSize = m_pMachineView->maxGuestSize();1493 const QSize screenSize = m_pMachineView->maximumGuestSize(); 1494 1494 if ( (screenSize.width() != 0) 1495 1495 && (uWidth > (ULONG)screenSize.width()) -
trunk/src/VBox/Frontends/VirtualBox/src/runtime/UIMachineView.cpp
r97856 r97976 188 188 189 189 /* Set a preliminary maximum size: */ 190 pMachineView->setMax GuestSize();190 pMachineView->setMaximumGuestSize(); 191 191 192 192 /* Resend the last resize hint finally: */ … … 294 294 295 295 /* Update current window size limitations: */ 296 setMax GuestSize(size);296 setMaximumGuestSize(size); 297 297 298 298 /* Record the hint to extra data, needed for guests using VMSVGA: … … 421 421 422 422 /* Update current window size limitations: */ 423 setMax GuestSize(QSize(uWidth, uHeight));423 setMaximumGuestSize(QSize(uWidth, uHeight)); 424 424 425 425 /* Record the hint to extra data, needed for guests using VMSVGA: … … 472 472 473 473 /* Update current window size limitations: */ 474 setMax GuestSize(size);474 setMaximumGuestSize(size); 475 475 476 476 /* Record the hint to extra data, needed for guests using VMSVGA: … … 661 661 void UIMachineView::sltDesktopResized() 662 662 { 663 setMax GuestSize();663 setMaximumGuestSize(); 664 664 } 665 665 … … 841 841 , m_iHostScreenNumber(0) 842 842 , m_enmMaximumGuestScreenSizePolicy(MaximumGuestScreenSizePolicy_Automatic) 843 , m_u64Max GuestSize(0)843 , m_u64MaximumGuestSize(0) 844 844 #ifdef VBOX_WITH_DRAG_AND_DROP_GH 845 845 , m_fIsDraggingFromGuest(false) … … 1215 1215 } 1216 1216 1217 void UIMachineView::setMax GuestSize(const QSize &minimumSizeHint /* = QSize() */)1217 void UIMachineView::setMaximumGuestSize(const QSize &minimumSizeHint /* = QSize() */) 1218 1218 { 1219 1219 QSize maxSize; … … 1230 1230 maxSize = QSize(0, 0); 1231 1231 } 1232 ASMAtomicWriteU64(&m_u64Max GuestSize,1232 ASMAtomicWriteU64(&m_u64MaximumGuestSize, 1233 1233 RT_MAKE_U64(maxSize.height(), maxSize.width())); 1234 1234 } 1235 1235 1236 QSize UIMachineView::max GuestSize()1237 { 1238 uint64_t u64Size = ASMAtomicReadU64(&m_u64Max GuestSize);1236 QSize UIMachineView::maximumGuestSize() 1237 { 1238 uint64_t u64Size = ASMAtomicReadU64(&m_u64MaximumGuestSize); 1239 1239 return QSize(int(RT_HI_U32(u64Size)), int(RT_LO_U32(u64Size))); 1240 1240 } -
trunk/src/VBox/Frontends/VirtualBox/src/runtime/UIMachineView.h
r97792 r97976 223 223 ulong screenId() const { return m_uScreenId; } 224 224 UIFrameBuffer* frameBuffer() const { return m_pFrameBuffer; } 225 225 226 /** Atomically store the maximum guest resolution which we currently wish 226 * to handle for @a max GuestSize() to read. Should be called if anything227 * to handle for @a maximumGuestSize() to read. Should be called if anything 227 228 * happens (e.g. a screen hotplug) which might cause the value to change. 228 * @sa m_u64Max GuestSize. */229 void setMax GuestSize(const QSize &minimumSizeHint = QSize());229 * @sa m_u64MaximumGuestSize. */ 230 void setMaximumGuestSize(const QSize &minimumSizeHint = QSize()); 230 231 /** Atomically read the maximum guest resolution which we currently wish to 231 232 * handle. This may safely be called from another thread (called by 232 233 * UIFramebuffer on EMT). 233 * @sa m_u64Max GuestSize. */234 QSize max GuestSize();234 * @sa m_u64MaximumGuestSize. */ 235 QSize maximumGuestSize(); 235 236 236 237 /** Retrieves the last guest-screen visibility status from extra-data. */ … … 401 402 */ 402 403 /** @todo This should be private. */ 403 volatile uint64_t m_u64Max GuestSize;404 volatile uint64_t m_u64MaximumGuestSize; 404 405 405 406 /** Holds the pause-pixmap. */ -
trunk/src/VBox/Frontends/VirtualBox/src/runtime/fullscreen/UIMachineViewFullscreen.cpp
r97975 r97976 77 77 break; 78 78 79 /* Recalculate max guest size: */80 setMax GuestSize();79 /* Recalculate maximum guest size: */ 80 setMaximumGuestSize(); 81 81 82 82 break; -
trunk/src/VBox/Frontends/VirtualBox/src/runtime/normal/UIMachineViewNormal.cpp
r97975 r97976 66 66 case QEvent::Resize: 67 67 { 68 /* Recalculate max guest size: */69 setMax GuestSize();68 /* Recalculate maximum guest size: */ 69 setMaximumGuestSize(); 70 70 /* And resize guest to current window size: */ 71 71 if (m_fGuestAutoresizeEnabled && uisession()->isGuestSupportsGraphics()) … … 158 158 159 159 /* Expand current limitations: */ 160 setMax GuestSize(sizeHint);160 setMaximumGuestSize(sizeHint); 161 161 162 162 /* Temporarily restrict the size to prevent a brief resize to the … … 201 201 202 202 /* Adjust guest-screen size if the last size hint is too big for the screen: */ 203 const QSize max GuestSize = calculateMaxGuestSize();204 if ( max GuestSize.width() < frameBufferSize.width()205 || max GuestSize.height() < frameBufferSize.height())203 const QSize maximumGuestSize = calculateMaxGuestSize(); 204 if ( maximumGuestSize.width() < frameBufferSize.width() 205 || maximumGuestSize.height() < frameBufferSize.height()) 206 206 sltPerformGuestResize(machineWindow()->centralWidget()->size()); 207 207 } -
trunk/src/VBox/Frontends/VirtualBox/src/runtime/scale/UIMachineViewScale.cpp
r97682 r97976 172 172 173 173 /* Expand current limitations: */ 174 setMax GuestSize(sizeHint);174 setMaximumGuestSize(sizeHint); 175 175 176 176 /* Send saved size-hint to the guest: */ -
trunk/src/VBox/Frontends/VirtualBox/src/runtime/seamless/UIMachineViewSeamless.cpp
r97682 r97976 88 88 break; 89 89 90 /* Recalculate max guest size: */91 setMax GuestSize();90 /* Recalculate maximum guest size: */ 91 setMaximumGuestSize(); 92 92 93 93 break;
Note:
See TracChangeset
for help on using the changeset viewer.