Skip to content
This repository was archived by the owner on Jul 9, 2025. It is now read-only.

Commit 83ee827

Browse files
Bug 1734771 - part 7: Get rid of ContentEventHandler::GetNativeTextLengthBefore() due to unused r=m_kato
Differential Revision: https://phabricator.services.mozilla.com/D128144
1 parent 372785e commit 83ee827

File tree

2 files changed

+0
-15
lines changed

2 files changed

+0
-15
lines changed

dom/events/ContentEventHandler.cpp

Lines changed: 0 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -583,17 +583,6 @@ uint32_t ContentEventHandler::GetNativeTextLength(const Text& aTextNode,
583583
return GetTextLength(aTextNode, LINE_BREAK_TYPE_NATIVE, aMaxLength);
584584
}
585585

586-
/* static */
587-
uint32_t ContentEventHandler::GetNativeTextLengthBefore(nsIContent* aContent,
588-
nsINode* aRootNode) {
589-
if (NS_WARN_IF(aContent->IsText())) {
590-
return 0;
591-
}
592-
return ShouldBreakLineBefore(*aContent, aRootNode)
593-
? GetBRLength(LINE_BREAK_TYPE_NATIVE)
594-
: 0;
595-
}
596-
597586
/* static inline */
598587
uint32_t ContentEventHandler::GetBRLength(LineBreakType aLineBreakType) {
599588
#if defined(XP_WIN)

dom/events/ContentEventHandler.h

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -255,10 +255,6 @@ class MOZ_STACK_CLASS ContentEventHandler {
255255
// Get the native text length of aTextNode.
256256
static uint32_t GetNativeTextLength(const dom::Text& aTextNode,
257257
uint32_t aMaxLength = UINT32_MAX);
258-
// Get the native text length which is inserted before aContent.
259-
// aContent should be an element.
260-
static uint32_t GetNativeTextLengthBefore(nsIContent* aContent,
261-
nsINode* aRootNode);
262258

263259
protected:
264260
// Get the text length of aTextNode.

0 commit comments

Comments
 (0)