Fix alignment of dropdowns in scrollable dialogs
authorMatthias Schmidt <gravatronics@live.com>
Thu, 20 Jun 2019 15:43:02 +0000 (17:43 +0200)
committerMatthias Schmidt <gravatronics@live.com>
Thu, 20 Jun 2019 15:43:02 +0000 (17:43 +0200)
wcfsetup/install/files/js/WoltLabSuite/Core/Ui/Dropdown/Simple.js

index b2331016adcf9019f7ca75526437d1f849baf638..a6bd4807aaabac7fdcfe5775927bfea04706a7d1 100644 (file)
@@ -330,7 +330,7 @@ define(
                                        this.toggleDropdown(containerId);
                                }
                                else {
-                                       this.setAlignment(containerId, _menus.get(containerId));
+                                       this.setAlignment(_dropdowns.get(containerId), _menus.get(containerId));
                                }
                        }
                },
@@ -408,7 +408,7 @@ define(
                                }
                                
                                // check if 'isOverlayDropdownButton' is set which indicates that the dropdown toggle is within an overlay
-                               if (elData(dropdown, 'is-overlay-dropdown-button') === null) {
+                               if (elData(dropdown, 'is-overlay-dropdown-button') === '') {
                                        var dialogContent = DomTraverse.parentByClass(dropdown, 'dialogContent');
                                        elData(dropdown, 'is-overlay-dropdown-button', (dialogContent !== null));