mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-12-14 10:43:24 +00:00
Bug 68012: Allow frames in a frameset to be manually resized by dragging the border. This is accomplished by changing the reflow from a ResizeReflow, which was blocked by block to box adapter optimizations as the window had not changed size, to a ReflowDirtyChild. r=jst@netscape.com, sr=attinasi@netscape.com, a=drivers@mozilla.org (blizzard)
This commit is contained in:
parent
b107830d2d
commit
cfa0ec9b73
@ -1550,9 +1550,21 @@ nsHTMLFramesetFrame::MouseDrag(nsIPresContext* aPresContext,
|
||||
|
||||
if (change != 0) {
|
||||
mDrag.Reset(mDragger->mVertical, mDragger->mPrevNeighbor, change, this);
|
||||
nsIFrame* parentFrame = nsnull;
|
||||
GetParent((nsIFrame**)&parentFrame);
|
||||
if (!parentFrame) {
|
||||
return;
|
||||
}
|
||||
|
||||
nsCOMPtr<nsIPresShell> shell;
|
||||
aPresContext->GetShell(getter_AddRefs(shell));
|
||||
shell->ResizeReflow(mTopLevelFrameset->mRect.width, mTopLevelFrameset->mRect.height);
|
||||
if (!shell) {
|
||||
return;
|
||||
}
|
||||
|
||||
parentFrame->ReflowDirtyChild(shell, this);
|
||||
|
||||
// Update the view immediately (make drag appear snappier)
|
||||
nsCOMPtr<nsIViewManager> vm;
|
||||
shell->GetViewManager(getter_AddRefs(vm));
|
||||
if (vm) {
|
||||
|
@ -1550,9 +1550,21 @@ nsHTMLFramesetFrame::MouseDrag(nsIPresContext* aPresContext,
|
||||
|
||||
if (change != 0) {
|
||||
mDrag.Reset(mDragger->mVertical, mDragger->mPrevNeighbor, change, this);
|
||||
nsIFrame* parentFrame = nsnull;
|
||||
GetParent((nsIFrame**)&parentFrame);
|
||||
if (!parentFrame) {
|
||||
return;
|
||||
}
|
||||
|
||||
nsCOMPtr<nsIPresShell> shell;
|
||||
aPresContext->GetShell(getter_AddRefs(shell));
|
||||
shell->ResizeReflow(mTopLevelFrameset->mRect.width, mTopLevelFrameset->mRect.height);
|
||||
if (!shell) {
|
||||
return;
|
||||
}
|
||||
|
||||
parentFrame->ReflowDirtyChild(shell, this);
|
||||
|
||||
// Update the view immediately (make drag appear snappier)
|
||||
nsCOMPtr<nsIViewManager> vm;
|
||||
shell->GetViewManager(getter_AddRefs(vm));
|
||||
if (vm) {
|
||||
|
Loading…
Reference in New Issue
Block a user