Commit Graph

4919 Commits

Author SHA1 Message Date
Keith Packard
a52efb096e Merge remote branch 'sthibaul/master-iopl' 2010-11-03 06:50:45 -07:00
Samuel Thibault
f72aadd38b hurd: Fix use of deprecated iopl device
Fix Xserver on GNU/Hurd into using the "mem" device instead of
the deprecated "iopl" device.

Reviewed-by: Olaf Buddenhagen <antrik@users.sf.net>
Signed-off-by: Samuel Thibault <samuel.thibault@ens-lyon.org>
2010-10-24 14:09:35 +02:00
Paulius Zaleckas
8990b31214 KDrive: Fix error handlig in tslib driver
If ts_open() fails and return NULL, then next call to ts_fd()
segfaults because of NULL dereference. There is no need to
check output of ts_fd() as ts_open() did this internally.

Signed-off-by: Paulius Zaleckas <paulius.zaleckas@gmail.com>
Reviewed-by: Daniel Stone <daniel@fooishbar.org>
Reviewed-by: Keith Packard <keithp@keithp.com>
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2010-10-22 13:36:10 +10:00
Keith Packard
d738175eaf Merge remote branch 'whot/for-keith' 2010-10-19 22:50:15 -07:00
Peter Hutterer
9872e0f011 xfree86: set mask for valuators 0/1 when emulating core events (#30267)
EventToCore as of the commit below won't generate core motion events if the
valuator mask for x/y isn't set. For DGA, we work around this check by
forcibly setting the mask in the event we pass down.

commit de8be07cc0
Author: Peter Hutterer <peter.hutterer@who-t.net>
Date:   Tue Aug 17 12:08:52 2010 +1000

    dix: don't create core motion events for non-x/y valuators.

X.Org Bug 30267 <http://bugs.freedesktop.org/show_bug.cgi?id=30267>

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Tested-by: Andrew Randrianasulu <randrik@mail.ru>
Tested-by: Andy Furniss
Reviewed-by: Daniel Stone <daniel@fooishbar.org>
2010-10-20 08:02:38 +10:00
Jon TURNEY
25801a2556 Cygwin/X: Move duplicate extern variable declarations from various .c files to a new header file
For the global variables defined in winglobals.c, remove duplicate extern
declarations from the beginning of various .c files, and move most of them
into a new header file, winglobals.h

Leave some clipboard related variables alone for the moment, they need treating
more carefully, to avoid mixing client and server type definitions.

Signed-off-by: Jon TURNEY <jon.turney@dronecode.org.uk>
Reviewed-by: Colin Harrison <colin.harrison@virgin.net>
2010-10-19 15:02:00 +01:00
Jon TURNEY
04d11abcf2 Cygwin/X: Remove g_hwndKeyboardFocus
It's set but it's value is never used

Signed-off-by: Jon TURNEY <jon.turney@dronecode.org.uk>
Reviewed-by: Colin Harrison <colin.harrison@virgin.net>
2010-10-19 15:01:58 +01:00
Jon TURNEY
5e896e425f Cygwin/X: Make g_hmodCommonControls static
Make g_hmodCommonControls static, it's only used in InitOutput.c

Signed-off-by: Jon TURNEY <jon.turney@dronecode.org.uk>
Reviewed-by: Colin Harrison <colin.harrison@virgin.net>
2010-10-19 15:01:56 +01:00
Jon TURNEY
49b996faad Cygwin/X: Make g_hmodDirectDraw static
Add winReleaseDDProcAddresses() for releasing the direct draw module
handle, so g_hmodDirectDraw can be made static

Remove unneeded duplicate extern definitions of g_fpDirectDrawCreate
and g_fpDirectDrawCreateClipper, and move the definition from
winglobals.c to winengine.c

Signed-off-by: Jon TURNEY <jon.turney@dronecode.org.uk>
Reviewed-by: Colin Harrison <colin.harrison@virgin.net>
2010-10-19 15:01:55 +01:00
Jon TURNEY
6f12277e37 Cygwin/X: Make g_hhookKeyboardLL static
Make g_hhookKeyboardLL static, it's only used in winkeyhook.c

Also remove unused externs

Signed-off-by: Jon TURNEY <jon.turney@dronecode.org.uk>
Reviewed-by: Colin Harrison <colin.harrison@virgin.net>
2010-10-19 15:01:53 +01:00
Jon TURNEY
9952b51f68 Cygwin/X: Fix typos in comments
Fix a few typos in comments

Signed-off-by: Jon TURNEY <jon.turney@dronecode.org.uk>
Reviewed-by: Colin Harrison <colin.harrison@virgin.net>
2010-10-19 15:01:51 +01:00
Jon TURNEY
1de5db73d3 Cygwin/X: Drop several unneeded includes of winprefs.h
Signed-off-by: Jon TURNEY <jon.turney@dronecode.org.uk>
Reviewed-by: Colin Harrison <colin.harrison@virgin.net>
2010-10-19 15:01:50 +01:00
Colin Harrison
8e72310815 Xming: Remove uses of register keyword
I'm pretty sure the compiler has a better idea how to optimize this

Signed-off-by: Jon TURNEY <jon.turney@dronecode.org.uk>
Reviewed-by: Jon TURNEY <jon.turney@dronecode.org.uk>
2010-10-19 15:01:48 +01:00
Colin Harrison
d11761c6a6 Xming: Casts to remove warnings on event pointers
winkeybd.c: In function ‘winSendKeyEvent’:
winkeybd.c:489: warning: passing argument 2 of ‘mieqEnqueue’ from incompatible pointer type
winmouse.c: In function ‘winMouseButtonsSendEvent’:
winmouse.c:247: warning: passing argument 2 of ‘mieqEnqueue’ from incompatible pointer type
winmouse.c: In function ‘winEnqueueMotion’:
winmouse.c:380: warning: passing argument 2 of ‘mieqEnqueue’ from incompatible pointer type

Signed-off-by: Jon TURNEY <jon.turney@dronecode.org.uk>
Reviewed-by: Jon TURNEY <jon.turney@dronecode.org.uk>
2010-10-19 15:01:19 +01:00
Colin Harrison
10bf8345cf Xming: Warning fix in winDeviceCursorCleanup()
return statement with an expression in a function whose return-type is void

Signed-off-by: Jon TURNEY <jon.turney@dronecode.org.uk>
Reviewed-by: Jon TURNEY <jon.turney@dronecode.org.uk>
2010-10-19 14:42:16 +01:00
Jon TURNEY
cab837a60a Cygwin/X: Reformat the keyboard layout mapping table
Also remove the out-of-date listing of keyboard layout IDs and which ones
have known mappings

XXX: layout zh_TW doesn't exist anymore

This patch brought to you by C-u M-x align-regexp

Signed-off-by: Jon TURNEY <jon.turney@dronecode.org.uk>
Reviewed-by: Colin Harrison <colin.harrison@virgin.net>
2010-10-19 14:41:40 +01:00
Jon TURNEY
ee2867649d Cygwin/X: Clarify XKB options in XWin man page
Signed-off-by: Jon TURNEY <jon.turney@dronecode.org.uk>
Reviewed-by: Colin Harrison <colin.harrison@virgin.net>
2010-10-19 14:40:53 +01:00
Colin Harrison
1ba1b12d24 Xming: Warning fix in winApplyHints()
winmultiwindowwm.c: In function ‘winApplyHints’:
winmultiwindowwm.c:1587: warning: ISO C90 forbids mixed declarations and code

Signed-off-by: Jon TURNEY <jon.turney@dronecode.org.uk>
Reviewed-by: Jon TURNEY <jon.turney@dronecode.org.uk>
2010-10-19 14:38:32 +01:00
Colin Harrison
fb64414548 Xming: Fix warnings in ProcWindowsWMFrameSetTitle()
winwindowswm.c: In function ‘ProcWindowsWMFrameSetTitle’:
winwindowswm.c:516: warning: pointer targets in passing argument 1 of ‘strncpy’ differ in signedness
winwindowswm.c:516: warning: pointer targets in passing argument 2 of ‘strncpy’ differ in signedness
winwindowswm.c:528: warning: pointer targets in passing argument 2 of ‘SetWindowTextA’ differ in signedness

Signed-off-by: Jon TURNEY <jon.turney@dronecode.org.uk>
Reviewed-by: Jon TURNEY <jon.turney@dronecode.org.uk>
2010-10-19 14:38:30 +01:00
Colin Harrison
da5955cc02 Xming: Fix warnings in windialogs.c
windialogs.c: In function ‘winDisplayExitDialog’:
windialogs.c:327: warning: passing argument 3 of ‘PostMessageA’ makes integer from pointer without a cast
windialogs.c: In function ‘winDisplayAboutDialog’:
windialogs.c:597: warning: passing argument 3 of ‘PostMessageA’ makes integer from pointer without a cast
windialogs.c: In function ‘winAboutDlgProc’:
windialogs.c:697: warning: comparison between pointer and integer
windialogs.c:701: warning: format ‘%d’ expects type ‘int’, but argument 2 has type ‘HINSTANCE’
windialogs.c:716: warning: assignment makes integer from pointer without a cast
windialogs.c:736: warning: assignment makes integer from pointer without a cast
windialogs.c:756: warning: assignment makes integer from pointer without a cast

Signed-off-by: Jon TURNEY <jon.turney@dronecode.org.uk>
Reviewed-by: Jon TURNEY <jon.turney@dronecode.org.uk>
2010-10-19 14:35:38 +01:00
Colin Harrison
6d9fb07db2 Xming: Fix warnings in winNameCompare(), winNormalizeName()
winconfig.c: In function ‘winNameCompare’:
winconfig.c:715: warning: array subscript has type ‘char’
winconfig.c:715: warning: array subscript has type ‘char’
winconfig.c:716: warning: array subscript has type ‘char’
winconfig.c:716: warning: array subscript has type ‘char’
winconfig.c:730: warning: array subscript has type ‘char’
winconfig.c:730: warning: array subscript has type ‘char’
winconfig.c:731: warning: array subscript has type ‘char’
winconfig.c:731: warning: array subscript has type ‘char’
winconfig.c: In function ‘winNormalizeName’:
winconfig.c:1092: warning: array subscript has type ‘char’
winconfig.c:1093: warning: array subscript has type ‘char’

Signed-off-by: Jon TURNEY <jon.turney@dronecode.org.uk>
Reviewed-by: Jon TURNEY <jon.turney@dronecode.org.uk>
2010-10-19 14:28:28 +01:00
Colin Harrison
20510e5100 Xming: Fix warnings in winClipboardFlushXEvents()
winclipboardxevents.c: In function ‘winClipboardFlushXEvents’:
winclipboardxevents.c:225: warning: format ‘%08x’ expects type ‘unsigned int’, but argument 2 has type ‘DWORD’
winclipboardxevents.c:266: warning: format ‘%08x’ expects type ‘unsigned int’, but argument 2 has type ‘DWORD’
winclipboardxevents.c:619: warning: pointer targets in passing argument 1 of ‘strcat’ differ in signedness
winclipboardxevents.c:659: warning: pointer targets in passing argument 1 of ‘strlen’ differ in signedness
winclipboardxevents.c:669: warning: pointer targets in passing argument 3 of ‘MultiByteToWideChar’ differ in signedness
winclipboardxevents.c:690: warning: pointer targets in passing argument 3 of ‘MultiByteToWideChar’ differ in signedness
winclipboardxevents.c:698: warning: pointer targets in passing argument 1 of ‘strdup’ differ in signedness

Signed-off-by: Jon TURNEY <jon.turney@dronecode.org.uk>
Reviewed-by: Jon TURNEY <jon.turney@dronecode.org.uk>
2010-10-19 14:27:33 +01:00
Colin Harrison
44c8b449d2 Xming: Fix warning in winClipboardErrorHandler()
winclipboardthread.c: In function ‘winClipboardErrorHandler’:
winclipboardthread.c:444: warning: format ‘%d’ expects type ‘int’, but argument 3 has type ‘long unsigned int’

Signed-off-by: Jon TURNEY <jon.turney@dronecode.org.uk>
Reviewed-by: Jon TURNEY <jon.turney@dronecode.org.uk>
2010-10-19 14:26:19 +01:00
Jon TURNEY
1f2a57d9e4 Cygwin/X: Turn off the bad-function-cast warning for XWin code
Turn off the bad-function-cast warning for the XWin code, it's near impossible
to write code which uses Win32 API calls that doesn't trigger this warning

For example, SendMessage(WM_SETICON) returns an LRESULT, but we are supposed to
know this is safe to cast this result to a HICON, which gcc considers a non-matching
type.

Signed-off-by: Jon TURNEY <jon.turney@dronecode.org.uk>
Reviewed-by: Colin Harrison <colin.harrison@virgin.net>
2010-10-19 14:20:05 +01:00
Jon TURNEY
55e528b6cc Cygwin/X: Remove execute permission from source files
Remove execute permission from source files

Signed-off-by: Jon TURNEY <jon.turney@dronecode.org.uk>
Reviewed-by: Colin Harrison <colin.harrison@virgin.net>
2010-10-19 14:19:29 +01:00
Jon TURNEY
b2b685e269 Cygwin/X: unifdef XFree86Server
Remove XFree86Server define, which was always on anyhow, and the
code which was guarded by !XFree86Server

This completes the process of removal started in 2006 :-)

