Added a comment explaining code added in r96834.
authormitz@apple.com <mitz@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 6 Oct 2011 23:40:22 +0000 (23:40 +0000)
committermitz@apple.com <mitz@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 6 Oct 2011 23:40:22 +0000 (23:40 +0000)
Suggested by Darin Adler.

* editing/FrameSelection.cpp:
(WebCore::FrameSelection::updateAppearance):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@96873 268f45cc-cd09-0410-ab3c-d52691b4dbfc

Source/WebCore/ChangeLog
Source/WebCore/editing/FrameSelection.cpp

index 405387ba9ada9068cf69fe9bd165dc1e9e85a14c..5fc369d799cd87629fdf3049a3cea821c8b31a6f 100644 (file)
@@ -1,3 +1,12 @@
+2011-10-06  Dan Bernstein  <mitz@apple.com>
+
+        Added a comment explaining code added in r96834.
+
+        Suggested by Darin Adler.
+
+        * editing/FrameSelection.cpp:
+        (WebCore::FrameSelection::updateAppearance):
+
 2011-10-05  Ryosuke Niwa  <rniwa@webkit.org>
 
         Deleting line break before h1 converts h1 to span
index 32c6b78d57bc01d41ff1efb680634ec68a1cad9d..35e9138dff82a450708660fdbbb37a79f584ad11 100644 (file)
@@ -1680,6 +1680,8 @@ void FrameSelection::updateAppearance()
     if (!view)
         return;
 
+    // Construct a new VisibleSolution, since m_selection is not necessarily valid, and the following steps
+    // assume a valid selection. See <https://bugs.webkit.org/show_bug.cgi?id=69563> and <rdar://problem/10232866>.
     VisibleSelection selection(m_selection.visibleStart(), m_selection.visibleEnd());
 
     if (!selection.isRange()) {