Bug 1343886. Handle input or textarea elements having a non-textcontrol frame better. r=ehsan
MozReview-Commit-ID: FRzdvTLMAID
This commit is contained in:
@@ -1553,11 +1553,13 @@ nsresult
|
||||
nsTextEditorState::GetSelectionRange(int32_t* aSelectionStart,
|
||||
int32_t* aSelectionEnd)
|
||||
{
|
||||
MOZ_ASSERT(mBoundFrame,
|
||||
"Caller didn't flush out frames and check for a frame?");
|
||||
MOZ_ASSERT(aSelectionStart);
|
||||
MOZ_ASSERT(aSelectionEnd);
|
||||
|
||||
if (!mBoundFrame) {
|
||||
return NS_ERROR_FAILURE;
|
||||
}
|
||||
|
||||
// It's not clear that all the checks here are needed, but the previous
|
||||
// version of this code in nsTextControlFrame was doing them, so we keep them
|
||||
// for now.
|
||||
|
||||
Reference in New Issue
Block a user