Bug 1063265 - Stop Blinking the Text Caret when it isn't visible. r=roc, a=bajaj
authorMason Chang <mchang@mozilla.com>
Sat, 06 Sep 2014 12:25:00 +0200
changeset 224664 b73932b2be075fb514c53538666f8621179a7f27
parent 224663 348fd67ac292acbcb1660f62619b35e0cb55522a
child 224665 b036cf84eac0ad70f127b370213ab48856f10bdb
push id3979
push userraliiev@mozilla.com
push dateMon, 13 Oct 2014 16:35:44 +0000
treeherdermozilla-beta@30f2cc610691 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersroc, bajaj
bugs1063265
milestone34.0a2
Bug 1063265 - Stop Blinking the Text Caret when it isn't visible. r=roc, a=bajaj
layout/base/nsCaret.cpp
--- a/layout/base/nsCaret.cpp
+++ b/layout/base/nsCaret.cpp
@@ -543,17 +543,17 @@ nsCaret::NotifySelectionChanged(nsIDOMDo
 
   return NS_OK;
 }
 
 void nsCaret::ResetBlinking()
 {
   mIsBlinkOn = true;
 
-  if (mReadOnly) {
+  if (mReadOnly || !mVisible) {
     StopBlinking();
     return;
   }
 
   if (mBlinkTimer) {
     mBlinkTimer->Cancel();
   } else {
     nsresult  err;