Changeset 85679 in vbox for trunk/src/VBox/Frontends/VirtualBox
- Timestamp:
- Aug 11, 2020 6:47:35 AM (4 years ago)
- Location:
- trunk/src/VBox/Frontends/VirtualBox
- Files:
-
- 1 deleted
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Frontends/VirtualBox/VBoxUI.pro
r85645 r85679 40 40 src/settings/machine/UIMachineSettingsSerial.ui \ 41 41 src/settings/machine/UIMachineSettingsUSB.ui \ 42 src/settings/machine/UIMachineSettingsUSBFilterDetails.ui \43 src/settings/machine/UIMachineSettingsInterface.ui 42 src/settings/machine/UIMachineSettingsUSBFilterDetails.ui 43 44 44 45 45 TRANSLATIONS = \ -
trunk/src/VBox/Frontends/VirtualBox/src/settings/machine/UIMachineSettingsInterface.cpp
r84904 r85679 16 16 */ 17 17 18 /* Qt includes: */ 19 #include <QCheckBox> 20 #include <QGridLayout> 21 #include <QLabel> 22 18 23 /* GUI includes: */ 19 24 #include "UIActionPool.h" 20 25 #include "UIExtraDataManager.h" 21 26 #include "UIMachineSettingsInterface.h" 22 27 #include "UIStatusBarEditorWindow.h" 28 #include "UIMenuBarEditorWindow.h" 29 #include "UIVisualStateEditor.h" 23 30 24 31 /** Machine settings: User Interface page data structure. */ … … 285 292 void UIMachineSettingsInterface::retranslateUi() 286 293 { 287 /* Translate uic generated strings: */ 288 Ui::UIMachineSettingsInterface::retranslateUi(this); 294 m_pMenuBarEditor->setWhatsThis(tr("Allows to modify VM menu-bar contents.")); 295 m_pLabelVisualState->setText(tr("Visual State:")); 296 m_pVisualStateEditor->setWhatsThis(tr("Selects the visual state. If machine is running it will be applied as soon as possible, otherwise desired one will be defined.")); 297 m_pLabelMiniToolBar->setText(tr("Mini ToolBar:")); 298 m_pCheckBoxShowMiniToolBar->setWhatsThis(tr("When checked, show the Mini ToolBar in full-screen and seamless modes.")); 299 m_pCheckBoxShowMiniToolBar->setText(tr("Show in &Full-screen/Seamless")); 300 m_pComboToolBarAlignment->setWhatsThis(tr("When checked, show the Mini ToolBar at the top of the screen, rather than in its default position at the bottom of the screen.")); 301 m_pComboToolBarAlignment->setText(tr("Show at &Top of Screen")); 302 m_pStatusBarEditor->setWhatsThis(tr("Allows to modify VM status-bar contents.")); 289 303 } 290 304 … … 305 319 } 306 320 321 void UIMachineSettingsInterface::prepareWidgets() 322 { 323 if (objectName().isEmpty()) 324 setObjectName(QStringLiteral("UIMachineSettingsInterface")); 325 resize(350, 300); 326 QGridLayout *pLayoutMain = new QGridLayout(this); 327 pLayoutMain->setObjectName(QStringLiteral("pLayoutMain")); 328 m_pMenuBarEditor = new UIMenuBarEditorWidget(this); 329 m_pMenuBarEditor->setObjectName(QStringLiteral("m_pMenuBarEditor")); 330 QSizePolicy sizePolicy(QSizePolicy::MinimumExpanding, QSizePolicy::Fixed); 331 sizePolicy.setHorizontalStretch(0); 332 sizePolicy.setVerticalStretch(0); 333 sizePolicy.setHeightForWidth(m_pMenuBarEditor->sizePolicy().hasHeightForWidth()); 334 m_pMenuBarEditor->setSizePolicy(sizePolicy); 335 pLayoutMain->addWidget(m_pMenuBarEditor, 0, 0, 1, 3); 336 337 m_pLabelVisualState = new QLabel; 338 m_pLabelVisualState->setObjectName(QStringLiteral("m_pLabelVisualState")); 339 m_pLabelVisualState->setAlignment(Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter); 340 pLayoutMain->addWidget(m_pLabelVisualState, 1, 0, 1, 1); 341 342 m_pVisualStateEditor = new UIVisualStateEditor; 343 m_pVisualStateEditor->setObjectName(QStringLiteral("m_pVisualStateEditor")); 344 pLayoutMain->addWidget(m_pVisualStateEditor, 1, 1, 1, 2); 345 346 m_pLabelMiniToolBar = new QLabel; 347 m_pLabelMiniToolBar->setObjectName(QStringLiteral("m_pLabelMiniToolBar")); 348 m_pLabelMiniToolBar->setAlignment(Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter); 349 pLayoutMain->addWidget(m_pLabelMiniToolBar, 2, 0, 1, 1); 350 351 m_pCheckBoxShowMiniToolBar = new QCheckBox; 352 m_pCheckBoxShowMiniToolBar->setObjectName(QStringLiteral("m_pCheckBoxShowMiniToolBar")); 353 sizePolicy.setHeightForWidth(m_pCheckBoxShowMiniToolBar->sizePolicy().hasHeightForWidth()); 354 m_pCheckBoxShowMiniToolBar->setSizePolicy(sizePolicy); 355 m_pCheckBoxShowMiniToolBar->setChecked(true); 356 pLayoutMain->addWidget(m_pCheckBoxShowMiniToolBar, 2, 1, 1, 2); 357 358 m_pComboToolBarAlignment = new QCheckBox; 359 m_pComboToolBarAlignment->setObjectName(QStringLiteral("m_pComboToolBarAlignment")); 360 sizePolicy.setHeightForWidth(m_pComboToolBarAlignment->sizePolicy().hasHeightForWidth()); 361 m_pComboToolBarAlignment->setSizePolicy(sizePolicy); 362 m_pComboToolBarAlignment->setChecked(false); 363 pLayoutMain->addWidget(m_pComboToolBarAlignment, 3, 1, 1, 2); 364 365 QSpacerItem *pSpacer = new QSpacerItem(0, 0, QSizePolicy::Minimum, QSizePolicy::Expanding); 366 pLayoutMain->addItem(pSpacer, 4, 0, 1, 3); 367 368 m_pStatusBarEditor = new UIStatusBarEditorWidget(this); 369 m_pStatusBarEditor->setObjectName(QStringLiteral("m_pStatusBarEditor")); 370 sizePolicy.setHeightForWidth(m_pStatusBarEditor->sizePolicy().hasHeightForWidth()); 371 m_pStatusBarEditor->setSizePolicy(sizePolicy); 372 pLayoutMain->addWidget(m_pStatusBarEditor, 5, 0, 1, 3); 373 374 QObject::connect(m_pCheckBoxShowMiniToolBar, &QCheckBox::toggled, 375 m_pComboToolBarAlignment, &UIMachineSettingsInterface::setEnabled); 376 } 377 307 378 void UIMachineSettingsInterface::prepare() 308 379 { 309 /* Apply UI decorations: */ 310 Ui::UIMachineSettingsInterface::setupUi(this); 380 prepareWidgets(); 311 381 312 382 /* Prepare cache: */ -
trunk/src/VBox/Frontends/VirtualBox/src/settings/machine/UIMachineSettingsInterface.h
r84904 r85679 24 24 /* GUI includes: */ 25 25 #include "UISettingsPage.h" 26 #include "UIMachineSettingsInterface.gen.h"27 26 28 27 /* Forward declarations: */ 28 class QCheckBox; 29 class QLabel; 29 30 class UIActionPool; 31 class UIMenuBarEditorWidget; 32 class UIStatusBarEditorWidget; 33 class UIVisualStateEditor; 30 34 struct UIDataSettingsMachineInterface; 31 35 typedef UISettingsCache<UIDataSettingsMachineInterface> UISettingsCacheMachineInterface; 32 36 33 37 /** Machine settings: User Interface page. */ 34 class SHARED_LIBRARY_STUFF UIMachineSettingsInterface : public UISettingsPageMachine, 35 public Ui::UIMachineSettingsInterface 38 class SHARED_LIBRARY_STUFF UIMachineSettingsInterface : public UISettingsPageMachine 36 39 { 37 40 Q_OBJECT; … … 73 76 /** Prepares all. */ 74 77 void prepare(); 78 /** Prepares widgets. */ 79 void prepareWidgets(); 75 80 /** Cleanups all. */ 76 81 void cleanup(); … … 94 99 /** Holds the page data cache instance. */ 95 100 UISettingsCacheMachineInterface *m_pCache; 101 102 /** @name Widgets 103 * @{ */ 104 UIStatusBarEditorWidget *m_pStatusBarEditor; 105 UIMenuBarEditorWidget *m_pMenuBarEditor; 106 QCheckBox *m_pCheckBoxShowMiniToolBar; 107 QCheckBox *m_pComboToolBarAlignment; 108 QLabel *m_pLabelVisualState; 109 UIVisualStateEditor *m_pVisualStateEditor; 110 QLabel *m_pLabelMiniToolBar; 111 /** @} */ 96 112 }; 97 113 -
trunk/src/VBox/Frontends/VirtualBox/src/settings/machine/UIMachineSettingsSFDetails.cpp
r85645 r85679 203 203 void UIMachineSettingsSFDetails::retranslateUi() 204 204 { 205 m_pPathLabel->setText( QApplication::translate("UIMachineSettingsSFDetails","Folder Path:"));206 m_pNameLabel->setText( QApplication::translate("UIMachineSettingsSFDetails","Folder Name:"));207 m_pNameLineEdit->setToolTip( QApplication::translate("UIMachineSettingsSFDetails","Holds the name of the shared folder (as it will be seen by the guest OS)."));208 m_pReadonlyCheckBox->setToolTip( QApplication::translate("UIMachineSettingsSFDetails","When checked, the guest OS will not be able to write to the specified shared folder."));209 m_pReadonlyCheckBox->setText( QApplication::translate("UIMachineSettingsSFDetails","&Read-only"));210 m_pAutoMountCheckBox->setToolTip( QApplication::translate("UIMachineSettingsSFDetails","When checked, the guest OS will try to automatically mount the shared folder on startup."));211 m_pAutoMountCheckBox->setText( QApplication::translate("UIMachineSettingsSFDetails","&Auto-mount"));212 m_pAutoMountPointLabel->setText( QApplication::translate("UIMachineSettingsSFDetails","Mount point:"));213 m_pAutoMountPointLineEdit->setToolTip( QApplication::translate("UIMachineSettingsSFDetails","Where to automatically mount the folder in the guest. A drive letter (e.g. 'G:') for Windows and OS/2 guests, path for the others. If left empty the guest will pick something fitting."));214 m_pPermanentCheckBox->setToolTip( QApplication::translate("UIMachineSettingsSFDetails","When checked, this shared folder will be permanent."));215 m_pPermanentCheckBox->setText( QApplication::translate("UIMachineSettingsSFDetails","&Make Permanent"));205 m_pPathLabel->setText(tr("Folder Path:")); 206 m_pNameLabel->setText(tr("Folder Name:")); 207 m_pNameLineEdit->setToolTip(tr("Holds the name of the shared folder (as it will be seen by the guest OS).")); 208 m_pReadonlyCheckBox->setToolTip(tr("When checked, the guest OS will not be able to write to the specified shared folder.")); 209 m_pReadonlyCheckBox->setText(tr("&Read-only")); 210 m_pAutoMountCheckBox->setToolTip(tr("When checked, the guest OS will try to automatically mount the shared folder on startup.")); 211 m_pAutoMountCheckBox->setText(tr("&Auto-mount")); 212 m_pAutoMountPointLabel->setText(tr("Mount point:")); 213 m_pAutoMountPointLineEdit->setToolTip(tr("Where to automatically mount the folder in the guest. A drive letter (e.g. 'G:') for Windows and OS/2 guests, path for the others. If left empty the guest will pick something fitting.")); 214 m_pPermanentCheckBox->setToolTip(tr("When checked, this shared folder will be permanent.")); 215 m_pPermanentCheckBox->setText(tr("&Make Permanent")); 216 216 217 217 switch (m_type)
Note:
See TracChangeset
for help on using the changeset viewer.