Commit dc9679c
committed
SystemKit: fix framebuffer sizing so single-axis resolution changes apply
applyDisplayLayout: enlarged the X framebuffer only when BOTH dimensions
grew (&&) and shrank it only when one dimension got smaller (||). A change
that altered a single axis - e.g. 1400x1050 -> 1680x1050, same height -
matched neither branch, so the framebuffer stayed at the old size while a
wider CRTC mode was requested. XRRSetCrtcConfig then failed with BadMatch,
the mode never took effect, and the display showed a black band on the
right (xrandr still reported the old 1400x1050 screen).
Grow the framebuffer up front to the per-axis maximum of the current and
new sizes so the new mode always fits, then set it to the exact final size
after all CRTCs are placed. This preserves the original VirtualBox BadMatch
safeguard (the framebuffer is never shrunk below the still-current layout
mid-transition) while covering single-axis and mixed grow/shrink changes.1 parent e5d55ef commit dc9679c
1 file changed
Lines changed: 20 additions & 13 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1091 | 1091 | | |
1092 | 1092 | | |
1093 | 1093 | | |
1094 | | - | |
1095 | | - | |
1096 | | - | |
1097 | | - | |
1098 | | - | |
| 1094 | + | |
| 1095 | + | |
| 1096 | + | |
| 1097 | + | |
| 1098 | + | |
| 1099 | + | |
| 1100 | + | |
| 1101 | + | |
| 1102 | + | |
1099 | 1103 | | |
1100 | | - | |
| 1104 | + | |
1101 | 1105 | | |
1102 | | - | |
| 1106 | + | |
| 1107 | + | |
1103 | 1108 | | |
1104 | | - | |
| 1109 | + | |
1105 | 1110 | | |
1106 | 1111 | | |
1107 | 1112 | | |
| |||
1143 | 1148 | | |
1144 | 1149 | | |
1145 | 1150 | | |
1146 | | - | |
1147 | | - | |
1148 | | - | |
1149 | | - | |
| 1151 | + | |
| 1152 | + | |
| 1153 | + | |
| 1154 | + | |
| 1155 | + | |
| 1156 | + | |
1150 | 1157 | | |
1151 | 1158 | | |
1152 | 1159 | | |
1153 | | - | |
| 1160 | + | |
1154 | 1161 | | |
1155 | 1162 | | |
1156 | 1163 | | |
| |||
0 commit comments