Index: branches/2.3/expressoMail1_2/index.php
===================================================================
--- branches/2.3/expressoMail1_2/index.php	(revision 5277)
+++ branches/2.3/expressoMail1_2/index.php	(revision 5319)
@@ -83,4 +83,7 @@
 	$_SESSION['phpgw_info']['user']['preferences']['expressoMail']['notification_domains'] = $current_config['expressoMail_notification_domains'];
 	$_SESSION['phpgw_info']['user']['preferences']['expressoMail']['googlegears_url'] = $current_config['expressoMail_googlegears_url'];
+	$_SESSION['phpgw_info']['user']['preferences']['expressoMail']['gears_firefox_windows'] = $current_config['expressoMail_gears_firefox_windows'];
+	$_SESSION['phpgw_info']['user']['preferences']['expressoMail']['gears_firefox_linux'] = $current_config['expressoMail_gears_firefox_linux'];
+	$_SESSION['phpgw_info']['user']['preferences']['expressoMail']['gears_ie'] = $current_config['expressoMail_gears_ie'];
     $_SESSION['phpgw_info']['user']['preferences']['expressoMail']['use_assinar_criptografar'] = $GLOBALS['phpgw_info']['server']['use_assinar_criptografar'] ?  $GLOBALS['phpgw_info']['server']['use_assinar_criptografar'] : "0";
     $_SESSION['phpgw_info']['user']['preferences']['expressoMail']['use_signature_digital_cripto'] = $GLOBALS['phpgw_info']['user']['preferences']['expressoMail']['use_signature_digital_cripto'] ? $GLOBALS['phpgw_info']['user']['preferences']['expressoMail']['use_signature_digital_cripto'] : "0";
Index: branches/2.3/expressoMail1_2/js/main.js
===================================================================
--- branches/2.3/expressoMail1_2/js/main.js	(revision 5277)
+++ branches/2.3/expressoMail1_2/js/main.js	(revision 5319)
@@ -25,18 +25,25 @@
 		if(parseInt(version)==7 && (/trident\/\d/i.test(navigator.userAgent)))
                         preferences.use_local_messages="0";
-		
+	
+		if ( preferences.use_local_messages == '1' && (!window.google || !google.gears)) {
+                                temp = confirm(get_lang("To use local messages you have to install google gears. Would you like to be redirected to gears installation page?"));
+                                if (temp) {
+                                       if(is_win && is_gecko && preferences.gears_firefox_windows != null)
+                                            location.href = preferences.gears_firefox_windows;
+                                       else if(!is_win && is_gecko && preferences.gears_firefox_linux != null)
+                                           location.href = preferences.gears_firefox_linux;
+                                       else if(is_ie && preferences.gears_ie != null)
+                                           location.href = preferences.gears_ie;
+                                       else
+                                            location.href = "http://gears.google.com/?action=install&message="+get_lang("To use local messages, install Google Gears")+"&return="+document.location.href;
+                                }
+                                else {
+                                        preferences.use_local_messages=0;
+                                }
+		}
+
 		if( (window.google && google.gears) && !google.gears.factory.getPermission())
 		    preferences.use_local_messages=0;
                 
-		if ((preferences.use_local_messages==1) && (!window.google || !google.gears)) {
-		    temp = confirm(get_lang("To use local messages you have to install google gears. Would you like to be redirected to gears installation page?"));
-		    if (temp) {
-			    location.href = "http://gears.google.com/?action=install&message="+
-			    "Para utilizar o recurso de mensagens locais, instale o google gears&return=" + document.location.href;
-		    }
-		    else {
-			    preferences.use_local_messages=0;
-		    }
-		}
 		if (preferences.use_local_messages==1) { //O I.E 7 estava se atrapalhando caso esses loads fossem feitos após as chamadas ajax. Antes não apresentou problemas...
 			connector.loadScript('mail_sync');
Index: branches/2.3/expressoMail1_2/js/draw_api.js
===================================================================
--- branches/2.3/expressoMail1_2/js/draw_api.js	(revision 4977)
+++ branches/2.3/expressoMail1_2/js/draw_api.js	(revision 5319)
@@ -152,26 +152,4 @@
 		 */
 		if (preferences.use_local_messages==1 || expresso_offline) {
-			if (!window.google || !google.gears) {
-				if (!expresso_local_messages.installGears())
-					preferences.use_local_messages=0;
-			}
-			else{
-				if (!window.google || !google.gears) {
-				temp = confirm(get_lang("To use local messages you have to install google gears. Would you like to be redirected to gears installation page?"));
-				if (temp) {
-                                       if(is_win && is_gecko && preferences.gears_firefox_windows != "")
-                                            location.href = preferences.gears_firefox_windows;
-                                       else if(!is_win && is_gecko && preferences.gears_firefox_linux != "")
-                                           location.href = preferences.gears_firefox_linux;
-                                       else if(is_ie && preferences.gears_ie != "")
-                                           location.href = preferences.gears_ie;
-                                       else
-                                            location.href = "http://gears.google.com/?action=install&message="+get_lang("To use local messages, install Google Gears")+"&return="+document.location.href;
-				}
-				else {
-					preferences.use_local_messages=0;
-				}
-			}
-			else{
 				if (expresso_offline)
 					tree_folders = new dFTree({
@@ -207,7 +185,5 @@
 						});
 						tree_folders.add(nodeLocal, node_root);
-					}
 				}
-			}
 		}
 
