summaryrefslogtreecommitdiff
AgeCommit message (Collapse)AuthorFilesLines
2012-01-04hw/xwin: Enable RANDR resize by defaultcygwin-patches-for-1.11Jon TURNEY2-5/+7
Also fix erroneous use of '--resize' not '-resize', and document '-noresize' in man page Signed-off-by: Jon TURNEY <jon.turney@dronecode.org.uk>
2012-01-04RANDR resize was missing in windowed mode, with option -resize, when the ↵Colin Harrison1-0/+5
window was maximized or restored. Signed-off-by: Jon TURNEY <jon.turney@dronecode.org.uk> Reviewed-by: Jon TURNEY <jon.turney@dronecode.org.uk>
2012-01-04hw/xwin: Fix winEnqueueMotion() for change in miPointerSetPosition()Colin Harrison1-1/+3
Commit 3b36fd1b49030ead44358945f62e5abe7f4609ce changed miPointerSetPosition() to take co-ordinates as doubles, not ints. Update for that change. Could lead to missing mouse events? On 04/10/2011 06:09, Peter Hutterer wrote: > Hi Jon, > > Just stumbled across this in the xwin ddx: > winEnqueueMotion() in hw/xwin/winmouse.c has a comment > > * XXX: miPointerMove does exactly this, but is static :-( (and uses a static buffer) > > miPointerMove isn't static anymore now, maybe you can replace this function > with a simple call now? > > Cheers, > Peter Signed-off-by: Jon TURNEY <jon.turney@dronecode.org.uk> Reviewed-by: Jon TURNEY <jon.turney@dronecode.org.uk>
2012-01-04Cygwin/X: Enable AIGLX by defaultYaakov Selkowitz3-3/+4
Signed-off-by: Yaakov Selkowitz <yselkowitz@users.sourceforge.net> Reviewed-by: Jon TURNEY <jon.turney@dronecode.org.uk>
2012-01-04hw/xwin: Fix rrScreenSetSize function pointer mismatchRyan Pavlik1-2/+0
winrandr.c: In function ‘winRandRInit’: winrandr.c:218:31: warning: assignment from incompatible pointer type Fix winRandRScreenSetSize() function signature to match RRScreenSetSizeProcPtr type, to align with commit fd9331f6 'Revert "Separate out screen size and screen pixmap sizes in RRScreenSizeSet"' This is fall-out from the late revert of RANDR 1.4 in the 1.10 release cycle, it will probably need to be reverted if/when that goes back in again. Reviewed-by: Jon TURNEY <jon.turney@dronecode.org.uk> Signed-off-by: Jon TURNEY <jon.turney@dronecode.org.uk>
2012-01-04Add Windows 8 to the list of Windows versions we know the name ofJon TURNEY1-1/+5
Signed-off-by: Jon TURNEY <jon.turney@dronecode.org.uk>
2011-12-20Add ' (on <WM_CLIENT_MACHINE>)' to window name when it's useful to do soJon TURNEY6-50/+118
Enhance GetWindowName() so it appends the result of XGetWMClientMachine() when it is avilable and useful to do so Refactor Xutf8TextPropertyToString() from GetWindowName() as a separate utility function Simplify GetWindowName() by moving UTF-8 to whcar conversion out to it's call site Add -hostintitle option to control this behaviour. Add documentation for this option to man page and -help text. Signed-off-by: Jon TURNEY <jon.turney@dronecode.org.uk>
2011-11-05Implement System() specially on Cygwin not to use fork/execJon TURNEY1-0/+20
Signed-off-by: Jon TURNEY <jon.turney@dronecode.org.uk>
2011-10-05Handle more motif window decoration hintingJon TURNEY2-0/+21
Handle the MWM_DECOR_MINIMIZE, MWM_DECOR_MAXIMIZE and MWM_DECOR_MENU decoration hints in a _MOTIF_WM_HINTS window property Signed-off-by: Jon TURNEY <jon.turney@dronecode.org.uk>
2011-10-05hw/xwin: Fix AltGr key sometimes firing an additional Ctrl-L keyOliver Schmidt2-43/+60
I also had problems with the AltGr key. These could reliably be reproduced by holding the AltGr for some seconds (causing Windows generating auto repeat events) I discovered that the mechanism in winkeybd.c function winIsFakeCtrl_L had a problem if PeekMessage cannot obtain the next Alt_R message because it is not there yet. I prepared a patch that remembers the last Ctrl_L event and reacts on a later Alt_R. It was also necessary to alter the order in winWindowProc() in winwndproc.c: the invocation of winIsFakeCtrl_L had to be done before discarding auto-repeated key presses, as winIsFakeCtrl_L() now has an internal state which must be updated by all key events. Signed-off-by: Jon TURNEY <jon.turney@dronecode.org.uk>
2011-10-05Minimize redraw events after resizing/moving windows in multiwindow modeOliver Schmidt1-4/+20
In multiwindow mode the modal moving/resizing of windows causes a lot of redraw events to be sent to the X clients after the user releases the mouse button. During the moving/resizing client windows are not redrawn as long as the mouse button is pressed, but all redraw/resizing events are queued and executed step after step after the moving/resizing ends. Some clients collect and combine multiple redraw or resizing events, other clients (e.g. xterm) simply execute each redraw or sizing event. The enclosed patch minimizes the events for clients to only one event after the user releases the mouse button to end the moving/resizing. This improves the user experience and reduces strange screen flickerings especially on slow platforms. The enclosed patch modifies winmultiwindowwndproc.c such that the windows events WM_ENTERSIZEMOVE and WM_EXITSIZEMOVE that are sent by Windows when the modal window resizing/moving begins or ends are considered. Only after WM_EXITSIZEMOVE is the redraw/resizing executed. Signed-off-by: Jon TURNEY <jon.turney@dronecode.org.uk>
2011-10-05hw/xwin: Add XF86 xkb private actions for grab debugging to XWinJon TURNEY1-0/+32
In order to invoke these actions, you will need to add them to you XKB maps, as described in [1] http://lists.x.org/archives/xorg-devel/2011-June/023508.html
2011-10-05Add correct taskbar grouping of X windows on Windows 7Tobias Häußler6-2/+219
I created a small patch for XWin that adds correct grouping of taskbar icons when 'Always combine, hide labels' is set in the taskbar properties. It uses the new taskbar APIs introduced in Windows 7 to set an application id for each window. The id is based on the X11 class hints. Signed-off-by: Jon TURNEY <jon.turney@dronecode.org.uk>
2011-10-05Handle the virtual key code generated by the Fn key on IBM Lenovo laptopsJon TURNEY2-2/+4
Apparently, IBM Leonovo laptops can generate a key-press event for the Fn key, with virtual key code 0xFF and scan code 0x163 Handle this specially, rather than just passing on key code 0x63 (delete), so you don't delete what you just typed when you adjust the screen brightness, etc. :-) Signed-off-by: Jon TURNEY <jon.turney@dronecode.org.uk>
2011-10-05XWin: GLX: Create a new dispatch table rather than modifying the existing oneJon TURNEY1-1/+9
When _glapi_create_table_from_handle lands, this should probably be changed to use that.
2011-10-05Load swrastg if GALLIUM_DRIVER environment variable is setJon TURNEY1-1/+6
Load swrastg rather than swrast if GALLIUM_DRIVER environment variable is set This is to enable developer testing of indirect rendering using softpipe/llvmpipe Signed-off-by: Jon TURNEY <jon.turney@dronecode.org.uk>
2011-10-05Use system() rather than pipe() & fork() to invoke xkbcompJon TURNEY3-16/+47
Use system() and a temp file rather than pipe() & fork() to invoke xkbcomp on cygwin Somewhat the counsel of despair, but sometimes Windows is being such a little bitch that the cygwin DLL just can't emulate fork() successfully, so just using system() here is more robust and means I don't have to deal with end-users reporting this as a problem with the xserver Ensure temporary file used to invoke xkbcomp is always removed. It was only being removed on error, not on success :S Signed-off-by: Jon TURNEY <jon.turney@dronecode.org.uk>
2011-10-05Cygwin/X: turn on -emulate3buttons if less than 3 mouse buttons are reportedJon TURNEY5-5/+46
Try to be more intelligent with default options, turn on -emulate3buttons by default if less than 3 mouse buttons are reported It's not clear if this is worthwhile at all, USB mice seem to report as having 5 buttons anyhow Also, add -noemulate3buttons option so this default setting can be reversed if desired Also, correctly report the number of mouse buttons windows is reporting, rather than always at least 3 Signed-off-by: Jon TURNEY <jon.turney@dronecode.org.uk>
2011-10-05Cygwin/X: turn on -nolock if /tmp is on FATJon TURNEY2-5/+26
Try to be more intelligent with default options, turn on -nolock if /tmp is on FAT as it can't work in that case Signed-off-by: Jon TURNEY <jon.turney@dronecode.org.uk>
2011-10-05Improve WM_ENDSESSION handling using separate messaging window threadJon TURNEY8-3/+229
WM_ENDSESSION just calls GiveUp to set the DE_TERMINATE flag. We also need the X server dispatch loop to be unblocked so it can notice that DE_TERMINATE has been set and the server exits cleanly, removing it's lock file and any unix domain socket. The system will terminate the process when the last UI thread in that process returns from processing WM_ENDSESSION for the last top-level window. Since WM_ENDSESSION appears to sent by the system via SendMessage(), which means the wndproc is called to process it directly from inside a blocking syscall in the message thread for that window (the X sever thread), we can't easily terminate the dispatch loop from inside the message processing. So, create a messaging window, a hidden, top-level window, with a separate thread to catch this message, and process it, blocking until the X server dispatch loop exits. Also, notice when this is a shutdown cancel WM_ENDSESSION message and take no action. Signed-off-by: Jon TURNEY <jon.turney@dronecode.org.uk> Conflicts: hw/xwin/InitOutput.c hw/xwin/winwindow.h
2011-10-05Link directly to TrackMouseEvent()Jon TURNEY6-49/+6
TrackMouseEvent has existed in user32 since at least NT4, so don't bother with jumping through all the ancient compatibility hoops of finding if _TrackMouseEvent() exists in comctl32 so it can check if TrackMouseEvent() exists in user32 to see if it needs to emulate it...
2011-10-05Add an item to open the logfile to the default tray icon menuJon TURNEY2-1/+16
Also add links to online FAQ and UG
2011-10-05Allow XScreenSaverSuspend() to effect Windows screen saver or monitor power offJon TURNEY1-0/+7
Reset the idle timer in the block handler if screenSaverSuspended is set. This isn't quite a complete solution. We should also set the block timeout to something less than the idle timer timeout to ensure we will reset the idle timer before it times out if we are blocking. The idle timer timeout is presumably the first one to expire of the screen saver activation or monitor low power or power down timeout, depending on configuration. Unfortunately this is probably not straightforward to do. Whilst SystemParametersInfo(SPI_GETSCREENSAVETIMEOUT) is portable, apparently SPI_GETLOWPOWERTIMEOUT and SPI_GETPOWEROFFTIMEOUT are not supported by Windows versions 6.0 or later, and the interface for discovering equivalent value is complex. This doesn't matter in the case where a media player or similar application is the one making the XScreenSaverSuspend() requests, as it will be continuously drawing, causing the X server to become unblocked often. In the case where slide show presentation application or similar is the one making the XScreenSaverSuspend() request, this might be a problem. Since "Powerpoint is Evil" [1], I think we'll leave it like this till someone complains :-) [1] http://www.edwardtufte.com/tufte/books_pp
2011-10-05Bug fixes for screen sizing when the screen window is on a non-primary monitorJon TURNEY5-34/+94
There is a bug that when the -screen option is used to specify a monitor for the screen window to be located on, but no explicit size is specified (and the -multiplemonitors option isn't specified), the screen window size is always constrained to fit the work area of the primary monitor (rather than the work area of the specified monitor) This gives incorrect results if you want a screen the same size as your non-primary monitor (e.g. by using -screen 0 @2) and your non-primary monitor is larger than your primary monitor. (This can be worked around by specifying -multiplemonitors and an explicit screen size the same size as the monitor (e.g. -multiplemonitors -screen 0 1600x1200@2)) Fix to use work area for the monitor specified for the screen, rather than the primary monitor work area (unless -multiplemonitors is used, in which case we continue to use the virtual desktop work area instead) Also fix the adjustment for an autohide taskbar, so that it is only done if the taskbar is on the same monitor as the screen (or -multiplemonitors is used)
2011-10-05In multiwindow mode, don't grab native input focus for new windows which ↵Jon TURNEY2-1/+26
hint they don't want it In multiwindow mode, avoid grabbing the input focus for newly created windows which have InputHint FALSE (this is used by e.g. glean to avoid every test window grabbing the focus) Signed-off-by: Jon TURNEY <jon.turney@dronecode.org.uk>
2011-10-05Tidy up some pointless output which is always emittedJon TURNEY8-18/+17
2011-10-05Don't bother reporting XORG_VERSION_CURRENTJon TURNEY2-3/+3
Don't bother reporting XORG_VERSION_CURRENT, when we also report the version number broken down into it's components XORG_VERSION_MAJOR, XORG_VERSION_MINOR, etc. as well. Signed-off-by: Jon TURNEY <jon.turney@dronecode.org.uk>
2011-10-05Tidy up OS version detection and reportingJon TURNEY3-22/+101
Also report if OS is WoW64 or not when reporting OS version Signed-off-by: Jon TURNEY <jon.turney@dronecode.org.uk>
2011-10-05Consolidate XInitThreads/XSupportsLocale() in a single place.Jon TURNEY4-45/+18
If XSupportsLocale() fails, set a known good locale.
2011-10-05Cygwin/X: Linkage bodge for swrast, part 2 (for mesa 7.10)Jon TURNEY4-700/+1040
Update the generated files glpapitable.h and glapioffsets.h to match the versions in mesa These offsets must match those used in the libGL we link with for GL function dispatch to operate correctly Signed-off-by: Jon TURNEY <jon.turney@dronecode.org.uk>
2011-10-05Avoid logging VENDOR_CONTACTJon TURNEY1-2/+2
The presence of the list email address in the log causes the emails containing a log to be bounced from the list email Also, avoid logging an extra blank line if BUILDERSTRING is empty
2011-10-05Don't assume we'll always have converted the selection after 2 attemptsRoland Cassard1-19/+4
Rather than knowing we have to call winProcessXEventsTimeout() for up to 2 WIN_XEVENTS_CONVERT messages, process all messages in winProcessXEventsTimeout() until either: (i) the time out expired, (ii) an error occurred, or (iii) received a WIN_XEVENTS_NOTIFY messaage indicating the data has been to put on the clipboard.
2011-10-05os: Add -displayfd option.Jon TURNEY7-26/+78
This option specifies a file descriptor in the launching process. X will scan for an available display number and write that number back to the launching process, at the same time as SIGUSR1 generation. This means display managers don't need to guess at available display numbers. As a consequence, if X fails to start when using -displayfd, it's not because the display was in use, so there's no point in retrying the X launch on a higher display number. Signed-off-by: Adam Jackson <ajax@redhat.com> Update for current X server Fix null DISPLAY crash when stderr is closed Rearrange init order to avoid null DISPLAY crash and correctly use DISPLAY in default logfile name when logfile isn't specified on command line Don't put '\'n on end of DISPLAY so internal XWin uses work correctly Do a bit more logging about what we are trying to do Signed-off-by: Jon TURNEY <jon.turney@dronecode.org.uk>
2011-10-05Cygwin/X: Migitate a race condition in clipboard thread initializationMichel Hummel1-2/+0
Remove the variables g_fClipboardLaunched and g_fClipboardStarted from winInitializeGlobals(), as their re-initialization is handled in the file hw/xwin/InitOutput.c. Re-initializing g_fClipboardLaunched and g_fClipboardStarted during the server reset procedure can lead to the clipboard thread being launched two times and sometimes leads to a crash of the X server...
2011-10-05Cygwin/X: Show any fatal error messageJon TURNEY1-7/+37
Report the fatal error message in the dialog we pop up, rather than just referring the user to the logfile. Signed-off-by: Jon TURNEY <jon.turney@dronecode.org.uk>
2011-10-05Cygwin/X: Make select() only poll and not block if there are unprocessed ↵Jon TURNEY1-0/+18
Windows messages This is a workaround for select() sometimes not finding /dev/windows ready, even if there are unprocessed Windows messages
2011-10-05Cygwin/X: Store pthread_ids and chain IOError handlers to avoid longjmp ↵Jon TURNEY2-25/+52
across threads Signed-off-by: Jon TURNEY <jon.turney@dronecode.org.uk>
2011-10-05Cygwin/X: Make default DPI match native DPIJon TURNEY3-5/+25
Make the default DPI match the current Windows DPI setting. If that setting can't be retrieved, change the fallback DPI value from 75 dpi to 96 dpi. Mark the application as dpiAware in the manifest, which prevents dpi virtualization for high (>96) dpi values on Vista and later. Signed-off-by: Jon TURNEY <jon.turney@dronecode.org.uk> Signed-off-by: Yaakov Selkowitz <yselkowitz@users.sourceforge.net>
2011-10-05Cygwin/X: Process one Windows message per wakeup, rather than all of them.Jon TURNEY2-21/+6
This gives the X server a chance to do stuff as well after each message http://cygwin.com/ml/cygwin-xfree/2010-01/msg00056.html Signed-off-by: Jon TURNEY <jon.turney@dronecode.org.uk>
2011-10-05Cygwin/X: Improve XWinrc loading and error recoveryYaakov Selkowitz2-19/+65
If $HOME/.XWinrc is present but badly formed, ignore it and try system.XWinrc instead. If neither file is present or both are badly formed, provide a built-in default which gives the user the chance to load their new or fixed configuration without restarting. Signed-off-by: Yaakov Selkowitz <yselkowitz@users.sourceforge.net>
2011-10-05Cygwin/X: Improve choice of display name used by internal clientsJon TURNEY8-20/+88
Choose display name used to connect internal clients and exported into environment of processes started by traymenu so that it uses a transport we know is working This should mean the server can start correctly with -multiwindow and/or -clipboard and any two of -nolisten inet6 -nolisten inet and -nolisten unix (the server will correctly refuse to start if all 3 are used, as it must be listening on at least one socket) Signed-off-by: Jon TURNEY <jon.turney@dronecode.org.uk> Signed-off-by: Yaakov Selkowitz <yselkowitz@users.sourceforge.net>
2011-10-05Cygwin/X: Linkage bodge for swrast, part 1Jon TURNEY5-2993/+3
Remove glapi.c and glthread.c, which contain GL dispatcher symbols which are defined in libGL, and link with libGL for them instead, as dri_swrast.so is linked with libGL on Cygwin to avoid undefined symbols at link time. Also remove glprocs.h which is only referred to by those .c files.
2011-10-05Fix the long-broken -silent-dup-error optionJon TURNEY2-86/+16
This is a horrible hack and is probably not suitable for pushing upstream. Signed-off-by: Yaakov Selkowitz <yselkowitz@users.sourceforge.net>
2011-10-05Xming: Fix the annoying menu/tooltip punch-through problem in -multiwindow mode.Colin Harrison1-0/+1
http://sourceware.org/bugzilla/show_bug.cgi?id=9929 Copyright (C) Colin Harrison 2005-2008 http://www.straightrunning.com/XmingNotes/ http://sourceforge.net/projects/xming/ Signed-off-by: Yaakov Selkowitz <yselkowitz@users.sourceforge.net>
2011-09-01Give clipboard window a nameJon TURNEY1-0/+2
2011-09-01Cygwin/X: Cause the X server to terminate if clipboard or WM internal client ↵Jon TURNEY2-6/+47
threads exit due to an error Calling FatalError from an internal client thread is a no-no, so these failures are silent at the moment (in the sense that no pop-up occurs to tell the user that we are terminating or why). Really we should either improve the way we try to avoid the internal clipboard client getting killed or perhaps restart it after an interval. Avoiding getting killed by the XDM is horribly heuristic at the moment, as we basically try to guess about what the XDM is doing, so this is always going to be fragile. (Should just check that we can't actually intercept the close request for the client) Restarting the clipboard client thread is complicated by the fact that at the moment the clipboard thread exits on server regeneration and is restarted by hooks installed by InitInput()) (So we either need to make arrangements not restart when server is restarting, or only start once and properly re-cache atoms on server regeneration) Also, I'm just noticing I should be using pthread_kill() to ensure the signal is delivered to the thread which is running the main dispatch loop so that will exit the select() it may be blocked in and notice that DE_TERMINATE is set. Also: http://xkcd.com/292/ Signed-off-by: Jon TURNEY <jon.turney@dronecode.org.uk> Signed-off-by: Yaakov Selkowitz <yselkowitz@users.sourceforge.net>
2011-09-01Remove no-longer needed tricks used to prevent the clipboard client from ↵Michel Hummel2-125/+3
being killed Remove no-longer needed tricks used to hide the clipboard client from XDM to prevent it from being killed - Delete XQuery wrapper used to hide clipboard client - Delete XDMCP mode heuristic which waits until some magic number of connections have been established before starting the clipboard We still need the EstablishConnection wrapper to ensure that the clipboard client isn't the first client (causing a server restart if it disconnects)
2011-09-01Automatically restart clipboard threadMichel Hummel2-8/+62
Automatically restart clipboard thread on unexpected exit of the clipboard
2011-09-01Revert "Fix bug #5735, Serious flaw in CygwinX clipboard"Yaakov Selkowitz1-46/+2
This commit wreaks havoc with other programs which manage the clipboard, such as MS Office Clipboard or Win32 VNC viewers: http://sourceware.org/bugzilla/show_bug.cgi?id=9910 This reverts commit 70ddd0f39d5118db72a1a4e473cbfb502f1ed9ec. Signed-off-by: Yaakov Selkowitz <yselkowitz@users.sourceforge.net>
2011-09-01Disable smart scheduler on CygwinJon TURNEY2-0/+6
The smart scheduler firing SIGALRM every 20ms causes serious problems on Cygwin. Symptoms include sporadic 'accept() failed' messages in the log and deadlocks in multiwindow mode. Signed-off-by: Yaakov Selkowitz <yselkowitz@users.sourceforge.net>