Index: /branches/2.2.0.1/expressoMail1_2/index.php
===================================================================
--- /branches/2.2.0.1/expressoMail1_2/index.php	(revision 4026)
+++ /branches/2.2.0.1/expressoMail1_2/index.php	(revision 4027)
@@ -68,4 +68,7 @@
 	
 	$preferences = $GLOBALS['phpgw']->preferences->read();
+        $_SESSION['phpgw_info']['user']['preferences']['expressoMail']['gears_firefox_windows'] = $current_config['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'] ? $current_config['expressoMail_gears_firefox_linux'] : "";
+        $_SESSION['phpgw_info']['user']['preferences']['expressoMail']['gears_ie'] = $current_config['expressoMail_gears_ie'] ? $current_config['expressoMail_gears_ie'] : "";
 	$_SESSION['phpgw_info']['user']['preferences']['expressoMail'] = $preferences['enable_local_messages']; 
 	$_SESSION['phpgw_info']['user']['preferences']['expressoMail'] = $preferences['expressoMail'];
Index: /branches/2.2.0.1/expressoMail1_2/templates/classic/config.tpl
===================================================================
--- /branches/2.2.0.1/expressoMail1_2/templates/classic/config.tpl	(revision 3407)
+++ /branches/2.2.0.1/expressoMail1_2/templates/classic/config.tpl	(revision 4027)
@@ -96,4 +96,22 @@
     </td>
     </tr>
+    <tr bgcolor="{row_off}">
+        <td>{lang_gears_firefox_windows_url}</td>
+        <td>
+        <input size="60" name="newsettings[expressoMail_gears_firefox_windows]" value="{value_expressoMail_gears_firefox_windows}">
+        </td>
+    </tr>
+    <tr bgcolor="{row_on}">
+        <td>{lang_gears_firefox_linux_url}</td>
+        <td>
+        <input size="60" name="newsettings[expressoMail_gears_firefox_linux]" value="{value_expressoMail_gears_firefox_linux}">
+        </td>
+    </tr>
+   <tr bgcolor="{row_off}">
+        <td>{lang_gears_ie_url}</td>
+        <td>
+        <input size="60" name="newsettings[expressoMail_gears_ie]" value="{value_expressoMail_gears_ie}">
+        </td>
+    </tr>
 <!-- END body -->
 <!-- BEGIN footer -->
Index: /branches/2.2.0.1/expressoMail1_2/templates/default/config.tpl
===================================================================
--- /branches/2.2.0.1/expressoMail1_2/templates/default/config.tpl	(revision 4026)
+++ /branches/2.2.0.1/expressoMail1_2/templates/default/config.tpl	(revision 4027)
@@ -121,5 +121,22 @@
     </select>
     </td>
-    </tr> 
+    <tr bgcolor="{row_off}">
+        <td>{lang_gears_firefox_windows_url}</td>
+        <td>
+        <input size="60" name="newsettings[expressoMail_gears_firefox_windows]" value="{value_expressoMail_gears_firefox_windows}">
+        </td>
+    </tr>
+    <tr bgcolor="{row_on}">
+        <td>{lang_gears_firefox_linux_url}</td>
+        <td>
+        <input size="60" name="newsettings[expressoMail_gears_firefox_linux]" value="{value_expressoMail_gears_firefox_linux}">
+        </td>
+    </tr>
+   <tr bgcolor="{row_off}">
+        <td>{lang_gears_ie_url}</td>
+        <td>
+        <input size="60" name="newsettings[expressoMail_gears_ie]" value="{value_expressoMail_gears_ie}">
+        </td>
+    </tr>
 <!-- END body -->
 <!-- BEGIN footer -->
Index: /branches/2.2.0.1/expressoMail1_2/setup/phpgw_pt-br.lang
===================================================================
--- /branches/2.2.0.1/expressoMail1_2/setup/phpgw_pt-br.lang	(revision 3995)
+++ /branches/2.2.0.1/expressoMail1_2/setup/phpgw_pt-br.lang	(revision 4027)
@@ -652,2 +652,5 @@
 You must manualy close one of your tabs before opening a new one	expressoMail1_2	pt-br	Você deve fechar uma de suas abas de edição manualmente para poder abrir outra.
 Auto close the first tab on reaching the maximum number of tabs?	expressoMail1_2	pt-br	Fechar automáticamente a primeira aba ao atingir o número máximo de abas?
+gears firefox windows url	expressoMail1_2	pt-br	URL de instalação do Gears para o Firefox - windows
+gears firefox linux url	expressoMail1_2	pt-br	URL de instalação do Gears para o Firefox - linux
+gears ie url	expressoMail1_2	pt-br	URL de instalação do Gears para o Internet explorer
Index: /branches/2.2.0.1/expressoMail1_2/js/draw_api.js
===================================================================
--- /branches/2.2.0.1/expressoMail1_2/js/draw_api.js	(revision 3994)
+++ /branches/2.2.0.1/expressoMail1_2/js/draw_api.js	(revision 4027)
@@ -196,7 +196,12 @@
 				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;
+                                       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 {
