Index: img_assist.css
===================================================================
RCS file: /cvs/drupal-contrib/contributions/modules/img_assist/Attic/img_assist.css,v
retrieving revision 1.3.2.1
diff -b -U3 -r1.3.2.1 img_assist.css
--- img_assist.css	17 Feb 2007 01:03:03 -0000	1.3.2.1
+++ img_assist.css	5 Mar 2007 16:55:51 -0000
@@ -44,8 +44,19 @@
 }
 
 /* Properties Window */
+.img_assist table {
+  margin-top: 0;
+}
+.img_assist table tbody {
+  border-top: 0;
+}
+.img_assist td {
+  padding-bottom: 0;
+  vertical-align: bottom;
+}
 .img_assist #preview {
   padding: 5px 10px 5px 5px;
+  vertical-align: top;
 }
 .img_assist .form-item { /* the first form field on the properties frame should be at the top of the page  */
   margin-top: 0px;
@@ -85,6 +96,14 @@
   display: none;
   visibility: hidden;
 }
+td.titlefield, td.titlefield .form-item {
+  margin-bottom: 0;
+  padding-bottom: 0;
+}
+td.form-item {
+  margin-top: 0;
+  padding-top: 0;
+}
 
 /* Header Frame */
 #header-uploading, #header-properties, #header-browse {
Index: img_assist.js
===================================================================
RCS file: /cvs/drupal-contrib/contributions/modules/img_assist/Attic/img_assist.js,v
retrieving revision 1.4
diff -b -U3 -r1.4 img_assist.js
--- img_assist.js	13 Feb 2007 22:48:31 -0000	1.4
+++ img_assist.js	5 Mar 2007 16:55:51 -0000
@@ -18,7 +18,11 @@
   var caption = frames['img_assist_main'].document.getElementById("caption");
   var title = frames['img_assist_main'].document.img_assist['edit-title'].value;
   var desc = frames['img_assist_main'].document.img_assist['edit-desc'].value;
