Changeset 17784 in vbox for trunk/src/VBox/Frontends/VirtualBox/include
- Timestamp:
- Mar 13, 2009 1:06:28 AM (16 years ago)
- Location:
- trunk/src/VBox/Frontends/VirtualBox/include
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Frontends/VirtualBox/include/VBoxProblemReporter.h
r17730 r17784 263 263 #if defined Q_WS_WIN 264 264 int confirmDeletingHostInterface (const QString &aName, QWidget *aParent = 0); 265 void cannotCreateHostInterface (const CHost &aHost, 266 QWidget *aParent = 0); 267 void cannotCreateHostInterface (const CProgress &aProgress, const QString &aName, 268 QWidget *aParent = 0); 265 void cannotCreateHostInterface (const CHost &aHost, QWidget *aParent = 0); 266 void cannotCreateHostInterface (const CProgress &aProgress, QWidget *aParent = 0); 269 267 void cannotRemoveHostInterface (const CHost &aHost, 270 268 const CHostNetworkInterface &aIface, -
trunk/src/VBox/Frontends/VirtualBox/include/VBoxVMSettingsNetwork.h
r17217 r17784 6 6 7 7 /* 8 * Copyright (C) 200 6-2008 Sun Microsystems, Inc.8 * Copyright (C) 2008 Sun Microsystems, Inc. 9 9 * 10 10 * This file is part of VirtualBox Open Source Edition (OSE), as … … 24 24 #define __VBoxVMSettingsNetwork_h__ 25 25 26 /* VBox Includes */ 27 #include "COMDefs.h" 26 28 #include "VBoxSettingsPage.h" 27 29 #include "VBoxVMSettingsNetwork.gen.h" 28 #include "COMDefs.h"29 30 30 #if defined (Q_WS_WIN) || defined (VBOX_WITH_NETFLT) 31 class QTreeWidget; 32 class QTreeWidgetItem; 33 #endif 31 /* VBox Forwardes */ 32 class VBoxVMSettingsNetworkPage; 33 class VBoxVMSettingsNetworkDetails; 34 34 35 /* 36 * QWidget sub-class which represents one tab-page per each network adapter. 37 * It has generated UI part. 38 */ 39 class VBoxVMSettingsNetwork : public QIWithRetranslateUI<QWidget>, 35 class VBoxVMSettingsNetwork : public QIWithRetranslateUI <QWidget>, 40 36 public Ui::VBoxVMSettingsNetwork 41 37 { … … 44 40 public: 45 41 46 VBoxVMSettingsNetwork ();42 VBoxVMSettingsNetwork (VBoxVMSettingsNetworkPage *aParent); 47 43 48 44 void getFromAdapter (const CNetworkAdapter &aAdapter); 49 45 void putBackToAdapter(); 50 46 51 QString pageTitle() const;52 53 47 void setValidator (QIWidgetValidator *aValidator); 48 bool revalidate (QString &aWarning, QString &aTitle); 54 49 55 50 QWidget* setOrderAfter (QWidget *aAfter); 56 51 57 void setNetworksList (const QStringList &aList); 58 59 #if defined (Q_WS_WIN) || defined (VBOX_WITH_NETFLT) 60 void setInterfaceName (const QString &); 61 QString interfaceName() const; 62 #endif 52 QString pageTitle() const; 53 QString currentName (KNetworkAttachmentType aType = KNetworkAttachmentType_Null) const; 63 54 64 55 protected: … … 68 59 private slots: 69 60 70 void adapterToggled (bool aOn); 71 void naTypeChanged (const QString &aString); 72 void genMACClicked(); 61 void updateCableConnectedState(); 62 void detailsClicked(); 73 63 74 64 private: 75 65 76 void prepareComboboxes(); 66 void populateComboboxes(); 67 KNetworkAttachmentType attachmentType() const; 77 68 78 void setTapEnabled (bool aEnabled); 79 void setTapVisible (bool aVisible); 80 69 VBoxVMSettingsNetworkPage *mParent; 70 VBoxVMSettingsNetworkDetails *mDetails; 81 71 CNetworkAdapter mAdapter; 82 72 QIWidgetValidator *mValidator; 83 84 #if defined (Q_WS_WIN) || defined (VBOX_WITH_NETFLT)85 QString mInterfaceName;86 #endif87 73 }; 88 74 89 90 #if defined (Q_WS_WIN) || defined (VBOX_WITH_NETFLT)91 /*92 * QGroupBox sub-class which represents network interface list.93 */94 class VBoxNIList : public QIWithRetranslateUI<QWidget>95 {96 Q_OBJECT;97 98 public:99 100 VBoxNIList (QWidget *aParent);101 102 bool isWrongInterface() const;103 void setCurrentInterface (const QString &aName);104 #if defined (Q_WS_WIN) && defined(VBOX_WITH_NETFLT)105 void updateInterfacesList(KNetworkAttachmentType enmAttachmentType);106 #endif107 signals:108 109 void listChanged();110 void currentInterfaceChanged (const QString &);111 112 private slots:113 114 void onCurrentItemChanged (QTreeWidgetItem *aCurrent, QTreeWidgetItem *aPrev = 0);115 void addHostInterface();116 void delHostInterface();117 118 protected:119 120 void retranslateUi();121 122 private:123 #if defined (Q_WS_WIN) && defined(VBOX_WITH_NETFLT)124 void populateInterfacesList(KNetworkAttachmentType enmAttachmentType);125 #else126 void populateInterfacesList();127 #endif128 QILabelSeparator *mLbTitle;129 QTreeWidget *mList;130 131 # if defined (Q_WS_WIN)132 QAction *mAddAction;133 QAction *mDelAction;134 # ifdef VBOX_WITH_NETFLT135 KNetworkAttachmentType mEnmAttachmentType;136 # endif137 # endif138 };139 #endif /* Q_WS_WIN || VBOX_WITH_NETFLT */140 141 142 /*143 * QWidget sub-class which represents network settings page itself.144 */145 75 class VBoxVMSettingsNetworkPage : public VBoxSettingsPage 146 76 { … … 151 81 VBoxVMSettingsNetworkPage(); 152 82 83 QStringList natList() const; 84 QStringList netList() const; 85 QStringList intList (KHostNetworkInterfaceType aType) const; 86 153 87 protected: 154 88 … … 156 90 void putBackTo(); 157 91 158 void setValidator (QIWidgetValidator *aVal );92 void setValidator (QIWidgetValidator *aValidator); 159 93 bool revalidate (QString &aWarning, QString &aTitle); 160 94 161 95 void retranslateUi(); 162 96 163 private slots:164 165 void updateNetworksList();166 #if defined (VBOX_WITH_NETFLT)167 void updateInterfaceList();168 #endif169 #if defined (Q_WS_WIN) || defined (VBOX_WITH_NETFLT)170 void onCurrentPageChanged (int);171 void onCurrentInterfaceChanged (const QString &);172 #endif173 174 97 private: 175 98 176 void populateNetworksList(); 177 178 /* Widgets */ 99 QIWidgetValidator *mValidator; 179 100 QTabWidget *mTwAdapters; 180 #if defined (Q_WS_WIN) || defined (VBOX_WITH_NETFLT)181 VBoxNIList *mNIList;182 #endif183 184 /* Widget Validator*/185 QIWidgetValidator *mValidator;186 187 /* Lists */188 QStringList mListNetworks;189 190 /* Flags */191 bool mLockNetworkListUpdate;192 101 }; 193 102
Note:
See TracChangeset
for help on using the changeset viewer.