From: <cod...@go...> - 2008-08-30 23:12:43
|
Author: uelsk8s Date: Sat Aug 30 16:12:21 2008 New Revision: 158 Added: branches/iVL/FrmRootPass.class branches/iVL/FrmRootPass.form Modified: branches/iVL/FMain.class branches/iVL/FrmZoneSet.class branches/iVL/FrmZoneSet.form Log: added root passwd module Modified: branches/iVL/FMain.class ============================================================================== --- branches/iVL/FMain.class (original) +++ branches/iVL/FMain.class Sat Aug 30 16:12:21 2008 @@ -256,7 +256,11 @@ CASE "FrmZoneSet" 'MdlZoneSet.TIME_ZONES() - frmNext = FrmSelISO + frmNext = FrmRootPass + + CASE "FrmRootPass" + + frmNext = FrmRootPass END SELECT Added: branches/iVL/FrmRootPass.class ============================================================================== --- (empty file) +++ branches/iVL/FrmRootPass.class Sat Aug 30 16:12:21 2008 @@ -0,0 +1,23 @@ +' Gambas class file + +PUBLIC SUB Form_Open() + Fmain.frmcurr = ME +END + + +PUBLIC SUB Button1_Click() + IF ME.tbPasswd1.Text = "" THEN + Message("Enter a Password for root.") + ELSE + IF ME.tbPasswd1.Text = ME.tbPasswd2.Text THEN + SHELL "chroot /mnt/target /sbin/passwdx root " & ME.tbPasswd1.Text + Message("Root password Set.") + ME.tbPasswd1.Clear + ME.tbPasswd2.Clear + ELSE + Message("Passwords do not match") + ME.tbPasswd1.Clear + ME.tbPasswd2.Clear + ENDIF + ENDIF +END Added: branches/iVL/FrmRootPass.form ============================================================================== --- (empty file) +++ branches/iVL/FrmRootPass.form Sat Aug 30 16:12:21 2008 @@ -0,0 +1,36 @@ +# Gambas Form File 2.0 + +{ Form Form + MoveScaled(0,0,64,64) + Text = ("") + { Frame1 Frame + MoveScaled(1,1,62,30) + Text = ("Set Root Password") + { TextLabel1 TextLabel + MoveScaled(3,3,29,11) + Text = ("Choose a password for the root account. You must enter the Root Password twice to ensure accuracy.") + } + { tbPasswd1 TextBox + MoveScaled(35,6,21,2) + Text = ("") + Password = True + } + { TextLabel2 TextLabel + MoveScaled(35,3,12,2) + Text = ("Enter Password") + } + { Button1 Button + MoveScaled(46,18,11,2) + Text = ("Set Password") + } + } + { tbPasswd2 TextBox + MoveScaled(36,14,21,2) + Text = ("") + Password = True + } + { TextLabel3 TextLabel + MoveScaled(36,11,15,2) + Text = ("ReEnter Password") + } +} Modified: branches/iVL/FrmZoneSet.class ============================================================================== --- branches/iVL/FrmZoneSet.class (original) +++ branches/iVL/FrmZoneSet.class Sat Aug 30 16:12:21 2008 @@ -2,6 +2,7 @@ PUBLIC SUB Form_Open() + Fmain.frmcurr = ME MdlZoneSet.TIME_ZONES() ME.lbTmZone.Index = 9 @@ -10,8 +11,15 @@ PUBLIC SUB lbTmZone_Click() - Message(ME.lbTmZone.Text) + 'Message(ME.lbTmZone.Text) + + +END + +PUBLIC SUB Button1_Click() + MdlZoneSet.SET_ZONE(ME.lbTmZone.Text) MdlZoneSet.WRITE_CONF() - + Message("TimeZone " & ME.lbTmZone.Text & " Was set.") + END Modified: branches/iVL/FrmZoneSet.form ============================================================================== --- branches/iVL/FrmZoneSet.form (original) +++ branches/iVL/FrmZoneSet.form Sat Aug 30 16:12:21 2008 @@ -3,20 +3,28 @@ { Form Form MoveScaled(0,0,64,55) Text = ("") - { cbHwClock ComboBox - MoveScaled(40,8,21,2) - Text = ("ComboBox1") - List = [("LocalTime"), ("UTC")] + { Frame1 Frame + MoveScaled(1,1,62,53) + Text = ("Set Hardware Clock and TimeZone") } { TextLabel1 TextLabel - MoveScaled(1,2,34,11) + MoveScaled(3,5,34,11) Text = ("Choose how\nyour hardware clock is set up.\nChoose UTC if you know that the clock is set up to\nthe Coordinated Universal Time (UTC/GMT). Otherwise,\nChoose localtime since most PCs are setup this way.") } { TextLabel2 TextLabel - MoveScaled(1,17,23,13) + MoveScaled(3,21,23,13) Text = ("Choose the correct timezone for the area in which you live.") } + { Button1 Button + MoveScaled(49,50,12,3) + Text = ("Set TimeZone") + } { lbTmZone ListBox - MoveScaled(29,16,32,30) + MoveScaled(29,18,32,23) + } + { cbHwClock ComboBox + MoveScaled(40,8,21,2) + Text = ("ComboBox1") + List = [("LocalTime"), ("UTC")] } } |