Signed-off-by: Jon TURNEY <jon.turney@dronecode.org.uk>
Reviewed-by: Colin Harrison <colin.harrison@virgin.net>
2010-10-19 14:17:21 +01:00
Jon TURNEY
9ed70f15ef Cygwin/X: Use normal apostrophe in XWin DDX help text
Use U+0027 APOSTROPHE in XWin DDX help text, rather than
U+2019 RIGHT SINGLE QUOTATION MARK

Signed-off-by: Jon TURNEY <jon.turney@dronecode.org.uk>
Reviewed-by: Colin Harrison <colin.harrison@virgin.net>
2010-10-19 14:15:38 +01:00
Jon TURNEY
9f8f056a21 Cygwin/X: Cleanup some VENDOR_STRING/VENDOR_CONTACT cruft
Cleanup some VENDOR_STRING/VENDOR_CONTACT cruft

Signed-off-by: Jon TURNEY <jon.turney@dronecode.org.uk>
Reviewed-by: Colin Harrison <colin.harrison@virgin.net>
2010-10-19 14:02:33 +01:00
Keith Packard
5aff712a8d Merge remote branch 'whot/for-keith' 2010-10-18 17:16:23 -07:00
Olivier Fourdan
7bb653bedc modes: improve aspect ratio match for classic drivers
After we infer the aspect ratio for the screen, we pick the largest
mode matching that aspect ratio from the best mode pool available.
We then clamp virtual size to that mode, and run the resulting mode
list through the driver's ValidMode hook.  In doing so we might filter
away our initial guess.  If this happens we shrink the default mode
to the next largest mode from _any_ mode pool.  This is usually wrong,
and we should instead pick the next aspect-matched mode from the best
available mode pool (as always, user then driver then default).

Reviewed-by: Alex Deucher <alexdeucher@gmail.com>
Signed-off-by: Adam Jackson <ajax@redhat.com>
2010-10-18 17:38:23 -04:00
Adam Jackson
d2064fbb68 ddc: Don't probe for DDC/CI or EEPROM
For whatever reason, some (broken) monitors will crash if you do this.
We're not actually using this information for anything, so let's just
not do it.

Originally reported as http://bugzilla.redhat.com/620333

Reviewed-by: Alex Deucher <alexdeucher@gmail.com>
Signed-off-by: Adam Jackson <ajax@redhat.com>
2010-10-18 15:42:54 -04:00
Adam Jackson
47c91dca8d xfree86: Drop linux libc5 support from the SIGIO code
Reviewed-by: Tiago Vignatti <tiago.vignatti@nokia.com>
Reviewed-by: Matt Turner <mattst88@gmail.com>
Signed-off-by: Adam Jackson <ajax@redhat.com>
2010-10-18 15:40:28 -04:00
Adam Jackson
788bfbf18a dri1: Remove "buffers" from the config logic
This was only ever used from the glint driver, which has since lost its
DRI support.

Reviewed-by: Matt Turner <mattst88@gmail.com>
Signed-off-by: Adam Jackson <ajax@redhat.com>
2010-10-18 15:34:08 -04:00
Adam Jackson
a77458486a xfree86: Remove %M expansion from config parser
This was to distinguish XFree86 3.x files from XFree86 4.x files.  It
never really made sense to be looking for xorg.conf-4.

Reviewed-by: Matt Turner <mattst88@gmail.com>
Reviewed-by: Dan Nicholson <dbn.lists@gmail.com>
Reviewed-by: Jesse Adkins <jesserayadkins@gmail.com>
Signed-off-by: Adam Jackson <ajax@redhat.com>
2010-10-18 15:33:27 -04:00
Adam Jackson
f8ec71603c xfree86: Remove an open-coded strtoul()
Reviewed-by: Matt Turner <mattst88@gmail.com>
Reviewed-by: Dan Nicholson <dbn.lists@gmail.com>
Signed-off-by: Adam Jackson <ajax@redhat.com>
2010-10-18 15:33:02 -04:00
Adam Jackson
52577ae8ee config: Remove atimisc workaround
Reviewed-by: Matt Turner <mattst88@gmail.com>
Reviewed-by: Mark Kettenis <kettenis@openbsd.org>
Reviewed-by: Jesse Adkins <jesserayadkins@gmail.com>
Signed-off-by: Adam Jackson <ajax@redhat.com>
2010-10-18 15:32:21 -04:00
Adam Jackson
8bb1983a5f config: Don't look for .o drivers anymore
This hasn't worked since we switched to dlloader.

Reviewed-by: Jesse Adkins <jesserayadkins@gmail.com>
Reviewed-by: Matt Turner <mattst88@gmail.com>
Signed-off-by: Adam Jackson <ajax@redhat.com>
2010-10-18 15:31:23 -04:00
Peter Hutterer
3c28a29e13 xfree86: rename parameter names to xf86ScaleAxis.
Maybe it's just me but every time I look at it I get confused again and need
to work it out from scratch. Rename the parameters to something
self-explanatory, to/from and min/max.

