Changeset 93180 in vbox
- Timestamp:
- Jan 11, 2022 10:09:35 AM (3 years ago)
- Location:
- trunk/src/VBox/Frontends/VirtualBox/src/guestctrl
- Files:
-
- 5 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Frontends/VirtualBox/src/guestctrl/UIFileManager.cpp
r93115 r93180 479 479 /* Mark the current guest table: */ 480 480 UIFileManagerGuestTable *pCurrentGuestTable = currentGuestTable(); 481 if (!pCurrentGuestTable) 482 return; 481 483 for (int i = 0; i < m_pGuestTablesContainer->count(); ++i) 482 484 { … … 486 488 pTable->setIsCurrent(pTable == pCurrentGuestTable); 487 489 } 490 if (m_pHostFileTable) 491 m_pHostFileTable->setEnabled(pCurrentGuestTable->isGuestSessionRunning()); 492 } 493 494 void UIFileManager::sltGuestFileTableStateChanged(bool fIsRunning) 495 { 496 if (m_pHostFileTable) 497 m_pHostFileTable->setEnabled(fIsRunning); 488 498 } 489 499 … … 801 811 connect(pGuestFileTable, &UIFileManagerGuestTable::sigDeleteConfirmationOptionChanged, 802 812 this, &UIFileManager::sltHandleOptionsUpdated); 813 connect(pGuestFileTable, &UIFileManagerGuestTable::sigStateChanged, 814 this, &UIFileManager::sltGuestFileTableStateChanged); 803 815 } 804 816 } -
trunk/src/VBox/Frontends/VirtualBox/src/guestctrl/UIFileManager.h
r93115 r93180 118 118 void sltFileTableSelectionChanged(bool fHasSelection); 119 119 void sltCurrentTabChanged(int iIndex); 120 void sltGuestFileTableStateChanged(bool fIsRunning); 120 121 121 122 private: -
trunk/src/VBox/Frontends/VirtualBox/src/guestctrl/UIFileManagerGuestTable.cpp
r93115 r93180 646 646 bool UIFileManagerGuestTable::isGuestSessionRunning() const 647 647 { 648 if (m_comGuestSession.isNull()) 649 return false; 650 if (m_comGuestSession.GetStatus() == KGuestSessionStatus_Starting || 651 m_comGuestSession.GetStatus() == KGuestSessionStatus_Started) 652 return true; 653 return false; 648 return m_enmState == State_SessionRunning; 654 649 } 655 650 … … 1390 1385 break; 1391 1386 } 1387 emit sigStateChanged(m_enmState == State_SessionRunning); 1392 1388 } 1393 1389 -
trunk/src/VBox/Frontends/VirtualBox/src/guestctrl/UIFileManagerGuestTable.h
r93115 r93180 55 55 56 56 void sigNewFileOperation(const CProgress &comProgress, const QString &strTableName); 57 void sigStateChanged(bool fSessionRunning); 57 58 58 59 public: -
trunk/src/VBox/Frontends/VirtualBox/src/guestctrl/UIFileManagerTable.cpp
r93115 r93180 818 818 m_pMainLayout->addWidget(m_pWarningLabel, 2, 0, 5, 7); 819 819 QFont labelFont = m_pWarningLabel->font(); 820 float fSizeMultiplier = 1. 5f;820 float fSizeMultiplier = 1.f; 821 821 if (labelFont.pointSize() != -1) 822 822 labelFont.setPointSize(fSizeMultiplier * labelFont.pointSize()); 823 823 else 824 824 labelFont.setPixelSize(fSizeMultiplier * labelFont.pixelSize()); 825 labelFont.setBold( true);825 labelFont.setBold(false); 826 826 m_pWarningLabel->setFont(labelFont); 827 m_pWarningLabel->setAlignment(Qt::Align Center| Qt::AlignVCenter);827 m_pWarningLabel->setAlignment(Qt::AlignLeft | Qt::AlignVCenter); 828 828 m_pWarningLabel->setWordWrap(true); 829 829 }
Note:
See TracChangeset
for help on using the changeset viewer.