Index: plugins/pages/_define.php
===================================================================
--- plugins/pages/_define.php	(revision 464)
+++ plugins/pages/_define.php	(revision 904)
@@ -16,5 +16,5 @@
 	/* Description*/	"Serve entries as simple web pages",
 	/* Author */		"Olivier Meunier",
-	/* Version */		'1.1.1',
+	/* Version */		'1.2',
 	array(
 		'permissions' =>	'contentadmin,pages',
Index: plugins/pages/_prepend.php
===================================================================
--- plugins/pages/_prepend.php	(revision 776)
+++ plugins/pages/_prepend.php	(revision 857)
@@ -12,4 +12,6 @@
 if (!defined('DC_RC_PATH')) { return; }
 
+global $core;
+
 $core->url->register('pages','pages','^pages/(.+)$',array('urlPages','pages'));
 $core->url->register('pagespreview','pagespreview','^pagespreview/(.+)$',array('urlPages','pagespreview'));
Index: plugins/pages/_public.php
===================================================================
--- plugins/pages/_public.php	(revision 727)
+++ plugins/pages/_public.php	(revision 904)
@@ -247,5 +247,5 @@
 		
 		$res =
-		'<div class="pages">'.
+		'<div class="pages'.($w->class ? ' '.html::escapeHTML($w->class) : '').'">'.
 		($w->title ? '<h2>'.html::escapeHTML($w->title).'</h2>' : '').
 		'<ul>';
Index: plugins/pages/_widgets.php
===================================================================
--- plugins/pages/_widgets.php	(revision 270)
+++ plugins/pages/_widgets.php	(revision 904)
@@ -32,4 +32,5 @@
 			array(__('Ascending') => 'asc', __('Descending') => 'desc')
 		);
+		$w->pages->setting('class',__('CSS class:'),'');
 	}
 	
Index: plugins/pages/list.php
===================================================================
--- plugins/pages/list.php	(revision 884)
+++ plugins/pages/list.php	(revision 578)
@@ -11,70 +11,55 @@
 # -- END LICENSE BLOCK -----------------------------------------
 if (!defined('DC_CONTEXT_ADMIN')) { return; }
-
 dcPage::check('pages,contentadmin');
 
-class adminPageList extends adminItemsList
-{
-	public function setColumns()
+/* Pager class
+-------------------------------------------------------- */
+class adminPageList extends adminGenericList
+{
+	public function display($page,$nb_per_page,$enclose_block='')
 	{
-		$this->addColumn('title','post_title',__('Title'),array('adminPostList','getTitle'),array('class' => array('maximal')),true,true,false);
-		$this->addColumn('date','post_dt',__('Date'),array('adminPostList','getDate'));
-		$this->addColumn('datetime','post_dt',__('Date and time'),array('adminPostList','getDateTime'));
-		$this->addColumn('author','user_id',__('Author'),array('adminPostList','getAuthor'));
-		$this->addColumn('comments','nb_comment',__('Comments'),array('adminPostList','getComments'));
-		$this->addColumn('trackbacks','nb_trackback',__('Trackbacks'),array('adminPostList','getTrackbacks'));
-		$this->addColumn('status','post_status',__('Status'),array('adminPostList','getStatus'));
-		$this->default_sortby = 'datetime';
-		$this->default_order = 'desc';
-
+		if ($this->rs->isEmpty())
+		{
+			echo '<p><strong>'.__('No page').'</strong></p>';
+		}
+		else
+		{
+			$pager = new pager($page,$this->rs_count,$nb_per_page,10);
+			$pager->html_prev = $this->html_prev;
+			$pager->html_next = $this->html_next;
+			$pager->var_page = 'page';
+			
+			$html_block =
+			'<table class="clear"><tr>'.
+			'<th colspan="2">'.__('Title').'</th>'.
+			'<th>'.__('Date').'</th>'.
+			'<th>'.__('Author').'</th>'.
+			'<th>'.__('Comments').'</th>'.
+			'<th>'.__('Trackbacks').'</th>'.
+			'<th>'.__('Status').'</th>'.
+			'</tr>%s</table>';
+			
+			if ($enclose_block) {
+				$html_block = sprintf($enclose_block,$html_block);
+			}
+			
+			echo '<p>'.__('Page(s)').' : '.$pager->getLinks().'</p>';
+			
+			$blocks = explode('%s',$html_block);
+			
+			echo $blocks[0];
+			
+			while ($this->rs->fetch())
+			{
+				echo $this->postLine();
+			}
+			
+			echo $blocks[1];
+			
+			echo '<p>'.__('Page(s)').' : '.$pager->getLinks().'</p>';
+		}
 	}
 	
-	protected function getDefaultCaption()
-	{
-		return __('Pages list');
-	}
-	
-	protected function getDefaultLine()
-	{
-		return
-		'<tr class="line'.($this->rs->post_status != 1 ? ' offline' : '').'"'.
-		' id="p'.$this->rs->post_id.'">%s</tr>';
-	}
-	
-	protected function getTitle()
-	{
-		return
-		'<th scope="row" class="maximal">'.
-		form::checkbox(array('entries[]'),$this->rs->post_id,'','','',!$this->rs->isEditable()).'&nbsp;'.
-		'<a href="'.$this->core->getPostAdminURL($this->rs->post_type,$this->rs->post_id).'">'.
-		html::escapeHTML($this->rs->post_title).'</a></th>';
-	}
-	
-	protected function getDate()
-	{
-		return '<td class="nowrap">'.dt::dt2str(__('%Y-%m-%d'),$this->rs->post_dt).'</td>';
-	}
-	
-	protected function getDateTime()
-	{
-		return '<td class="nowrap">'.dt::dt2str(__('%Y-%m-%d %H:%M'),$this->rs->post_dt).'</td>';
-	}
-	
-	protected function getAuthor()
-	{
-		return '<td class="nowrap">'.$this->rs->user_id.'</td>';
-	}
-	
-	protected function getComments()
-	{
-		return '<td class="nowrap">'.$this->rs->nb_comment.'</td>';
-	}
-	
-	protected function getTrackbacks()
-	{
-		return '<td class="nowrap">'.$this->rs->nb_trackback.'</td>';
-	}
-	
-	protected function getStatus()
+	private function postLine()
 	{
 		$img = '<img alt="%1$s" title="%1$s" src="images/%2$s" />';
@@ -99,4 +84,9 @@
 		}
 		
+		$selected = '';
+		if ($this->rs->post_selected) {
+			$selected = sprintf($img,__('selected'),'selected.png');
+		}
+		
 		$attach = '';
 		$nb_media = $this->rs->countMedia();
@@ -106,61 +96,47 @@
 		}
 		
-		return '<td class="nowrap status">'.$img_status.' '.$protected.' '.$attach.'</td>';
+		$res = '<tr class="line'.($this->rs->post_status != 1 ? ' offline' : '').'"'.
+		' id="p'.$this->rs->post_id.'">';
+		
+		$res .=
+		'<td class="nowrap">'.
+		form::checkbox(array('entries[]'),$this->rs->post_id,'','','',!$this->rs->isEditable(),'title="'.__('select this page').'"').'</td>'.
+		'<td class="maximal"><a href="'.$this->core->getPostAdminURL($this->rs->post_type,$this->rs->post_id).'">'.
+		html::escapeHTML($this->rs->post_title).'</a></td>'.
+		'<td class="nowrap">'.dt::dt2str(__('%Y-%m-%d %H:%M'),$this->rs->post_dt).'</td>'.
+		
+		'<td class="nowrap">'.$this->rs->user_id.'</td>'.
+		'<td class="nowrap">'.$this->rs->nb_comment.'</td>'.
+		'<td class="nowrap">'.$this->rs->nb_trackback.'</td>'.
+		'<td class="nowrap status">'.$img_status.' '.$selected.' '.$protected.' '.$attach.'</td>'.
+		'</tr>';
+		
+		return $res;
 	}
 }
 
