From 100348226b5b8ff1070a4ccbf3f5b1df7feb751a Mon Sep 17 00:00:00 2001 From: "robin.lu%sun.com" Date: Fri, 11 Jun 2004 08:03:16 +0000 Subject: [PATCH] fix bug 220390 ACCESSKEY incorrectly supported on multiline SELECT tag. patched by Nian Liu (neo.liu@sun.com). r=aaronleventhal sr=jst git-svn-id: svn://10.0.0.236/trunk@157767 18797224-902f-48f8-a5cc-f745e15eee43 --- mozilla/layout/forms/nsListControlFrame.cpp | 8 ++------ mozilla/layout/html/forms/src/nsListControlFrame.cpp | 8 ++------ 2 files changed, 4 insertions(+), 12 deletions(-) diff --git a/mozilla/layout/forms/nsListControlFrame.cpp b/mozilla/layout/forms/nsListControlFrame.cpp index bf319b3b324..bb07550e425 100644 --- a/mozilla/layout/forms/nsListControlFrame.cpp +++ b/mozilla/layout/forms/nsListControlFrame.cpp @@ -501,9 +501,7 @@ nsListControlFrame::Destroy(nsIPresContext *aPresContext) mEventListener), NS_GET_IID(nsIDOMKeyListener)); - if (IsInDropDownMode() == PR_FALSE) { - nsFormControlFrame::RegUnRegAccessKey(aPresContext, NS_STATIC_CAST(nsIFrame*, this), PR_FALSE); - } + nsFormControlFrame::RegUnRegAccessKey(aPresContext, NS_STATIC_CAST(nsIFrame*, this), PR_FALSE); return nsGfxScrollFrame::Destroy(aPresContext); } @@ -1058,9 +1056,7 @@ nsListControlFrame::Reflow(nsIPresContext* aPresContext, // Add the list frame as a child of the form if (eReflowReason_Initial == aReflowState.reason) { - if (!IsInDropDownMode()) { - nsFormControlFrame::RegUnRegAccessKey(aPresContext, NS_STATIC_CAST(nsIFrame*, this), PR_TRUE); - } + nsFormControlFrame::RegUnRegAccessKey(aPresContext, NS_STATIC_CAST(nsIFrame*, this), PR_TRUE); } //--Calculate a width just big enough for the scrollframe to shrink around the diff --git a/mozilla/layout/html/forms/src/nsListControlFrame.cpp b/mozilla/layout/html/forms/src/nsListControlFrame.cpp index bf319b3b324..bb07550e425 100644 --- a/mozilla/layout/html/forms/src/nsListControlFrame.cpp +++ b/mozilla/layout/html/forms/src/nsListControlFrame.cpp @@ -501,9 +501,7 @@ nsListControlFrame::Destroy(nsIPresContext *aPresContext) mEventListener), NS_GET_IID(nsIDOMKeyListener)); - if (IsInDropDownMode() == PR_FALSE) { - nsFormControlFrame::RegUnRegAccessKey(aPresContext, NS_STATIC_CAST(nsIFrame*, this), PR_FALSE); - } + nsFormControlFrame::RegUnRegAccessKey(aPresContext, NS_STATIC_CAST(nsIFrame*, this), PR_FALSE); return nsGfxScrollFrame::Destroy(aPresContext); } @@ -1058,9 +1056,7 @@ nsListControlFrame::Reflow(nsIPresContext* aPresContext, // Add the list frame as a child of the form if (eReflowReason_Initial == aReflowState.reason) { - if (!IsInDropDownMode()) { - nsFormControlFrame::RegUnRegAccessKey(aPresContext, NS_STATIC_CAST(nsIFrame*, this), PR_TRUE); - } + nsFormControlFrame::RegUnRegAccessKey(aPresContext, NS_STATIC_CAST(nsIFrame*, this), PR_TRUE); } //--Calculate a width just big enough for the scrollframe to shrink around the