Bug 3256: Add ScrollIntoView() method to form frame objects.

git-svn-id: svn://10.0.0.236/trunk@43912 18797224-902f-48f8-a5cc-f745e15eee43
This commit is contained in:
pollmann%netscape.com
1999-08-21 00:09:24 +00:00
parent 509fb31739
commit 60e2a67f05
22 changed files with 196 additions and 24 deletions

View File

@@ -43,7 +43,7 @@
#include "nsIDOMDocument.h"
#include "nsDocument.h"
#include "nsIDOMMouseListener.h"
#include "nsIPresShell.h"
static NS_DEFINE_IID(kCFileWidgetCID, NS_FILEWIDGET_CID);
@@ -188,6 +188,18 @@ nsFileControlFrame::SetFocus(PRBool aOn, PRBool aRepaint)
}
}
void
nsFileControlFrame::ScrollIntoView(nsIPresContext* aPresContext)
{
if (aPresContext) {
nsCOMPtr<nsIPresShell> presShell;
aPresContext->GetShell(getter_AddRefs(presShell));
presShell->ScrollFrameIntoView(this,
NS_PRESSHELL_SCROLL_ANYWHERE,NS_PRESSHELL_SCROLL_ANYWHERE);
}
}
/**
* This is called when our browse button is clicked
*/