Skip to content

Commit

Permalink
Backed out changeset 64abec51f1cb (bug 1710533) for causing failures …
Browse files Browse the repository at this point in the history
…at test_panel.xhtml. CLOSED TREE
  • Loading branch information
Butkovits Atila committed May 12, 2021
1 parent b770282 commit fed1064
Show file tree
Hide file tree
Showing 3 changed files with 1 addition and 12 deletions.
3 changes: 0 additions & 3 deletions view/nsView.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -332,9 +332,6 @@ void nsView::DoResetWidgetBounds(bool aMoveOnly, bool aInvalidateChangedSize) {
return;
}

// Apply the widget size constraints to newBounds.
widget->ConstrainSize(&newBounds.width, &newBounds.height);

bool changedPos = curBounds.TopLeft() != newBounds.TopLeft();
bool changedSize = curBounds.Size() != newBounds.Size();

Expand Down
2 changes: 1 addition & 1 deletion widget/nsBaseWidget.h
Original file line number Diff line number Diff line change
Expand Up @@ -578,7 +578,7 @@ class nsBaseWidget : public nsIWidget, public nsSupportsWeakReference {
* @param aWidth width to constrain
* @param aHeight height to constrain
*/
void ConstrainSize(int32_t* aWidth, int32_t* aHeight) override {
void ConstrainSize(int32_t* aWidth, int32_t* aHeight) {
SizeConstraints c = GetSizeConstraints();
*aWidth = std::max(c.mMinSize.width, std::min(c.mMaxSize.width, *aWidth));
*aHeight =
Expand Down
8 changes: 0 additions & 8 deletions widget/nsIWidget.h
Original file line number Diff line number Diff line change
Expand Up @@ -2079,14 +2079,6 @@ class nsIWidget : public nsISupports {
*/
virtual const SizeConstraints GetSizeConstraints() = 0;

/**
* Apply the current size constraints to the given size.
*
* @param aWidth width to constrain
* @param aHeight height to constrain
*/
virtual void ConstrainSize(int32_t* aWidth, int32_t* aHeight) = 0;

/**
* If this is owned by a BrowserChild, return that. Otherwise return
* null.
Expand Down

0 comments on commit fed1064

Please sign in to comment.