-
-# Getting authors
+/* Getting pages
+-------------------------------------------------------- */
+$params = array(
+	'post_type' => 'page'
+);
+
+$page = !empty($_GET['page']) ? (integer) $_GET['page'] : 1;
+$nb_per_page =  30;
+
+if (!empty($_GET['nb']) && (integer) $_GET['nb'] > 0) {
+	$nb_per_page = (integer) $_GET['nb'];
+}
+
+$params['limit'] = array((($page-1)*$nb_per_page),$nb_per_page);
+$params['no_content'] = true;
+$params['order'] = 'post_position ASC, post_title ASC';
+
 try {
-	$users = $core->blog->getPostsUsers('page');
+	$pages = $core->blog->getPosts($params);
+	$counter = $core->blog->getPosts($params,true);
+	$post_list = new adminPageList($core,$pages,$counter->f(0));
 } catch (Exception $e) {
 	$core->error->add($e->getMessage());
-}
-
-# Getting dates
-try {
-	$dates = $core->blog->getDates(array('type'=>'month','post_type'=>'page'));
-} catch (Exception $e) {
-	$core->error->add($e->getMessage());
-}
-
-# Getting langs
-try {
-	$langs = $core->blog->getLangs(array('post_type'=>'page'));
-} catch (Exception $e) {
-	$core->error->add($e->getMessage());
-}
-
-# Creating filter combo boxes
-if (!$core->error->flag())
-{
-	# Filter form we'll put in html_block
-	$users_combo = array();
-	while ($users->fetch())
-	{
-		$user_cn = dcUtils::getUserCN($users->user_id,$users->user_name,
-		$users->user_firstname,$users->user_displayname);
-		
-		if ($user_cn != $users->user_id) {
-			$user_cn .= ' ('.$users->user_id.')';
-		}
-		
-		$users_combo[$user_cn] = $users->user_id; 
-	}
-	
-	$status_combo = array(
-	);
-	foreach ($core->blog->getAllPostStatus() as $k => $v) {
-		$status_combo[$v] = (string) $k;
-	}
-	
-	# Months array
-	while ($dates->fetch()) {
-		$dt_m_combo[dt::str('%B %Y',$dates->ts())] = $dates->year().$dates->month();
-	}
-	
-	while ($langs->fetch()) {
-		$lang_combo[$langs->post_lang] = $langs->post_lang;
-	}
 }
 