-  if (desc != '') {
+  var alt = frames['img_assist_main'].document.img_assist['edit-alt'].checked;
+  if (alt == true) {
+    title = '';
+  }
+  if (desc != '' && title != '') {
     title = title + ': ';
   }
   caption.innerHTML = '<strong>' + title + '</strong>' + desc;
Index: img_assist.module
===================================================================
RCS file: /cvs/drupal-contrib/contributions/modules/img_assist/Attic/img_assist.module,v
retrieving revision 1.68.2.3
diff -b -U3 -r1.68.2.3 img_assist.module
--- img_assist.module	23 Feb 2007 22:30:04 -0000	1.68.2.3
+++ img_assist.module	5 Mar 2007 16:55:52 -0000
@@ -127,7 +127,7 @@
  * Theme for adding an image link underneath textareas
  */
 function theme_img_assist_textarea_link($element, $link) {
-  $output  = '<div class="img_assist-button"><a class="img_assist-link" id="img_assist-link-'. $element['#id'] .'" title="' . t('Click here to add images') . '" href="'. url('img_assist/load/textarea', 'textarea='. $element['#name']) .'" onclick="window.open(this.href, \'img_assist_link\', \'width=600,height=350,scrollbars=yes,status=yes,resizable=yes,toolbar=no,menubar=no\'); return false">';
+  $output  = '<div class="img_assist-button"><a class="img_assist-link" id="img_assist-link-'. $element['#id'] .'" title="' . t('Click here to add images') . '" href="'. url('img_assist/load/textarea', 'textarea='. $element['#name']) .'" onclick="window.open(this.href, \'img_assist_link\', \'width=600,height=400,scrollbars=yes,status=yes,resizable=yes,toolbar=no,menubar=no\'); return false">';
   $output .= ($link == 'icon') ? '<img src="'. base_path() . drupal_get_path('module', 'img_assist') .'/add-image.jpg" border="0" width="36" height="25" />' : t('Add image');
   $output .= '</a></div>';
   return $output;
@@ -843,10 +843,10 @@
   // Create the form
   $form[] = array('#value' => "<div id=\"properties\">\n");
   $form[] = array('#value' => '<table width="100%" border="0" cellspacing="0" cellpadding="0">');
-  $form[] = array('#value' => "<tr><td valign=\"top\" rowspan=\"3\" id=\"preview\">\n");
+  $form[] = array('#value' => "<tr><td valign=\"top\" rowspan=\"5\" id=\"preview\">\n");
   $form[] = array('#value' => $properties_image);
   $form[] = array('#value' => "<span id=\"caption\" style=\"width: {$properties_size['width']}px;\">{$node->title}</span>\n");
-  $form[] = array('#value' => "</td><td width=\"100%\" colspan=\"2\">\n");
+  $form[] = array('#value' => "</td><td width=\"90%\" class=\"titlefield\">\n");
 
   $form['title'] = array(
     '#type' => 'textfield',
@@ -854,16 +854,24 @@
     '#default_value' => variable_get('img_assist_load_title', 1) ? $node->title : '',
     '#size' => 50,
     '#maxlength' => 255,
-    '#description' => NULL,
     '#attributes' => array('onblur'=>'parent.updateCaption()'),
   );
+  $form[] = array('#value'=>"</td><td width=\"10%\" class=\"titlefield\">\n");
+  $form['alt'] = array(
+    '#type' => 'checkbox',
+    '#title' => t('Alt only'),
+    '#default_value' => FALSE,
+    '#attributes' => array('onclick'=>'parent.updateCaption()'),
+  );
+  $form[] = array('#value'=>"</td></tr><tr><td colspan=\"2\" class=\"form-item\">\n");
+  $form[] = array('#value'=>'<div class="description">With <em>Alt only</em> enabled, the title will only be show in the alt attribute of the image.</div>');
+  $form[] = array('#value'=>"</td></tr><tr><td colspan=\"2\">\n");
   $form['desc'] = array(
     '#type' => 'textfield',
     '#title' => t('Description (optional)'),
     '#default_value' => variable_get('img_assist_load_description', 1) ? $node->body : '',
     '#size' => 50,
     '#maxlength' => 255,
-    '#description' => NULL,
     '#attributes' => array('onblur'=>'parent.updateCaption()'),
   );
 
@@ -1193,6 +1201,14 @@
       $width = ($width <= $max_size[0]) ? $width : $max_size[0];
       $height = ($height <= $max_size[1]) ? $height : $max_size[1];
 
+      // Get the width & height of the 'original' size
+      $original_size = image_get_info(file_create_path($node->images['_original']));
+      if ($width == $original_size['width'] && $height == $original_size['height']) {
+        // Nothing to process, this is the original image size
+        $closest_std_size = '_original';
+        $create_custom = false;
+      }
+      else {
       // Get the width & height of the 'preview' size
       $preview_size = image_get_info(file_create_path($node->images['preview']));
       $preview_width = $preview_size['width'];
@@ -1212,6 +1228,7 @@
         // Compare the new width & height to existing image derivative sizes
         $diag_size_new = sqrt(pow($width, 2) + pow($height, 2));
         $closest_difference = 9999;
+
         foreach (_image_get_sizes() as $stdsize) {
           if ($stdsize['label']) {
             $width_std = $stdsize['width'];
@@ -1262,6 +1279,7 @@
           }
         }
       }
+      }
 
       if ($create_custom) {
         // try to get this page's NID to add to this custom image's derivative label;
@@ -1301,10 +1319,14 @@
 }
 
 function theme_img_assist_inline($node, $size, $attributes) {
-
-  if ($attributes['title'] && $attributes['desc']) {
+  if ($attributes['alt'] == 1 || $attributes['alt'] == 'true') {
+    $attributes['alt'] = TRUE;
+  } else {
+    $attributes['alt'] = FALSE;
+  }
+  if ($attributes['alt'] == FALSE && $attributes['title'] && $attributes['desc']) {
     $caption = '<strong>' . $attributes['title'] . ': </strong>' . $attributes['desc'];
-  } elseif ($attributes['title']) {
+  } elseif ($attributes['alt'] == FALSE && $attributes['title']) {
     $caption = '<strong>' . $attributes['title'] . '</strong>';
   } elseif ($attributes['desc']) {
   	$caption = $attributes['desc'];
Index: img_assist_textarea.js
===================================================================
RCS file: /cvs/drupal-contrib/contributions/modules/img_assist/Attic/img_assist_textarea.js,v
retrieving revision 1.2
diff -b -U3 -r1.2 img_assist_textarea.js
--- img_assist_textarea.js	13 Feb 2007 22:48:31 -0000	1.2
+++ img_assist_textarea.js	5 Mar 2007 16:55:53 -0000
@@ -60,6 +60,7 @@
 function getFilterTag(formObj) {
   var nid          = formObj['edit-nid'].value;
   var captionTitle = formObj['edit-title'].value;
+  var captionAlt   = formObj['edit-alt'].checked;
   var captionDesc  = formObj['edit-desc'].value;
   var link         = formObj['edit-link'].value;
   if (link == 'url') {
@@ -70,7 +71,7 @@
   var height       = formObj['edit-height'].value;
   
   // Create the image tag
-  var miscAttribs = 'nid=' + nid + '|title=' + captionTitle + '|desc=' + captionDesc + '|link=' + link;
+  var miscAttribs = 'nid=' + nid + '|title=' + captionTitle + '|alt=' + captionAlt + '|desc=' + captionDesc + '|link=' + link;
   var content = '[img_assist|' + miscAttribs + '' + '|align=' + align + '|width=' + width + '|height=' + height + ']';
   
   return content;
Index: img_assist_tinymce.js
===================================================================
RCS file: /cvs/drupal-contrib/contributions/modules/img_assist/Attic/img_assist_tinymce.js,v
retrieving revision 1.1.4.1
diff -b -U3 -r1.1.4.1 img_assist_tinymce.js
--- img_assist_tinymce.js	23 Feb 2007 22:30:04 -0000	1.1.4.1
+++ img_assist_tinymce.js	5 Mar 2007 16:55:53 -0000
@@ -13,6 +13,7 @@
 // get variables that were passed to this window from the tinyMCE editor
 var nid;
 var captionTitle;
+var captionAlt;
 var captionDesc;
 var link;
 var align;
@@ -28,6 +29,7 @@
 function initLoader() {
   nid          =      tinyMCE.getWindowArg('nid');
   captionTitle = '' + tinyMCE.getWindowArg('captionTitle');
+  captionAlt   = '' + tinyMCE.getWindowArg('captionAlt');
   captionDesc  = '' + tinyMCE.getWindowArg('captionDesc');
   link         = '' + tinyMCE.getWindowArg('link');
   align        = '' + tinyMCE.getWindowArg('align');
@@ -45,6 +47,7 @@
   var formObj = frames['img_assist_main'].document.forms[0];
   if (formObj['edit-update'].value == 1) {
     formObj['edit-title'].value  = captionTitle;
+    formObj['edit-alt'].checked  = captionAlt;
     formObj['edit-desc'].value   = captionDesc;
     link = link.split(',');
     formObj['edit-link'].value = link[0];
@@ -85,6 +88,7 @@
 function getFilterTag(formObj) {
   nid = formObj['edit-nid'].value
   captionTitle = formObj['edit-title'].value;
+  captionAlt   = formObj['edit-alt'].checked;
   captionDesc  = formObj['edit-desc'].value;
   link         = formObj['edit-link'].value;
   if (link == 'url') {
@@ -96,7 +100,7 @@
   
   // Create the image placeholder tag
   //  (see the TinyMCE_drupalimage_cleanup() function in the drupalimage plugin for documentation)
-  var miscAttribs = 'nid=' + nid + '|title=' + captionTitle + '|desc=' + captionDesc + '|link=' + link;
+  var miscAttribs = 'nid=' + nid + '|title=' + captionTitle + '|alt=' + captionAlt + '|desc=' + captionDesc + '|link=' + link;
   miscAttribs = encodeURIComponent(miscAttribs);
   var html    = '';
   html += ''
