Bug 1216857 - Notify selection dialog to update its position if carets are logically visible. r=TYLin
authorJeremy Chen <jeremychen@mozilla.com>
Fri, 23 Oct 2015 10:21:16 +0800
changeset 304851 1650689e3fdbe69a67bd7b8f69bab1c8570861b4
parent 304850 ec5247a32592e3a0fd43b59f4109414cd11653c0
child 304852 21cc3138e88410ab02c1cd5a979a9c49cbd4dc3b
push id1001
push userraliiev@mozilla.com
push dateMon, 18 Jan 2016 19:06:03 +0000
treeherdermozilla-release@8b89261f3ac4 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersTYLin
bugs1216857
milestone44.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1216857 - Notify selection dialog to update its position if carets are logically visible. r=TYLin
layout/base/AccessibleCaretManager.cpp
--- a/layout/base/AccessibleCaretManager.cpp
+++ b/layout/base/AccessibleCaretManager.cpp
@@ -286,21 +286,17 @@ AccessibleCaretManager::UpdateCaretsForS
   if (firstCaretResult == PositionChangedResult::Changed ||
       secondCaretResult == PositionChangedResult::Changed) {
     // Flush layout to make the carets intersection correct.
     FlushLayout();
   }
 
   UpdateCaretsForTilt();
 
-  if ((firstCaretResult == PositionChangedResult::Changed ||
-       secondCaretResult == PositionChangedResult::Changed ||
-       firstCaretResult == PositionChangedResult::Invisible ||
-       secondCaretResult == PositionChangedResult::Invisible) &&
-      !mActiveCaret) {
+  if (!mActiveCaret) {
     DispatchCaretStateChangedEvent(CaretChangedReason::Updateposition);
   }
 }
 
 void
 AccessibleCaretManager::UpdateCaretsForTilt()
 {
   if (mFirstCaret->IsVisuallyVisible() && mSecondCaret->IsVisuallyVisible()) {