Changeset 18312 in vbox for trunk/src/VBox/Frontends/VirtualBox
- Timestamp:
- Mar 26, 2009 1:42:44 PM (16 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Frontends/VirtualBox/src/VBoxGLSettingsNetworkDetails.cpp
r18253 r18312 43 43 44 44 /* Setup validators */ 45 mLeIPv4->setValidator (new QRegExpValidator 46 (QRegExp ("\\d{1,3}\\.\\d{1,3}\\.\\d{1,3}\\.\\d{1,3}"), this)); 47 mLeNMv4->setValidator (new QRegExpValidator 48 (QRegExp ("\\d{1,3}\\.\\d{1,3}\\.\\d{1,3}\\.\\d{1,3}"), this)); 49 mLeIPv6->setValidator (new QRegExpValidator 50 (QRegExp ("[0-9a-fA-Z]{1,4}:{1,2}[0-9a-fA-Z]{1,4}:{1,2}" 51 "[0-9a-fA-Z]{1,4}:{1,2}[0-9a-fA-Z]{1,4}:{1,2}" 52 "[0-9a-fA-Z]{1,4}:{1,2}[0-9a-fA-Z]{1,4}:{1,2}" 53 "[0-9a-fA-Z]{1,4}:{1,2}[0-9a-fA-Z]{1,4}"), this)); 54 mLeNMv6->setValidator (new QRegExpValidator 55 (QRegExp ("[1-9][0-9]|1[0-1][0-9]|12[0-8]"), this)); 56 mLeDhcpAddress->setValidator (new QRegExpValidator 57 (QRegExp ("\\d{1,3}\\.\\d{1,3}\\.\\d{1,3}\\.\\d{1,3}"), this)); 58 mLeDhcpMask->setValidator (new QRegExpValidator 59 (QRegExp ("\\d{1,3}\\.\\d{1,3}\\.\\d{1,3}\\.\\d{1,3}"), this)); 60 mLeDhcpLowerAddress->setValidator (new QRegExpValidator 61 (QRegExp ("\\d{1,3}\\.\\d{1,3}\\.\\d{1,3}\\.\\d{1,3}"), this)); 62 mLeDhcpUpperAddress->setValidator (new QRegExpValidator 63 (QRegExp ("\\d{1,3}\\.\\d{1,3}\\.\\d{1,3}\\.\\d{1,3}"), this)); 45 QString templateIPv4 ("([0-9]|[1-9][0-9]|1[0-9][0-9]|2[0-4][0-9]|25[0-5])\\." 46 "([0-9]|[1-9][0-9]|1[0-9][0-9]|2[0-4][0-9]|25[0-5])\\." 47 "([0-9]|[1-9][0-9]|1[0-9][0-9]|2[0-4][0-9]|25[0-5])\\." 48 "([0-9]|[1-9][0-9]|1[0-9][0-9]|2[0-4][0-9]|25[0-5])"); 49 QString templateIPv6 ("[0-9a-fA-Z]{1,4}:{1,2}[0-9a-fA-Z]{1,4}:{1,2}" 50 "[0-9a-fA-Z]{1,4}:{1,2}[0-9a-fA-Z]{1,4}:{1,2}" 51 "[0-9a-fA-Z]{1,4}:{1,2}[0-9a-fA-Z]{1,4}:{1,2}" 52 "[0-9a-fA-Z]{1,4}:{1,2}[0-9a-fA-Z]{1,4}"); 53 54 mLeIPv4->setValidator (new QRegExpValidator (QRegExp (templateIPv4), this)); 55 mLeNMv4->setValidator (new QRegExpValidator (QRegExp (templateIPv4), this)); 56 mLeIPv6->setValidator (new QRegExpValidator (QRegExp (templateIPv6), this)); 57 mLeNMv6->setValidator (new QRegExpValidator (QRegExp ("[1-9][0-9]|1[0-1][0-9]|12[0-8]"), this)); 58 mLeDhcpAddress->setValidator (new QRegExpValidator (QRegExp (templateIPv4), this)); 59 mLeDhcpMask->setValidator (new QRegExpValidator (QRegExp (templateIPv4), this)); 60 mLeDhcpLowerAddress->setValidator (new QRegExpValidator (QRegExp (templateIPv4), this)); 61 mLeDhcpUpperAddress->setValidator (new QRegExpValidator (QRegExp (templateIPv4), this)); 64 62 65 63 /* Setup widgets */
Note:
See TracChangeset
for help on using the changeset viewer.