VirtualBox

Changeset 33958 in vbox


Ignore:
Timestamp:
Nov 11, 2010 9:17:02 AM (14 years ago)
Author:
vboxsync
Message:

FE/Qt: Global settings / Input page refactoring.

Location:
trunk/src/VBox/Frontends/VirtualBox/src/settings/global
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Frontends/VirtualBox/src/settings/global/UIGlobalSettingsGeneral.h

    r33926 r33958  
    6363
    6464    /* Navigation stuff: */
    65     void setOrderAfter (QWidget *aWidget);
     65    void setOrderAfter(QWidget *pWidget);
    6666
    6767    /* Translation stuff: */
  • trunk/src/VBox/Frontends/VirtualBox/src/settings/global/UIGlobalSettingsInput.cpp

    r33882 r33958  
    1818 */
    1919
     20/* Local includes */
    2021#include "UIGlobalSettingsInput.h"
    2122#include "VBoxGlobalSettings.h"
    2223
     24/* Input page constructor: */
    2325UIGlobalSettingsInput::UIGlobalSettingsInput()
    2426{
    25     /* Apply UI decorations */
     27    /* Apply UI decorations: */
    2628    Ui::UIGlobalSettingsInput::setupUi (this);
    2729
    28     /* Applying language settings */
     30    /* Apply language settings: */
    2931    retranslateUi();
    3032}
     
    5052{
    5153    /* Fetch from cache: */
    52     mHeHostKey->setKey(m_cache.m_iHostKey);
    53     mCbAutoGrab->setChecked(m_cache.m_fAutoCapture);
     54    m_pHostKeyEditor->setKey(m_cache.m_iHostKey);
     55    m_pEnableAutoGrabCheckbox->setChecked(m_cache.m_fAutoCapture);
    5456}
    5557
     
    5961{
    6062    /* Upload to cache: */
    61     m_cache.m_iHostKey = mHeHostKey->key();
    62     m_cache.m_fAutoCapture = mCbAutoGrab->isChecked();
     63    m_cache.m_iHostKey = m_pHostKeyEditor->key();
     64    m_cache.m_fAutoCapture = m_pEnableAutoGrabCheckbox->isChecked();
    6365}
    6466
     
    7880}
    7981
    80 void UIGlobalSettingsInput::setOrderAfter (QWidget *aWidget)
     82/* Navigation stuff: */
     83void UIGlobalSettingsInput::setOrderAfter(QWidget *pWidget)
    8184{
    82     setTabOrder (aWidget, mHeHostKey);
    83     setTabOrder (mHeHostKey, mTbResetHostKey);
    84     setTabOrder (mTbResetHostKey, mCbAutoGrab);
     85    setTabOrder(pWidget, m_pHostKeyEditor);
     86    setTabOrder(m_pHostKeyEditor, m_pResetHostKeyButton);
     87    setTabOrder(m_pResetHostKeyButton, m_pEnableAutoGrabCheckbox);
    8588}
    8689
     90/* Translation stuff: */
    8791void UIGlobalSettingsInput::retranslateUi()
    8892{
    89     /* Translate uic generated strings */
     93    /* Translate uic generated strings: */
    9094    Ui::UIGlobalSettingsInput::retranslateUi (this);
    9195}
  • trunk/src/VBox/Frontends/VirtualBox/src/settings/global/UIGlobalSettingsInput.h

    r33882 r33958  
    2020#define __UIGlobalSettingsInput_h__
    2121
     22/* Local includes */
    2223#include "UISettingsPage.h"
    2324#include "UIGlobalSettingsInput.gen.h"
     
    3132
    3233/* Global settings / Input page: */
    33 class UIGlobalSettingsInput : public UISettingsPageGlobal,
    34                             public Ui::UIGlobalSettingsInput
     34class UIGlobalSettingsInput : public UISettingsPageGlobal, public Ui::UIGlobalSettingsInput
    3535{
    3636    Q_OBJECT;
     
    5656    void saveFromCacheTo(QVariant &data);
    5757
    58     void setOrderAfter (QWidget *aWidget);
     58    /* Navigation stuff: */
     59    void setOrderAfter(QWidget *pWidget);
    5960
     61    /* Translation stuff: */
    6062    void retranslateUi();
    6163
  • trunk/src/VBox/Frontends/VirtualBox/src/settings/global/UIGlobalSettingsInput.ui

    r33882 r33958  
    1 <?xml version="1.0" encoding="UTF-8"?>
    21<ui version="4.0">
    32 <comment>
    4  VBox frontends: Qt4 GUI (&quot;VirtualBox&quot;):
     3 VBox frontends: Qt4 GUI ("VirtualBox"):
    54
    6      Copyright (C) 2008 Oracle Corporation
     5     Copyright (C) 2008-2010 Oracle Corporation
    76
    87     This file is part of VirtualBox Open Source Edition (OSE), as
     
    4544   </item>
    4645   <item row="0" column="1">
    47     <widget class="QLabel" name="mLbHostKey">
     46    <widget class="QLabel" name="m_pHostKeyLabel">
    4847     <property name="text">
    4948      <string>Host &amp;Key:</string>
    5049     </property>
    5150     <property name="buddy">
    52       <cstring>mHeHostKey</cstring>
     51      <cstring>m_pHostKeyEditor</cstring>
    5352     </property>
    5453    </widget>
    5554   </item>
    5655   <item row="0" column="2">
    57     <widget class="QIHotKeyEdit" name="mHeHostKey">
     56    <widget class="QIHotKeyEdit" name="m_pHostKeyEditor">
    5857     <property name="whatsThis">
    5958      <string>Displays the key used as a Host Key in the VM window. Activate the entry field and press a new Host Key. Note that alphanumeric, cursor movement and editing keys cannot be used.</string>
     59     </property>
     60     <property name="sizePolicy">
     61      <sizepolicy hsizetype="MinimumExpanding" vsizetype="Minimum">
     62       <horstretch>0</horstretch>
     63       <verstretch>0</verstretch>
     64      </sizepolicy>
    6065     </property>
    6166    </widget>
    6267   </item>
    6368   <item row="0" column="3">
    64     <widget class="UIResetButton" name="mTbResetHostKey">
     69    <widget class="UIResetButton" name="m_pResetHostKeyButton">
    6570     <property name="focusPolicy">
    6671      <enum>Qt::StrongFocus</enum>
     
    8287      <enum>Qt::Horizontal</enum>
    8388     </property>
     89     <property name="sizeType">
     90      <enum>QSizePolicy::Fixed</enum>
     91     </property>
    8492     <property name="sizeHint" stdset="0">
    8593      <size>
    86        <width>0</width>
     94       <width>40</width>
    8795       <height>20</height>
    8896      </size>
     
    9199   </item>
    92100   <item row="1" column="2" colspan="3">
    93     <widget class="QCheckBox" name="mCbAutoGrab">
     101    <widget class="QCheckBox" name="m_pEnableAutoGrabCheckbox">
    94102     <property name="whatsThis">
    95103      <string>When checked, the keyboard is automatically captured every time the VM window is activated. When the keyboard is captured, all keystrokes (including system ones like Alt-Tab) are directed to the VM.</string>
     
    107115     <property name="sizeHint" stdset="0">
    108116      <size>
    109        <width>121</width>
    110        <height>271</height>
     117       <width>0</width>
     118       <height>0</height>
    111119      </size>
    112120     </property>
     
    132140 <connections>
    133141  <connection>
    134    <sender>mTbResetHostKey</sender>
     142   <sender>m_pResetHostKeyButton</sender>
    135143   <signal>clicked(bool)</signal>
    136    <receiver>mHeHostKey</receiver>
     144   <receiver>m_pHostKeyEditor</receiver>
    137145   <slot>clear()</slot>
    138146   <hints>
Note: See TracChangeset for help on using the changeset viewer.

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