Index: cvs.module
===================================================================
RCS file: /cvs/drupal-contrib/contributions/modules/cvslog/cvs.module,v
retrieving revision 1.219
diff -u -F^f -u -F^f -r1.219 cvs.module
--- cvs.module	21 Feb 2009 19:13:40 -0000	1.219
+++ cvs.module	24 Feb 2009 01:56:13 -0000
@@ -2201,39 +2201,47 @@ function cvs_application_form(&$form_sta
 
   $strings = _cvs_get_strings();
 
+  $form['cvs_overview'] = array('#type' => 'fieldset', '#title' => t('Overview'));
+  $form['cvs_overview']['overview'] = array(
+    '#type' => 'item',
+    '#value' => variable_get('cvs_message_auth', $strings['cvs_message_auth']),
+  );
+
+  $form['cvs_details'] = array('#type' => 'fieldset', '#title' => t('Account details'));
   if (empty($application['cvs_user'])) {
     $cvs_user = strtr(strtolower($user->name), array(' ' => '', '@' => '', '.' => '', '-' => '', '_' => '', '.' => ''));
-    $attributes = '';
+    $form['cvs_details']['cvs_user'] = array(
+      '#type' => 'textfield',
+      '#title' => t('CVS username'),
+      '#default_value' => $cvs_user,
+      '#size' => 30,
+      '#maxlength' => 50,
+      '#description' => t('Choose a username to access the CVS repository with. CVS usernames should be lowercase. Spaces or other special characters are not allowed.'),
+      '#required' => TRUE,
+    );
   }
   else {
     $cvs_user = $application['cvs_user'];
     // Since disabled accounts (possibly with a commit history) are also
-    // eligible for reapplication, the username field is set to disabled.
-    $attributes = array('disabled' => 'disabled');
+    // eligible for reapplication, the username field is not editable.
+    $form['cvs_details']['cvs_user'] = array(
+      '#type' => 'value',
+      '#value' => $cvs_user,
+    );
+    $form['cvs_details']['cvs_user_display'] = array(
+      '#type' => 'item',
+      '#title' => t('CVS username'),
+      '#value' => $cvs_user,
+      '#description' => t('Your CVS username. This field can only be edited by administrators and is used to link your CVS messages to your user account.'),
+    );
     $form['cvs_reapplication'] = array('#type' => 'value', '#value' => 'reapplication');
     $form['cvs_reapplication_message'] = array(
       '#type' => 'item',
-      '#value' => t('<p><em>If you are interested in reapplying for a CVS account, please amend your application accordingly and resubmit.</em></p>')
+      '#value' => t('<p><em>If you are interested in reapplying for a CVS account, please amend your application accordingly and resubmit.</em></p>'),
+      '#weight' => -10,
     );
   }
 
-  $form['cvs_overview'] = array('#type' => 'fieldset', '#title' => t('Overview'));
-  $form['cvs_overview']['overview'] = array(
-    '#type' => 'item',
-    '#value' => variable_get('cvs_message_auth', $strings['cvs_message_auth']),
-  );
-
-  $form['cvs_details'] = array('#type' => 'fieldset', '#title' => t('Account details'));
-  $form['cvs_details']['cvs_user'] = array(
-    '#type' => 'textfield',
-    '#title' => t('CVS username'),
-    '#default_value' => $cvs_user,
-    '#size' => 30,
-    '#maxlength' => 50,
-    '#description' => t('Choose a username to access the CVS repository with. CVS usernames should be lowercase. Spaces or other special characters are not allowed.'),
-    '#required' => TRUE,
-    '#attributes' => $attributes
-  );
   $form['cvs_details']['cvs_pass'] = array(
     '#type' => 'password_confirm',
     '#title' => t('CVS password'),
