Index: contrib/node_gallery_access/node_gallery_access.module
===================================================================
RCS file: /cvs/drupal-contrib/contributions/modules/node_gallery/contrib/node_gallery_access/node_gallery_access.module,v
retrieving revision 1.6.2.12
diff -u -r1.6.2.12 node_gallery_access.module
--- contrib/node_gallery_access/node_gallery_access.module	24 Sep 2009 17:30:47 -0000	1.6.2.12
+++ contrib/node_gallery_access/node_gallery_access.module	22 Oct 2009 21:14:18 -0000
@@ -86,7 +86,7 @@
       }
     }
     elseif ($access->access_type == NODE_GALLERY_ACCESS_TYPE_PASSWORD) {
-      if ($user->uid == $access->uid) {
+      if ($user->uid == $access->uid || node_gallery_access_skip_password()) {
         return ;
       }
       elseif (!isset($_SESSION['_node_gallery']['passwords'][$access->nid]) || ($_SESSION['_node_gallery']['passwords'][$access->nid] != $access->password)) {
@@ -97,6 +97,16 @@
   }
 }
 
+function node_gallery_access_skip_password() {
+  if (variable_get('ng_access_pass_allow_admins',0)) {
+    if (user_access(NODE_GALLERY_ACCESS_PERM_ACCESS_PROTECTED_CONTENTS) ||
+        user_access(NODE_GALLERY_ACCESS_PERM_EDIT_PROTECTED_CONTENTS)) {
+          return TRUE;
+        }
+  }
+  return FALSE;
+}
+
 function node_gallery_access_node_gallery_access() {
   $args = arg();
   if (count($args) == 2 && $args[0] == 'node' && is_numeric($args[1])) {
@@ -262,7 +272,7 @@
     if (!$user->uid && variable_get('cache', 0)) {
       $GLOBALS['conf']['cache'] = FALSE;
     }
-    if ($user->uid != $node->uid) {
+    if ($user->uid != $node->uid && !node_gallery_access_skip_password()) {
       $id = (!empty($gid) && is_numeric($gid)) ? $gid : $node->nid;
       // If node is protected and not teaser nor page view and not owner of node
       if (!isset($_SESSION['_node_gallery']['passwords'][$id])) {
Index: contrib/node_gallery_access/node_gallery_access.admin.inc
===================================================================
RCS file: /cvs/drupal-contrib/contributions/modules/node_gallery/contrib/node_gallery_access/Attic/node_gallery_access.admin.inc,v
retrieving revision 1.1.2.2
diff -u -r1.1.2.2 node_gallery_access.admin.inc
--- contrib/node_gallery_access/node_gallery_access.admin.inc	21 Jun 2009 11:17:53 -0000	1.1.2.2
+++ contrib/node_gallery_access/node_gallery_access.admin.inc	22 Oct 2009 21:14:18 -0000
@@ -9,16 +9,22 @@
     '#weight' => -1,
     '#description' => t('Specify which node gallery types you want to set access controls.'),
   );
+  $form['ng_access_pass_allow_admins'] = array(
+    '#type' => 'checkbox',
+    '#title' => t('Allow admin and users with view/edit permissions access without a password'),
+    '#description' => t("When checked, password protected galleries will be accessible without a password by admin and by users with the 'access protected contents' or 'edit protected contents' permissions."),
+    '#default_value' => variable_get('ng_access_pass_allow_admins',0),
+  );
   $form['ng_access_pass_gallery'] = array(
     '#type' => 'textfield',
     '#title' => t('Password Mode Gallery File'),
-    '#description' => t("Specify the image display when viewing a gallery need inputing password. The root is the web root. The default file is $default"),
+    '#description' => t("Specify the image to display when the gallery being viewed needs a password. The root is the web root. The default file is ".drupal_get_path('module', 'node_gallery_access') ."/images/passAlbum.gif"),
     '#default_value' => node_gallery_access_default_pass_image('gallery'),
   );
   $form['ng_access_pass_image'] = array(
     '#type' => 'textfield',
     '#title' => t('Password Mode Image File'),
-    '#description' => t("Specify the image display when viewing an image need inputing password. The root is the web root. The default file is $default"),
+    '#description' => t("Specify the image to display when the image being viewed needs a password. The root is the web root. The default file is ".drupal_get_path('module', 'node_gallery_access') ."/images/passAlbum.gif"),
     '#default_value' => node_gallery_access_default_pass_image(),
   );
   return system_settings_form($form);
