Index: /extensions/skeleton/trunk/include/public_events.inc.php
===================================================================
--- /extensions/skeleton/trunk/include/public_events.inc.php	(revision 21306)
+++ /extensions/skeleton/trunk/include/public_events.inc.php	(revision 21307)
@@ -12,8 +12,18 @@
   {
     $page['section'] = 'skeleton';
-    $page['title'] = '<a href="'.get_absolute_root_url().'">'.l10n('Home').'</a>'.$conf['level_separator'].'<a href="'.SKELETON_PUBLIC.'">'.l10n('Skeleton').'</a>';
     
-    // print_r($tokens);
+    // section_title is for breadcrumb, title is for page <title>
+    $page['section_title'] = '<a href="'.get_absolute_root_url().'">'.l10n('Home').'</a>'.$conf['level_separator'].'<a href="'.SKELETON_PUBLIC.'">'.l10n('Skeleton').'</a>';
+    $page['title'] = l10n('Skeleton');
+    
+    // define body_id
+    add_event_handler('loc_begin_page_header', 'skeleton_loc_begin_page_header');
   }
+}
+
+function skeleton_loc_begin_page_header()
+{
+  global $page;
+  $page['body_id'] = 'theSkeletonPage';
 }
 
@@ -23,9 +33,30 @@
 function skeleton_loc_end_page()
 {
-  global $page;
+  global $page, $template;
 
-  if ( isset($page['section']) and $page['section'] == 'skeleton' )
+  if ( isset($page['section']) and $page['section']=='skeleton' )
   {
     include(SKELETON_PATH . 'include/skeleton_page.inc.php');
+  }
+}
+
+/*
+ * button on album and photos pages
+ */
+function skeleton_add_button()
+{
+  global $template;
+  
+  $template->assign('SKELETON_PATH', SKELETON_PATH);
+  $template->set_filename('skeleton_button', realpath(SKELETON_PATH.'template/my_button.tpl'));
+  $button = $template->parse('skeleton_button', true);
+  
+  if (script_basename()=='index')
+  {
+    $template->add_index_button('<li>'.$button.'</li>', EVENT_HANDLER_PRIORITY_NEUTRAL);
+  }
+  else
+  {
+    $template->add_picture_button($button, EVENT_HANDLER_PRIORITY_NEUTRAL);
   }
 }
Index: /extensions/skeleton/trunk/language/en_UK/intro.html
===================================================================
--- /extensions/skeleton/trunk/language/en_UK/intro.html	(revision 21306)
+++ /extensions/skeleton/trunk/language/en_UK/intro.html	(revision 21307)
@@ -16,4 +16,5 @@
     <li>Simple template prefilter (on picture.php page)</li>
     <li>Add new method to the API</li>
+    <li>Add a toolbar button</li>
   </ul>
 </p>
Index: /extensions/skeleton/trunk/language/fr_FR/intro.html
===================================================================
--- /extensions/skeleton/trunk/language/fr_FR/intro.html	(revision 21306)
+++ /extensions/skeleton/trunk/language/fr_FR/intro.html	(revision 21307)
@@ -16,4 +16,5 @@
     <li>Préfiltre de template simple (sur page picture.php)</li>
     <li>Ajout d'une méthode à l'API</li>
+    <li>Ajout d'un bouton dans la barre d'outils</li>
   </ul>
 </p>
Index: /extensions/skeleton/trunk/main.inc.php
===================================================================
--- /extensions/skeleton/trunk/main.inc.php	(revision 21306)
+++ /extensions/skeleton/trunk/main.inc.php	(revision 21307)
@@ -71,4 +71,8 @@
   // NOTE: skeleton_blockmanager_apply1() and skeleton_blockmanager_apply2() can (should) be merged
   
+  // add button on album and photos pages
+  add_event_handler('loc_end_index', 'skeleton_add_button');
+  add_event_handler('loc_end_picture', 'skeleton_add_button');
+  
   // prefilter on photo page
   add_event_handler('loc_end_picture', 'skeleton_loc_end_picture');
Index: /extensions/skeleton/trunk/template/my_button.tpl
===================================================================
--- /extensions/skeleton/trunk/template/my_button.tpl	(revision 21307)
+++ /extensions/skeleton/trunk/template/my_button.tpl	(revision 21307)
@@ -0,0 +1,6 @@
+{strip}
+<a href="javascript:alert('Hello world!');" title="{'This is not the button you are looking for'|@translate}" class="pwg-state-default pwg-button" rel="nofollow">
+  <span class="pwg-icon" style="background:url('{$ROOT_URL}{$SKELETON_PATH}template/head.png') center center no-repeat;"> </span>
+  <span class="pwg-button-text">{'Skeleton'|@translate}</span>
+</a>
+{/strip}
