Index: .hgsigs
===================================================================
--- .hgsigs	(revision 3084)
+++ .hgsigs	(revision 3084)
@@ -0,0 +1,1 @@
+266ba234e2a5115e47379030e9439b6abcb11e80 0 iQEcBAABCgAGBQJV1WIcAAoJELwJObfmz3HnHHEH/1+ohmFEzHx5M90oAtQN4pQLsPCZ/fCVG5w6OoD56DOPP3IMaTSxlEzoG3mjWv0gzAb4zJjPErBwRy7keq3rjT5SyDs17aHRmCE91+YuGNBDnQHAD68gVZaQQ+L2d5+EHYdGtxcwiFUyRWEv+U/4NW0UexuJDVqzS6ztUC45D1a2Qt9Q4bbEsywmE5Bl7IP7hjxKlICJNo3fclpCgdryPeB7gatOJz4uw/T6tbJVzvD2ETA/9kp+hg2yFNWBhS0zgK/BKcinqlh2AW4fPDsrOvr7LnIQUt5KwdJmbNA3A8moF2EU9/PiF76tWF5IHtnk9x/bQjCgukZSZ383eUzlY58=
Index: .hgtags
===================================================================
--- .hgtags	(revision 2959)
+++ .hgtags	(revision 3083)
@@ -25,2 +25,3 @@
 c45489df2bde825c7ed9c756e00444b54caf8e10 2.7.3
 27e258e592e45b56a803038279adb6faa5865265 2.7.4
+5e377b0f479e0f45cf199b24c3f997449a6f5a8a 2.8.0
Index: inc/admin/class.dc.favorites.php
===================================================================
--- inc/admin/class.dc.favorites.php	(revision 2725)
+++ inc/admin/class.dc.favorites.php	(revision 3075)
@@ -315,5 +315,6 @@
 				true,
 				$v['id'],
-				$v['class']
+				$v['class'],
+				true
 			);
 		}
Index: inc/admin/class.dc.menu.php
===================================================================
--- inc/admin/class.dc.menu.php	(revision 2566)
+++ inc/admin/class.dc.menu.php	(revision 3075)
@@ -22,18 +22,29 @@
 		$this->title = $title;
 		$this->itemSpace = $itemSpace;
+		$this->pinned = array();
 		$this->items = array();
 	}
 
-	public function addItem($title,$url,$img,$active,$show=true,$id=null,$class=null)
+	public function addItem($title,$url,$img,$active,$show=true,$id=null,$class=null,$pinned=false)
 	{
 		if($show) {
-			$this->items[] = $this->itemDef($title,$url,$img,$active,$id,$class);
+			$item = $this->itemDef($title,$url,$img,$active,$id,$class);
+			if ($pinned) {
+				$this->pinned[] = $item;
+			} else {
+				$this->items[$title] = $item;
+			}
 		}
 	}
 
-	public function prependItem($title,$url,$img,$active,$show=true,$id=null,$class=null)
+	public function prependItem($title,$url,$img,$active,$show=true,$id=null,$class=null,$pinned=false)
 	{
 		if ($show) {
-			array_unshift($this->items,$this->itemDef($title,$url,$img,$active,$id,$class));
+			$item = $this->itemDef($title,$url,$img,$active,$id,$class);
+			if ($pinned) {
+				array_unshift($this->pinned,$item);
+			} else {
+				$this->items[$title] = $item;
+			}
 		}
 	}
