Fix Impersonate Roles dialog rendering with a hugely oversized column - #7901
Open
labkey-tchad wants to merge 1 commit into
Open
Fix Impersonate Roles dialog rendering with a hugely oversized column#7901labkey-tchad wants to merge 1 commit into
labkey-tchad wants to merge 1 commit into
Conversation
The role grid's single flex column could be laid out before the containing window had a final, on-screen width, leaving the column (and its header) stuck at ExtJS's internal 20000px box-layout measurement placeholder instead of the real rendered width, which pushed the dialog's contents far outside the window frame. Force the grid to relayout once the window's `show` event fires, guaranteeing the flex column recalculates against the window's actual, final size.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Rationale
The "Impersonate Roles" dialog intermittently rendered with its role grid massively oversized (column width in the tens of thousands of pixels), spilling the dialog content far outside its window frame. This was traced to a race in ExtJS 4's box layout: the grid's single
flex: 1column can be laid out before the containingExt.window.Windowhas a final, resolved width, leaving the column stuck at ExtJS's internal 20000px measurement placeholder (Ext.layout.container.Box.beginLayoutCycle) instead of being corrected to the real width. This is more likely to reproduce under CI timing than in normal local use.Related Pull Requests
None
Changes
core/webapp/Impersonate.js: added ashowlistener on theImpersonateRoleswindow that forces the role grid to relayout once the window is fully shown, so the flex column recalculates against the window's actual final width.