Index: branches/2.2/phpgwapi/inc/class.vfs_shared.inc.php
===================================================================
--- branches/2.2/phpgwapi/inc/class.vfs_shared.inc.php	(revision 2)
+++ branches/2.2/phpgwapi/inc/class.vfs_shared.inc.php	(revision 5059)
@@ -419,4 +419,12 @@
 
 		/*!
+		* @function get_size_all
+		* @abstract Determine size of location
+		* @owner_id string	uid owner
+		*/
+		
+		function get_size_all($owner_id) { return 0; }
+		
+		/*!
 		 * @function get_size
 		 * @abstract Determine size of location
Index: branches/2.2/phpgwapi/inc/class.vfs_sql.inc.php
===================================================================
--- branches/2.2/phpgwapi/inc/class.vfs_sql.inc.php	(revision 3743)
+++ branches/2.2/phpgwapi/inc/class.vfs_sql.inc.php	(revision 5059)
@@ -2512,4 +2512,15 @@
 			return $size;
 		}
+		
+		function get_size_all($owner_id)
+		{
+			$query = $GLOBALS['phpgw']->db->query ("SELECT Sum(size) FROM phpgw_vfs WHERE owner_id = '".$owner_id."'" .
+													$this->extra_sql(array ('query_text' => VFS_SQL_SELECT)));
+			$GLOBALS['phpgw']->db->next_record ();
+			
+			$size = $GLOBALS['phpgw']->db->Record[0];			
+			
+			return $size;
+		}		
 
 		/*return the total number of files in path*/
Index: branches/2.2/filemanager/tp/expressowindow/xsl/historyFile.xsl
===================================================================
--- branches/2.2/filemanager/tp/expressowindow/xsl/historyFile.xsl	(revision 3885)
+++ branches/2.2/filemanager/tp/expressowindow/xsl/historyFile.xsl	(revision 5059)
@@ -14,10 +14,10 @@
 	<xsl:template match="file">
 		
-		<div style="font-size:10pt; margin: 6px;">
+		<div style="font-size:10pt; margin: 10px 6px 10px 6px; border-bottom:1px solid #000;">
 			<img src="{$path_filemanager}templates/default/images/button_info.png" style="margin-right: 5px;"/>
 			<label style="font-size:12px;font-weight:bold;"> <xsl:value-of select="$lang_history" /></label>
 		</div>
 		
-		<div style='margin:6px; width:{($width)-20}px ; height:{($height)-40}px; overflow-y: auto; text-align: left;'>
+		<div style='margin:6px; width:{($width)-20}px ; height:{($height)-80}px; overflow-y: auto; text-align: left;'>
 			<xsl:for-each select="info">
 				<div style="margin-bottom:10px;">
Index: branches/2.2/filemanager/inc/class.vfs_functions.inc.php
===================================================================
--- branches/2.2/filemanager/inc/class.vfs_functions.inc.php	(revision 3924)
+++ branches/2.2/filemanager/inc/class.vfs_functions.inc.php	(revision 5059)
@@ -134,14 +134,33 @@
 		}
 		
+		function convertDateForm($pDate)
+		{
+			/**
+			 * Recebe a data no formato	 : aaaa-mm-dd
+			 * Retorna a data no formato : dd/mm/aaaa
+			 **/
+		
+			$cDate = date_parse($pDate);
+			$day   = ( strlen($cDate['day']) > 1 ) ? $cDate['day'] : "0".$cDate['day'];
+			$month = ( strlen($cDate['month']) > 1 ) ? $cDate['month'] : "0".$cDate['month'];
+			$year  = $cDate['year'];
+		
+			return $day."/".$month."/".$year;
+		}
+		
 		// String format is YYYY-MM-DD HH:MM
 		function dateString2timeStamp($string)
 		{
-			return mktime($string[11].$string[12],
-				$string[14].$string[15],
-				$string[17].$string[18], 
-				$string[5].$string[6], 
-				$string[8].$string[9],
-				$string[0].$string[1].
-				$string[2].$string[3]);
+			/**
+			 * Recebe a data no formato	 : aaaa-mm-dd
+			 * Retorna a data no formato : dd/mm/aaaa
+			 **/
+		
+			$cDate = date_parse($string);
+			$day   = ( strlen($cDate['day']) > 1 ) ? $cDate['day'] : "0".$cDate['day'];
+			$month = ( strlen($cDate['month']) > 1 ) ? $cDate['month'] : "0".$cDate['month'];
+			$year  = $cDate['year'];
+		
+			return $day."/".$month."/".$year;
 		}
 		
Index: branches/2.2/filemanager/inc/class.uifilemanager.inc.php
===================================================================
--- branches/2.2/filemanager/inc/class.uifilemanager.inc.php	(revision 4915)
+++ branches/2.2/filemanager/inc/class.uifilemanager.inc.php	(revision 5059)
@@ -337,7 +337,4 @@
 		echo "<script src='" . $GLOBALS['phpgw_info']['flags']['currentapp'] . "/js/handler.js'></script>";
 		