@@ -169,76 +145,19 @@
 if ($core->auth->check('publish,contentadmin',$core->blog->id))
 {
-	$combo_action[__('Status')] = array(
-		__('Publish') => 'publish',
-		__('Unpublish') => 'unpublish',
-		__('Schedule') => 'schedule',
-		__('Mark as pending') => 'pending'
-	);
-}
-if ($core->auth->check('admin',$core->blog->id))
-{
-	$combo_action[__('Change')] = array(__('Change author') => 'author');
+	$combo_action[__('publish')] = 'publish';
+	$combo_action[__('unpublish')] = 'unpublish';
+	$combo_action[__('schedule')] = 'schedule';
+	$combo_action[__('mark as pending')] = 'pending';
+}
+if ($core->auth->check('admin',$core->blog->id)) {
+	$combo_action[__('change author')] = 'author';
 }
 if ($core->auth->check('delete,contentadmin',$core->blog->id))
 {
-	$combo_action[__('Delete')] = array(__('Delete') => 'delete');
+	$combo_action[__('delete')] = 'delete';
 }
 
 # --BEHAVIOR-- adminPagesActionsCombo
 $core->callBehavior('adminPagesActionsCombo',array(&$combo_action));
-
-
-/* Get posts
--------------------------------------------------------- */
-$post_list = new adminPageList($core);
-
-$params = new ArrayObject();
-$params['post_type'] = 'page';
-$params['no_content'] = true;
-
-$filterSet = new dcFilterSet('pages',$p_url);
-class monthComboFilter extends comboFilter {
-	public function applyFilter($params) {
-		$month=$this->values[0];
-		$params['post_month'] = substr($month,4,2);
-		$params['post_year'] = substr($month,0,4);
-	}
-}
-$filterSet
-	->addFilter(new comboFilter(
-		'users',__('Author'), __('Author'), 'user_id', $users_combo))
-	->addFilter(new comboFilter(
-		'post_status',__('Status'), __('Status'), 'post_status', $status_combo))
-	->addFilter(new comboFilter(
-		'lang',__('Lang'), __('Lang'), 'post_lang', $lang_combo))
-	->addFilter(new monthComboFilter(
-		'month',__('Month'),__('Month'), 'post_month', $dt_m_combo,array('singleval' => 1)))
-	->addFilter(new textFilter(
-		'search',__('Contains'),__('The page contains'), 'search',20,255));
-
-$core->callBehavior('adminPagesFilters',$filterSet);
-$filterSet->setExtra($post_list);
-
-$filterSet->setup($_GET,$_POST);
-
-# Get pages
-try {
-	$nfparams = $params->getArrayCopy();
-	$filtered = $filterSet->applyFilters($params);
-	$core->callBehavior('adminPostsParams',$params);
-	$posts = $core->blog->getPosts($params);
-	$counter = $core->blog->getPosts($params,true);
-	if ($filtered) {
-		$totalcounter = $core->blog->getPosts($nfparams,true);
-		$page_title = sprintf(__('Pages / %s filtered out of %s'),$counter->f(0),$totalcounter->f(0));
-	} else {
-		$page_title = __('Pages');
-		$filters_info = '';
-	}
-	$post_list->setItems($posts,$counter->f(0));
-} catch (Exception $e) {
-	$core->error->add($e->getMessage());
-}
-
 
 /* Display
@@ -254,20 +173,16 @@
   //]]>
   </script>
-<?php
-echo $filterSet->header();
-?>
 </head>
 
 <body>
 <?php
+echo '<h2>'.html::escapeHTML($core->blog->name).' &rsaquo; <span class="page-title">'.__('Pages').'</span></h2>'.
+'<p class="top-add"><a class="button add" href="'.$p_url.'&amp;act=page">'.__('New page').'</a></p>';
+
 if (!$core->error->flag())
 {
-	echo 
-	'<h2>'.html::escapeHTML($core->blog->name).' &rsaquo; <span class="page-title">'.__('Pages').'</span></h2>'.
-	'<p class="top-add"><a class="button add" href="'.$p_url.'&amp;act=page">'.__('New page').'</a></p>';
-
-	$filterSet->display();
 	# Show pages
-	$post_list->display('<form action="posts_actions.php" method="post" id="form-entries">'.
+	$post_list->display($page,$nb_per_page,
+	'<form action="posts_actions.php" method="post" id="form-entries">'.
 	
 	'%s'.
@@ -279,11 +194,10 @@
 	form::combo('action',$combo_action).
 	'<input type="submit" value="'.__('ok').'" /></p>'.
-	str_replace('%','%%',$filterSet->getFormFieldsAsHidden()).
+	form::hidden(array('post_type'),'page').
+	form::hidden(array('redir'),html::escapeHTML($_SERVER['REQUEST_URI'])).
 	$core->formNonce().
 	'</div>'.
-	'</form>'
-	);
-}
-
+	'</form>');
+}
 dcPage::helpBlock('pages');
 ?>
