[PC-BSD Commits] r5070 - pcbsd/trunk/SysInstaller

svn at pcbsd.org svn at pcbsd.org
Wed Nov 18 12:32:54 PST 2009


Author: kris
Date: 2009-11-18 12:32:53 -0800 (Wed, 18 Nov 2009)
New Revision: 5070

Modified:
   pcbsd/trunk/SysInstaller/sysinstaller.cpp
   pcbsd/trunk/SysInstaller/sysinstaller.ui
Log:

Updated the UI on the install type page further, now show / hide nic options



Modified: pcbsd/trunk/SysInstaller/sysinstaller.cpp
===================================================================
--- pcbsd/trunk/SysInstaller/sysinstaller.cpp	2009-11-18 19:56:14 UTC (rev 5069)
+++ pcbsd/trunk/SysInstaller/sysinstaller.cpp	2009-11-18 20:32:53 UTC (rev 5070)
@@ -111,6 +111,9 @@
 
     setKbDefaults();
 
+    // Hide the network options until the user selects it
+    slotChangedInstallSource();
+
     // load drives
     comboDiskList->clear();
     sysDisks = Scripts::Backend::hardDrives();
@@ -253,6 +256,13 @@
 
 void SysInstaller::slotChangedInstallSource()
 {
+  // Check the type of source we have selected and show the widget below for networking
+  if ( radioDVDUSBInstall->isChecked())
+  {
+    stackedWidgetNetOptions->setCurrentIndex(1);
+  } else {
+    stackedWidgetNetOptions->setCurrentIndex(0);
+  }
 
 }
 

Modified: pcbsd/trunk/SysInstaller/sysinstaller.ui
===================================================================
--- pcbsd/trunk/SysInstaller/sysinstaller.ui	2009-11-18 19:56:14 UTC (rev 5069)
+++ pcbsd/trunk/SysInstaller/sysinstaller.ui	2009-11-18 20:32:53 UTC (rev 5070)
@@ -1075,6 +1075,9 @@
                        <property name="orientation">
                         <enum>Qt::Vertical</enum>
                        </property>
+                       <property name="sizeType">
+                        <enum>QSizePolicy::Preferred</enum>
+                       </property>
                        <property name="sizeHint" stdset="0">
                         <size>
                          <width>328</width>
@@ -1136,90 +1139,96 @@
                       </widget>
                      </item>
                      <item row="2" column="0" colspan="2">
-                      <widget class="QWidget" name="widgetNetOptions" native="true">
-                       <layout class="QGridLayout" name="gridLayout_8">
-                        <item row="1" column="1">
-                         <widget class="QGroupBox" name="groupBox_2">
-                          <property name="title">
-                           <string/>
-                          </property>
-                          <layout class="QGridLayout" name="gridLayout_4">
-                           <item row="0" column="0">
-                            <widget class="QLabel" name="label_18">
-                             <property name="text">
-                              <string>Network Inferface</string>
-                             </property>
-                            </widget>
-                           </item>
-                           <item row="0" column="2">
-                            <spacer name="horizontalSpacer_22">
-                             <property name="orientation">
-                              <enum>Qt::Horizontal</enum>
-                             </property>
-                             <property name="sizeType">
-                              <enum>QSizePolicy::MinimumExpanding</enum>
-                             </property>
-                             <property name="sizeHint" stdset="0">
-                              <size>
-                               <width>101</width>
-                               <height>23</height>
-                              </size>
-                             </property>
-                            </spacer>
-                           </item>
-                           <item row="1" column="0">
-                            <widget class="QLabel" name="label_19">
-                             <property name="text">
-                              <string>IP Address</string>
-                             </property>
-                            </widget>
-                           </item>
-                           <item row="1" column="1" colspan="3">
-                            <widget class="QLineEdit" name="lineIP"/>
-                           </item>
-                           <item row="2" column="0">
-                            <widget class="QLabel" name="label_20">
-                             <property name="text">
-                              <string>Netmask</string>
-                             </property>
-                            </widget>
-                           </item>
-                           <item row="2" column="1" colspan="3">
-                            <widget class="QLineEdit" name="lineNetmask"/>
-                           </item>
-                           <item row="3" column="0">
-                            <widget class="QLabel" name="label_21">
-                             <property name="text">
-                              <string>Nameserver (DNS)</string>
-                             </property>
-                            </widget>
-                           </item>
-                           <item row="3" column="1" colspan="3">
-                            <widget class="QLineEdit" name="lineDNS"/>
-                           </item>
-                           <item row="4" column="0">
-                            <widget class="QLabel" name="label_22">
-                             <property name="text">
-                              <string>Gateway</string>
-                             </property>
-                            </widget>
-                           </item>
-                           <item row="4" column="1" colspan="3">
-                            <widget class="QLineEdit" name="lineDefaultRouter"/>
-                           </item>
-                           <item row="0" column="3">
-                            <widget class="QComboBox" name="comboSelectNic">
-                             <item>
+                      <widget class="QStackedWidget" name="stackedWidgetNetOptions">
+                       <property name="currentIndex">
+                        <number>0</number>
+                       </property>
+                       <widget class="QWidget" name="stackedWidgetNetOptionsPage1" native="true">
+                        <layout class="QGridLayout" name="gridLayout_8">
+                         <item row="1" column="1">
+                          <widget class="QGroupBox" name="groupBox_2">
+                           <property name="title">
+                            <string/>
+                           </property>
+                           <layout class="QGridLayout" name="gridLayout_4">
+                            <item row="0" column="0">
+                             <widget class="QLabel" name="label_18">
                               <property name="text">
