diff options
author | Allan Sandfeld Jensen <allan.jensen@qt.io> | 2021-10-26 13:57:00 +0200 |
---|---|---|
committer | Allan Sandfeld Jensen <allan.jensen@qt.io> | 2021-11-02 11:31:01 +0000 |
commit | 1943b3c2a1dcee36c233724fc4ee7613d71b9cf6 (patch) | |
tree | 8c1b5f12357025c197da5427ae02cfdc2f3570d6 /chromium/third_party/blink/renderer/core/html/forms/resources/pickerCommon.js | |
parent | 21ba0c5d4bf8fba15dddd97cd693bad2358b77fd (diff) | |
download | qtwebengine-chromium-1943b3c2a1dcee36c233724fc4ee7613d71b9cf6.tar.gz |
BASELINE: Update Chromium to 94.0.4606.111
Change-Id: I924781584def20fc800bedf6ff41fdb96c438193
Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
Diffstat (limited to 'chromium/third_party/blink/renderer/core/html/forms/resources/pickerCommon.js')
-rw-r--r-- | chromium/third_party/blink/renderer/core/html/forms/resources/pickerCommon.js | 19 |
1 files changed, 1 insertions, 18 deletions
diff --git a/chromium/third_party/blink/renderer/core/html/forms/resources/pickerCommon.js b/chromium/third_party/blink/renderer/core/html/forms/resources/pickerCommon.js index ae3504dd303..b72800b4e0b 100644 --- a/chromium/third_party/blink/renderer/core/html/forms/resources/pickerCommon.js +++ b/chromium/third_party/blink/renderer/core/html/forms/resources/pickerCommon.js @@ -148,13 +148,7 @@ function _adjustWindowRectVertically( availableSpaceBelow = Math.max(0, Math.min(availRect.height, availableSpaceBelow)); - // In some situations, there may be no space available. This can happen on - // Linux when using a buggy window manager (https://crbug.com/774232). When - // this happens, don't try to constrain the window at all. - if (availableSpaceAbove == 0 && availableSpaceBelow == 0) { - windowRect.height = Math.max(minHeight, windowRect.height); - windowRect.y = anchorRect.maxY; - } else if ( + if ( windowRect.height > availableSpaceBelow && availableSpaceBelow < availableSpaceAbove) { windowRect.height = Math.min(windowRect.height, availableSpaceAbove); @@ -172,11 +166,6 @@ function _adjustWindowRectVertically( */ function _adjustWindowRectHorizontally( windowRect, availRect, anchorRect, minWidth) { - if (anchorRect.maxX <= availRect.x || availRect.maxX <= anchorRect.x) { - windowRect.width = Math.max(minWidth, windowRect.width); - windowRect.x = anchorRect.x - return; - } windowRect.width = Math.min(windowRect.width, availRect.width); windowRect.width = Math.max(windowRect.width, minWidth); windowRect.x = anchorRect.x; @@ -331,7 +320,6 @@ Picker.prototype = Object.create(EventEmitter.prototype); Picker.Actions = { SetValue: 0, Cancel: -1, - ChooseOtherColor: -2 }; /** @@ -346,11 +334,6 @@ Picker.prototype.handleCancel = function() { window.pagePopupController.closePopup(); }; -Picker.prototype.chooseOtherColor = function() { - window.pagePopupController.setValueAndClosePopup( - Picker.Actions.ChooseOtherColor, ''); -}; - Picker.prototype.cleanup = function() {}; window.addEventListener('keyup', function(event) { |