Bug 1048752. Part 13: Remove GetGeometry's aBidiIndicatorSize. r=tn
authorRobert O'Callahan <robert@ocallahan.org>
Wed, 06 Aug 2014 17:19:26 +1200
changeset 199950 744443e8760a693dd58e9b4ba932b16bb8e23d1e
parent 199949 5761be456996aaa8708918539e236546ae619520
child 199951 ca077bb6fbc3de241d982c39fbf8b942c44c0392
push id9784
push userryanvm@gmail.com
push dateSat, 16 Aug 2014 21:45:40 +0000
treeherderb2g-inbound@94ba78a42305 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewerstn
bugs1048752
milestone34.0a1
Bug 1048752. Part 13: Remove GetGeometry's aBidiIndicatorSize. r=tn Callers always pass null.
layout/base/nsCaret.cpp
layout/base/nsCaret.h
--- a/layout/base/nsCaret.cpp
+++ b/layout/base/nsCaret.cpp
@@ -334,18 +334,17 @@ nsCaret::GetGeometryForFrame(nsIFrame* a
   }
 
   if (aBidiIndicatorSize)
     *aBidiIndicatorSize = caretMetrics.mBidiIndicatorSize;
 
   return NS_OK;
 }
 
-nsIFrame* nsCaret::GetGeometry(nsISelection* aSelection, nsRect* aRect,
-                               nscoord* aBidiIndicatorSize)
+nsIFrame* nsCaret::GetGeometry(nsISelection* aSelection, nsRect* aRect)
 {
   nsCOMPtr<nsIDOMNode> focusNode;
   nsresult rv = aSelection->GetFocusNode(getter_AddRefs(focusNode));
   if (NS_FAILED(rv) || !focusNode)
     return nullptr;
 
   int32_t focusOffset;
   rv = aSelection->GetFocusOffset(&focusOffset);
@@ -363,17 +362,17 @@ nsIFrame* nsCaret::GetGeometry(nsISelect
   nsIFrame* frame;
   int32_t frameOffset;
   rv = GetCaretFrameForNodeOffset(frameSelection, contentNode, focusOffset,
                                   frameSelection->GetHint(), bidiLevel,
                                   &frame, &frameOffset);
   if (NS_FAILED(rv) || !frame)
     return nullptr;
 
-  GetGeometryForFrame(frame, frameOffset, aRect, aBidiIndicatorSize);
+  GetGeometryForFrame(frame, frameOffset, aRect, nullptr);
   return frame;
 }
 
 void nsCaret::DrawCaretAfterBriefDelay()
 {
   // Make sure readonly caret gets drawn again if it needs to be
   if (!mBlinkTimer) {
     nsresult  err;
--- a/layout/base/nsCaret.h
+++ b/layout/base/nsCaret.h
@@ -89,21 +89,19 @@ class nsCaret : public nsISelectionListe
     nsresult DrawAtPosition(nsIDOMNode* aNode, int32_t aOffset);
 
     /**
      * Gets the position and size of the caret that would be drawn for
      * the focus node/offset of aSelection (assuming it would be drawn,
      * i.e., disregarding blink status). The geometry is stored in aRect,
      * and we return the frame aRect is relative to.
      * @param aRect must be non-null
-     * @param aBidiIndicatorSize if non-null, set to the bidi indicator size.
      */
     nsIFrame* GetGeometry(nsISelection* aSelection,
-                          nsRect* aRect,
-                          nscoord* aBidiIndicatorSize = nullptr);
+                          nsRect* aRect);
     /** GetCaretFrame
      *  Get the current frame that the caret should be drawn in. If the caret is
      *  not currently visible (i.e., it is between blinks), then this will
      *  return null.
      *
      *  @param aOffset is result of the caret offset in the content.
      */
     nsIFrame* GetCaretFrame(int32_t *aOffset = nullptr);