@@ -41,5 +52,5 @@
 	public function draw()
 	{
-		if (count($this->items) == 0) {
+		if (count($this->items) + count($this->pinned) == 0) {
 			return '';
 		}
@@ -50,12 +61,27 @@
 		'<ul>'."\n";
 
-		for ($i=0; $i<count($this->items); $i++)
+		// 1. Display pinned items (unsorted)
+		for ($i=0; $i<count($this->pinned); $i++)
+		{
+			if ($i+1 < count($this->pinned) && $this->itemSpace != '') {
+				$res .= preg_replace('|</li>$|',$this->itemSpace.'</li>',$this->pinned[$i]);
+				$res .= "\n";
+			} else {
+				$res .= $this->pinned[$i]."\n";
+			}
+		}
+
+		// 2. Display unpinned itmes (sorted)
+		$i = 0;
+		dcUtils::lexicalKeySort($this->items);
+		foreach ($this->items as $title => $item)
 		{
 			if ($i+1 < count($this->items) && $this->itemSpace != '') {
-				$res .= preg_replace('|</li>$|',$this->itemSpace.'</li>',$this->items[$i]);
+				$res .= preg_replace('|</li>$|',$this->itemSpace.'</li>',$item);
 				$res .= "\n";
 			} else {
-				$res .= $this->items[$i]."\n";
+				$res .= $item."\n";
 			}
+			$i++;
 		}
 
Index: inc/admin/lib.admincombos.php
===================================================================
--- inc/admin/lib.admincombos.php	(revision 3011)
+++ inc/admin/lib.admincombos.php	(revision 3082)
@@ -37,5 +37,5 @@
 		while ($categories->fetch()) {
 			$categories_combo[] = new formSelectOption (
-				str_repeat('&nbsp;&nbsp;',$categories->level-1).($categories->level-1 == 0 ? '' : '&bull; ').html::escapeHTML($categories->cat_title).' ('.$categories->nb_post.')',
+                html::escapeHTML($categories->cat_title).' ('.$categories->nb_post.')',
 				($use_url ? $categories->cat_url : $categories->cat_id),
 				($categories->level-1 ? 'sub-option'.($categories->level-1) : '')
@@ -152,5 +152,5 @@
 			$editors_combo[$v] = $v;
 		}
-		
+
 		return $editors_combo;
 	}
Index: inc/admin/lib.dc.page.php
===================================================================
--- inc/admin/lib.dc.page.php	(revision 3080)
+++ inc/admin/lib.dc.page.php	(revision 3086)
@@ -177,24 +177,27 @@
 		}
 
-		// Display breadcrumb (if given) before any error message
+		// Display breadcrumb (if given) before any error messages
 		echo $breadcrumb;
 
-		if ($core->error->flag()) {
-			echo
-			'<div class="error"><p><strong>'.(count($core->error->getErrors()) > 1 ? __('Errors:') : __('Error:')).'</strong></p>'.
+		// Display notices and errors
+		echo self::notices();
+	}
+
+	public static function notices()
+	{
+		global $core;
+		static $error_displayed = false;
+		$res = '';
+
+		// return error messages if any
+		if ($core->error->flag() && !$error_displayed) {
+			$res .= '<div class="error"><p><strong>'.(count($core->error->getErrors()) > 1 ? __('Errors:') : __('Error:')).'</strong></p>'.
 			$core->error->toHTML().
 			'</div>';
-		}
-
-		// Display notices
-		echo self::notices();
-	}
-
-	public static function notices()
-	{
+			$error_displayed = true;
+		}
+
 		// return notices if any
-		$res = '';
 		if (isset($_SESSION['notifications'])) {
-			$notifications = $_SESSION['notifications'];
 			foreach ($_SESSION['notifications'] as $notification) {
 				$res .= self::getNotification($notification);
@@ -366,10 +369,6 @@
 		echo $breadcrumb;
 
-		if ($core->error->flag()) {
-			echo
-			'<div class="error" role="alert"><strong>'.__('Errors:').'</strong>'.
-			$core->error->toHTML().
-			'</div>';
-		}
+		// Display notices and errors
+		echo self::notices();
 	}
 
@@ -545,10 +544,10 @@
 	}
 
-	public static function cssLoad($src, $media='screen')
+	public static function cssLoad($src,$media='screen',$v='')
 	{
 		$escaped_src = html::escapeHTML($src);
 		if (!isset(self::$loaded_css[$escaped_src])) {
 			self::$loaded_css[$escaped_src] = true;
-			$escaped_src = self::appendVersion($escaped_src);
+			$escaped_src = self::appendVersion($escaped_src,$v);
 
 			return '<link rel="stylesheet" href="'.$escaped_src.'" type="text/css" media="'.$media.'" />'."\n";
@@ -556,28 +555,22 @@
 	}
 
-	public static function jsLoad($src)
+	public static function jsLoad($src,$v='')
 	{
 		$escaped_src = html::escapeHTML($src);
 		if (!isset(self::$loaded_js[$escaped_src])) {
 			self::$loaded_js[$escaped_src] = true;
-			$escaped_src = self::appendVersion($escaped_src);
+			$escaped_src = self::appendVersion($escaped_src,$v);
 			return '<script type="text/javascript" src="'.$escaped_src.'"></script>'."\n";
 		}
 	}
 
-	private static function appendVersion($src)
-	{
-		if (strpos($src,'?')===false) {
-			$src .= '?v=';
-		} else {
-			$src .= '&v=';
-		}
-
+	private static function appendVersion($src,$v='')
+	{
+		$src .= (strpos($src,'?') === false ? '?' : '&').'v=';
 		if (defined('DC_DEV') && DC_DEV === true) {
 			$src .= md5(uniqid());
 		} else {
-			$src .= DC_VERSION;
-		}
-
+			$src .= ($v === '' ? DC_VERSION : $v);
+		}
 		return $src;
 	}
Index: inc/admin/prepend.php
===================================================================
--- inc/admin/prepend.php	(revision 3059)
+++ inc/admin/prepend.php	(revision 3075)
@@ -69,5 +69,6 @@
 
 	$url = $core->adminurl->get($adminurl);
-	$_menu[$section]->prependItem($desc,$url,$icon,preg_match('/'.preg_quote($url).'(\?.*)?$/',$_SERVER['REQUEST_URI']),$perm);
+	$_menu[$section]->prependItem($desc,$url,$icon,
+		preg_match('/'.preg_quote($url).'(\?.*)?$/',$_SERVER['REQUEST_URI']),$perm,null,null,true);
 }
 
Index: inc/core/class.dc.error.php
===================================================================
--- inc/core/class.dc.error.php	(revision 2566)
+++ inc/core/class.dc.error.php	(revision 3074)
@@ -30,13 +30,4 @@
 	/** @var string HTML error item pattern */
 	protected $html_item = "<li>%s</li>\n";
-
-	/**
-	* Object constructor.
-	*/
-	public function __construct()
-	{
-		$this->code = 0;
-		$this->msg = '';
-	}
 
 	/**
Index: inc/prepend.php
===================================================================
--- inc/prepend.php	(revision 3079)
+++ inc/prepend.php	(revision 3081)
@@ -140,5 +140,5 @@
 # Constants
 define('DC_ROOT',path::real(dirname(__FILE__).'/..'));
-define('DC_VERSION','2.8.1');
+define('DC_VERSION','2.9-dev');
 define('DC_DIGESTS',dirname(__FILE__).'/digests');
 define('DC_L10N_ROOT',dirname(__FILE__).'/../locales');
Index: plugins/maintenance/index.php
===================================================================
--- plugins/maintenance/index.php	(revision 2849)
+++ plugins/maintenance/index.php	(revision 3073)
@@ -158,5 +158,5 @@
 			html::escapeHTML($task->name())=> ''
 		)
-	);
+	).dcPage::notices();
 
 	// content
@@ -193,5 +193,5 @@
 			__('Maintenance') => ''
 		)
-	);
+	).dcPage::notices();
 
 	// Simple task (with only a button to start it)
