Index: galleria.module
===================================================================
RCS file: /cvs/drupal-contrib/contributions/modules/galleria/galleria.module,v
retrieving revision 1.1.2.13
diff -u -r1.1.2.13 galleria.module
--- galleria.module	23 Mar 2009 14:40:16 -0000	1.1.2.13
+++ galleria.module	7 Apr 2009 00:46:05 -0000
@@ -237,6 +237,7 @@
 function template_preprocess_galleria(&$vars) {
   $node = $vars['node'];
   $files = $node->files;
+  $filecount = count($files);
   $images = array();
   $i = 0;
 
@@ -285,6 +286,6 @@
     'class' => 'gallery clear-block',
   );
 
-  $vars['next_prev_links'] = '<a onclick="$.galleria.prev(); return false;" href="#"><< ' . t('previous') . '</a> | <a onclick="$.galleria.next(); return false;" href="#">' . t('next') . '>></a>';
+  $vars['next_prev_links'] = ($filecount > 1) ? '<a onclick="$.galleria.prev(); return false;" href="#"><< ' . t('previous') . '</a> | <a onclick="$.galleria.next(); return false;" href="#">' . t('next') . '>></a>' : '';
   $vars['gallery'] = theme('item_list', $images, NULL, 'ul', $attribs);
 }
Index: inc/galleria.js
===================================================================
RCS file: /cvs/drupal-contrib/contributions/modules/galleria/inc/galleria.js,v
retrieving revision 1.1.2.3
diff -u -r1.1.2.3 galleria.js
--- inc/galleria.js	16 Jan 2009 17:02:58 -0000	1.1.2.3
+++ inc/galleria.js	7 Apr 2009 00:47:28 -0000
@@ -12,16 +12,23 @@
     // fetch the thumbnail container
     var _li = thumb.parents('li');
 
-    // fade out inactive thumbnail
-    _li.siblings().children('img.selected').fadeTo(500, Drupal.settings.thumb_opacity);
+    // if there is only one thumbnail, hide it and
+    // turn off the clickNext action on the displayed image
+    if (_li.siblings('li').length == 0) {
+      _li.css('display','none');
+      $.galleria.clickNext = false;
+    } else {
+      // fade out inactive thumbnail
+      _li.siblings().children('img.selected').fadeTo(500, Drupal.settings.thumb_opacity);
 
-    // fade in active thumbnail
-    thumb.fadeTo('fast',1).addClass('selected');
+      // fade in active thumbnail
+      thumb.fadeTo('fast',1).addClass('selected');
 
-    // add a title for the clickable image
-    image.attr('title','Next image >>');
+      // add a title for the clickable image
+      image.attr('title','Next image >>');
 
-    $('.galleria-nav').show();
+      $('.galleria-nav').show();
+    }
   },
 
   onThumb : function(thumb) {

