Changeset 79387 in vbox for trunk/src/VBox/Frontends
- Timestamp:
- Jun 27, 2019 12:11:36 PM (6 years ago)
- svn:sync-xref-src-repo-rev:
- 131626
- Location:
- trunk/src/VBox/Frontends/VirtualBox/src
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Frontends/VirtualBox/src/runtime/UIMachineLogic.cpp
r79365 r79387 1605 1605 /* Create the soft keyboard only once: */ 1606 1606 if (m_pSoftKeyboardDialog) 1607 return; 1608 1609 UISoftKeyboard *pSoftKeyboard = new UISoftKeyboard(0, uisession(), machine().GetName()); 1610 // UISoftKeyboardDialogFactory dialogFactory(uisession(), actionPool(), machine().GetName()); 1611 // dialogFactory.prepare(pSoftKeyboardDialog, activeMachineWindow()); 1612 if (pSoftKeyboard) 1613 { 1614 //m_pSoftKeyboardDialog = pSoftKeyboardDialog; 1615 1616 /* Show instance: */ 1617 pSoftKeyboard->show(); 1618 // pSoftKeyboardDialog->setWindowState(pSoftKeyboardDialog->windowState() & ~Qt::WindowMinimized); 1619 // pSoftKeyboardDialog->activateWindow(); 1620 // connect(pSoftKeyboardDialog, &QIManagerDialog::sigClose, 1621 // this, &UIMachineLogic::sltCloseSoftKeyboard); 1622 } 1623 } 1624 1625 void UIMachineLogic::sltCloseSoftKeyboard() 1626 { 1627 // QIManagerDialog* pDialog = qobject_cast<QIManagerDialog*>(sender()); 1628 // if (m_pSoftKeyboardDialog != pDialog || !pDialog) 1629 // return; 1630 1631 // /* Set the m_pSoftKeyboardDialog to NULL before closing the dialog. or we will have redundant deletes*/ 1632 // m_pSoftKeyboardDialog = 0; 1633 // pDialog->close(); 1634 // UISoftKeyboardDialogFactory().cleanup(pDialog); 1607 { 1608 m_pSoftKeyboardDialog->raise(); 1609 return; 1610 } 1611 m_pSoftKeyboardDialog = new UISoftKeyboard(0, uisession(), machine().GetName()); 1612 if (m_pSoftKeyboardDialog) 1613 { 1614 connect(m_pSoftKeyboardDialog, &QMainWindow::destroyed, this, &UIMachineLogic::sltSoftKeyboardClosed); 1615 m_pSoftKeyboardDialog->show(); 1616 } 1617 } 1618 1619 void UIMachineLogic::sltSoftKeyboardClosed() 1620 { 1621 m_pSoftKeyboardDialog = 0; 1635 1622 } 1636 1623 -
trunk/src/VBox/Frontends/VirtualBox/src/runtime/UIMachineLogic.h
r78567 r79387 40 40 class UIMachineView; 41 41 class UIDockIconPreview; 42 class UISoftKeyboard; 42 43 class CSession; 43 44 class CMachine; … … 266 267 void sltShowKeyboardSettings(); 267 268 void sltShowSoftKeyboard(); 268 void slt CloseSoftKeyboard();269 void sltSoftKeyboardClosed(); 269 270 void sltToggleMouseIntegration(bool fEnabled); 270 271 void sltTypeCAD(); … … 438 439 QIManagerDialog *m_pFileManagerDialog; 439 440 QIManagerDialog *m_pProcessControlDialog; 440 QIManagerDialog*m_pSoftKeyboardDialog;441 UISoftKeyboard *m_pSoftKeyboardDialog; 441 442 442 443 /* Friend classes: */ -
trunk/src/VBox/Frontends/VirtualBox/src/softkeyboard/UISoftKeyboard.cpp
r79385 r79387 1960 1960 QString strNewName; 1961 1961 if (!newLayout.name().isEmpty()) 1962 strNewName= QString("%1-%2").arg(newLayout.name()).arg( tr("Copy"));1962 strNewName= QString("%1-%2").arg(newLayout.name()).arg(UISoftKeyboard::tr("Copy")); 1963 1963 QString strNewNativeName; 1964 1964 if (!newLayout.nativeName().isEmpty()) 1965 strNewNativeName= QString("%1-%2").arg(newLayout.nativeName()).arg( tr("Copy"));1965 strNewNativeName= QString("%1-%2").arg(newLayout.nativeName()).arg(UISoftKeyboard::tr("Copy")); 1966 1966 newLayout.setName(strNewName); 1967 1967 newLayout.setNativeName(strNewNativeName); … … 2829 2829 { 2830 2830 if (m_pLayoutListButton) 2831 m_pLayoutListButton->setToolTip( tr("Layout List"));2831 m_pLayoutListButton->setToolTip(UISoftKeyboard::tr("Layout List")); 2832 2832 if (m_pSettingsButton) 2833 m_pSettingsButton->setToolTip( tr("Settings"));2833 m_pSettingsButton->setToolTip(UISoftKeyboard::tr("Settings")); 2834 2834 } 2835 2835
Note:
See TracChangeset
for help on using the changeset viewer.