VirtualBox

Changeset 71191 in vbox for trunk/src/VBox


Ignore:
Timestamp:
Mar 5, 2018 8:34:54 AM (7 years ago)
Author:
vboxsync
svn:sync-xref-src-repo-rev:
121096
Message:

FE/Qt bugref:6699 Adding actions to file table toolbars

Location:
trunk/src/VBox/Frontends/VirtualBox/src/runtime/information/guestctrl
Files:
8 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Frontends/VirtualBox/src/runtime/information/guestctrl/UIGuestControlConsole.cpp

    r71145 r71191  
    259259    const QList<QString> &matches = matchedWords(currentWord);
    260260    /* If there are no matches do nothing: */
    261     if(matches.empty())
     261    if (matches.empty())
    262262        return;
    263263    /* if there are more than one match list them all and
    264264       reprint the line: */
    265     if(matches.size() > 1)
     265    if (matches.size() > 1)
    266266    {
    267267        moveCursor(QTextCursor::End);
    268268        QString strMatches;
    269         for(int i = 0; i < matches.size(); ++i)
     269        for (int i = 0; i < matches.size(); ++i)
    270270        {
    271271            strMatches.append(matches.at(i));
     
    284284    /* if there is only one word just complete: */
    285285    /* some sanity checks */
    286     if(matches.at(0).length() > currentWord.length())
     286    if (matches.at(0).length() > currentWord.length())
    287287       insertPlainText(matches.at(0).right(matches.at(0).length() - currentWord.length()));
    288288}
     
    293293    QList<QString> list;
    294294    /* Go thru the map and find which of its elements start with @pstrSearch: */
    295     for(TabDictionary::const_iterator iterator = m_tabDictinary.begin();
     295    for (TabDictionary::const_iterator iterator = m_tabDictinary.begin();
    296296        iterator != m_tabDictinary.end(); ++iterator)
    297297    {
    298298        const QString &strMap = iterator.key();
    299         if(strMap.startsWith(strSearch))
     299        if (strMap.startsWith(strSearch))
    300300            list.push_back(strMap);
    301301    }
  • trunk/src/VBox/Frontends/VirtualBox/src/runtime/information/guestctrl/UIGuestControlFileManager.cpp

    r71185 r71191  
    3434# include "QIWithRetranslateUI.h"
    3535# include "UIExtraDataManager.h"
     36# include "UIIconPool.h"
    3637# include "UIGuestControlFileManager.h"
    3738# include "UIGuestControlFileTable.h"
    3839# include "UIGuestControlInterface.h"
     40# include "UIToolBar.h"
    3941# include "UIVMInformationDialog.h"
    4042# include "VBoxGlobal.h"
     
    159161void UIGuestSessionCreateWidget::sltCreateButtonClick()
    160162{
    161     if(m_pUserNameEdit && m_pPasswordEdit)
     163    if (m_pUserNameEdit && m_pPasswordEdit)
    162164        emit sigCreateSession(m_pUserNameEdit->text(), m_pPasswordEdit->text());
    163165}
     
    183185        m_pPasswordLabel->setText(UIVMInformationDialog::tr("Password"));
    184186    }
    185     if(m_pCreateButton)
     187    if (m_pCreateButton)
    186188        m_pCreateButton->setText(UIVMInformationDialog::tr("Create Session"));
    187     if(m_pCloseButton)
     189    if (m_pCloseButton)
    188190        m_pCloseButton->setText(UIVMInformationDialog::tr("Close Session"));
    189191
     
    216218
    217219UIGuestControlFileManager::UIGuestControlFileManager(QWidget *pParent, const CGuest &comGuest)
    218     : QWidget(pParent)
     220    : QIWithRetranslateUI<QWidget>(pParent)
    219221    , m_iMaxRecursionDepth(1)
    220222    , m_comGuest(comGuest)
     
    222224    , m_pVerticalSplitter(0)
    223225    , m_pLogOutput(0)
     226    , m_pToolBar(0)
     227    , m_pCopyGuestToHost(0)
    224228    , m_pSessionCreateWidget(0)
    225229    , m_pGuestFileTable(0)
     
    229233    prepareObjects();
    230234    prepareConnections();
     235    retranslateUi();
    231236}
    232237
    233238UIGuestControlFileManager::~UIGuestControlFileManager()
    234239{
    235     if(m_comGuest.isOk() && m_pQtGuestListener && m_comGuestListener.isOk())
     240    if (m_comGuest.isOk() && m_pQtGuestListener && m_comGuestListener.isOk())
    236241        cleanupListener(m_pQtGuestListener, m_comGuestListener, m_comGuest.GetEventSource());
    237     if(m_comGuestSession.isOk() && m_pQtSessionListener && m_comSessionListener.isOk())
     242    if (m_comGuestSession.isOk() && m_pQtSessionListener && m_comSessionListener.isOk())
    238243        cleanupListener(m_pQtSessionListener, m_comSessionListener, m_comGuestSession.GetEventSource());
    239244}
    240245
     246void UIGuestControlFileManager::retranslateUi()
     247{
     248    if (m_pCopyGuestToHost)
     249    {
     250        m_pCopyGuestToHost->setText(UIVMInformationDialog::tr("Copy the selected object from guest to host"));
     251        m_pCopyGuestToHost->setToolTip(UIVMInformationDialog::tr("Copy the selected object from guest to host"));
     252        m_pCopyGuestToHost->setStatusTip(UIVMInformationDialog::tr("Copy the selected object from guest to host"));
     253    }
     254
     255    if (m_pCopyHostToGuest)
     256    {
     257        m_pCopyHostToGuest->setText(UIVMInformationDialog::tr("Copy the selected object from host to guest"));
     258        m_pCopyHostToGuest->setToolTip(UIVMInformationDialog::tr("Copy the selected object from host to guest"));
     259        m_pCopyHostToGuest->setStatusTip(UIVMInformationDialog::tr("Copy the selected object from host to guest"));
     260    }
     261
     262}
     263
    241264void UIGuestControlFileManager::prepareGuestListener()
    242265{
    243     if(m_comGuest.isOk())
     266    if (m_comGuest.isOk())
    244267    {
    245268        QVector<KVBoxEventType> eventTypes;
     
    277300    QWidget *fileTableContainer = new QWidget;
    278301    QHBoxLayout *containerLayout = new QHBoxLayout;
    279     if(fileTableContainer)
    280     {
    281         if(containerLayout)
     302    if (fileTableContainer)
     303    {
     304        if (containerLayout)
    282305        {
    283306            fileTableContainer->setLayout(containerLayout);
     
    287310            if (m_pGuestFileTable)
    288311                containerLayout->addWidget(m_pGuestFileTable);
     312
     313            m_pToolBar = new UIToolBar;
     314            if (m_pToolBar)
     315            {
     316                m_pToolBar->setOrientation(Qt::Vertical);
     317
     318                /* Add to dummy QWidget to toolbar to center the action icons vertically: */
     319                QWidget *topSpacerWidget = new QWidget(this);
     320                topSpacerWidget->setSizePolicy(QSizePolicy::Preferred, QSizePolicy::Expanding);
     321                topSpacerWidget->setVisible(true);
     322                QWidget *bottomSpacerWidget = new QWidget(this);
     323                bottomSpacerWidget->setSizePolicy(QSizePolicy::Preferred, QSizePolicy::Expanding);
     324                bottomSpacerWidget->setVisible(true);
     325
     326
     327
     328                m_pCopyGuestToHost = new QAction(this);
     329                m_pCopyGuestToHost->setIcon(UIIconPool::iconSet(QString(":/arrow_right_10px_x2.png")));
     330                m_pCopyHostToGuest = new QAction(this);
     331                m_pCopyHostToGuest->setIcon(UIIconPool::iconSet(QString(":/arrow_left_10px_x2.png")));
     332
     333
     334                m_pToolBar->addWidget(topSpacerWidget);
     335                m_pToolBar->addAction(m_pCopyGuestToHost);
     336                m_pToolBar->addAction(m_pCopyHostToGuest);
     337                m_pToolBar->addWidget(bottomSpacerWidget);
     338
     339
     340                containerLayout->addWidget(m_pToolBar);
     341            }
     342
    289343            m_pHostFileTable = new UIHostFileTable;
    290344            if (m_pHostFileTable)
     
    315369                this, &UIGuestControlFileManager::sltGuestSessionUnregistered, Qt::DirectConnection);
    316370    }
    317     if(m_pSessionCreateWidget)
     371    if (m_pSessionCreateWidget)
    318372    {
    319373        connect(m_pSessionCreateWidget, &UIGuestSessionCreateWidget::sigCreateSession,
     
    328382    if (!guestSession.isOk())
    329383        return;
    330     if(guestSession == m_comGuestSession && m_comGuestSession.isOk())
     384    if (guestSession == m_comGuestSession && m_comGuestSession.isOk())
    331385        m_comGuestSession.detach();
    332386    if (m_pSessionCreateWidget)
     
    336390void UIGuestControlFileManager::sltCreateSession(QString strUserName, QString strPassword)
    337391{
    338     if(strUserName.isEmpty())
     392    if (strUserName.isEmpty())
    339393    {
    340394        m_pLogOutput->appendPlainText("No user name is given");
     
    354408        m_pGuestFileTable->reset();
    355409
    356     if(m_comGuestSession.isOk() && m_pQtSessionListener && m_comSessionListener.isOk())
     410    if (m_comGuestSession.isOk() && m_pQtSessionListener && m_comSessionListener.isOk())
    357411        cleanupListener(m_pQtSessionListener, m_comSessionListener, m_comGuestSession.GetEventSource());
    358412
    359413    m_comGuestSession.Close();
    360414    m_pLogOutput->appendPlainText("Guest session is closed");
    361     if(m_pSessionCreateWidget)
     415    if (m_pSessionCreateWidget)
    362416        m_pSessionCreateWidget->switchSessionCreateMode();
    363417}
     
    409463
    410464    m_pLogOutput->appendPlainText("Guest session has been created");
    411     if(m_pSessionCreateWidget)
     465    if (m_pSessionCreateWidget)
    412466        m_pSessionCreateWidget->switchSessionCloseMode();
    413467
  • trunk/src/VBox/Frontends/VirtualBox/src/runtime/information/guestctrl/UIGuestControlFileManager.h

    r71185 r71191  
    3030
    3131/* GUI includes: */
     32#include "QIWithRetranslateUI.h"
    3233#include "UIMainEventListener.h"
    3334
     
    4041class UIHostFileTable;
    4142class UIGuestSessionCreateWidget;
     43class UIToolBar;
    4244
    4345/** QWidget extension
    4446  * providing GUI with guest session information and control tab in session-information window. */
    45 class UIGuestControlFileManager : public QWidget
     47class UIGuestControlFileManager : public QIWithRetranslateUI<QWidget>
    4648{
    4749    Q_OBJECT;
     
    5153    UIGuestControlFileManager(QWidget *pParent, const CGuest &comGuest);
    5254    ~UIGuestControlFileManager();
     55
     56protected:
     57
     58    void retranslateUi();
    5359
    5460private slots:
     
    8995    QSplitter        *m_pVerticalSplitter;
    9096    QPlainTextEdit   *m_pLogOutput;
     97    UIToolBar        *m_pToolBar;
     98    QAction          *m_pCopyGuestToHost;
     99    QAction          *m_pCopyHostToGuest;
    91100
    92101    UIGuestSessionCreateWidget *m_pSessionCreateWidget;
  • trunk/src/VBox/Frontends/VirtualBox/src/runtime/information/guestctrl/UIGuestControlFileTable.cpp

    r71187 r71191  
    2525# include <QHeaderView>
    2626# include <QItemDelegate>
    27 # include <QVBoxLayout>
     27# include <QGridLayout>
    2828
    2929/* GUI includes: */
     30# include "QILabel.h"
    3031# include "QILineEdit.h"
    3132# include "UIIconPool.h"
    3233# include "UIGuestControlFileTable.h"
    3334# include "UIToolBar.h"
     35# include "UIVMInformationDialog.h"
    3436
    3537/* COM includes: */
     
    236238    if (role == Qt::DecorationRole && index.column() == 0)
    237239    {
    238         if (item->isDirectory() && !item->isUpDirectory())
    239             return QIcon(":/sf_32px.png");
    240         if (!item->isDirectory())
     240        if (item->isDirectory())
     241        {
     242            if (item->isUpDirectory())
     243                return QIcon(":/arrow_up_10px_x2.png");
     244            else
     245                return QIcon(":/sf_32px.png");
     246        }
     247        else
    241248            return QIcon(":/vm_open_filemanager_16px");
    242249    }
     
    351358    , m_pModel(0)
    352359    , m_pTree(0)
     360    , m_pLocationLabel(0)
    353361    , m_pMainLayout(0)
    354362    , m_pCurrentLocationEdit(0)
    355363    , m_pToolBar(0)
     364    , m_pRefresh(0)
     365    , m_pDelete(0)
     366    , m_pNewFolder(0)
     367    , m_pGoUp(0)
     368    , m_pCopy(0)
     369    , m_pCut(0)
     370    , m_pPaste(0)
     371
    356372{
    357373    prepareObjects();
     374    prepareActions();
    358375}
    359376
     
    365382void UIGuestControlFileTable::reset()
    366383{
    367     if(m_pModel)
     384    if (m_pModel)
    368385        m_pModel->beginReset();
    369386    delete m_pRootItem;
    370387    m_pRootItem = 0;
    371     if(m_pModel)
     388    if (m_pModel)
    372389        m_pModel->endReset();
    373     if(m_pCurrentLocationEdit)
     390    if (m_pCurrentLocationEdit)
    374391        m_pCurrentLocationEdit->clear();
    375392}
     
    377394void UIGuestControlFileTable::prepareObjects()
    378395{
    379     m_pMainLayout = new QVBoxLayout();
     396    m_pMainLayout = new QGridLayout();
    380397    if (!m_pMainLayout)
    381398        return;
     
    384401    setLayout(m_pMainLayout);
    385402
    386 
    387403    m_pToolBar = new UIToolBar;
    388404    if (m_pToolBar)
    389405    {
    390         m_pMainLayout->addWidget(m_pToolBar);
    391     }
    392     m_pActionRefresh = new QAction(this);
    393     m_pActionRefresh->setIcon(UIIconPool::iconSet(QString(":/refresh_22px.png")));
    394 
    395     m_pToolBar->addAction(m_pActionRefresh);
    396 
    397 
    398 
     406        m_pMainLayout->addWidget(m_pToolBar, 0, 0, 1, 5);
     407    }
     408
     409    m_pLocationLabel = new QILabel;
     410    if (m_pLocationLabel)
     411    {
     412        m_pMainLayout->addWidget(m_pLocationLabel, 1, 0, 1, 1);
     413    }
    399414
    400415    m_pCurrentLocationEdit = new QILineEdit;
    401     if(m_pCurrentLocationEdit)
    402     {
    403         m_pMainLayout->addWidget(m_pCurrentLocationEdit);
     416    if (m_pCurrentLocationEdit)
     417    {
     418        m_pMainLayout->addWidget(m_pCurrentLocationEdit, 1, 1, 1, 4);
    404419        m_pCurrentLocationEdit->setReadOnly(true);
    405420    }
     
    417432        m_pView->verticalHeader()->setVisible(false);
    418433
    419         m_pMainLayout->addWidget(m_pView);
     434        m_pMainLayout->addWidget(m_pView, 2, 0, 5, 5);
    420435        m_pView->setModel(m_pModel);
    421436        m_pView->setItemDelegate(new UIFileDelegate);
     
    431446}
    432447
     448void UIGuestControlFileTable::prepareActions()
     449{
     450    if (!m_pToolBar)
     451        return;
     452
     453    m_pGoUp = new QAction(this);
     454    m_pGoUp->setIcon(UIIconPool::iconSet(QString(":/arrow_up_10px_x2.png")));
     455    m_pToolBar->addAction(m_pGoUp);
     456
     457
     458    m_pRefresh = new QAction(this);
     459    m_pRefresh->setIcon(UIIconPool::iconSet(QString(":/refresh_22px.png")));
     460    m_pToolBar->addAction(m_pRefresh);
     461
     462    m_pDelete = new QAction(this);
     463    m_pDelete->setIcon(UIIconPool::iconSet(QString(":/vm_delete_32px.png")));
     464    m_pToolBar->addAction(m_pDelete);
     465
     466    m_pNewFolder = new QAction(this);
     467    m_pNewFolder->setIcon(UIIconPool::iconSet(QString(":/sf_32px.png")));
     468    m_pToolBar->addAction(m_pNewFolder);
     469
     470    m_pCopy = new QAction(this);
     471    m_pCopy->setIcon(UIIconPool::iconSet(QString(":/fd_copy_22px.png")));
     472    m_pToolBar->addAction(m_pCopy);
     473
     474    m_pCut = new QAction(this);
     475    m_pCut->setIcon(UIIconPool::iconSet(QString(":/fd_move_22px.png")));
     476    m_pToolBar->addAction(m_pCut);
     477
     478
     479    m_pPaste = new QAction(this);
     480    m_pPaste->setIcon(UIIconPool::iconSet(QString(":/shared_clipboard_16px.png")));
     481    m_pToolBar->addAction(m_pPaste);
     482}
     483
    433484void UIGuestControlFileTable::updateCurrentLocationEdit(const QString& strLocation)
    434485{
     
    440491void UIGuestControlFileTable::changeLocation(const QModelIndex &index)
    441492{
    442     if(!index.isValid() || !m_pView)
     493    if (!index.isValid() || !m_pView)
    443494        return;
    444495    m_pView->setRootIndex(index);
     
    446497
    447498    UIFileTableItem *item = static_cast<UIFileTableItem*>(index.internalPointer());
    448     if(item)
     499    if (item)
    449500    {
    450501        updateCurrentLocationEdit(item->path());
     
    455506void UIGuestControlFileTable::initializeFileTree()
    456507{
    457     if(m_pRootItem)
     508    if (m_pRootItem)
    458509        reset();
    459510
     
    498549        }
    499550    }
    500     for(QMap<QString,UIFileTableItem*>::const_iterator iterator = map.begin();
     551    for (QMap<QString,UIFileTableItem*>::const_iterator iterator = map.begin();
    501552        iterator != map.end(); ++iterator)
    502553    {
    503         if(iterator.key() == "." || iterator.key().isEmpty())
     554        if (iterator.key() == "." || iterator.key().isEmpty())
    504555            continue;
    505556        parent->appendChild(iterator.value());
     
    526577    if (!item->isDirectory())
    527578        return;
    528     if(!item->isOpened())
     579    if (!item->isOpened())
    529580       readDirectory(item->path(),item);
    530581
     
    534585void UIGuestControlFileTable::retranslateUi()
    535586{
    536     // if (m_pUserNameEdit)
    537     // {
    538     //     m_pUserNameEdit->setToolTip(UIVMInformationDialog::tr("User name to authenticate session creation"));
    539     // }
     587    if (m_pRefresh)
     588    {
     589        m_pRefresh->setText(UIVMInformationDialog::tr("Refresh"));
     590        m_pRefresh->setToolTip(UIVMInformationDialog::tr("Refresh the current directory"));
     591        m_pRefresh->setStatusTip(UIVMInformationDialog::tr("Refresh the current directory"));
     592    }
     593    if (m_pDelete)
     594    {
     595        m_pDelete->setText(UIVMInformationDialog::tr("Delete"));
     596        m_pDelete->setToolTip(UIVMInformationDialog::tr("Delete the selected item"));
     597        m_pDelete->setStatusTip(UIVMInformationDialog::tr("Delete the selected item"));
     598    }
     599
     600    if (m_pNewFolder)
     601    {
     602        m_pNewFolder->setText(UIVMInformationDialog::tr("Create a new folder"));
     603        m_pNewFolder->setToolTip(UIVMInformationDialog::tr("Create a new folder"));
     604        m_pNewFolder->setStatusTip(UIVMInformationDialog::tr("Create a new folder"));
     605
     606    }
     607    if (m_pGoUp)
     608    {
     609        m_pGoUp->setText(UIVMInformationDialog::tr("Move one level up"));
     610        m_pGoUp->setToolTip(UIVMInformationDialog::tr("Move one level up"));
     611        m_pGoUp->setStatusTip(UIVMInformationDialog::tr("Move one level up"));
     612
     613    }
     614
     615    if (m_pCopy)
     616    {
     617        m_pCopy->setText(UIVMInformationDialog::tr("Copy the selected item"));
     618        m_pCopy->setToolTip(UIVMInformationDialog::tr("Copy the selected item"));
     619        m_pCopy->setStatusTip(UIVMInformationDialog::tr("Copy the selected item"));
     620
     621    }
     622
     623    if (m_pCut)
     624    {
     625        m_pCut->setText(UIVMInformationDialog::tr("Cut the selected item"));
     626        m_pCut->setToolTip(UIVMInformationDialog::tr("Cut the selected item"));
     627        m_pCut->setStatusTip(UIVMInformationDialog::tr("Cut the selected item"));
     628
     629    }
     630
     631    if ( m_pPaste)
     632    {
     633        m_pPaste->setText(UIVMInformationDialog::tr("Paste the copied item"));
     634        m_pPaste->setToolTip(UIVMInformationDialog::tr("Paste the copied item"));
     635        m_pPaste->setStatusTip(UIVMInformationDialog::tr("Paste the copied item"));
     636    }
    540637
    541638}
     
    549646    :UIGuestControlFileTable(pParent)
    550647{
     648    retranslateUi();
    551649}
    552650
     
    561659
    562660    initializeFileTree();
     661}
     662
     663void UIGuestFileTable::retranslateUi()
     664{
     665    if (m_pLocationLabel)
     666        m_pLocationLabel->setText(UIVMInformationDialog::tr("Guest System"));
     667    UIGuestControlFileTable::retranslateUi();
    563668}
    564669
     
    618723{
    619724    initializeFileTree();
     725    retranslateUi();
     726}
     727
     728void UIHostFileTable::retranslateUi()
     729{
     730    if (m_pLocationLabel)
     731        m_pLocationLabel->setText(UIVMInformationDialog::tr("Host System"));
     732    UIGuestControlFileTable::retranslateUi();
    620733}
    621734
     
    634747
    635748
    636     for(int i = 0; i < entries.size(); ++i)
     749    for (int i = 0; i < entries.size(); ++i)
    637750    {
    638751        const QFileInfo &fileInfo = entries.at(i);
  • trunk/src/VBox/Frontends/VirtualBox/src/runtime/information/guestctrl/UIGuestControlFileTable.h

    r71186 r71191  
    3434/* Forward declarations: */
    3535class QAction;
     36class QILabel;
    3637class QILineEdit;
    37 class QVBoxLayout;
     38class QGridLayout;
    3839class UIFileTableItem;
    3940class UIGuestControlFileTable;
     
    7576};
    7677
    77 /** This serves a base class for file table. Currently a guest version
     78/** This class serves a base class for file table. Currently a guest version
    7879    and a host version are derived from this base. Each of these children
    7980    populates the UIGuestControlFileModel by scanning the file system
     
    108109    UIGuestControlFileModel *m_pModel;
    109110    QTreeView               *m_pTree;
     111    QILabel                 *m_pLocationLabel;
    110112
    111113protected slots:
     
    115117private:
    116118
    117     void           prepareObjects();
    118     QVBoxLayout    *m_pMainLayout;
     119    void            prepareObjects();
     120    void            prepareActions();
     121    QGridLayout    *m_pMainLayout;
    119122    QILineEdit     *m_pCurrentLocationEdit;
    120123    UIToolBar      *m_pToolBar;
    121     QAction        *m_pActionRefresh;
     124    QAction        *m_pRefresh;
     125    QAction        *m_pDelete;
     126    QAction        *m_pNewFolder;
     127    QAction        *m_pGoUp;
     128    QAction        *m_pCopy;
     129    QAction        *m_pCut;
     130    QAction        *m_pPaste;
    122131
    123132    friend class UIGuestControlFileModel;
     
    137146protected:
    138147
     148    void retranslateUi() /* override */;
    139149    virtual void readDirectory(const QString& strPath, UIFileTableItem *parent, bool isStartDir = false) /* override */;
    140150
     
    156166protected:
    157167
     168    void retranslateUi() /* override */;
    158169    virtual void readDirectory(const QString& strPath, UIFileTableItem *parent, bool isStartDir = false) /* override */;
    159170
  • trunk/src/VBox/Frontends/VirtualBox/src/runtime/information/guestctrl/UIGuestControlInterface.cpp

    r71181 r71191  
    467467
    468468    QVector<CGuestSession> sessions = m_comGuest.GetSessions();
    469     for(int i = 0; i < sessions.size(); ++i)
     469    for (int i = 0; i < sessions.size(); ++i)
    470470    {
    471471        if (sessions[i].isOk() && sessions[i].GetStatus() == KGuestSessionStatus_Started)
     
    644644    if (!m_comGuest.isOk())
    645645        return false;
    646     if(commandData.m_strUserName.isEmpty())
     646    if (commandData.m_strUserName.isEmpty())
    647647        RETURN_ERROR("No user name has been given");
    648648    CGuestSession guestSession = m_comGuest.CreateSession(commandData.m_strUserName,
  • trunk/src/VBox/Frontends/VirtualBox/src/runtime/information/guestctrl/UIGuestControlTreeItem.cpp

    r71100 r71191  
    248248        return;
    249249    QVector<CGuestProcess> processes = m_comGuestSession.GetProcesses();
    250     for(int  i =0; i < processes.size(); ++i)
     250    for (int  i =0; i < processes.size(); ++i)
    251251        addGuestProcess(processes[i]);
    252252}
  • trunk/src/VBox/Frontends/VirtualBox/src/runtime/information/guestctrl/UIGuestControlWidget.cpp

    r71101 r71191  
    147147    void expandCollapseAll(bool bFlag)
    148148    {
    149         for(int i = 0; i < topLevelItemCount(); ++i)
     149        for (int i = 0; i < topLevelItemCount(); ++i)
    150150        {
    151151            if (!topLevelItem(i))
Note: See TracChangeset for help on using the changeset viewer.

© 2025 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette