diff options
author | Keith Packard <keithp@guitar.keithp.com> | 2007-02-18 23:49:38 -0800 |
---|---|---|
committer | Keith Packard <keithp@neko.keithp.com> | 2007-03-17 23:20:07 -0700 |
commit | 2c93083edd29a65e73bb2e8eff9d353e92845c9b (patch) | |
tree | 596e34a8f006c18bf9984e87303dac546a048e5c /randr/rrinfo.c | |
parent | 3bffb281260476d2f74f0bf451d85d2f7cacd6c4 (diff) |
Add support for user-defined modelines in RandR.
The RandR protocol spec has several requests in support of user-defined
modes, but the implementation was stubbed out inside the X server. Fill out
the DIX portion and start on the xf86 DDX portion. It might be necessary to
add more code to the DDX to insert the user-defined modes into the output
mode list.
(cherry picked from commit 63cc2a51ef87130c632a874672a8c9167f14314e)
Conflicts:
randr/randrstr.h
Updated code to work in master with recent security API changes.
Diffstat (limited to 'randr/rrinfo.c')
-rw-r--r-- | randr/rrinfo.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/randr/rrinfo.c b/randr/rrinfo.c index 797cdb1b4..549d501dc 100644 --- a/randr/rrinfo.c +++ b/randr/rrinfo.c @@ -157,9 +157,11 @@ RRScanOldConfig (ScreenPtr pScreen, Rotation rotations) pScrPriv->nSizes = 0; /* find size bounds */ - for (i = 0; i < output->numModes; i++) + for (i = 0; i < output->numModes + output->numUserModes; i++) { - RRModePtr mode = output->modes[i]; + RRModePtr mode = (i < output->numModes ? + output->modes[i] : + output->userModes[i-output->numModes]); CARD16 width = mode->mode.width; CARD16 height = mode->mode.height; |