No functional change.

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Julien Cristau <jcristau@debian.org>
2010-10-15 11:56:27 +10:00
Adam Jackson
e418cd332c xwin: Remove some undue paranoia about UNDRAWABLE_WINDOW
mi will throw away rendering to input-only windows.

Signed-off-by: Adam Jackson <ajax@redhat.com>
Reviewed-by: Jon TURNEY <jon.turney@dronecode.org.uk>
Signed-off-by: Keith Packard <keithp@keithp.com>
2010-10-13 09:21:27 -07:00
Adam Jackson
febf3e7ead dix: Remove the memory of the multibuffer extension
Drop DRAWABLE_BUFFER and related checks, mbuf was the only thing that
used them and it was killed in 0ba82562.

Signed-off-by: Adam Jackson <ajax@redhat.com>
Reviewed-by: Keith Packard <keithp@keithp.com>
Reviewed-by: Jon TURNEY <jon.turney@dronecode.org.uk>
Signed-off-by: Keith Packard <keithp@keithp.com>
2010-10-13 09:18:41 -07:00
Adam Jackson
853d7ebfa3 vbe: Fix copying the mode info block
Just use memcpy, seriously.

Reviewed-by: RĂ©mi Cardona <remi@gentoo.org>
Signed-off-by: Adam Jackson <ajax@redhat.com>
Signed-off-by: Keith Packard <keithp@keithp.com>
2010-10-05 10:20:43 -07:00
Adam Jackson
b2f9ce201c edid: Fix the HDTV sync pulse adjustment
Simple typo, should have been adjusting the horizontal timings
consistently since we're not trying to mangle vertical at all.

