Merge "Fix measurement for dialog windows that do not have fixed width" into jb-dev