You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@myfaces.apache.org by lo...@apache.org on 2012/09/18 14:45:46 UTC

svn commit: r1387123 - /myfaces/tobago/branches/tobago-1.0.x/theme/standard/src/main/resources/org/apache/myfaces/tobago/renderkit/html/standard/standard/script/tobago.js

Author: lofwyr
Date: Tue Sep 18 12:45:46 2012
New Revision: 1387123

URL: http://svn.apache.org/viewvc?rev=1387123&view=rev
Log:
TOBAGO-1201: Clicking into an empty cell of an Ajax-enabled tc:sheet leads to JavaScript error

Modified:
    myfaces/tobago/branches/tobago-1.0.x/theme/standard/src/main/resources/org/apache/myfaces/tobago/renderkit/html/standard/standard/script/tobago.js

Modified: myfaces/tobago/branches/tobago-1.0.x/theme/standard/src/main/resources/org/apache/myfaces/tobago/renderkit/html/standard/standard/script/tobago.js
URL: http://svn.apache.org/viewvc/myfaces/tobago/branches/tobago-1.0.x/theme/standard/src/main/resources/org/apache/myfaces/tobago/renderkit/html/standard/standard/script/tobago.js?rev=1387123&r1=1387122&r2=1387123&view=diff
==============================================================================
--- myfaces/tobago/branches/tobago-1.0.x/theme/standard/src/main/resources/org/apache/myfaces/tobago/renderkit/html/standard/standard/script/tobago.js (original)
+++ myfaces/tobago/branches/tobago-1.0.x/theme/standard/src/main/resources/org/apache/myfaces/tobago/renderkit/html/standard/standard/script/tobago.js Tue Sep 18 12:45:46 2012
@@ -1405,7 +1405,11 @@ var Tobago = {
     */
   clearSelection: function() {
     if (document.selection) {  // IE
-      document.selection.empty();
+      try {
+        document.selection.empty();
+      } catch (error) {
+        // Ignore error: seems to be a browser bug (TOBAGO-1201)
+      }
     } else if (window.getSelection) {  // GECKO
       window.getSelection().removeAllRanges();
     }