Signed-off-by: Adam Jackson <ajax@redhat.com>
Reviewed-by: Patrick E. Kane <pekane52@gmail.com>
Signed-off-by: Keith Packard <keithp@keithp.com>
2010-10-05 08:19:25 -07:00
Chris Wilson
9a893fe52f xfree86: Do not call dlclose(NULL) [regression after ab7f057]
During unwind following an error when attempting to a load a module, we
attempt to call dlclose on a potentially NULL handle. This is a
side-effect of removing the abstraction layer in ab7f057.

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Cc: Adam Jackson <ajax@redhat.com>
Reviewed-by: Adam Jackson <ajax@redhat.com>
Signed-off-by: Keith Packard <keithp@keithp.com>
2010-10-04 11:46:07 -07:00
Jon TURNEY
72a9c686d7 Cygwin/X: Fix compilation after "delete pervasively use of DISPATCH_PROC"
commit cbd4d5dbb7
removes the static declarations of ProcWindowsWMDispatch and
SProcWindowsWMDispatch which precede their first use in
winWindowsWMExtensionInit()

Move winWindowsWMExtensionInit() to after the definition of those
two functions to fix compilation.

Signed-off-by: Jon TURNEY <jon.turney@dronecode.org.uk>
Reviewed-by: Tiago Vignatti <tiago.vignatti@nokia.com>
Signed-off-by: Keith Packard <keithp@keithp.com>
2010-09-29 12:15:11 -07:00
Aaron Plattner
1a9022d328 Bump video driver ABI version to 9.0
Signed-off-by: Aaron Plattner <aplattner@nvidia.com>
Reviewed-by: Keith Packard <keithp@keithp.com>
Signed-off-by: Keith Packard <keithp@keithp.com>
2010-09-28 15:52:38 -07:00
Jeremy Huddleston
c45bea0c04 XQuartz: RandR: Refactor legacy mode-switching to be better integrated with RandR
Adds three new functions
void QuartzRandRSetFakeRootless (void);
void QuartzRandRSetFakeFullscreen (void);
void QuartzRandRToggleFullscreen (void);

The first two are identical to requesting the fake modes from a RandR client
The third responds to cmd-alt-a to leave fullscreen or RandR.

Signed-off-by: Jeremy Huddleston <jeremyhu@apple.com>
2010-09-28 10:09:11 -07:00
Jeremy Huddleston
229323a19b XQuartz: RandR: Don't change the rootless preference when changing RandR mode
Also renames a bunch of other variables for better consistency.

Signed-off-by: Jeremy Huddleston <jeremyhu@apple.com>
2010-09-28 09:50:35 -07:00
Jeremy Huddleston
721edc69c3 XQuartz: RandR: Better handle switching betwen RandR modes that share CG modes
Signed-off-by: Jeremy Huddleston <jeremyhu@apple.com>
2010-09-28 09:50:35 -07:00
Jeremy Huddleston
026a47e212 XQuartz: RandR: Respond better to resolution changes made outside X
Signed-off-by: Jeremy Huddleston <jeremyhu@apple.com>
2010-09-28 09:50:34 -07:00
Jeremy Huddleston
59cd93f48a XQuartz: RandR: Use deprecated CG APIs only on Leopard and earlier
Signed-off-by: Jeremy Huddleston <jeremyhu@apple.com>
2010-09-28 09:50:34 -07:00