From ea15ca6fcde02b3277ca904db00a2b537d7162a4 Mon Sep 17 00:00:00 2001 From: "sfraser%netscape.com" Date: Thu, 11 May 2000 22:47:19 +0000 Subject: [PATCH] Fix 38949 -- setSelectionRange broken by mjudge checking in nsGfxTextControlFrame2 stuff prematurely. --- content/html/content/src/nsHTMLInputElement.cpp | 10 +++++----- layout/html/content/src/nsHTMLInputElement.cpp | 10 +++++----- 2 files changed, 10 insertions(+), 10 deletions(-) diff --git a/content/html/content/src/nsHTMLInputElement.cpp b/content/html/content/src/nsHTMLInputElement.cpp index 26bf774fff67..33a669927d1d 100644 --- a/content/html/content/src/nsHTMLInputElement.cpp +++ b/content/html/content/src/nsHTMLInputElement.cpp @@ -1132,7 +1132,7 @@ nsHTMLInputElement::GetTextLength(PRInt32* aTextLength) nsresult rv = nsGenericHTMLElement::GetPrimaryFrame(this, formControlFrame); if (NS_SUCCEEDED(rv) && formControlFrame) { - nsCOMPtr textControlFrame(do_QueryInterface(formControlFrame)); + nsCOMPtr textControlFrame(do_QueryInterface(formControlFrame)); if (textControlFrame) textControlFrame->GetTextLength(aTextLength); @@ -1148,7 +1148,7 @@ nsHTMLInputElement::SetSelectionRange(PRInt32 aSelectionStart, PRInt32 aSelectio nsresult rv = nsGenericHTMLElement::GetPrimaryFrame(this, formControlFrame); if (NS_SUCCEEDED(rv) && formControlFrame) { - nsCOMPtr textControlFrame(do_QueryInterface(formControlFrame)); + nsCOMPtr textControlFrame(do_QueryInterface(formControlFrame)); if (textControlFrame) textControlFrame->SetSelectionRange(aSelectionStart, aSelectionEnd); @@ -1173,7 +1173,7 @@ nsHTMLInputElement::SetSelectionStart(PRInt32 aSelectionStart) nsresult rv = nsGenericHTMLElement::GetPrimaryFrame(this, formControlFrame); if (NS_SUCCEEDED(rv) && formControlFrame) { - nsCOMPtr textControlFrame(do_QueryInterface(formControlFrame)); + nsCOMPtr textControlFrame(do_QueryInterface(formControlFrame)); if (textControlFrame) textControlFrame->SetSelectionStart(aSelectionStart); @@ -1199,7 +1199,7 @@ nsHTMLInputElement::SetSelectionEnd(PRInt32 aSelectionEnd) nsresult rv = nsGenericHTMLElement::GetPrimaryFrame(this, formControlFrame); if (NS_SUCCEEDED(rv) && formControlFrame) { - nsCOMPtr textControlFrame(do_QueryInterface(formControlFrame)); + nsCOMPtr textControlFrame(do_QueryInterface(formControlFrame)); if (textControlFrame) textControlFrame->SetSelectionEnd(aSelectionEnd); @@ -1215,7 +1215,7 @@ nsHTMLInputElement::GetSelectionRange(PRInt32* aSelectionStart, PRInt32* aSelect nsresult rv = nsGenericHTMLElement::GetPrimaryFrame(this, formControlFrame); if (NS_SUCCEEDED(rv) && formControlFrame) { - nsCOMPtr textControlFrame(do_QueryInterface(formControlFrame)); + nsCOMPtr textControlFrame(do_QueryInterface(formControlFrame)); if (textControlFrame) textControlFrame->GetSelectionRange(aSelectionStart, aSelectionEnd); diff --git a/layout/html/content/src/nsHTMLInputElement.cpp b/layout/html/content/src/nsHTMLInputElement.cpp index 26bf774fff67..33a669927d1d 100644 --- a/layout/html/content/src/nsHTMLInputElement.cpp +++ b/layout/html/content/src/nsHTMLInputElement.cpp @@ -1132,7 +1132,7 @@ nsHTMLInputElement::GetTextLength(PRInt32* aTextLength) nsresult rv = nsGenericHTMLElement::GetPrimaryFrame(this, formControlFrame); if (NS_SUCCEEDED(rv) && formControlFrame) { - nsCOMPtr textControlFrame(do_QueryInterface(formControlFrame)); + nsCOMPtr textControlFrame(do_QueryInterface(formControlFrame)); if (textControlFrame) textControlFrame->GetTextLength(aTextLength); @@ -1148,7 +1148,7 @@ nsHTMLInputElement::SetSelectionRange(PRInt32 aSelectionStart, PRInt32 aSelectio nsresult rv = nsGenericHTMLElement::GetPrimaryFrame(this, formControlFrame); if (NS_SUCCEEDED(rv) && formControlFrame) { - nsCOMPtr textControlFrame(do_QueryInterface(formControlFrame)); + nsCOMPtr textControlFrame(do_QueryInterface(formControlFrame)); if (textControlFrame) textControlFrame->SetSelectionRange(aSelectionStart, aSelectionEnd); @@ -1173,7 +1173,7 @@ nsHTMLInputElement::SetSelectionStart(PRInt32 aSelectionStart) nsresult rv = nsGenericHTMLElement::GetPrimaryFrame(this, formControlFrame); if (NS_SUCCEEDED(rv) && formControlFrame) { - nsCOMPtr textControlFrame(do_QueryInterface(formControlFrame)); + nsCOMPtr textControlFrame(do_QueryInterface(formControlFrame)); if (textControlFrame) textControlFrame->SetSelectionStart(aSelectionStart); @@ -1199,7 +1199,7 @@ nsHTMLInputElement::SetSelectionEnd(PRInt32 aSelectionEnd) nsresult rv = nsGenericHTMLElement::GetPrimaryFrame(this, formControlFrame); if (NS_SUCCEEDED(rv) && formControlFrame) { - nsCOMPtr textControlFrame(do_QueryInterface(formControlFrame)); + nsCOMPtr textControlFrame(do_QueryInterface(formControlFrame)); if (textControlFrame) textControlFrame->SetSelectionEnd(aSelectionEnd); @@ -1215,7 +1215,7 @@ nsHTMLInputElement::GetSelectionRange(PRInt32* aSelectionStart, PRInt32* aSelect nsresult rv = nsGenericHTMLElement::GetPrimaryFrame(this, formControlFrame); if (NS_SUCCEEDED(rv) && formControlFrame) { - nsCOMPtr textControlFrame(do_QueryInterface(formControlFrame)); + nsCOMPtr textControlFrame(do_QueryInterface(formControlFrame)); if (textControlFrame) textControlFrame->GetSelectionRange(aSelectionStart, aSelectionEnd);