-                               <string>AUTO-DHCP</string>
+                               <string>Network Inferface</string>
                               </property>
-                             </item>
-                            </widget>
-                           </item>
-                          </layout>
-                         </widget>
-                        </item>
-                       </layout>
+                             </widget>
+                            </item>
+                            <item row="0" column="2">
+                             <spacer name="horizontalSpacer_22">
+                              <property name="orientation">
+                               <enum>Qt::Horizontal</enum>
+                              </property>
+                              <property name="sizeType">
+                               <enum>QSizePolicy::MinimumExpanding</enum>
+                              </property>
+                              <property name="sizeHint" stdset="0">
+                               <size>
+                                <width>101</width>
+                                <height>23</height>
+                               </size>
+                              </property>
+                             </spacer>
+                            </item>
+                            <item row="1" column="0">
+                             <widget class="QLabel" name="label_19">
+                              <property name="text">
+                               <string>IP Address</string>
+                              </property>
+                             </widget>
+                            </item>
+                            <item row="1" column="1" colspan="3">
+                             <widget class="QLineEdit" name="lineIP"/>
+                            </item>
+                            <item row="2" column="0">
+                             <widget class="QLabel" name="label_20">
+                              <property name="text">
+                               <string>Netmask</string>
+                              </property>
+                             </widget>
+                            </item>
+                            <item row="2" column="1" colspan="3">
+                             <widget class="QLineEdit" name="lineNetmask"/>
+                            </item>
+                            <item row="3" column="0">
+                             <widget class="QLabel" name="label_21">
+                              <property name="text">
+                               <string>Nameserver (DNS)</string>
+                              </property>
+                             </widget>
+                            </item>
+                            <item row="3" column="1" colspan="3">
+                             <widget class="QLineEdit" name="lineDNS"/>
+                            </item>
+                            <item row="4" column="0">
+                             <widget class="QLabel" name="label_22">
+                              <property name="text">
+                               <string>Gateway</string>
+                              </property>
+                             </widget>
+                            </item>
+                            <item row="4" column="1" colspan="3">
+                             <widget class="QLineEdit" name="lineDefaultRouter"/>
+                            </item>
+                            <item row="0" column="3">
+                             <widget class="QComboBox" name="comboSelectNic">
+                              <item>
+                               <property name="text">
+                                <string>AUTO-DHCP</string>
+                               </property>
+                              </item>
+                             </widget>
+                            </item>
+                           </layout>
+                          </widget>
+                         </item>
+                        </layout>
+                       </widget>
+                       <widget class="QWidget" name="page_4"/>
                       </widget>
                      </item>
                     </layout>



More information about the Commits mailing list