Commit Graph

382 Commits

Author SHA1 Message Date
crs 135c670182 Added VK_SLEEP. 2004-10-24 18:12:38 +00:00
crs 9a1de9f105 Previous half-duplex fix fixed secondary screens with half
duplex keys but broke primary screens.  This fixes both and
also ensures that the primary screen updates its shadow toggle
modifier state when leaving so the secondary screens get the
correct toggle modifier state.  Together these fix some strange
inconsistencies in toggle state across screens.
2004-10-23 19:43:37 +00:00
crs 3f7f946ab0 Fixed bug in half-duplex keys. Was updating their toggled state
om every release as well as press.
2004-10-23 18:40:31 +00:00
crs 07e2a3e511 Removed recursive mutexes. Simplified stream filters as a side
effect.  Removed -D_BSD_SOURCE and -D_XOPEN_SOURCE=500 from
compile since they're not longer necessary.
2004-09-29 21:59:26 +00:00
crs 376bba970b Now accepting screen names that end in a dot since many OS X
users have misconfigured their systems to have hostnames that
end in a dot.
2004-09-28 22:25:35 +00:00
crs 3c3c31008e Added half-duplex option for scroll lock key. 2004-09-28 22:19:11 +00:00
crs dc499149f4 Fixed compile on gcc 3.4 and later. gcc started doing access checks
for class visibility on pointers to member function 'using the
qualifying scope of the name itself.'  what this means is if method
'prot' is declared protected in class A and B inherits from A then
a method in B cannot use &A::prot but can use &B::prot.  Synergy
now does this in the one place it had not.
2004-09-27 21:54:49 +00:00
crs e7ae6831cf Worked around minor gcc 3.3.2 -O3 compiler bug. 2004-09-27 21:23:47 +00:00
crs 06987c2070 Changed version to 1.1.9. Changed configure.in to get version
number from lib/common/Version.h so it only has to be changed
there.
2004-09-27 20:53:54 +00:00
crs b72d882f41 Fixed handling of auto-repeat, ctrl + character key, and button
to KeyCode translation.
2004-08-04 22:48:08 +00:00
crs 8c93cfdb24 Fixed space key on OS X server -> client. 2004-08-03 22:02:57 +00:00
crs 0df2e9ce6a Fixed warnings in deployment build style on OS X. 2004-08-03 21:14:30 +00:00
crs b66a403941 Now using <poll.h> instead of <sys/poll.h>. Also added a bit
to autoconf to ensure we don't use poll on OS X.
2004-07-31 11:19:39 +00:00
crs 6284286d4f Fixed handling of modifier keys on OS X. Also made OS X client
ignore small mouse wheel events (which seem to get sent by some
win32 systems).  Other platforms were already ignoring them.
2004-07-29 22:11:27 +00:00
crs 3d2fa92654 Fixed handling of ctrl and alt keys when using low level hooks.
They were being discarded so the server wouldn't correctly send
ctrl, alt, or AltGr to clients.
2004-07-29 21:59:26 +00:00
crs 898a9af3b0 Added comment about a problem detecting the screen saver. 2004-07-29 21:57:42 +00:00
crs b1ead05a3c Worked around bogus key mapping on 95/98/me where multiple virtual
keys are mapped to the same button.  For example, the backslash
virtual key shares a button with some other virtual key on british
english key mappings.  Synergy could end up using the wrong virtual
key.  In the given case, the other virtual key produced no character
at all.  To determine which virtual key should really be mapped to
a button we map the button back to a virtual key and see if it's the
virtual key we started with.