-		//echo "<script src='" . $GLOBALS['phpgw_info']['flags']['currentapp'] . "/js/NewHandler.js'></script>";
-
-
 		// Temas Expresso
 		$theme = "window_" . $GLOBALS['phpgw_info']['user']['preferences']['common']['theme'] . ".css";
@@ -529,22 +526,24 @@
 	}
 
-	function dir_ls() {
+	function dir_ls()
+	{
 		// change dir to this->path
 		$this->bo->vfs->cd(array('string' => $this->path, 'relatives' => array(RELATIVE_NONE), 'relative' => False));
 		$return['permissions'] = $this->get_permissions();
-		$return['quota']['usedSpace'] = $this->bo->vfs->get_size(array(
+		/*$return['quota']['usedSpace'] = $this->bo->vfs->get_size(array(
 						'string' => $this->path,
 						'relatives' => array(RELATIVE_NONE)
-				  ));
-		$return['files_count'] = $this->bo->vfs->count_files(array(
-						'string' => $this->path,
-				  ));
-		$quota = $this->bo->vfs->get_quota(array(
-						'string' => $this->path
-				  ));
+				  ));*/
+		
+		$return['quota']['usedSpace'] = $this->bo->vfs->get_size_all( $GLOBALS['phpgw_info']['user']['account_id'] );
+		$return['files_count'] = $this->bo->vfs->count_files(array( 'string' => $this->path ));
+		
+		$quota = $this->bo->vfs->get_quota(array('string' => $this->bo->homedir ));
+		
 		reset($this->files_array);
 		$this->readFilesInfo();
 
-		for ($i = 0; $i != $this->numoffiles; $i++) {
+		for ($i = 0; $i != $this->numoffiles; $i++)
+		{
 			$files = $this->files_array[$i];
 
@@ -554,8 +553,10 @@
 			/* small keys to safe bandwidth */
 			$tuple['name'] = htmlentities($files['name']);
-			if ($_SESSION['phpgw_info']['user']['preferences']['filemanager']['viewIcons'] == 1) {
+			if ($_SESSION['phpgw_info']['user']['preferences']['filemanager']['viewIcons'] == 1) 
+			{
 				if ($files['mime_type'] == 'image/png' ||
 						  $files['mime_type'] == 'image/gif' ||
-						  $files['mime_type'] == 'image/jpg') {
+						  $files['mime_type'] == 'image/jpg')
+				{
 					$filename = str_replace('=', '', base64_encode($tuple['name']));
 					$pathname = str_replace('=', '', base64_encode($this->path));
@@ -567,20 +568,21 @@
 			else
 				$tuple['icon'] = $this->mime_icon($files['mime_type']);
-			$tuple['type'] = $files['type'];
-			$tuple['created'] = $this->vfs_functions->dateString2timeStamp($files['created']);
-			$tuple['modified'] = $this->vfs_functions->dateString2timeStamp($files['modified']);
-			$tuple['size'] = $files['size'];
-			$tuple['mime_type'] = $files['mime_type'];
-			$tuple['pub'] = $files['type'];
-			$tuple['createdby_id'] = $GLOBALS['phpgw']->accounts->id2name($files['createdby_id']);
+
+			$tuple['type']			= $files['type'];
+			$tuple['created']		= $this->vfs_functions->dateString2timeStamp($files['created']);
+			$tuple['modified']		= ( $files['modified'] != "" ) ? $this->vfs_functions->dateString2timeStamp($files['modified']) : "";
+			$tuple['size']			= $files['size'];
+			$tuple['mime_type']		= $files['mime_type'];
+			$tuple['pub']			= $files['type'];
+			$tuple['createdby_id'] 	= $GLOBALS['phpgw']->accounts->id2name($files['createdby_id']);
 			$tuple['modifiedby_id'] = $files['modifiedby_id'] ? $GLOBALS['phpgw']->accounts->id2name($files['modifiedby_id']) : '';
-			$tuple['owner'] = $GLOBALS['phpgw']->accounts->id2name($files['owner_id']);
-			$tuple['comment'] = $files['comment'];
-			$tuple['version'] = $files['version'];
+			$tuple['owner']			= $GLOBALS['phpgw']->accounts->id2name($files['owner_id']);
+			$tuple['comment']		= $files['comment'];
+			$tuple['version']		= $files['version'];
+			
 			$output[] = $tuple;
 		}
 		$return['files'] = $output;
 		$return['quota']['quotaSize'] = ($quota * 1024 * 1024);
-		//echo serialize(htmlspecialchars_decode(htmlentities($return)));
 		echo serialize($return);
 	}
@@ -1010,5 +1012,5 @@
 				{
 					$historyFile[] = array(
-											"created"	=> $journal_entry['created'],
+											"created"	=> $this->vfs_functions->dateString2timeStamp($journal_entry['created']),
 											"version"	=> $journal_entry['version'],
 											"who"		=> $GLOBALS['phpgw']->accounts->id2name($journal_entry['owner_id']),
