[Fedora-directory-commits] ldapserver/ldap/admin/src/scripts Dialog.pm, 1.3, 1.4 DialogManager.pm, 1.3, 1.4 Setup.pm.in, 1.6, 1.7

Richard Allen Megginson (rmeggins) fedora-directory-commits at redhat.com
Wed Jun 20 16:27:52 UTC 2007


Author: rmeggins

Update of /cvs/dirsec/ldapserver/ldap/admin/src/scripts
In directory cvs-int.fedora.redhat.com:/tmp/cvs-serv18222/ldapserver/ldap/admin/src/scripts

Modified Files:
	Dialog.pm DialogManager.pm Setup.pm.in 
Log Message:
Resolves: bug 237356
Description: Move DS Admin Code into Admin Server - navigation
Fix Description: Some minor cleanup:
1) Fixed navigation.  Now you can go back through several dialogs.
2) Need to create a new Inf even if no file given
Platforms tested: RHEL4
Flag Day: No.
Doc impact: No.



Index: Dialog.pm
===================================================================
RCS file: /cvs/dirsec/ldapserver/ldap/admin/src/scripts/Dialog.pm,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -r1.3 -r1.4
--- Dialog.pm	15 Jun 2007 22:11:15 -0000	1.3
+++ Dialog.pm	20 Jun 2007 16:27:50 -0000	1.4
@@ -136,6 +136,7 @@
 # you can set the 0 to a 1 if the user has chosen to use security
 sub run {
     my $self = shift;
+    my $direction = shift;
     my $resp = $DialogManager::SAME;
 
     # display the dialog text
@@ -181,6 +182,12 @@
             }
         } elsif ($resp == $DialogManager::ERR) {
             last;
+        } elsif (!$self->isDisplayed() && ($direction < 0) &&
+                 ($resp == $DialogManager::NEXT)) {
+            # we did not display this dialog, and the current navigation
+            # direction is BACK, so we should return BACK, to allow
+            # the user to go back through several dialogs
+            $resp = $DialogManager::BACK;
         }
     }
 


Index: DialogManager.pm
===================================================================
RCS file: /cvs/dirsec/ldapserver/ldap/admin/src/scripts/DialogManager.pm,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -r1.3 -r1.4
--- DialogManager.pm	19 Jun 2007 18:24:57 -0000	1.3
+++ DialogManager.pm	20 Jun 2007 16:27:50 -0000	1.4
@@ -206,7 +206,7 @@
         my $dialog = $self->{dialogs}->[$index];
         if ($dialog->isEnabled()) {
             my $resp = $NEXT;
-            $resp = $dialog->run();
+            $resp = $dialog->run($incr);
             if ($resp == $BACK) {
                 $incr = -1;
             } elsif ($resp == $NEXT) {


Index: Setup.pm.in
===================================================================
RCS file: /cvs/dirsec/ldapserver/ldap/admin/src/scripts/Setup.pm.in,v
retrieving revision 1.6
retrieving revision 1.7
diff -u -r1.6 -r1.7
--- Setup.pm.in	20 Jun 2007 14:40:24 -0000	1.6
+++ Setup.pm.in	20 Jun 2007 16:27:50 -0000	1.7
@@ -135,6 +135,8 @@
     # if user supplied inf file, use that to initialize
     if (defined($self->{inffile})) {
         $self->{inf} = new Inf($self->{inffile});
+    } else {
+        $self->{inf} = new Inf;
     }
     my $fh;
     # create a temp inf file for writing for other processes




More information about the Fedora-directory-commits mailing list