Also fixed mapping of pause key.  Previously, windows+pause sent to
a win32 client wouldn't bring up system properties like it should.
2004-07-29 21:53:30 +00:00
crs bac1f24a53 Synergy now steals window activation when using low level hooks
and a console window is the active window.  This is to work around
console windows preventing the hook from detecting the shift key.
2004-07-29 21:50:17 +00:00
crs ef85356f45 Worked around bug/weirdness on OS X. It's reporting that a
non-blocking connect is available for writing (i.e. the connection
was successful) when the connection has actually failed.  This
caused synergy to rapidly retry connecting.  This change makes
synergy check for a connection error whether one was reported or
not.  Thankfully, OS X does correctly set the socket error state
when it bogusly reports a successful connection so we can tell the
connection failed.
2004-07-29 21:48:40 +00:00
crs 970c8b2fba Added workaround for apparent bug in OS X 10.3.4. If you started
a synergy client on that OS and pointed it at a system that wasn't
listening for connections then instead of the connection attempt
failing with 'connection refused' the system would claim the
connection succeeded.  A subsequent read would reveal the problem
and synergy would "disconnect" and retry, causing the CPU to spin.
The system does correctly set the socket error state so this
workaround checks for socket errors when connecting whether or not
select reports an error state.

Also, sometimes the system doesn't claim success but doesn't report
an error.  Synergy eventually times out these attempts.
2004-07-28 21:54:39 +00:00
crs 59e466da0a Changed version to 1.1.8. 2004-07-25 14:18:50 +00:00
crs 95e4963f1d Disable key event capture on X11. This was going to be used to
detect synergy hotkeys but a design flaw in X11 makes it problematic
with many applications.  We'll have to fall back to the more
traditional XGrabKey when the time comes.
2004-06-22 21:11:14 +00:00
crs ccb45bc2bc (Maybe) fixed a problem detecting when win32 screen saver started. 2004-06-12 20:48:04 +00:00
crs a80ddb4a78 Fixed bug in converting wide characters to multibyte. 2004-06-12 20:46:35 +00:00
crs 4836452038 Fixed assertion failure when client connection fails immediately. 2004-06-10 21:25:09 +00:00
crs 9c9db6958f Changed O_NDELAY to O_NONBLOCK. On some versions of Unix, read
return 0 when O_NDELAY is set and there is nothing to read.  We
want the O_NONBLOCK behavior where read returns -1 and sets
errno to EAGAIN when there is nothing to read.
2004-06-10 19:56:35 +00:00
crs 613413fb50 Added OS X precompiled header file for XCode compiles. 2004-06-10 19:42:01 +00:00
crs 20bfb04886 Changed version to 1.1.7. 2004-06-10 19:32:40 +00:00
crs 2de2b72af9 Failed to reset flag in X11 event queue buffer and that could cause
multiple threads to access the X display connection simultaneously
which causes synergy to die.
2004-06-07 21:06:49 +00:00
crs 06d77fe314 Merged Bertrand's OS X changes. Also added support for mouse wheel
on OS X server.
2004-05-26 19:23:32 +00:00
crs 84247b4c6c If the server manages to detect ctrl+alt+del it will no longer send
that to the client.  If it did then the user could see the effect of
ctrl+alt+del on both the server and client which we never want.  The
user can use ctrl+alt+pause to emulate ctrl+alt+del on the client.
2004-05-18 20:32:13 +00:00
crs 88c6769ebe Fixed bug that could allow multiple threads to simultaneously access
the X11 display connection.  The only problematic method was
CXWindowsEventQueueBuffer::addEvent given that the other event queue
methods are only called from the main thread.
2004-05-18 20:26:48 +00:00
crs ce399937f0 Fixed ctrl+alt+del emulation on win32 server. It was mapping
VK_DELETE to the keypad delete key.  This key is not interpreted
on the client as causing ctrl+alt+del.
2004-05-17 21:55:38 +00:00
crs 93d74a1fda Fixed handling of screen resolution changes. 2004-05-16 18:04:36 +00:00
crs 62b5cefb64 Changed VC++ projects to put release targets in ./build, debug
targets in ./debug, and intermediate files under ./gen.
2004-05-16 18:02:49 +00:00
crs c9046a9557 Changed version to 1.1.6. 2004-05-15 19:44:05 +00:00
crs 5a990691ca Avoided duplicate logging of screen size on win32. 2004-05-15 19:43:33 +00:00
crs d9387dbed7 Added bertrand landry hetu's mac OS X port to date. 2004-05-15 19:41:46 +00:00
crs 242050d0f2 Now restoring input focus when entering the screen to the window
that had the focus when the screen was left.
2004-05-12 20:28:00 +00:00
crs 455d0210b2 Fixed thread reference leak in network code. 2004-05-12 19:50:58 +00:00
crs df4807950a Fixed build error in gcc 3.3. 2004-05-12 18:54:03 +00:00
crs ab0a693891 Fixed bug in TCP socket that caused a busy loop in the socket
multiplexer.  That caused a lock up on windows when quitting
the server with a client connected.
2004-05-04 19:37:46 +00:00
crs fdf4b2604d Fixed X11 BMP and other bitmap conversion. Had data alignment
problems.
2004-05-03 21:14:01 +00:00
crs 4b212ad704 Added image/bmp and text/html support to X11. 2004-05-02 21:31:19 +00:00
crs 500362d5c0 Relative mouse motion for OS X. 2004-05-02 16:13:11 +00:00
crs a1bd77f91a Used MouseKeys accessibility function to show the mouse cursor
on a secondary screen when there's no physical mouse attached to
the system.  Kinda flaky when a mouse is attached or detached but
seems to work well enough when the device is not attached to start
with and not attached while running synergy.
2004-05-02 16:06:04 +00:00
crs 423dd3b718 Added support for daemon startup dependencies. Made synergy
dependent on NetBT, which I hope is right.
2004-05-02 16:01:59 +00:00
crs d97879b25c Fixed comment about canonical bitmap clipboard format. 2004-05-02 16:00:45 +00:00
crs d84e5a26be Added win32 clipboard support for images and HTML. Still need X11
support.
2004-05-02 08:04:48 +00:00
crs 9c35a45a2c Added relative mouse move support to win32. 2004-05-02 08:04:15 +00:00
crs 0f45face21 Forgot to change the client to handle relative moves. 2004-05-02 08:03:49 +00:00
crs fddf7d04a3 X11 clipboard logging now also prints atom names, not just numbers. 2004-05-01 16:10:09 +00:00
crs 3758d9d282 Added files forgotten in previous checkin. 2004-05-01 15:19:53 +00:00
crs 16110acaa2 Added support for a global relative mouse motion option. When true
and on a secondary screen and locked to the screen (via scroll lock)
mouse motion is sent as motion deltas.  When true and scroll lock
is toggled off the mouse is warped to the secondary screen's center
so the server knows where it is.  This option is intended to support
games and other programs that repeatedly warp the mouse to the center
of the screen.  This change adds general and X11 support but not
win32.  The option name is "relativeMouseMoves".
2004-05-01 15:18:59 +00:00
crs 320cc754a2 Better fixes for compiling on FreeBSD and OpenBSD. 2004-05-01 12:11:28 +00:00
crs 975d888d65 Fixes for FreeBSD. 2004-05-01 11:01:40 +00:00
crs 165c889c5d Fixes to compile on solaris 9 using g++. 2004-05-01 10:12:06 +00:00
crs dcfe49ef48 Fixed regression where cursor wasn't locked to screen when a mouse
button is down on win32.
2004-05-01 08:56:24 +00:00
crs 4d2d4a2171 Fixed type cast warnings. 2004-05-01 08:54:42 +00:00
crs 54b3884eba Removed use of mbrtowc, wcrtomb, and mbsinit. Many platforms
didn't support them and the emulated versions were just as good
except for a performance problem with excessive locking and
unlocking of a mutex.  So this also changes IArchString to
provide string rather than character conversion so we can lock
the mutex once per string rather than once per character.
2004-04-13 19:39:04 +00:00
crs e1027eeb3a More changes for MSYS/MinGW builds. Added makefile for launcher.
Still need hook library and resource compiling.
2004-04-11 19:43:16 +00:00
crs bf2879724f Preliminary support for MSYS/MinGW builds. Doesn't yet build
CSynergyHook as a DLL and does not compile or link in the
resources for the binaries.
2004-04-11 19:15:09 +00:00
crs 530be3ff9d Updates to support OS X. This improves support for building on
multiple systems with automake, with X Windows and Carbon window
system APIs supported.  It's also a starting port for supporting
win32 builds using mingw.  OS X support is incomplete;  the tree
will compile and link but the binaries will not function.
2004-04-11 14:58:08 +00:00
crs 619dd75f0d Added missing initialization of mutex attribute call. 2004-04-06 22:09:38 +00:00
crs bede6352c1 Fixed bug in handling rejection of screen with name that's already
in use.  The client was being correctly rejected but the already
connected client was being forcefully disconnected too because the
client to disconnect was found by looking up the client by name.
We now instead look up the client by IClient*.
2004-04-05 21:23:44 +00:00
crs 3db9facb6c Added workaround for win32 low-level mouse hook position weirdness.
The low-level hook can report mouse positions outside the boundaries
of the screen and bogus retrograde motion.  This messes up switch on
double tap.  This change attempts to detect and suppress the bogus
events.
2004-04-05 21:10:06 +00:00
crs 6d6ebf7926 Made hook debug logging print at DEBUG1 rather than INFO level. 2004-04-05 21:08:49 +00:00
crs 083607345a Removed DEPTH, VDEPTH, and VPATH from makefiles. 2004-04-04 12:12:32 +00:00
crs ef908bf0bc Changed version to 1.1.5. 2004-04-04 12:12:30 +00:00
crs d1a60e848e Reverted task bar code to 1.0.15 version. That used a window in
its own thread for handling messages.  It seems to fix most of
the task bar bugs but there's still an hourglass cursor on NT
when using the popup menu.
2004-03-31 22:15:13 +00:00
crs 4576b30c37 Fixed lookup of hosts by name on win32. 2004-03-31 22:14:15 +00:00
crs 4805453190 Fixed failure to initialize double tap and wait to switch timeouts. 2004-03-31 22:12:53 +00:00
crs 610518104b Fixed crash bug in CKeyState. Would deference bogus pointer in
isModifierActive if there's an unmapped toggle modifier.
2004-03-30 18:55:58 +00:00
crs ceb654246c Changed version to 1.1.4. This time changing the version before
making any other changes.
2004-03-30 18:54:56 +00:00
crs cfb082f306 Added ISO_Level3_Shift as a synonym for Mode_switch. I've no idea
if this will work as hoped but I've seen documentation that XFree
4.3 uses ISO_Level3_Shift rather than Mode_switch.
2004-03-28 14:53:01 +00:00
crs 97046541b9 Fixed keyboard handling on windows 95 family. 2004-03-28 14:07:58 +00:00
crs e50146119f Updated makefile to reflect renaming of platform files for win32. 2004-03-28 14:07:37 +00:00
crs 0f7fa2dfd9 Fixed windows 95 family screen saver stuff. 2004-03-28 14:06:40 +00:00
crs bf7643faab Changed debug logging of key IDs to use hex. 2004-03-28 14:05:52 +00:00
crs d2f4cbf002 Fixed bugs in installing per-user startup programs on windows 95
family.
2004-03-28 14:05:31 +00:00
crs e2a31e8b66 Converted win32 to new keyboard state tracking design. Also
changed locking to screen so that keys no longer count (only
mouse buttons and scroll lock toggled on).  This is to deal
with the unreliability of key event reporting which can leave
us locked to a screen with no key physically pressed.  The
result of this is that clients get key repeats and releases
without the corresponding key press.  CKeyState handles this
by discarding repeat/release events on keys it hasn't seen go
down.  Also made a few other minor fixes to win32 keyboard
handling.
2004-03-26 20:59:26 +00:00
crs ab11ebea01 Fixed handling of reading strings from the registry. This was
broken when support for binary data was added.  The terminating
NUL was included in the string as a character (that's in addition
to the terminating NUL added by std::string).
2004-03-26 20:59:21 +00:00
crs 8d99fd2511 Checkpoint. Converted X11 to new keyboard state tracking design.
This new design is simpler.  For keyboard support, clients need only
implement 4 virtual methods on a class derived from CKeyState and
one trivial method in the class derived from CPlatformScreen, which
is now the superclass of platform screens instead of IPlatformScreen.
Keyboard methods have been removed from IPlatformScreen, IPrimaryScreen
and ISecondaryScreen.  Also, all keyboard state tracking is now in
exactly one place (the CKeyState subclass) rather than in CScreen,
the platform screen, and the key mapper.  Still need to convert Win32.
2004-03-21 20:01:41 +00:00
crs 19559d4b4e Updated keyboard handling on win32. Still needs some work to
avoid shadowing key state in multiple places.  Also got locked
to screen and reported key appeared to be wrong.
2004-03-17 20:59:25 +00:00
crs 20ba10bfa8 Changed how key state is tracked on X11. Now updating key state
on every key press and release so we don't have to updateKeys()
in isLockedToScreen().  However, if any key appears to be down
we still call updateKeys() to double check that it's really down.
If not we note the spurious lock and don't lock to the screen.
2004-03-14 17:55:53 +00:00
crs 6f19fcfe39 Fixed doxygen formatting error. 2004-03-14 17:50:37 +00:00
crs 03dc45972b Improved handling of active window on win32. Synergy no longer
takes activation so the previously active window doesn't pop to
the top of the window stack when it regains activation.  One
drawback of this is that the mouse cursor isn't shown when
a window (other than synergy's) is activated.  However, synergy
does detect mouse motion as before and shows the cursor when it
sees any.
2004-03-13 19:01:27 +00:00
crs 83713c6235 Fixed error in previous submit. 2004-03-13 18:58:20 +00:00
crs 12fa99aee0 Fixed handling of handshake complete. Was posting an event for it
but making direct calls for other messages from the server.  This
could cause messages to be handled out of order.  Now making a
direct call for handshake complete.
2004-03-13 17:16:24 +00:00
crs 8c1af9d53f Fixed win32 taskbar icon event handling. Wasn't responding to
messages sent via SendMessage (rather than PostMessage).
2004-03-13 17:14:32 +00:00
crs a6e858a208 Added win32 support for power management. 2004-03-13 17:13:55 +00:00
crs a1c807ba67 Added support for DPMS in X11 screen saver. DPMS is the extension
that allows you to power down the display.  Previously, synergy
would not power on the display if DPMS was enabled and activated
and xscreensaver was not running.  It also wouldn't disable DPMS
so the display would power down normally on a synergy client if
there was no input activity.
2004-03-10 22:03:01 +00:00
crs 6c7039490d Added check for inet_aton and a simple implementation for platforms
that are missing it.
2004-03-10 20:35:03 +00:00
crs 3920c63af6 Removed dependency on X11/XF86keysym.h. There are several versions
of that file in existance, not all of which have all the symbols we
require and none of which provide any convenient means of telling
what groups of symbols they define.
2004-03-08 21:18:36 +00:00
crs 9e995bedbf Win32 fixes. Fixed slightly off cursor positioning when using
absolute mouse_event().  Improved keyboard handling:  now using
keyboard layout of last foreground window when leaving server
so users can meaningfully choose the locale, moved dead key
handling into hook library so there should be no more race
conditions involving the keyboard dead key buffer, simplified
keyboard and cursor handling by using a full screen transparent
window when not using low level hooks, fixed error in restoring
buffered dead key when checking for dead keys.  This hopefully
fixes all known keyboard bugs on win32.
2004-03-08 20:53:32 +00:00
crs f068232643 Typecasting fix to compile on old solaris. 2004-03-08 20:45:53 +00:00
crs a27c6ad2c6 Server now disables jump zones when scroll lock is active. 2004-03-06 16:20:08 +00:00
crs 5593573182 Fixed processing of events. Was waking up on a sent (rather than
posted) message but then blocking in GetMessage() which handles
the sent message directly.  No longer blocking on sent messages.
2004-02-29 21:34:30 +00:00
crs ffa966747b Fixed handling of winsock connect event. Was always immediately
indicating socket had connected.
2004-02-29 21:33:20 +00:00
crs 4ac756fc28 Fixed cursor hiding on win32. Still fails occassionally. 2004-02-29 21:32:00 +00:00