Compare commits

..

49 Commits

Author SHA1 Message Date
Andrew Nelless
0bd448d5ca Reduce clipboard chunk size to 32KiB 2017-10-31 13:28:36 +00:00
Jerry (Xinyu Hou)
8d440e68ec Update send log link 2017-10-11 12:29:54 +01:00
Nick Bolton
36f4003688 Merge branch 'master' of github.com:symless/synergy-core 2017-10-04 10:33:27 +01:00
Nick Bolton
39fe216b8c #6151 Remove synergy2 Linux shortcut 2017-10-04 10:33:05 +01:00
Nick Bolton
ad8a911590 #6162 Make --run-as-uid Linux specific 2017-10-02 22:42:56 +01:00
Nick Bolton
b028e88fed #6162 Add UID arg so service can change process user 2017-10-02 18:20:47 +01:00
Xinyu Hou
23464a38a7 #6161 Install hook before connection established 2017-09-29 12:54:30 -04:00
Xinyu Hou
0625daacde #6161 Detect local input before connected on Mac 2017-09-28 14:04:48 -04:00
Nick Bolton
856e93df0c Update Readme.txt 2017-09-18 12:05:03 +01:00
Nick Bolton
d75e7aa638 #6151 Add optional cmake install 2017-09-18 09:48:46 +01:00
Nick Bolton
e674c0e63b Revert "Revert "#6151 Install synergy core to dictory for packaging""
This reverts commit 77d82b4f4b.
2017-09-18 09:41:13 +01:00
Nick Bolton
77d82b4f4b Revert "#6151 Install synergy core to dictory for packaging"
This reverts commit 841bd079c9.
2017-09-15 13:17:22 +01:00
Jerry (Xinyu Hou)
841bd079c9 #6151 Install synergy core to dictory for packaging 2017-09-14 18:04:11 +01:00
Nick Bolton
d2f5ba6599 #6151 Improve --server and --client arg suppress comment 2017-09-14 14:57:44 +01:00
Nick Bolton
c47b4bd492 #6151 Remove redundant --no-tray arg 2017-09-14 14:40:49 +01:00
Nick Bolton
7e0cdf6c7f #6151 Update copyright and simplify cmake 2017-09-14 13:38:51 +01:00
Nick Bolton
4fe38023aa #6151 Rename synergy lib to core lib 2017-09-14 13:28:16 +01:00
Nick Bolton
ce02171eab #6151 Remove tray from core, add core deprecated warning 2017-09-14 13:28:01 +01:00
Nick Bolton
c66729e187 #6151 Introduce synergy-core 2017-09-14 13:27:02 +01:00
Nick Bolton
4d13e57ef1 #6151 Correct cmake project name 2017-09-14 12:36:08 +01:00
Nick Bolton
9e58f6834e #6151 Ignore cmake user file 2017-09-14 12:35:51 +01:00
Nick Bolton
92c344a67c Version to v2.0.0 2017-09-14 12:29:39 +01:00
Nick Bolton
6a1767efc3 #6151 Remove synergyd and syntool 2017-09-14 12:09:47 +01:00
Nick Bolton
a5b9905c96 Merge branch 'master' of https://github.com/symless/synergy-core 2017-09-14 12:09:01 +01:00
Nick Bolton
6617e1b84e #6151 Remove cmake install calls 2017-09-14 12:08:56 +01:00
Nick Bolton
f7f55d33f1 #6151 Ignore cmake cache file 2017-09-14 12:08:15 +01:00
Nick Bolton
6b7db76b88 #6151 Replace legacy Linux desktop file 2017-09-14 11:58:02 +01:00
Nick Bolton
5b46821b93 Remove all legacy components 2017-09-14 11:01:21 +01:00
Nick Bolton
a6382cea56 Revert "Revert "Removed v1 legacy config UI""
This reverts commit 3ccf3d17e4.
2017-09-14 09:47:27 +01:00
Andrew Nelless
3ccf3d17e4 Revert "Removed v1 legacy config UI"
This reverts commit 956f071f20.
2017-09-05 20:21:22 +01:00
Andrew Nelless
d0ded4e56b Merge branch 'v1.9' into v2.0 2017-08-09 19:44:01 +01:00
Nick Bolton
956f071f20 Removed v1 legacy config UI 2017-08-09 09:20:11 +01:00
Nick Bolton
0b88247b61 Update hard coded Qt version in Wix config 2017-07-31 15:40:16 +01:00
Nick Bolton
df2793c1fa #6116 Change log level for unknown quartz event type to DEBUG3 2017-07-31 14:08:02 +01:00
Andrew Nelless
0c28da7d9f Merge branch 'v1.9' into v1.9-bidir 2017-05-27 14:17:05 +01:00
Andrew Nelless
5cf74a7019 Merge remote-tracking branch 'origin/v1.9' into v1.9-bidir 2017-05-26 22:47:49 +01:00
Andrew Nelless
77a6a53a34 Merge remote-tracking branch 'origin/v1.9' into v1.9-bidir 2017-05-25 13:35:58 +01:00
Andrew Nelless
1070ffce53 Simplify version number handling 2017-05-23 16:05:35 +01:00
Andrew Nelless
9bb4f564e5 Merge branch 'v1.9' into v1.9-bidir 2017-05-23 15:25:42 +01:00
Andrew Nelless
3e5cb09e19 Merge branch 'v1.9' into v1.9-bidir 2017-05-22 21:40:44 +01:00
Andrew Nelless
79b814622e Replace 'Symless Ltd' with 'Symless' 2017-05-22 17:03:21 +01:00
Andrew Nelless
7b19ac89a1 Merge branch 'v1.9' into v1.9-bidir 2017-05-22 16:48:32 +01:00
Andrew Nelless
d5d2f937c3 Update Build.properties 2017-05-21 21:35:33 +01:00
Andrew Nelless
41721e9eac Partial local input detection for Linux 2017-05-19 20:16:30 +01:00
Andrew Nelless
0ac42d4d05 Experiment catching client-side native clicks 2017-05-16 14:26:19 +01:00
Jerry (Xinyu Hou)
9551329392 Compare source pid from event to detect local input on Mac 2017-05-10 16:24:44 +01:00
Jerry (Xinyu Hou)
f83da9ae34 Use IOHID to fake mouse buttons 2017-05-10 16:09:09 +01:00
Andrew Nelless
271ac9e057 Reduce local input detection notice to INFO level 2017-05-09 19:32:29 +01:00
Andrew Nelless
c3530a0ff3 Add synwinhk support to synergyc 2017-05-09 19:24:07 +01:00
517 changed files with 1923 additions and 85389 deletions

View File

@@ -1,62 +0,0 @@
gcp_credentials: ENCRYPTED[d3110e2399b82e1d2adb6f9294917064a448a4d102c42c5023815723841db4ff7aa1d0df64a44281ed25b3adbeb08eff]
windows_task:
gce_instance:
image_project: buildcluster-237411
image_name: windows2019-vs2017-ramdisk
platform: windows
zone: us-central1-a
type: n1-highcpu-16
disk: 32
use_ssd: true
env:
BONJOUR_SDK_HOME: C:\Program Files\Bonjour SDK\
CMAKE_PREFIX_PATH: C:\Qt\5.9.5\msvc2017_64
CIRRUS_WORKING_DIR: D:\
build_script:
- .\CI\Windows\build.bat
ubuntu1604_task:
use_compute_credits: true
container:
dockerfile: CI/ubuntu1604.Dockerfile
build_script:
- pwd; ls -la
- chmod +x ./CI/build.sh
- ./CI/build.sh
ubuntu1804_task:
use_compute_credits: true
container:
dockerfile: CI/ubuntu1804.Dockerfile
build_script:
- pwd; ls -la
- chmod +x ./CI/build.sh
- ./CI/build.sh
ubuntu1904_task:
use_compute_credits: true
container:
dockerfile: CI/ubuntu1904.Dockerfile
build_script:
- pwd; ls -la
- chmod +x ./CI/build.sh
- ./CI/build.sh
macos_task:
use_compute_credits: true
osx_instance:
image: mojave-xcode-10.2
env:
PATH: /usr/local/opt/qt/bin:$PATH
install_script:
- brew install qt
build_script:
- mkdir build
- cd build
- cmake -DCMAKE_OSX_DEPLOYMENT_TARGET=10.10 -DCMAKE_OSX_ARCHITECTURES=x86_64 -DCMAKE_BUILD_TYPE=$CMAKE_BUILD_TYPE -DCMAKE_CONFIGURATION_TYPES=$CMAKE_BUILD_TYPE ..
- make

View File

@@ -27,6 +27,6 @@ Client: Applesoft Windy OS 10
* Is there a way to work around it? No/Yes, you can...
* Does this bug prevent you from using Synergy entirely? Yes/No
Please follow the link below to send us logs from both your server and client sides if it's appropriate. https://github.com/symless/synergy/wiki/Sending-logs
Please follow the link below to send us logs from both your server and client sides if it's appropriate. https://github.com/symless/synergy-core/wiki/Sending-logs
Put anything else you can think of here.

5
.gitignore vendored
View File

@@ -19,6 +19,5 @@ src/gui/gui.pro.user*
src/gui/.qmake.stash
src/gui/.rnd
src/setup/win32/synergy.suo
/.idea
/cmake-build-debug
/CMakeLists.txt.user
CMakeCache.txt
CMakeLists.txt.user

View File

@@ -1,7 +1,7 @@
#
# Synergy build parameters
#
SYNERGY_VERSION_MAJOR = 1
SYNERGY_VERSION_MINOR = 10
SYNERGY_VERSION_PATCH = 2
SYNERGY_VERSION_MAJOR = 2
SYNERGY_VERSION_MINOR = 0
SYNERGY_VERSION_PATCH = 0
SYNERGY_VERSION_STAGE = snapshot

View File

@@ -1,56 +0,0 @@
function Controller() {
installer.autoRejectMessageBoxes();
installer.installationFinished.connect(function() {
gui.clickButton(buttons.NextButton);
})
}
Controller.prototype.WelcomePageCallback = function() {
gui.clickButton(buttons.NextButton, 3000);
}
Controller.prototype.CredentialsPageCallback = function() {
gui.clickButton(buttons.NextButton);
}
Controller.prototype.IntroductionPageCallback = function() {
gui.clickButton(buttons.NextButton);
}
Controller.prototype.TargetDirectoryPageCallback = function()
{
gui.currentPageWidget().TargetDirectoryLineEdit.setText(installer.value("HomeDir") + "/Qt");
gui.clickButton(buttons.NextButton);
}
Controller.prototype.ComponentSelectionPageCallback = function() {
var widget = gui.currentPageWidget();
widget.deselectAll();
widget.selectComponent("qt.595.clang_64")
gui.clickButton(buttons.NextButton);
}
Controller.prototype.LicenseAgreementPageCallback = function() {
gui.currentPageWidget().AcceptLicenseRadioButton.setChecked(true);
gui.clickButton(buttons.NextButton);
}
Controller.prototype.StartMenuDirectoryPageCallback = function() {
gui.clickButton(buttons.NextButton);
}
Controller.prototype.ReadyForInstallationPageCallback = function()
{
gui.clickButton(buttons.NextButton);
}
Controller.prototype.FinishedPageCallback = function() {
var checkBoxForm = gui.currentPageWidget().LaunchQtCreatorCheckBoxForm
if (checkBoxForm && checkBoxForm.launchQtCreatorCheckBox) {
checkBoxForm.launchQtCreatorCheckBox.checked = false;
}
gui.clickButton(buttons.FinishButton);
}

View File

@@ -1,6 +0,0 @@
SET VS_INSTALL_PATH=C:\"Program Files (x86)"\"Microsoft Visual Studio"\2019\Community\
call %VS_INSTALL_PATH%Common7\Tools\VsDevCmd.bat
mkdir build
cd build
cmake -G "Visual Studio 15 2017 Win64" -DCMAKE_BUILD_TYPE=Debug ..
msbuild synergy-core.sln /p:Platform="x64" /p:Configuration=Debug /m

View File

@@ -1,54 +0,0 @@
function Controller() {
installer.autoRejectMessageBoxes();
installer.installationFinished.connect(function() {
gui.clickButton(buttons.NextButton);
})
}
Controller.prototype.WelcomePageCallback = function() {
gui.clickButton(buttons.NextButton, 3000);
}
Controller.prototype.CredentialsPageCallback = function() {
gui.clickButton(buttons.NextButton);
}
Controller.prototype.IntroductionPageCallback = function() {
gui.clickButton(buttons.NextButton);
}
Controller.prototype.TargetDirectoryPageCallback = function() {
gui.currentPageWidget().TargetDirectoryLineEdit.setText(installer.environmentVariable("QT_INSTALL_DIR"));
gui.clickButton(buttons.NextButton);
}
Controller.prototype.ComponentSelectionPageCallback = function() {
var widget = gui.currentPageWidget();
widget.deselectAll();
widget.selectComponent("qt.595.win32_msvc2015");
widget.selectComponent("qt.595.win64_msvc2015_64");
widget.selectComponent("qt.595.qtscript");
widget.selectComponent("qt.tools.vcredist_msvc2015_x86");
widget.selectComponent("qt.tools.vcredist_msvc2015_x64");
gui.clickButton(buttons.NextButton);
}
Controller.prototype.LicenseAgreementPageCallback = function() {
gui.currentPageWidget().AcceptLicenseRadioButton.setChecked(true);
gui.clickButton(buttons.NextButton);
}
Controller.prototype.StartMenuDirectoryPageCallback = function() {
gui.clickButton(buttons.NextButton);
}
Controller.prototype.ReadyForInstallationPageCallback = function() {
gui.clickButton(buttons.NextButton);
}
Controller.prototype.FinishedPageCallback = function() {
var checkBoxForm = gui.currentPageWidget().LaunchQtCreatorCheckBoxForm;
if (checkBoxForm && checkBoxForm.launchQtCreatorCheckBox)
checkBoxForm.launchQtCreatorCheckBox.checked = false;
gui.clickButton(buttons.FinishButton);
}

View File

@@ -1,6 +0,0 @@
pwd
ls -la
mkdir build
cd build
cmake ..
make

View File

@@ -1,12 +0,0 @@
cd ${CIRRUS_WORKING_DIR}
source ./build/version
SYNERGY_VERSION="$SYNERGY_VERSION_MAJOR.$SYNERGY_VERSION_MINOR.$SYNERGY_VERSION_PATCH"
SYNERGY_REVISION=`git rev-parse --short=8 HEAD`
SYNERGY_DEB_VERSION="${SYNERGY_VERSION}.${SYNERGY_VERSION_STAGE}~b${BUILD_NUMBER}+${SYNERGY_REVISION}"
dch --create --package "synergy" --controlmaint --distribution unstable --newversion $SYNERGY_DEB_VERSION "Initial release"
export DEB_BUILD_OPTIONS="parallel=4"
debuild --preserve-envvar SYNERGY_* --preserve-envvar GIT_COMMIT --preserve-envvar BUILD_NUMBER

View File

@@ -1,24 +0,0 @@
#
# Ubuntu Dockerfile
#
# https://github.com/dockerfile/ubuntu
#
# Pull base image.
FROM ubuntu:16.04
# Install.
RUN \
sed -i 's/# \(.*multiverse$\)/\1/g' /etc/apt/sources.list && \
apt-get update && \
apt-get install -y git cmake qtbase5-dev build-essential libx11-dev libxtst-dev libgl1-mesa-dev libssl-dev libavahi-compat-libdnssd-dev && \
apt-get install -y debhelper devscripts
# Set environment variables.
ENV HOME /root
# Define working directory.
WORKDIR /root
# Define default command.
CMD ["bash"]

View File

@@ -1,24 +0,0 @@
#
# Ubuntu Dockerfile
#
# https://github.com/dockerfile/ubuntu
#
# Pull base image.
FROM ubuntu:18.04
# Install.
RUN \
sed -i 's/# \(.*multiverse$\)/\1/g' /etc/apt/sources.list && \
apt-get update && \
apt-get install -y git cmake qtbase5-dev build-essential libx11-dev libxtst-dev libgl1-mesa-dev libssl-dev libavahi-compat-libdnssd-dev && \
apt-get install -y debhelper devscripts
# Set environment variables.
ENV HOME /root
# Define working directory.
WORKDIR /root
# Define default command.
CMD ["bash"]

View File

@@ -1,24 +0,0 @@
#
# Ubuntu Dockerfile
#
# https://github.com/dockerfile/ubuntu
#
# Pull base image.
FROM ubuntu:19.04
# Install.
RUN \
sed -i 's/# \(.*multiverse$\)/\1/g' /etc/apt/sources.list && \
apt-get update && \
apt-get install -y git cmake qtbase5-dev build-essential libx11-dev libxtst-dev libgl1-mesa-dev libssl-dev libavahi-compat-libdnssd-dev && \
apt-get install -y debhelper devscripts
# Set environment variables.
ENV HOME /root
# Define working directory.
WORKDIR /root
# Define default command.
CMD ["bash"]

View File

@@ -17,15 +17,7 @@
cmake_minimum_required (VERSION 3.4)
project (synergy-core C CXX)
option (SYNERGY_BUILD_LEGACY_GUI "Build the legacy GUI" ON)
option (SYNERGY_BUILD_LEGACY_SERVICE "Build the legacy service (synergyd)" ON)
option (SYNERGY_BUILD_LEGACY_INSTALLER "Build the legacy installer" ON)
if (DEFINED ENV{SYNERGY_ENTERPRISE})
option (SYNERGY_ENTERPRISE "Build Enterprise" ON)
else()
option (SYNERGY_ENTERPRISE "Build Enterprise" OFF)
endif()
option (SYNERGY_CORE_INSTALL "Enable Synergy Core install (Mac and Linux)" OFF)
set (CMAKE_CXX_STANDARD 14)
set (CMAKE_CXX_EXTENSIONS OFF)
@@ -136,6 +128,13 @@ if (UNIX)
message (FATAL_ERROR "Missing library: pthread")
endif()
# curl is used on both Linux and Mac
find_package (CURL)
if (CURL_FOUND)
list (APPEND libs curl)
else()
message (FATAL_ERROR "Missing library: curl")
endif()
if (APPLE)
set (CMAKE_CXX_FLAGS "--sysroot ${CMAKE_OSX_SYSROOT} ${CMAKE_CXX_FLAGS} -DGTEST_USE_OWN_TR1_TUPLE=1")
@@ -336,62 +335,4 @@ macro (configure_files srcDir destDir)
endforeach (templateFile)
endmacro (configure_files)
macro(generate_versionfile)
if (${CMAKE_SYSTEM_NAME} MATCHES "Darwin" OR ${CMAKE_SYSTEM_NAME} MATCHES "Linux")
FILE(WRITE ${CMAKE_BINARY_DIR}/version
"export SYNERGY_VERSION_MAJOR=\"${SYNERGY_VERSION_MAJOR}\"\n"
"export SYNERGY_VERSION_MINOR=\"${SYNERGY_VERSION_MINOR}\"\n"
"export SYNERGY_VERSION_PATCH=\"${SYNERGY_VERSION_PATCH}\"\n"
"export SYNERGY_VERSION_STAGE=\"${SYNERGY_VERSION_STAGE}\"\n")
elseif(${CMAKE_SYSTEM_NAME} MATCHES "Windows")
FILE(WRITE ${CMAKE_BINARY_DIR}/version
"$env:SYNERGY_VERSION_MAJOR=\"${SYNERGY_VERSION_MAJOR}\"\n"
"$env:SYNERGY_VERSION_MINOR=\"${SYNERGY_VERSION_MINOR}\"\n"
"$env:SYNERGY_VERSION_PATCH=\"${SYNERGY_VERSION_PATCH}\"\n"
"$env:SYNERGY_VERSION_STAGE=\"${SYNERGY_VERSION_STAGE}\"\n")
endif()
endmacro(generate_versionfile)
if (${SYNERGY_BUILD_LEGACY_INSTALLER})
#
# macOS app Bundle
#
if (${CMAKE_SYSTEM_NAME} MATCHES "Darwin")
set (CMAKE_INSTALL_RPATH "@loader_path/../Libraries;@loader_path/../Frameworks")
set (SYNERGY_BUNDLE_SOURCE_DIR ${CMAKE_CURRENT_SOURCE_DIR}/dist/macos/bundle)
set (SYNERGY_BUNDLE_DIR ${CMAKE_BINARY_DIR}/bundle)
set (SYNERGY_BUNDLE_APP_DIR ${SYNERGY_BUNDLE_DIR}/Synergy.app)
set (SYNERGY_BUNDLE_BINARY_DIR ${SYNERGY_BUNDLE_APP_DIR}/Contents/MacOS)
generate_versionfile()
configure_files (${SYNERGY_BUNDLE_SOURCE_DIR} ${SYNERGY_BUNDLE_DIR})
endif()
#
# Windows installer
#
if (${CMAKE_SYSTEM_NAME} MATCHES "Windows")
message (STATUS "Configuring the v1 installer")
configure_files (${CMAKE_CURRENT_SOURCE_DIR}/dist/wix ${CMAKE_BINARY_DIR}/installer)
generate_versionfile()
endif()
#
# Linux installation
#
if (${CMAKE_SYSTEM_NAME} MATCHES "Linux")
configure_files (${CMAKE_CURRENT_SOURCE_DIR}/dist/rpm ${CMAKE_BINARY_DIR}/rpm)
install(FILES res/synergy.svg DESTINATION share/icons/hicolor/scalable/apps)
if("${VERSION_MAJOR}" STREQUAL "2")
install(FILES res/synergy2.desktop DESTINATION share/applications)
else()
install(FILES res/synergy.desktop DESTINATION share/applications)
endif()
generate_versionfile()
endif()
else()
message (STATUS "NOT configuring the v1 installer")
endif()
add_subdirectory (src)

View File

@@ -1,91 +1,21 @@
v1.10.2-rc2
==============
v1.9.0-rc3
============
Bug #4132 - Laggy mouse cursor on macOS clients
Bug fixes:
- #6495 Event queue memory leak in server cleanup
- #6471 Unable to stop core retry loop in config app
- #6460 TLS memory leak on Linux server when using client
- #6407 Enterprise config app shows auto-config elements
- #6403 Mouse cursor movement drifts over time
- #6392 Hostname alert shows unnecessarily on every open
- #6373 Compile fails on BSD Unix with dl error
v1.9.0-rc2
===========
Bug #5901 - Stored serial key corrupted on macOS
Bug #5757 - Failure to build against OpenSSL v1.1.0
Enhancements:
- #6485 Readme for master branch with download help
- #6475 Change master branch to current version
- #6470 CI solution with on-demand containers
- #6397 Remember last server used in Auto Config
- #6375 Support for Qt 5.11 framework on Windows
v1.10.1-stable
==============
Bug fixes:
- #6339 Windows validating install step freezes
- #6374 Windows background service crashes randomly
- #6376 Undeclared identifier compile error in VS2017
Enhancements:
- #6372 Forced use of TLS 1.2 without fallback method
- #6338 Auto config checkbox on settings screen
- #6384 Removal of GPL screen on Windows installer
- #6383 Extend foreground mode for Windows daemon
- #6382 Code comment for MSVC debugger logging
- #6380 Compile without warnings using VS2017
v1.10.0-stable
==============
Bug fixes:
- #6347 Log to file defaults to unwritable location
- #6345 Losing GUI config when restarting the OS
- #4991 Oversized Bonjour protocol name could conflict
Enhancements:
- #6348 Use different hard coded Qt path for CI
- #6346 CLI argument to control screen lock feature
- #6344 Customizable size limit on clipboard sharing
- #6332 Decouple version from CI build properties
- #6319 Bonjour auto-config disabled by default
- #6318 Hide TIS/TSM error on config app log
- #6312 Removal of redundant CURL library
- #6306 Show version number in config app title
- #6305 Support for Raspbian in package config
- #6301 Combine enterprise and community codebases
v1.9.1-stable
=============
Bug fix:
- #5964 Can't click after sleep on Mac client
Enhancements:
- #6310 More robust macOS screen shape detection
- #6309 Update OpenSSL to v1.0.2o for better security
v1.9.0-stable
=============
Bug fixes:
- #6251 Service hangs after GUI is opened
- #5844 Icon causes Linux package manager to fail
- #4132 Laggy mouse cursor on macOS clients
Enhancements:
- #6116 Quieter quartz event log entry on Mac
- #6037 Solve defects reported by PVS Studio
- #6014 Code sign binaries on Windows
- #6012 Jenkins integration for Ubuntu
- #5836 Jenkins integration for macOS
- #5834 Jenkins integration for Fedora
- #5390 Allow tests to be skipped during build
- #5389 Qt 5 library support for config app
- #5019 Raspbian armhf support for Raspberry Pi
- #4978 Visual Studio 2015 support on Windows 10
- #4154 IPv6 support for Windows and Linux
v1.9.0-rc1
==========
Bug #5467 - Failing to automatically download and install Bonjour
Enhancement #5389 - Ported GUI to Qt 5
Enhancement #4978 - Windows: Added support for Visual Studio 2015
Enhancement #5398 - Windows: Updated OpenSSL dependency to 1.0.2k
v1.8.8-stable
=============
==========
Bug #5196 - Some keys on Korean and Japanese keyboards have the same keycode
Bug #5578 - Pressing Hangul key results in alt+'a'
Bug #5785 - Can't switch screens when cursor is in a corner
@@ -493,3 +423,4 @@ Feature #3119: Mac OS X secondary screen
Task #2905: Unit tests: Clipboard classes
Task #3072: Downgrade Linux build machines
Task #3090: CXWindowsKeyState integ test args wrong

View File

@@ -3,30 +3,37 @@ cmake_minimum_required (VERSION 3.4)
#
# Synergy Version
#
set (SYNERGY_VERSION_MAJOR 1)
set (SYNERGY_VERSION_MINOR 10)
set (SYNERGY_VERSION_PATCH 2)
set (SYNERGY_VERSION_STAGE "rc2")
#
# Version from CI
#
if (DEFINED ENV{SYNERGY_VERSION_MAJOR})
set (SYNERGY_VERSION_MAJOR $ENV{SYNERGY_VERSION_MAJOR})
if (NOT DEFINED SYNERGY_VERSION_MAJOR)
if (DEFINED ENV{SYNERGY_VERSION_MAJOR})
set (SYNERGY_VERSION_MAJOR $ENV{SYNERGY_VERSION_MAJOR})
else()
set (SYNERGY_VERSION_MAJOR 2)
endif()
endif()
if (DEFINED ENV{SYNERGY_VERSION_MINOR})
set (SYNERGY_VERSION_MINOR $ENV{SYNERGY_VERSION_MINOR})
if (NOT DEFINED SYNERGY_VERSION_MINOR)
if (DEFINED ENV{SYNERGY_VERSION_MINOR})
set (SYNERGY_VERSION_MINOR $ENV{SYNERGY_VERSION_MINOR})
else()
set (SYNERGY_VERSION_MINOR 0)
endif()
endif()
if (DEFINED ENV{SYNERGY_VERSION_PATCH})
set (SYNERGY_VERSION_PATCH $ENV{SYNERGY_VERSION_PATCH})
if (NOT DEFINED SYNERGY_VERSION_PATCH)
if (DEFINED ENV{SYNERGY_VERSION_PATCH})
set (SYNERGY_VERSION_PATCH $ENV{SYNERGY_VERSION_PATCH})
else()
set (SYNERGY_VERSION_PATCH 0)
message (WARNING "Synergy version wasn't set. Set to ${SYNERGY_VERSION_MAJOR}.${SYNERGY_VERSION_MINOR}.${SYNERGY_VERSION_PATCH}")
endif()
endif()
if (DEFINED ENV{SYNERGY_VERSION_STAGE})
set (SYNERGY_VERSION_STAGE $ENV{SYNERGY_VERSION_STAGE})
if (NOT DEFINED SYNERGY_VERSION_STAGE)
if (DEFINED ENV{SYNERGY_VERSION_STAGE})
set (SYNERGY_VERSION_STAGE $ENV{SYNERGY_VERSION_STAGE})
else()
set (SYNERGY_VERSION_STAGE "snapshot")
endif()
endif()
if (NOT DEFINED SYNERGY_REVISION)
@@ -81,6 +88,3 @@ if (SYNERGY_DEVELOPER_MODE)
add_definitions (-DSYNERGY_DEVELOPER_MODE=1)
endif()
if (SYNERGY_ENTERPRISE)
add_definitions (-DSYNERGY_ENTERPRISE=1)
endif()

2
debian/control vendored
View File

@@ -6,7 +6,7 @@ Homepage: https://www.symless.com/
Maintainer: Symless <engineering@symless.com>
Package: synergy
Architecture: any
Architecture: amd64
Section: utils
Priority: optional
Depends: ${shlibs:Depends},

View File

@@ -2,8 +2,8 @@
<Include>
<?define Name="Synergy" ?>
<?define Version="@SYNERGY_VERSION@" ?>
<?define QtVersion="5.9.5" ?> <!-- TODO: Configure this externally //-->
<?define Author="Symless Ltd" ?>
<?define QtVersion="5.9.1" ?> <!-- TODO: Configure this externally //-->
<?define Author="Symless" ?>
<?define BinPath="@CMAKE_RUNTIME_OUTPUT_DIRECTORY@/$(var.Configuration)" ?>
<?define ResPath="@CMAKE_CURRENT_SOURCE_DIR@/res" ?>
<?define ExtPath="@CMAKE_CURRENT_SOURCE_DIR@/ext" ?>
@@ -11,12 +11,12 @@
<?define ProgramFilesFolder="ProgramFiles64Folder" ?>
<?define PlatformSimpleName="64-bit" ?>
<?define UpgradeGuid="E8A4FA54-14B9-4FD1-8E00-7BC46555FDA0" ?>
<?define QtPath="C:\Qt\Qt$(var.QtVersion)\$(var.QtVersion)\msvc2015_64" ?>
<?define QtPath="C:\Qt\$(var.QtVersion)\msvc2015_64" ?>
<?else ?>
<?define ProgramFilesFolder="ProgramFilesFolder" ?>
<?define PlatformSimpleName="32-bit" ?>
<?define UpgradeGuid="BE0B9FD8-45E2-4A8E-A0D8-1F774D074A78" ?>
<?define QtPath="C:\Qt\Qt$(var.QtVersion)\$(var.QtVersion)\msvc2015" ?>
<?define QtPath="C:\Qt\$(var.QtVersion)\msvc2015" ?>
<?endif ?>
<?define QtBinPath="$(var.QtPath)\bin" ?>
<?define QtPlatformPath="$(var.QtPath)\plugins\platforms" ?>

27
dist/wix/Product.wxs vendored
View File

@@ -22,30 +22,20 @@
</Feature>
<DirectoryRef Id="TARGETDIR">
<Component Guid="7CF3564D-1F8E-4D3D-9781-E1EE22D5BD67" Id="RegistryEntries">
<RegistryKey Id="synergys" ForceCreateOnInstall="yes" ForceDeleteOnUninstall="yes" Key="Software\Microsoft\Windows NT\CurrentVersion\AppCompatFlags\Layers" Root="HKLM">
<RegistryKey ForceCreateOnInstall="yes" ForceDeleteOnUninstall="yes" Key="Software\Microsoft\Windows NT\CurrentVersion\AppCompatFlags\Layers" Root="HKLM">
<RegistryValue Name="[INSTALLFOLDER]synergys.exe" Type="string" Value="~ HIGHDPIAWARE WIN7RTM"/>
</RegistryKey>
<RegistryKey Id="synergyc" Root="HKLM"
Key="Software\Microsoft\Windows NT\CurrentVersion\AppCompatFlags\Layers"
Action="createAndRemoveOnUninstall">
<RegistryValue Type="string" Name="[INSTALLFOLDER]synergyc.exe" Value="~ HIGHDPIAWARE WIN7RTM"/>
</RegistryKey>
<RegistryKey Id="synergy" Root="HKLM"
Key="Software\Microsoft\Windows NT\CurrentVersion\AppCompatFlags\Layers"
Action="createAndRemoveOnUninstall">
<RegistryValue Type="string" Name="[INSTALLFOLDER]synergy.exe" Value="~ HIGHDPIAWARE WIN7RTM"/>
</RegistryKey>
<!-- Windows 8 and later only -->
<Condition><![CDATA[Installed OR (VersionNT >= 602)]]></Condition>
</Component>
</DirectoryRef>
<Icon Id="synergy.ico" SourceFile="$(var.ResPath)/synergy.ico"/>
<WixVariable Id="WixUILicenseRtf" Value="$(var.ResPath)\License.rtf"/>
<WixVariable Id="WixUIBannerBmp" Value="$(var.ResPath)\banner.bmp"/>
<WixVariable Id="WixUIDialogBmp" Value="$(var.ResPath)\dialog.bmp"/>
<Property Id="ARPPRODUCTICON" Value="synergy.ico"/>
<Property Id="WIXUI_INSTALLDIR" Value="INSTALLFOLDER"/>
<Property Id="MSIRESTARTMANAGERCONTROL" Value="Disable"/>
<Property Id="LEGACY_UNINSTALL_EXISTS">
<RegistrySearch Id="LegacyRegistrySearch" Key="SOFTWARE\Wow6432Node\Microsoft\Windows\CurrentVersion\Uninstall\Synergy" Name="UninstallString" Root="HKLM" Type="file" Win64="no">
<FileSearch Id="LegacyFileSearch" Name="uninstall.exe"/>
@@ -55,17 +45,6 @@
</Condition>
<CustomAction ExeCommand="" FileKey="GuiProgram" Id="StartGui" Return="asyncNoWait"/>
<UI>
<UIRef Id="WixUI_InstallDir" />
<Publish Dialog="WelcomeDlg"
Control="Next"
Event="NewDialog"
Value="InstallDirDlg"
Order="2">1</Publish>
<Publish Dialog="InstallDirDlg"
Control="Back"
Event="NewDialog"
Value="WelcomeDlg"
Order="2">1</Publish>
<Publish Control="Finish" Dialog="ExitDialog" Event="DoAction" Value="StartGui">NOT Installed</Publish>
</UI>
</Product>

View File

@@ -1365,7 +1365,6 @@ void ERR_load_ASN1_strings(void);
# define ASN1_R_MSTRING_NOT_UNIVERSAL 139
# define ASN1_R_MSTRING_WRONG_TAG 140
# define ASN1_R_NESTED_ASN1_STRING 197
# define ASN1_R_NESTED_TOO_DEEP 219
# define ASN1_R_NON_HEX_CHARACTERS 141
# define ASN1_R_NOT_ASCII_FORMAT 190
# define ASN1_R_NOT_ENOUGH_DATA 142

View File

@@ -257,13 +257,11 @@ DH *DH_get_1024_160(void);
DH *DH_get_2048_224(void);
DH *DH_get_2048_256(void);
# ifndef OPENSSL_NO_CMS
/* RFC2631 KDF */
int DH_KDF_X9_42(unsigned char *out, size_t outlen,
const unsigned char *Z, size_t Zlen,
ASN1_OBJECT *key_oid,
const unsigned char *ukm, size_t ukmlen, const EVP_MD *md);
# endif
# define EVP_PKEY_CTX_set_dh_paramgen_prime_len(ctx, len) \
EVP_PKEY_CTX_ctrl(ctx, EVP_PKEY_DH, EVP_PKEY_OP_PARAMGEN, \

View File

@@ -1363,98 +1363,6 @@ void EVP_PKEY_meth_set_ctrl(EVP_PKEY_METHOD *pmeth,
const char *type,
const char *value));
void EVP_PKEY_meth_get_init(EVP_PKEY_METHOD *pmeth,
int (**pinit) (EVP_PKEY_CTX *ctx));
void EVP_PKEY_meth_get_copy(EVP_PKEY_METHOD *pmeth,
int (**pcopy) (EVP_PKEY_CTX *dst,
EVP_PKEY_CTX *src));
void EVP_PKEY_meth_get_cleanup(EVP_PKEY_METHOD *pmeth,
void (**pcleanup) (EVP_PKEY_CTX *ctx));
void EVP_PKEY_meth_get_paramgen(EVP_PKEY_METHOD *pmeth,
int (**pparamgen_init) (EVP_PKEY_CTX *ctx),
int (**pparamgen) (EVP_PKEY_CTX *ctx,
EVP_PKEY *pkey));
void EVP_PKEY_meth_get_keygen(EVP_PKEY_METHOD *pmeth,
int (**pkeygen_init) (EVP_PKEY_CTX *ctx),
int (**pkeygen) (EVP_PKEY_CTX *ctx,
EVP_PKEY *pkey));
void EVP_PKEY_meth_get_sign(EVP_PKEY_METHOD *pmeth,
int (**psign_init) (EVP_PKEY_CTX *ctx),
int (**psign) (EVP_PKEY_CTX *ctx,
unsigned char *sig, size_t *siglen,
const unsigned char *tbs,
size_t tbslen));
void EVP_PKEY_meth_get_verify(EVP_PKEY_METHOD *pmeth,
int (**pverify_init) (EVP_PKEY_CTX *ctx),
int (**pverify) (EVP_PKEY_CTX *ctx,
const unsigned char *sig,
size_t siglen,
const unsigned char *tbs,
size_t tbslen));
void EVP_PKEY_meth_get_verify_recover(EVP_PKEY_METHOD *pmeth,
int (**pverify_recover_init) (EVP_PKEY_CTX
*ctx),
int (**pverify_recover) (EVP_PKEY_CTX
*ctx,
unsigned char
*sig,
size_t *siglen,
const unsigned
char *tbs,
size_t tbslen));
void EVP_PKEY_meth_get_signctx(EVP_PKEY_METHOD *pmeth,
int (**psignctx_init) (EVP_PKEY_CTX *ctx,
EVP_MD_CTX *mctx),
int (**psignctx) (EVP_PKEY_CTX *ctx,
unsigned char *sig,
size_t *siglen,
EVP_MD_CTX *mctx));
void EVP_PKEY_meth_get_verifyctx(EVP_PKEY_METHOD *pmeth,
int (**pverifyctx_init) (EVP_PKEY_CTX *ctx,
EVP_MD_CTX *mctx),
int (**pverifyctx) (EVP_PKEY_CTX *ctx,
const unsigned char *sig,
int siglen,
EVP_MD_CTX *mctx));
void EVP_PKEY_meth_get_encrypt(EVP_PKEY_METHOD *pmeth,
int (**pencrypt_init) (EVP_PKEY_CTX *ctx),
int (**pencryptfn) (EVP_PKEY_CTX *ctx,
unsigned char *out,
size_t *outlen,
const unsigned char *in,
size_t inlen));
void EVP_PKEY_meth_get_decrypt(EVP_PKEY_METHOD *pmeth,
int (**pdecrypt_init) (EVP_PKEY_CTX *ctx),
int (**pdecrypt) (EVP_PKEY_CTX *ctx,
unsigned char *out,
size_t *outlen,
const unsigned char *in,
size_t inlen));
void EVP_PKEY_meth_get_derive(EVP_PKEY_METHOD *pmeth,
int (**pderive_init) (EVP_PKEY_CTX *ctx),
int (**pderive) (EVP_PKEY_CTX *ctx,
unsigned char *key,
size_t *keylen));
void EVP_PKEY_meth_get_ctrl(EVP_PKEY_METHOD *pmeth,
int (**pctrl) (EVP_PKEY_CTX *ctx, int type, int p1,
void *p2),
int (**pctrl_str) (EVP_PKEY_CTX *ctx,
const char *type,
const char *value));
void EVP_add_alg_module(void);
/* BEGIN ERROR CODES */

View File

@@ -30,11 +30,11 @@ extern "C" {
* (Prior to 0.9.5a beta1, a different scheme was used: MMNNFFRBB for
* major minor fix final patch/beta)
*/
# define OPENSSL_VERSION_NUMBER 0x100020ffL
# define OPENSSL_VERSION_NUMBER 0x100020cfL
# ifdef OPENSSL_FIPS
# define OPENSSL_VERSION_TEXT "OpenSSL 1.0.2o-fips 27 Mar 2018"
# define OPENSSL_VERSION_TEXT "OpenSSL 1.0.2l-fips 25 May 2017"
# else
# define OPENSSL_VERSION_TEXT "OpenSSL 1.0.2o 27 Mar 2018"
# define OPENSSL_VERSION_TEXT "OpenSSL 1.0.2l 25 May 2017"
# endif
# define OPENSSL_VERSION_PTEXT " part of " OPENSSL_VERSION_TEXT

View File

@@ -1727,7 +1727,7 @@ extern "C" {
# define SSL_ST_BEFORE 0x4000
# define SSL_ST_OK 0x03
# define SSL_ST_RENEGOTIATE (0x04|SSL_ST_INIT)
# define SSL_ST_ERR (0x05|SSL_ST_INIT)
# define SSL_ST_ERR 0x05
# define SSL_CB_LOOP 0x01
# define SSL_CB_EXIT 0x02

View File

@@ -280,8 +280,6 @@
# define OPENSSL_add_all_algorithms_conf OPENSSL_add_all_algo_conf
# undef EVP_PKEY_meth_set_verify_recover
# define EVP_PKEY_meth_set_verify_recover EVP_PKEY_meth_set_vrfy_recover
# undef EVP_PKEY_meth_get_verify_recover
# define EVP_PKEY_meth_get_verify_recover EVP_PKEY_meth_get_vrfy_recover
/* Hack some long EC names */
# undef EC_GROUP_set_point_conversion_form

View File

@@ -317,7 +317,7 @@ int SSL_get_servername_type(const SSL *s);
*/
int SSL_export_keying_material(SSL *s, unsigned char *out, size_t olen,
const char *label, size_t llen,
const unsigned char *context, size_t contextlen,
const unsigned char *p, size_t plen,
int use_context);
int SSL_get_sigalgs(SSL *s, int idx,

View File

@@ -1365,7 +1365,6 @@ void ERR_load_ASN1_strings(void);
# define ASN1_R_MSTRING_NOT_UNIVERSAL 139
# define ASN1_R_MSTRING_WRONG_TAG 140
# define ASN1_R_NESTED_ASN1_STRING 197
# define ASN1_R_NESTED_TOO_DEEP 219
# define ASN1_R_NON_HEX_CHARACTERS 141
# define ASN1_R_NOT_ASCII_FORMAT 190
# define ASN1_R_NOT_ENOUGH_DATA 142

View File

@@ -257,13 +257,11 @@ DH *DH_get_1024_160(void);
DH *DH_get_2048_224(void);
DH *DH_get_2048_256(void);
# ifndef OPENSSL_NO_CMS
/* RFC2631 KDF */
int DH_KDF_X9_42(unsigned char *out, size_t outlen,
const unsigned char *Z, size_t Zlen,
ASN1_OBJECT *key_oid,
const unsigned char *ukm, size_t ukmlen, const EVP_MD *md);
# endif
# define EVP_PKEY_CTX_set_dh_paramgen_prime_len(ctx, len) \
EVP_PKEY_CTX_ctrl(ctx, EVP_PKEY_DH, EVP_PKEY_OP_PARAMGEN, \

View File

@@ -1363,98 +1363,6 @@ void EVP_PKEY_meth_set_ctrl(EVP_PKEY_METHOD *pmeth,
const char *type,
const char *value));
void EVP_PKEY_meth_get_init(EVP_PKEY_METHOD *pmeth,
int (**pinit) (EVP_PKEY_CTX *ctx));
void EVP_PKEY_meth_get_copy(EVP_PKEY_METHOD *pmeth,
int (**pcopy) (EVP_PKEY_CTX *dst,
EVP_PKEY_CTX *src));
void EVP_PKEY_meth_get_cleanup(EVP_PKEY_METHOD *pmeth,
void (**pcleanup) (EVP_PKEY_CTX *ctx));
void EVP_PKEY_meth_get_paramgen(EVP_PKEY_METHOD *pmeth,
int (**pparamgen_init) (EVP_PKEY_CTX *ctx),
int (**pparamgen) (EVP_PKEY_CTX *ctx,
EVP_PKEY *pkey));
void EVP_PKEY_meth_get_keygen(EVP_PKEY_METHOD *pmeth,
int (**pkeygen_init) (EVP_PKEY_CTX *ctx),
int (**pkeygen) (EVP_PKEY_CTX *ctx,
EVP_PKEY *pkey));
void EVP_PKEY_meth_get_sign(EVP_PKEY_METHOD *pmeth,
int (**psign_init) (EVP_PKEY_CTX *ctx),
int (**psign) (EVP_PKEY_CTX *ctx,
unsigned char *sig, size_t *siglen,
const unsigned char *tbs,
size_t tbslen));
void EVP_PKEY_meth_get_verify(EVP_PKEY_METHOD *pmeth,
int (**pverify_init) (EVP_PKEY_CTX *ctx),
int (**pverify) (EVP_PKEY_CTX *ctx,
const unsigned char *sig,
size_t siglen,
const unsigned char *tbs,
size_t tbslen));
void EVP_PKEY_meth_get_verify_recover(EVP_PKEY_METHOD *pmeth,
int (**pverify_recover_init) (EVP_PKEY_CTX
*ctx),
int (**pverify_recover) (EVP_PKEY_CTX
*ctx,
unsigned char
*sig,
size_t *siglen,
const unsigned
char *tbs,
size_t tbslen));
void EVP_PKEY_meth_get_signctx(EVP_PKEY_METHOD *pmeth,
int (**psignctx_init) (EVP_PKEY_CTX *ctx,
EVP_MD_CTX *mctx),
int (**psignctx) (EVP_PKEY_CTX *ctx,
unsigned char *sig,
size_t *siglen,
EVP_MD_CTX *mctx));
void EVP_PKEY_meth_get_verifyctx(EVP_PKEY_METHOD *pmeth,
int (**pverifyctx_init) (EVP_PKEY_CTX *ctx,
EVP_MD_CTX *mctx),
int (**pverifyctx) (EVP_PKEY_CTX *ctx,
const unsigned char *sig,
int siglen,
EVP_MD_CTX *mctx));
void EVP_PKEY_meth_get_encrypt(EVP_PKEY_METHOD *pmeth,
int (**pencrypt_init) (EVP_PKEY_CTX *ctx),
int (**pencryptfn) (EVP_PKEY_CTX *ctx,
unsigned char *out,
size_t *outlen,
const unsigned char *in,
size_t inlen));
void EVP_PKEY_meth_get_decrypt(EVP_PKEY_METHOD *pmeth,
int (**pdecrypt_init) (EVP_PKEY_CTX *ctx),
int (**pdecrypt) (EVP_PKEY_CTX *ctx,
unsigned char *out,
size_t *outlen,
const unsigned char *in,
size_t inlen));
void EVP_PKEY_meth_get_derive(EVP_PKEY_METHOD *pmeth,
int (**pderive_init) (EVP_PKEY_CTX *ctx),
int (**pderive) (EVP_PKEY_CTX *ctx,
unsigned char *key,
size_t *keylen));
void EVP_PKEY_meth_get_ctrl(EVP_PKEY_METHOD *pmeth,
int (**pctrl) (EVP_PKEY_CTX *ctx, int type, int p1,
void *p2),
int (**pctrl_str) (EVP_PKEY_CTX *ctx,
const char *type,
const char *value));
void EVP_add_alg_module(void);
/* BEGIN ERROR CODES */

View File

@@ -30,11 +30,11 @@ extern "C" {
* (Prior to 0.9.5a beta1, a different scheme was used: MMNNFFRBB for
* major minor fix final patch/beta)
*/
# define OPENSSL_VERSION_NUMBER 0x100020ffL
# define OPENSSL_VERSION_NUMBER 0x100020cfL
# ifdef OPENSSL_FIPS
# define OPENSSL_VERSION_TEXT "OpenSSL 1.0.2o-fips 27 Mar 2018"
# define OPENSSL_VERSION_TEXT "OpenSSL 1.0.2l-fips 25 May 2017"
# else
# define OPENSSL_VERSION_TEXT "OpenSSL 1.0.2o 27 Mar 2018"
# define OPENSSL_VERSION_TEXT "OpenSSL 1.0.2l 25 May 2017"
# endif
# define OPENSSL_VERSION_PTEXT " part of " OPENSSL_VERSION_TEXT

View File

@@ -1727,7 +1727,7 @@ extern "C" {
# define SSL_ST_BEFORE 0x4000
# define SSL_ST_OK 0x03
# define SSL_ST_RENEGOTIATE (0x04|SSL_ST_INIT)
# define SSL_ST_ERR (0x05|SSL_ST_INIT)
# define SSL_ST_ERR 0x05
# define SSL_CB_LOOP 0x01
# define SSL_CB_EXIT 0x02

View File

@@ -280,8 +280,6 @@
# define OPENSSL_add_all_algorithms_conf OPENSSL_add_all_algo_conf
# undef EVP_PKEY_meth_set_verify_recover
# define EVP_PKEY_meth_set_verify_recover EVP_PKEY_meth_set_vrfy_recover
# undef EVP_PKEY_meth_get_verify_recover
# define EVP_PKEY_meth_get_verify_recover EVP_PKEY_meth_get_vrfy_recover
/* Hack some long EC names */
# undef EC_GROUP_set_point_conversion_form

View File

@@ -317,7 +317,7 @@ int SSL_get_servername_type(const SSL *s);
*/
int SSL_export_keying_material(SSL *s, unsigned char *out, size_t olen,
const char *label, size_t llen,
const unsigned char *context, size_t contextlen,
const unsigned char *p, size_t plen,
int use_context);
int SSL_get_sigalgs(SSL *s, int idx,

View File

@@ -3,8 +3,8 @@ http://symless.com/
Synergy allows you to share your keyboard and mouse between computers over a network.
For FAQ, setup, and usage instructions, please visit our online Readme:
http://symless.com/pm/projects/synergy/wiki/Readme
For FAQ, setup, and usage instructions, please visit our wiki:
https://github.com/symless/synergy-core/wiki
Have fun!

View File

@@ -1,12 +0,0 @@
[Desktop Entry]
Type=Application
Version=1.0
Name=Synergy
Comment=Keyboard and mouse sharing solution
Path=/usr/bin
Exec=/usr/bin/synergy
Icon=synergy
Terminal=false
Categories=Utility;
Keywords=keyboard;mouse;sharing;network;share;

View File

@@ -1,11 +0,0 @@
[Desktop Entry]
Type=Application
Version=1.0
Name=Synergy
Comment=Keyboard and mouse sharing solution
Path=/usr/bin
Exec=/usr/bin/synergy2
Icon=synergy
Terminal=false
Categories=Utility;
Keywords=keyboard;mouse;sharing;network;share;

View File

@@ -19,6 +19,3 @@ include_directories (${CMAKE_CURRENT_BINARY_DIR}/lib)
add_subdirectory(lib)
add_subdirectory(cmd)
if (SYNERGY_BUILD_LEGACY_GUI)
add_subdirectory(gui)
endif (SYNERGY_BUILD_LEGACY_GUI)

View File

@@ -14,11 +14,6 @@
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>.
add_subdirectory(core)
add_subdirectory(synergyc)
add_subdirectory(synergys)
add_subdirectory(syntool)
if (SYNERGY_BUILD_LEGACY_SERVICE)
add_subdirectory(synergyd)
endif (SYNERGY_BUILD_LEGACY_SERVICE)

View File

@@ -1,5 +1,5 @@
# synergy -- mouse and keyboard sharing utility
# Copyright (C) 2014-2016 Symless Ltd.
# Copyright (C) 2017 Symless Ltd.
#
# This package is free software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License
@@ -13,15 +13,14 @@
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>.
file(GLOB headers "*.h")
file(GLOB sources "*.cpp")
add_executable(synergy-core main.cpp)
target_link_libraries(synergy-core
arch base client common io mt net ipc platform server core ${libs} ${OPENSSL_LIBS})
add_executable(syntool ${sources})
target_link_libraries(syntool
synlib arch base client common io ipc mt net platform server ${libs} ${OPENSSL_LIBS})
if (${CMAKE_SYSTEM_NAME} MATCHES "Darwin")
install (TARGETS syntool DESTINATION ${SYNERGY_BUNDLE_BINARY_DIR})
elseif (${CMAKE_SYSTEM_NAME} MATCHES "Linux")
install (TARGETS syntool DESTINATION bin)
if (SYNERGY_CORE_INSTALL)
if (${CMAKE_SYSTEM_NAME} MATCHES "Darwin")
install (TARGETS synergy-core DESTINATION ${SYNERGY_BUNDLE_BINARY_DIR})
elseif (${CMAKE_SYSTEM_NAME} MATCHES "Linux")
install (TARGETS synergy-core DESTINATION bin)
endif()
endif()

61
src/cmd/core/main.cpp Normal file
View File

@@ -0,0 +1,61 @@
/*
* synergy -- mouse and keyboard sharing utility
* Copyright (C) 2012-2016 Symless Ltd.
* Copyright (C) 2002 Chris Schoeneman
*
* This package is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License
* found in the file LICENSE that should have accompanied this file.
*
* This package is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
#include "core/ClientApp.h"
#include "core/ServerApp.h"
#include "arch/Arch.h"
#include "base/Log.h"
#include "base/EventQueue.h"
#include <iostream>
int
main(int argc, char** argv)
{
// TODO: use existing arg parse code
bool server, client;
if (argc > 1) {
server = std::string(argv[1]) == "--server";
client = std::string(argv[1]) == "--client";
}
#if SYSAPI_WIN32
// record window instance for tray icon, etc
ArchMiscWindows::setInstanceWin32(GetModuleHandle(NULL));
#endif
Arch arch;
arch.init();
Log log;
EventQueue events;
if (server) {
ServerApp app(&events);
return app.run(argc, argv);
}
else if (client) {
ClientApp app(&events);
return app.run(argc, argv);
}
else {
// TODO: use common error code
std::cerr << "error: use --client or --server args" << std::endl;
return 1;
}
}

View File

@@ -19,8 +19,6 @@ set(sources
)
if (WIN32)
file(GLOB arch_headers "MSWindows*.h")
file(GLOB arch_sources "MSWindows*.cpp")
list(APPEND sources
resource.h
synergyc.ico
@@ -30,12 +28,6 @@ if (WIN32)
tb_run.ico
tb_wait.ico
)
elseif (APPLE)
file(GLOB arch_headers "OSX*.h")
file(GLOB arch_sources "OSX*.cpp")
elseif (UNIX)
file(GLOB arch_headers "XWindows*.h")
file(GLOB arch_sources "XWindows*.cpp")
endif()
list(APPEND sources ${arch_sources})
@@ -47,11 +39,4 @@ endif()
add_executable(synergyc ${sources})
target_link_libraries(synergyc
arch base client common io mt net ipc platform server synlib ${libs} ${OPENSSL_LIBS})
if (${CMAKE_SYSTEM_NAME} MATCHES "Darwin")
install (TARGETS synergyc DESTINATION ${SYNERGY_BUNDLE_BINARY_DIR})
elseif (${CMAKE_SYSTEM_NAME} MATCHES "Linux")
install (TARGETS synergyc DESTINATION bin)
endif()
arch base client common io mt net ipc platform server core ${libs} ${OPENSSL_LIBS})

View File

@@ -1,376 +0,0 @@
/*
* synergy -- mouse and keyboard sharing utility
* Copyright (C) 2012-2016 Symless Ltd.
* Copyright (C) 2003 Chris Schoeneman
*
* This package is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License
* found in the file LICENSE that should have accompanied this file.
*
* This package is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
#include "MSWindowsClientTaskBarReceiver.h"
#include "resource.h"
#include "client/Client.h"
#include "platform/MSWindowsClipboard.h"
#include "platform/MSWindowsScreen.h"
#include "arch/win32/ArchTaskBarWindows.h"
#include "arch/win32/ArchMiscWindows.h"
#include "arch/Arch.h"
#include "base/EventQueue.h"
#include "base/log_outputters.h"
#include "base/EventTypes.h"
//
// MSWindowsClientTaskBarReceiver
//
const UINT MSWindowsClientTaskBarReceiver::s_stateToIconID[kMaxState] =
{
IDI_TASKBAR_NOT_RUNNING,
IDI_TASKBAR_NOT_WORKING,
IDI_TASKBAR_NOT_CONNECTED,
IDI_TASKBAR_NOT_CONNECTED,
IDI_TASKBAR_CONNECTED
};
MSWindowsClientTaskBarReceiver::MSWindowsClientTaskBarReceiver(
HINSTANCE appInstance, const BufferedLogOutputter* logBuffer, IEventQueue* events) :
ClientTaskBarReceiver(events),
m_appInstance(appInstance),
m_window(NULL),
m_logBuffer(logBuffer)
{
for (UInt32 i = 0; i < kMaxState; ++i) {
m_icon[i] = loadIcon(s_stateToIconID[i]);
}
m_menu = LoadMenu(m_appInstance, MAKEINTRESOURCE(IDR_TASKBAR));
// don't create the window yet. we'll create it on demand. this
// has the side benefit of being created in the thread used for
// the task bar. that's good because it means the existence of
// the window won't prevent changing the main thread's desktop.
// add ourself to the task bar
ARCH->addReceiver(this);
}
MSWindowsClientTaskBarReceiver::~MSWindowsClientTaskBarReceiver()
{
cleanup();
}
void
MSWindowsClientTaskBarReceiver::cleanup()
{
ARCH->removeReceiver(this);
for (UInt32 i = 0; i < kMaxState; ++i) {
deleteIcon(m_icon[i]);
}
DestroyMenu(m_menu);
destroyWindow();
}
void
MSWindowsClientTaskBarReceiver::showStatus()
{
// create the window
createWindow();
// lock self while getting status
lock();
// get the current status
std::string status = getToolTip();
// done getting status
unlock();
// update dialog
HWND child = GetDlgItem(m_window, IDC_TASKBAR_STATUS_STATUS);
SendMessage(child, WM_SETTEXT, 0, (LPARAM)status.c_str());
if (!IsWindowVisible(m_window)) {
// position it by the mouse
POINT cursorPos;
GetCursorPos(&cursorPos);
RECT windowRect;
GetWindowRect(m_window, &windowRect);
int x = cursorPos.x;
int y = cursorPos.y;
int fw = GetSystemMetrics(SM_CXDLGFRAME);
int fh = GetSystemMetrics(SM_CYDLGFRAME);
int ww = windowRect.right - windowRect.left;
int wh = windowRect.bottom - windowRect.top;
int sw = GetSystemMetrics(SM_CXFULLSCREEN);
int sh = GetSystemMetrics(SM_CYFULLSCREEN);
if (fw < 1) {
fw = 1;
}
if (fh < 1) {
fh = 1;
}
if (x + ww - fw > sw) {
x -= ww - fw;
}
else {
x -= fw;
}
if (x < 0) {
x = 0;
}
if (y + wh - fh > sh) {
y -= wh - fh;
}
else {
y -= fh;
}
if (y < 0) {
y = 0;
}
SetWindowPos(m_window, HWND_TOPMOST, x, y, ww, wh,
SWP_SHOWWINDOW);
}
}
void
MSWindowsClientTaskBarReceiver::runMenu(int x, int y)
{
// do popup menu. we need a window to pass to TrackPopupMenu().
// the SetForegroundWindow() and SendMessage() calls around
// TrackPopupMenu() are to get the menu to be dismissed when
// another window gets activated and are just one of those
// win32 weirdnesses.
createWindow();
SetForegroundWindow(m_window);
HMENU menu = GetSubMenu(m_menu, 0);
SetMenuDefaultItem(menu, IDC_TASKBAR_STATUS, FALSE);
HMENU logLevelMenu = GetSubMenu(menu, 3);
CheckMenuRadioItem(logLevelMenu, 0, 6,
CLOG->getFilter() - kERROR, MF_BYPOSITION);
int n = TrackPopupMenu(menu,
TPM_NONOTIFY |
TPM_RETURNCMD |
TPM_LEFTBUTTON |
TPM_RIGHTBUTTON,
x, y, 0, m_window, NULL);
SendMessage(m_window, WM_NULL, 0, 0);
// perform the requested operation
switch (n) {
case IDC_TASKBAR_STATUS:
showStatus();
break;
case IDC_TASKBAR_LOG:
copyLog();
break;
case IDC_TASKBAR_SHOW_LOG:
ARCH->showConsole(true);
break;
case IDC_TASKBAR_LOG_LEVEL_ERROR:
CLOG->setFilter(kERROR);
break;
case IDC_TASKBAR_LOG_LEVEL_WARNING:
CLOG->setFilter(kWARNING);
break;
case IDC_TASKBAR_LOG_LEVEL_NOTE:
CLOG->setFilter(kNOTE);
break;
case IDC_TASKBAR_LOG_LEVEL_INFO:
CLOG->setFilter(kINFO);
break;
case IDC_TASKBAR_LOG_LEVEL_DEBUG:
CLOG->setFilter(kDEBUG);
break;
case IDC_TASKBAR_LOG_LEVEL_DEBUG1:
CLOG->setFilter(kDEBUG1);
break;
case IDC_TASKBAR_LOG_LEVEL_DEBUG2:
CLOG->setFilter(kDEBUG2);
break;
case IDC_TASKBAR_QUIT:
quit();
break;
}
}
void
MSWindowsClientTaskBarReceiver::primaryAction()
{
showStatus();
}
const IArchTaskBarReceiver::Icon
MSWindowsClientTaskBarReceiver::getIcon() const
{
return static_cast<Icon>(m_icon[getStatus()]);
}
void
MSWindowsClientTaskBarReceiver::copyLog() const
{
if (m_logBuffer != NULL) {
// collect log buffer
String data;
for (BufferedLogOutputter::const_iterator index = m_logBuffer->begin();
index != m_logBuffer->end(); ++index) {
data += *index;
data += "\n";
}
// copy log to clipboard
if (!data.empty()) {
MSWindowsClipboard clipboard(m_window);
clipboard.open(0);
clipboard.emptyUnowned();
clipboard.add(IClipboard::kText, data);
clipboard.close();
}
}
}
void
MSWindowsClientTaskBarReceiver::onStatusChanged()
{
if (IsWindowVisible(m_window)) {
showStatus();
}
}
HICON
MSWindowsClientTaskBarReceiver::loadIcon(UINT id)
{
HANDLE icon = LoadImage(m_appInstance,
MAKEINTRESOURCE(id),
IMAGE_ICON,
0, 0,
LR_DEFAULTCOLOR);
return static_cast<HICON>(icon);
}
void
MSWindowsClientTaskBarReceiver::deleteIcon(HICON icon)
{
if (icon != NULL) {
DestroyIcon(icon);
}
}
void
MSWindowsClientTaskBarReceiver::createWindow()
{
// ignore if already created
if (m_window != NULL) {
return;
}
// get the status dialog
m_window = CreateDialogParam(m_appInstance,
MAKEINTRESOURCE(IDD_TASKBAR_STATUS),
NULL,
(DLGPROC)&MSWindowsClientTaskBarReceiver::staticDlgProc,
reinterpret_cast<LPARAM>(
static_cast<void*>(this)));
// window should appear on top of everything, including (especially)
// the task bar.
LONG_PTR style = GetWindowLongPtr(m_window, GWL_EXSTYLE);
style |= WS_EX_TOOLWINDOW | WS_EX_TOPMOST;
SetWindowLongPtr(m_window, GWL_EXSTYLE, style);
// tell the task bar about this dialog
ArchTaskBarWindows::addDialog(m_window);
}
void
MSWindowsClientTaskBarReceiver::destroyWindow()
{
if (m_window != NULL) {
ArchTaskBarWindows::removeDialog(m_window);
DestroyWindow(m_window);
m_window = NULL;
}
}
BOOL
MSWindowsClientTaskBarReceiver::dlgProc(HWND hwnd,
UINT msg, WPARAM wParam, LPARAM)
{
switch (msg) {
case WM_INITDIALOG:
// use default focus
return TRUE;
case WM_ACTIVATE:
// hide when another window is activated
if (LOWORD(wParam) == WA_INACTIVE) {
ShowWindow(hwnd, SW_HIDE);
}
break;
}
return FALSE;
}
BOOL CALLBACK
MSWindowsClientTaskBarReceiver::staticDlgProc(HWND hwnd,
UINT msg, WPARAM wParam, LPARAM lParam)
{
// if msg is WM_INITDIALOG, extract the MSWindowsClientTaskBarReceiver*
// and put it in the extra window data then forward the call.
MSWindowsClientTaskBarReceiver* self = NULL;
if (msg == WM_INITDIALOG) {
self = static_cast<MSWindowsClientTaskBarReceiver*>(
reinterpret_cast<void*>(lParam));
SetWindowLongPtr(hwnd, GWLP_USERDATA, (LONG_PTR) lParam);
}
else {
// get the extra window data and forward the call
LONG_PTR data = GetWindowLongPtr(hwnd, GWLP_USERDATA);
if (data != 0) {
self = (MSWindowsClientTaskBarReceiver*) data;
}
}
// forward the message
if (self != NULL) {
return self->dlgProc(hwnd, msg, wParam, lParam);
}
else {
return (msg == WM_INITDIALOG) ? TRUE : FALSE;
}
}
IArchTaskBarReceiver*
createTaskBarReceiver(const BufferedLogOutputter* logBuffer, IEventQueue* events)
{
ArchMiscWindows::setIcons(
(HICON)LoadImage(ArchMiscWindows::instanceWin32(),
MAKEINTRESOURCE(IDI_SYNERGY),
IMAGE_ICON,
32, 32, LR_SHARED),
(HICON)LoadImage(ArchMiscWindows::instanceWin32(),
MAKEINTRESOURCE(IDI_SYNERGY),
IMAGE_ICON,
16, 16, LR_SHARED));
return new MSWindowsClientTaskBarReceiver(
MSWindowsScreen::getWindowInstance(), logBuffer, events);
}

View File

@@ -1,68 +0,0 @@
/*
* synergy -- mouse and keyboard sharing utility
* Copyright (C) 2012-2016 Symless Ltd.
* Copyright (C) 2003 Chris Schoeneman
*
* This package is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License
* found in the file LICENSE that should have accompanied this file.
*
* This package is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
#pragma once
#include "synergy/ClientTaskBarReceiver.h"
#define WIN32_LEAN_AND_MEAN
#include <Windows.h>
class BufferedLogOutputter;
class IEventQueue;
//! Implementation of ClientTaskBarReceiver for Microsoft Windows
class MSWindowsClientTaskBarReceiver : public ClientTaskBarReceiver {
public:
MSWindowsClientTaskBarReceiver(HINSTANCE, const BufferedLogOutputter*, IEventQueue* events);
virtual ~MSWindowsClientTaskBarReceiver();
// IArchTaskBarReceiver overrides
virtual void showStatus();
virtual void runMenu(int x, int y);
virtual void primaryAction();
virtual const Icon getIcon() const;
void cleanup();
protected:
void copyLog() const;
// ClientTaskBarReceiver overrides
virtual void onStatusChanged();
private:
HICON loadIcon(UINT);
void deleteIcon(HICON);
void createWindow();
void destroyWindow();
BOOL dlgProc(HWND hwnd,
UINT msg, WPARAM wParam, LPARAM lParam);
static BOOL CALLBACK
staticDlgProc(HWND hwnd,
UINT msg, WPARAM wParam, LPARAM lParam);
private:
HINSTANCE m_appInstance;
HWND m_window;
HMENU m_menu;
HICON m_icon[kMaxState];
const BufferedLogOutputter* m_logBuffer;
static const UINT s_stateToIconID[];
};

View File

@@ -1,69 +0,0 @@
/*
* synergy -- mouse and keyboard sharing utility
* Copyright (C) 2012-2016 Symless Ltd.
* Copyright (C) 2004 Chris Schoeneman
*
* This package is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License
* found in the file LICENSE that should have accompanied this file.
*
* This package is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
#include "OSXClientTaskBarReceiver.h"
#include "arch/Arch.h"
//
// OSXClientTaskBarReceiver
//
OSXClientTaskBarReceiver::OSXClientTaskBarReceiver(
const BufferedLogOutputter*,
IEventQueue* events) :
ClientTaskBarReceiver(events)
{
// add ourself to the task bar
ARCH->addReceiver(this);
}
OSXClientTaskBarReceiver::~OSXClientTaskBarReceiver()
{
ARCH->removeReceiver(this);
}
void
OSXClientTaskBarReceiver::showStatus()
{
// do nothing
}
void
OSXClientTaskBarReceiver::runMenu(int, int)
{
// do nothing
}
void
OSXClientTaskBarReceiver::primaryAction()
{
// do nothing
}
const IArchTaskBarReceiver::Icon
OSXClientTaskBarReceiver::getIcon() const
{
return NULL;
}
IArchTaskBarReceiver*
createTaskBarReceiver(const BufferedLogOutputter* logBuffer, IEventQueue* events)
{
return new OSXClientTaskBarReceiver(logBuffer, events);
}

View File

@@ -1,37 +0,0 @@
/*
* synergy -- mouse and keyboard sharing utility
* Copyright (C) 2012-2016 Symless Ltd.
* Copyright (C) 2004 Chris Schoeneman
*
* This package is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License
* found in the file LICENSE that should have accompanied this file.
*
* This package is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
#pragma once
#include "synergy/ClientTaskBarReceiver.h"
class BufferedLogOutputter;
class IEventQueue;
//! Implementation of ClientTaskBarReceiver for OS X
class OSXClientTaskBarReceiver : public ClientTaskBarReceiver {
public:
OSXClientTaskBarReceiver(const BufferedLogOutputter*, IEventQueue* events);
virtual ~OSXClientTaskBarReceiver();
// IArchTaskBarReceiver overrides
virtual void showStatus();
virtual void runMenu(int x, int y);
virtual void primaryAction();
virtual const Icon getIcon() const;
};

View File

@@ -1,68 +0,0 @@
/*
* synergy -- mouse and keyboard sharing utility
* Copyright (C) 2012-2016 Symless Ltd.
* Copyright (C) 2003 Chris Schoeneman
*
* This package is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License
* found in the file LICENSE that should have accompanied this file.
*
* This package is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
#include "XWindowsClientTaskBarReceiver.h"
#include "arch/Arch.h"
//
// CXWindowsClientTaskBarReceiver
//
CXWindowsClientTaskBarReceiver::CXWindowsClientTaskBarReceiver(
const BufferedLogOutputter*,
IEventQueue* events) :
ClientTaskBarReceiver(events)
{
// add ourself to the task bar
ARCH->addReceiver(this);
}
CXWindowsClientTaskBarReceiver::~CXWindowsClientTaskBarReceiver()
{
ARCH->removeReceiver(this);
}
void
CXWindowsClientTaskBarReceiver::showStatus()
{
// do nothing
}
void
CXWindowsClientTaskBarReceiver::runMenu(int, int)
{
// do nothing
}
void
CXWindowsClientTaskBarReceiver::primaryAction()
{
// do nothing
}
const IArchTaskBarReceiver::Icon
CXWindowsClientTaskBarReceiver::getIcon() const
{
return NULL;
}
IArchTaskBarReceiver*
createTaskBarReceiver(const BufferedLogOutputter* logBuffer, IEventQueue* events)
{
return new CXWindowsClientTaskBarReceiver(logBuffer, events);
}

View File

@@ -1,38 +0,0 @@
/*
* synergy -- mouse and keyboard sharing utility
* Copyright (C) 2012-2016 Symless Ltd.
* Copyright (C) 2003 Chris Schoeneman
*
* This package is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License
* found in the file LICENSE that should have accompanied this file.
*
* This package is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
#pragma once
#include "synergy/ClientTaskBarReceiver.h"
class BufferedLogOutputter;
class IEventQueue;
//! Implementation of ClientTaskBarReceiver for X Windows
class CXWindowsClientTaskBarReceiver : public ClientTaskBarReceiver {
public:
CXWindowsClientTaskBarReceiver(
const BufferedLogOutputter*, IEventQueue* events);
virtual ~CXWindowsClientTaskBarReceiver();
// IArchTaskBarReceiver overrides
virtual void showStatus();
virtual void runMenu(int x, int y);
virtual void primaryAction();
virtual const Icon getIcon() const;
};

View File

@@ -16,24 +16,18 @@
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
#include "synergy/ClientApp.h"
#include "core/ClientApp.h"
#include "arch/Arch.h"
#include "base/Log.h"
#include "base/EventQueue.h"
#if WINAPI_MSWINDOWS
#include "MSWindowsClientTaskBarReceiver.h"
#elif WINAPI_XWINDOWS
#include "XWindowsClientTaskBarReceiver.h"
#elif WINAPI_CARBON
#include "OSXClientTaskBarReceiver.h"
#else
#error Platform not supported.
#endif
#include <iostream>
int
main(int argc, char** argv)
{
std::cerr << "warning: synergyc is deprecated. instead, use: synergy-core --client" << std::endl;
#if SYSAPI_WIN32
// record window instance for tray icon, etc
ArchMiscWindows::setInstanceWin32(GetModuleHandle(NULL));
@@ -45,6 +39,6 @@ main(int argc, char** argv)
Log log;
EventQueue events;
ClientApp app(&events, createTaskBarReceiver);
ClientApp app(&events);
return app.run(argc, argv);
}

View File

@@ -1,27 +0,0 @@
# synergy -- mouse and keyboard sharing utility
# Copyright (C) 2012-2016 Symless Ltd.
# Copyright (C) 2012 Nick Bolton
#
# This package is free software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# found in the file LICENSE that should have accompanied this file.
#
# This package is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>.
file(GLOB headers "*.h")
file(GLOB sources "*.cpp")
if (WIN32)
add_executable (synergyd WIN32 ${sources})
else()
add_executable (synergyd ${sources})
endif()
target_link_libraries (synergyd
arch base common io ipc mt net platform synlib shared ${libs} ${OPENSSL_LIBS})

View File

@@ -1,44 +0,0 @@
/*
* synergy -- mouse and keyboard sharing utility
* Copyright (C) 2012-2016 Symless Ltd.
* Copyright (C) 2012 Nick Bolton
*
* This package is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License
* found in the file LICENSE that should have accompanied this file.
*
* This package is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
#include "synergy/DaemonApp.h"
#include <iostream>
#ifdef SYSAPI_UNIX
int
main(int argc, char** argv)
{
DaemonApp app;
return app.run(argc, argv);
}
#elif SYSAPI_WIN32
#define WIN32_LEAN_AND_MEAN
#include <Windows.h>
int WINAPI
WinMain(HINSTANCE, HINSTANCE, LPSTR, int)
{
DaemonApp app;
return app.run(__argc, __argv);
}
#endif

View File

@@ -19,8 +19,6 @@ set(sources
)
if (WIN32)
file(GLOB arch_headers "MSWindows*.h")
file(GLOB arch_sources "MSWindows*.cpp")
list(APPEND sources
resource.h
synergys.ico
@@ -30,29 +28,12 @@ if (WIN32)
tb_run.ico
tb_wait.ico
)
elseif (APPLE)
file(GLOB arch_headers "OSX*.h")
file(GLOB arch_sources "OSX*.cpp")
elseif (UNIX)
file(GLOB arch_headers "XWindows*.h")
file(GLOB arch_sources "XWindows*.cpp")
endif()
list(APPEND sources ${arch_sources})
list(APPEND headers ${arch_headers})
if (SYNERGY_ADD_HEADERS)
list(APPEND sources ${headers})
endif()
add_executable(synergys ${sources})
target_link_libraries(synergys
arch base client common io mt net ipc platform server synlib ${libs} ${OPENSSL_LIBS})
if (${CMAKE_SYSTEM_NAME} MATCHES "Darwin")
install (TARGETS synergys DESTINATION ${SYNERGY_BUNDLE_BINARY_DIR})
elseif (${CMAKE_SYSTEM_NAME} MATCHES "Linux")
install (TARGETS synergys DESTINATION bin)
endif()
arch base client common io mt net ipc platform server core ${libs} ${OPENSSL_LIBS})

View File

@@ -1,408 +0,0 @@
/*
* synergy -- mouse and keyboard sharing utility
* Copyright (C) 2012-2016 Symless Ltd.
* Copyright (C) 2003 Chris Schoeneman
*
* This package is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License
* found in the file LICENSE that should have accompanied this file.
*
* This package is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
#include "MSWindowsServerTaskBarReceiver.h"
#include "resource.h"
#include "server/Server.h"
#include "platform/MSWindowsClipboard.h"
#include "platform/MSWindowsScreen.h"
#include "arch/win32/ArchTaskBarWindows.h"
#include "arch/win32/ArchMiscWindows.h"
#include "arch/Arch.h"
#include "base/EventQueue.h"
#include "base/IEventQueue.h"
#include "base/log_outputters.h"
#include "base/EventTypes.h"
//
// MSWindowsServerTaskBarReceiver
//
const UINT MSWindowsServerTaskBarReceiver::s_stateToIconID[kMaxState] =
{
IDI_TASKBAR_NOT_RUNNING,
IDI_TASKBAR_NOT_WORKING,
IDI_TASKBAR_NOT_CONNECTED,
IDI_TASKBAR_CONNECTED
};
MSWindowsServerTaskBarReceiver::MSWindowsServerTaskBarReceiver(
HINSTANCE appInstance, const BufferedLogOutputter* logBuffer, IEventQueue* events) :
ServerTaskBarReceiver(events),
m_events(events),
m_appInstance(appInstance),
m_window(NULL),
m_logBuffer(logBuffer)
{
for (UInt32 i = 0; i < kMaxState; ++i) {
m_icon[i] = loadIcon(s_stateToIconID[i]);
}
m_menu = LoadMenu(m_appInstance, MAKEINTRESOURCE(IDR_TASKBAR));
// don't create the window yet. we'll create it on demand. this
// has the side benefit of being created in the thread used for
// the task bar. that's good because it means the existence of
// the window won't prevent changing the main thread's desktop.
// add ourself to the task bar
ARCH->addReceiver(this);
}
void
MSWindowsServerTaskBarReceiver::cleanup()
{
ARCH->removeReceiver(this);
for (UInt32 i = 0; i < kMaxState; ++i) {
deleteIcon(m_icon[i]);
}
DestroyMenu(m_menu);
destroyWindow();
}
MSWindowsServerTaskBarReceiver::~MSWindowsServerTaskBarReceiver()
{
cleanup();
}
void
MSWindowsServerTaskBarReceiver::showStatus()
{
// create the window
createWindow();
// lock self while getting status
lock();
// get the current status
std::string status = getToolTip();
// get the connect clients, if any
const Clients& clients = getClients();
// done getting status
unlock();
// update dialog
HWND child = GetDlgItem(m_window, IDC_TASKBAR_STATUS_STATUS);
SendMessage(child, WM_SETTEXT, 0, (LPARAM)status.c_str());
child = GetDlgItem(m_window, IDC_TASKBAR_STATUS_CLIENTS);
SendMessage(child, LB_RESETCONTENT, 0, 0);
for (Clients::const_iterator index = clients.begin();
index != clients.end(); ) {
const char* client = index->c_str();
if (++index == clients.end()) {
SendMessage(child, LB_ADDSTRING, 0, (LPARAM)client);
}
else {
SendMessage(child, LB_INSERTSTRING, (WPARAM)-1, (LPARAM)client);
}
}
if (!IsWindowVisible(m_window)) {
// position it by the mouse
POINT cursorPos;
GetCursorPos(&cursorPos);
RECT windowRect;
GetWindowRect(m_window, &windowRect);
int x = cursorPos.x;
int y = cursorPos.y;
int fw = GetSystemMetrics(SM_CXDLGFRAME);
int fh = GetSystemMetrics(SM_CYDLGFRAME);
int ww = windowRect.right - windowRect.left;
int wh = windowRect.bottom - windowRect.top;
int sw = GetSystemMetrics(SM_CXFULLSCREEN);
int sh = GetSystemMetrics(SM_CYFULLSCREEN);
if (fw < 1) {
fw = 1;
}
if (fh < 1) {
fh = 1;
}
if (x + ww - fw > sw) {
x -= ww - fw;
}
else {
x -= fw;
}
if (x < 0) {
x = 0;
}
if (y + wh - fh > sh) {
y -= wh - fh;
}
else {
y -= fh;
}
if (y < 0) {
y = 0;
}
SetWindowPos(m_window, HWND_TOPMOST, x, y, ww, wh,
SWP_SHOWWINDOW);
}
}
void
MSWindowsServerTaskBarReceiver::runMenu(int x, int y)
{
// do popup menu. we need a window to pass to TrackPopupMenu().
// the SetForegroundWindow() and SendMessage() calls around
// TrackPopupMenu() are to get the menu to be dismissed when
// another window gets activated and are just one of those
// win32 weirdnesses.
createWindow();
SetForegroundWindow(m_window);
HMENU menu = GetSubMenu(m_menu, 0);
SetMenuDefaultItem(menu, IDC_TASKBAR_STATUS, FALSE);
HMENU logLevelMenu = GetSubMenu(menu, 3);
CheckMenuRadioItem(logLevelMenu, 0, 6,
CLOG->getFilter() - kERROR, MF_BYPOSITION);
int n = TrackPopupMenu(menu,
TPM_NONOTIFY |
TPM_RETURNCMD |
TPM_LEFTBUTTON |
TPM_RIGHTBUTTON,
x, y, 0, m_window, NULL);
SendMessage(m_window, WM_NULL, 0, 0);
// perform the requested operation
switch (n) {
case IDC_TASKBAR_STATUS:
showStatus();
break;
case IDC_TASKBAR_LOG:
copyLog();
break;
case IDC_TASKBAR_SHOW_LOG:
ARCH->showConsole(true);
break;
case IDC_RELOAD_CONFIG:
m_events->addEvent(Event(m_events->forServerApp().reloadConfig(),
m_events->getSystemTarget()));
break;
case IDC_FORCE_RECONNECT:
m_events->addEvent(Event(m_events->forServerApp().forceReconnect(),
m_events->getSystemTarget()));
break;
case ID_SYNERGY_RESETSERVER:
m_events->addEvent(Event(m_events->forServerApp().resetServer(),
m_events->getSystemTarget()));
break;
case IDC_TASKBAR_LOG_LEVEL_ERROR:
CLOG->setFilter(kERROR);
break;
case IDC_TASKBAR_LOG_LEVEL_WARNING:
CLOG->setFilter(kWARNING);
break;
case IDC_TASKBAR_LOG_LEVEL_NOTE:
CLOG->setFilter(kNOTE);
break;
case IDC_TASKBAR_LOG_LEVEL_INFO:
CLOG->setFilter(kINFO);
break;
case IDC_TASKBAR_LOG_LEVEL_DEBUG:
CLOG->setFilter(kDEBUG);
break;
case IDC_TASKBAR_LOG_LEVEL_DEBUG1:
CLOG->setFilter(kDEBUG1);
break;
case IDC_TASKBAR_LOG_LEVEL_DEBUG2:
CLOG->setFilter(kDEBUG2);
break;
case IDC_TASKBAR_QUIT:
quit();
break;
}
}
void
MSWindowsServerTaskBarReceiver::primaryAction()
{
showStatus();
}
const IArchTaskBarReceiver::Icon
MSWindowsServerTaskBarReceiver::getIcon() const
{
return static_cast<Icon>(m_icon[getStatus()]);
}
void
MSWindowsServerTaskBarReceiver::copyLog() const
{
if (m_logBuffer != NULL) {
// collect log buffer
String data;
for (BufferedLogOutputter::const_iterator index = m_logBuffer->begin();
index != m_logBuffer->end(); ++index) {
data += *index;
data += "\n";
}
// copy log to clipboard
if (!data.empty()) {
MSWindowsClipboard clipboard(m_window);
clipboard.open(0);
clipboard.emptyUnowned();
clipboard.add(IClipboard::kText, data);
clipboard.close();
}
}
}
void
MSWindowsServerTaskBarReceiver::onStatusChanged()
{
if (IsWindowVisible(m_window)) {
showStatus();
}
}
HICON
MSWindowsServerTaskBarReceiver::loadIcon(UINT id)
{
HANDLE icon = LoadImage(m_appInstance,
MAKEINTRESOURCE(id),
IMAGE_ICON,
0, 0,
LR_DEFAULTCOLOR);
return static_cast<HICON>(icon);
}
void
MSWindowsServerTaskBarReceiver::deleteIcon(HICON icon)
{
if (icon != NULL) {
DestroyIcon(icon);
}
}
void
MSWindowsServerTaskBarReceiver::createWindow()
{
// ignore if already created
if (m_window != NULL) {
return;
}
// get the status dialog
m_window = CreateDialogParam(m_appInstance,
MAKEINTRESOURCE(IDD_TASKBAR_STATUS),
NULL,
(DLGPROC)&MSWindowsServerTaskBarReceiver::staticDlgProc,
reinterpret_cast<LPARAM>(
static_cast<void*>(this)));
// window should appear on top of everything, including (especially)
// the task bar.
LONG_PTR style = GetWindowLongPtr(m_window, GWL_EXSTYLE);
style |= WS_EX_TOOLWINDOW | WS_EX_TOPMOST;
SetWindowLongPtr(m_window, GWL_EXSTYLE, style);
// tell the task bar about this dialog
ArchTaskBarWindows::addDialog(m_window);
}
void
MSWindowsServerTaskBarReceiver::destroyWindow()
{
if (m_window != NULL) {
ArchTaskBarWindows::removeDialog(m_window);
DestroyWindow(m_window);
m_window = NULL;
}
}
BOOL
MSWindowsServerTaskBarReceiver::dlgProc(HWND hwnd,
UINT msg, WPARAM wParam, LPARAM)
{
switch (msg) {
case WM_INITDIALOG:
// use default focus
return TRUE;
case WM_ACTIVATE:
// hide when another window is activated
if (LOWORD(wParam) == WA_INACTIVE) {
ShowWindow(hwnd, SW_HIDE);
}
break;
}
return FALSE;
}
BOOL CALLBACK
MSWindowsServerTaskBarReceiver::staticDlgProc(HWND hwnd,
UINT msg, WPARAM wParam, LPARAM lParam)
{
// if msg is WM_INITDIALOG, extract the MSWindowsServerTaskBarReceiver*
// and put it in the extra window data then forward the call.
MSWindowsServerTaskBarReceiver* self = NULL;
if (msg == WM_INITDIALOG) {
self = static_cast<MSWindowsServerTaskBarReceiver*>(
reinterpret_cast<void*>(lParam));
SetWindowLongPtr(hwnd, GWLP_USERDATA, lParam);
}
else {
// get the extra window data and forward the call
LONG_PTR data = GetWindowLongPtr(hwnd, GWLP_USERDATA);
if (data != 0) {
self = static_cast<MSWindowsServerTaskBarReceiver*>(
reinterpret_cast<void*>(data));
}
}
// forward the message
if (self != NULL) {
return self->dlgProc(hwnd, msg, wParam, lParam);
}
else {
return (msg == WM_INITDIALOG) ? TRUE : FALSE;
}
}
IArchTaskBarReceiver*
createTaskBarReceiver(const BufferedLogOutputter* logBuffer, IEventQueue* events)
{
ArchMiscWindows::setIcons(
(HICON)LoadImage(ArchMiscWindows::instanceWin32(),
MAKEINTRESOURCE(IDI_SYNERGY),
IMAGE_ICON,
32, 32, LR_SHARED),
(HICON)LoadImage(ArchMiscWindows::instanceWin32(),
MAKEINTRESOURCE(IDI_SYNERGY),
IMAGE_ICON,
16, 16, LR_SHARED));
return new MSWindowsServerTaskBarReceiver(
MSWindowsScreen::getWindowInstance(), logBuffer, events);
}

View File

@@ -1,69 +0,0 @@
/*
* synergy -- mouse and keyboard sharing utility
* Copyright (C) 2012-2016 Symless Ltd.
* Copyright (C) 2003 Chris Schoeneman
*
* This package is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License
* found in the file LICENSE that should have accompanied this file.
*
* This package is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
#pragma once
#include "synergy/ServerTaskBarReceiver.h"
#define WIN32_LEAN_AND_MEAN
#include <Windows.h>
class BufferedLogOutputter;
class IEventQueue;
//! Implementation of ServerTaskBarReceiver for Microsoft Windows
class MSWindowsServerTaskBarReceiver : public ServerTaskBarReceiver {
public:
MSWindowsServerTaskBarReceiver(HINSTANCE, const BufferedLogOutputter*, IEventQueue* events);
virtual ~MSWindowsServerTaskBarReceiver();
// IArchTaskBarReceiver overrides
virtual void showStatus();
virtual void runMenu(int x, int y);
virtual void primaryAction();
virtual const Icon getIcon() const;
void cleanup();
protected:
void copyLog() const;
// ServerTaskBarReceiver overrides
virtual void onStatusChanged();
private:
HICON loadIcon(UINT);
void deleteIcon(HICON);
void createWindow();
void destroyWindow();
BOOL dlgProc(HWND hwnd,
UINT msg, WPARAM wParam, LPARAM lParam);
static BOOL CALLBACK
staticDlgProc(HWND hwnd,
UINT msg, WPARAM wParam, LPARAM lParam);
private:
HINSTANCE m_appInstance;
HWND m_window;
HMENU m_menu;
HICON m_icon[kMaxState];
const BufferedLogOutputter* m_logBuffer;
IEventQueue* m_events;
static const UINT s_stateToIconID[];
};

View File

@@ -1,67 +0,0 @@
/*
* synergy -- mouse and keyboard sharing utility
* Copyright (C) 2012-2016 Symless Ltd.
* Copyright (C) 2004 Chris Schoeneman
*
* This package is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License
* found in the file LICENSE that should have accompanied this file.
*
* This package is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
#include "OSXServerTaskBarReceiver.h"
#include "arch/Arch.h"
//
// OSXServerTaskBarReceiver
//
OSXServerTaskBarReceiver::OSXServerTaskBarReceiver(
const BufferedLogOutputter*, IEventQueue* events) :
ServerTaskBarReceiver(events)
{
// add ourself to the task bar
ARCH->addReceiver(this);
}
OSXServerTaskBarReceiver::~OSXServerTaskBarReceiver()
{
ARCH->removeReceiver(this);
}
void
OSXServerTaskBarReceiver::showStatus()
{
// do nothing
}
void
OSXServerTaskBarReceiver::runMenu(int, int)
{
// do nothing
}
void
OSXServerTaskBarReceiver::primaryAction()
{
// do nothing
}
const IArchTaskBarReceiver::Icon
OSXServerTaskBarReceiver::getIcon() const
{
return NULL;
}
IArchTaskBarReceiver*
createTaskBarReceiver(const BufferedLogOutputter* logBuffer, IEventQueue* events)
{
return new OSXServerTaskBarReceiver(logBuffer, events);
}

View File

@@ -1,36 +0,0 @@
/*
* synergy -- mouse and keyboard sharing utility
* Copyright (C) 2012-2016 Symless Ltd.
* Copyright (C) 2004 Chris Schoeneman
*
* This package is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License
* found in the file LICENSE that should have accompanied this file.
*
* This package is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
#pragma once
#include "synergy/ServerTaskBarReceiver.h"
class BufferedLogOutputter;
//! Implementation of ServerTaskBarReceiver for OS X
class OSXServerTaskBarReceiver : public ServerTaskBarReceiver {
public:
OSXServerTaskBarReceiver(const BufferedLogOutputter*, IEventQueue* events);
virtual ~OSXServerTaskBarReceiver();
// IArchTaskBarReceiver overrides
virtual void showStatus();
virtual void runMenu(int x, int y);
virtual void primaryAction();
virtual const Icon getIcon() const;
};

View File

@@ -1,67 +0,0 @@
/*
* synergy -- mouse and keyboard sharing utility
* Copyright (C) 2012-2016 Symless Ltd.
* Copyright (C) 2003 Chris Schoeneman
*
* This package is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License
* found in the file LICENSE that should have accompanied this file.
*
* This package is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
#include "XWindowsServerTaskBarReceiver.h"
#include "arch/Arch.h"
//
// CXWindowsServerTaskBarReceiver
//
CXWindowsServerTaskBarReceiver::CXWindowsServerTaskBarReceiver(
const BufferedLogOutputter*, IEventQueue* events) :
ServerTaskBarReceiver(events)
{
// add ourself to the task bar
ARCH->addReceiver(this);
}
CXWindowsServerTaskBarReceiver::~CXWindowsServerTaskBarReceiver()
{
ARCH->removeReceiver(this);
}
void
CXWindowsServerTaskBarReceiver::showStatus()
{
// do nothing
}
void
CXWindowsServerTaskBarReceiver::runMenu(int, int)
{
// do nothing
}
void
CXWindowsServerTaskBarReceiver::primaryAction()
{
// do nothing
}
const IArchTaskBarReceiver::Icon
CXWindowsServerTaskBarReceiver::getIcon() const
{
return NULL;
}
IArchTaskBarReceiver*
createTaskBarReceiver(const BufferedLogOutputter* logBuffer, IEventQueue* events)
{
return new CXWindowsServerTaskBarReceiver(logBuffer, events);
}

View File

@@ -1,38 +0,0 @@
/*
* synergy -- mouse and keyboard sharing utility
* Copyright (C) 2012-2016 Symless Ltd.
* Copyright (C) 2003 Chris Schoeneman
*
* This package is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License
* found in the file LICENSE that should have accompanied this file.
*
* This package is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
#pragma once
#include "synergy/ServerTaskBarReceiver.h"
class BufferedLogOutputter;
class IEventQueue;
//! Implementation of ServerTaskBarReceiver for X Windows
class CXWindowsServerTaskBarReceiver : public ServerTaskBarReceiver {
public:
CXWindowsServerTaskBarReceiver(
const BufferedLogOutputter*, IEventQueue* events);
virtual ~CXWindowsServerTaskBarReceiver();
// IArchTaskBarReceiver overrides
virtual void showStatus();
virtual void runMenu(int x, int y);
virtual void primaryAction();
virtual const Icon getIcon() const;
};

View File

@@ -16,24 +16,18 @@
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
#include "synergy/ServerApp.h"
#include "core/ServerApp.h"
#include "arch/Arch.h"
#include "base/Log.h"
#include "base/EventQueue.h"
#if WINAPI_MSWINDOWS
#include "MSWindowsServerTaskBarReceiver.h"
#elif WINAPI_XWINDOWS
#include "XWindowsServerTaskBarReceiver.h"
#elif WINAPI_CARBON
#include "OSXServerTaskBarReceiver.h"
#else
#error Platform not supported.
#endif
#include <iostream>
int
main(int argc, char** argv)
{
std::cerr << "warning: synergys is deprecated. instead, use: synergy-core --server" << std::endl;
#if SYSAPI_WIN32
// record window instance for tray icon, etc
ArchMiscWindows::setInstanceWin32(GetModuleHandle(NULL));
@@ -45,6 +39,6 @@ main(int argc, char** argv)
Log log;
EventQueue events;
ServerApp app(&events, createTaskBarReceiver);
ServerApp app(&events);
return app.run(argc, argv);
}

View File

@@ -1,67 +0,0 @@
cmake_minimum_required (VERSION 3.4)
find_package (Qt5 COMPONENTS Core Widgets Network)
set (CMAKE_AUTOMOC ON)
set (CMAKE_AUTORCC ON)
set (CMAKE_AUTOUIC ON)
set (CMAKE_INCLUDE_CURRENT_DIR ON)
file (GLOB LEGACY_GUI_SOURCE_FILES src/*.cpp src/*.h)
file (GLOB LEGACY_GUI_UI_FILES src/*.ui)
file (GLOB LEGACY_ACTIVATION_FILES src/*Activation* src/*License*)
file (GLOB LEGACY_ZEROCONF_FILES src/Zeroconf*)
if (SYNERGY_ENTERPRISE)
list (REMOVE_ITEM LEGACY_GUI_SOURCE_FILES ${LEGACY_ACTIVATION_FILES})
list (REMOVE_ITEM LEGACY_GUI_UI_FILES ${LEGACY_ACTIVATION_FILES})
list (REMOVE_ITEM LEGACY_GUI_SOURCE_FILES ${LEGACY_ZEROCONF_FILES})
endif ()
if (WIN32)
set (LEGACY_GUI_RC_FILES res/win/Synergy.rc)
endif()
add_executable (synergy WIN32
${LEGACY_GUI_SOURCE_FILES}
${LEGACY_GUI_UI_FILES}
${LEGACY_GUI_RC_FILES}
res/Synergy.qrc
)
include_directories (./src)
target_link_libraries (synergy shared)
if (NOT SYNERGY_ENTERPRISE)
if (WIN32)
include_directories ($ENV{BONJOUR_SDK_HOME}/Include)
if (CMAKE_SIZEOF_VOID_P EQUAL 8)
find_library (DNSSD_LIB dnssd.lib
HINTS ENV BONJOUR_SDK_HOME
PATH_SUFFIXES "Lib/x64")
else()
find_library (DNSSD_LIB dnssd.lib
HINTS ENV BONJOUR_SDK_HOME
PATH_SUFFIXES "Lib/Win32")
endif()
elseif (${CMAKE_SYSTEM_NAME} MATCHES "Linux")
target_link_libraries (synergy dns_sd)
endif()
endif()
qt5_use_modules (synergy Core Widgets Network)
target_compile_definitions (synergy PRIVATE -DSYNERGY_VERSION_STAGE="${SYNERGY_VERSION_STAGE}")
target_compile_definitions (synergy PRIVATE -DSYNERGY_REVISION="${SYNERGY_REVISION}")
if (WIN32)
if (NOT SYNERGY_ENTERPRISE)
target_link_libraries (synergy ${DNSSD_LIB})
endif ()
set_target_properties (synergy PROPERTIES LINK_FLAGS "/NODEFAULTLIB:LIBCMT")
endif()
if (${CMAKE_SYSTEM_NAME} MATCHES "Darwin")
install (TARGETS synergy DESTINATION ${SYNERGY_BUNDLE_BINARY_DIR})
elseif (${CMAKE_SYSTEM_NAME} MATCHES "Linux")
install (TARGETS synergy DESTINATION bin)
endif()

View File

@@ -1,162 +0,0 @@
QT += widgets \
network
TEMPLATE = app
TARGET = synergy
DEFINES += VERSION_STAGE=\\\"$$QMAKE_VERSION_STAGE\\\"
DEFINES += VERSION_REVISION=\\\"$$QMAKE_VERSION_REVISION\\\"
DEFINES -= UNICODE
DEFINES += _MBCS
DEPENDPATH += . \
res
INCLUDEPATH += . \
src \
../lib/shared/
FORMS += src/MainWindowBase.ui \
src/AboutDialogBase.ui \
src/ServerConfigDialogBase.ui \
src/ScreenSettingsDialogBase.ui \
src/ActionDialogBase.ui \
src/HotkeyDialogBase.ui \
src/SettingsDialogBase.ui \
src/SetupWizardBase.ui \
src/AddClientDialogBase.ui \
src/ActivationDialog.ui \
src/CancelActivationDialog.ui \
src/FailedLoginDialog.ui
SOURCES += src/main.cpp \
src/MainWindow.cpp \
src/AboutDialog.cpp \
src/ServerConfig.cpp \
src/ServerConfigDialog.cpp \
src/ScreenSetupView.cpp \
src/Screen.cpp \
src/ScreenSetupModel.cpp \
src/NewScreenWidget.cpp \
src/TrashScreenWidget.cpp \
src/ScreenSettingsDialog.cpp \
src/BaseConfig.cpp \
src/HotkeyDialog.cpp \
src/ActionDialog.cpp \
src/Hotkey.cpp \
src/Action.cpp \
src/KeySequence.cpp \
src/KeySequenceWidget.cpp \
src/SettingsDialog.cpp \
src/AppConfig.cpp \
src/QSynergyApplication.cpp \
src/VersionChecker.cpp \
src/SetupWizard.cpp \
src/IpcClient.cpp \
src/IpcReader.cpp \
src/Ipc.cpp \
src/SynergyLocale.cpp \
src/QUtility.cpp \
src/ZeroconfServer.cpp \
src/ZeroconfThread.cpp \
src/ZeroconfRegister.cpp \
src/ZeroconfBrowser.cpp \
src/ZeroconfService.cpp \
src/DataDownloader.cpp \
src/AddClientDialog.cpp \
src/CommandProcess.cpp \
src/CoreInterface.cpp \
src/Fingerprint.cpp \
src/SslCertificate.cpp \
src/WebClient.cpp \
src/ActivationNotifier.cpp \
src/ActivationDialog.cpp \
src/CancelActivationDialog.cpp \
src/FailedLoginDialog.cpp \
../lib/shared/SerialKey.cpp \
src/LicenseManager.cpp
HEADERS += src/MainWindow.h \
src/AboutDialog.h \
src/ServerConfig.h \
src/ServerConfigDialog.h \
src/ScreenSetupView.h \
src/Screen.h \
src/ScreenSetupModel.h \
src/NewScreenWidget.h \
src/TrashScreenWidget.h \
src/ScreenSettingsDialog.h \
src/BaseConfig.h \
src/HotkeyDialog.h \
src/ActionDialog.h \
src/Hotkey.h \
src/Action.h \
src/KeySequence.h \
src/KeySequenceWidget.h \
src/SettingsDialog.h \
src/AppConfig.h \
src/QSynergyApplication.h \
src/VersionChecker.h \
src/SetupWizard.h \
src/IpcClient.h \
src/IpcReader.h \
src/Ipc.h \
src/SynergyLocale.h \
src/QUtility.h \
src/ZeroconfServer.h \
src/ZeroconfThread.h \
src/ZeroconfRegister.h \
src/ZeroconfRecord.h \
src/ZeroconfBrowser.h \
src/ZeroconfService.h \
src/DataDownloader.h \
src/AddClientDialog.h \
src/CommandProcess.h \
src/ProcessorArch.h \
src/CoreInterface.h \
src/Fingerprint.h \
src/SslCertificate.h \
src/WebClient.h \
src/ActivationNotifier.h \
src/ElevateMode.h \
src/ActivationDialog.h \
src/CancelActivationDialog.h \
src/FailedLoginDialog.h \
../lib/shared/EditionType.h \
../lib/shared/SerialKey.h \
src/LicenseManager.h
RESOURCES += res/Synergy.qrc
RC_FILE = res/win/Synergy.rc
macx {
QMAKE_INFO_PLIST = res/mac/Info.plist
TARGET = Synergy
QSYNERGY_ICON.files = res/mac/Synergy.icns
QSYNERGY_ICON.path = Contents/Resources
QMAKE_BUNDLE_DATA += QSYNERGY_ICON
LIBS += $$MACX_LIBS
}
unix:!macx:LIBS += -ldns_sd
debug {
OBJECTS_DIR = tmp/debug
MOC_DIR = tmp/debug
RCC_DIR = tmp/debug
}
release {
OBJECTS_DIR = tmp/release
MOC_DIR = tmp/release
RCC_DIR = tmp/release
}
win32-msvc2015 {
LIBS += -lAdvapi32
QMAKE_LFLAGS += /NODEFAULTLIB:LIBCMT
}
win32-msvc* {
contains(QMAKE_HOST.arch, x86):{
QMAKE_LFLAGS *= /MACHINE:X86
LIBS += -L"$$(BONJOUR_SDK_HOME)/Lib/Win32" -ldnssd
}
contains(QMAKE_HOST.arch, x86_64):{
QMAKE_LFLAGS *= /MACHINE:X64
LIBS += -L"$$(BONJOUR_SDK_HOME)/Lib/x64" -ldnssd
}
}
win32 {
Debug:DESTDIR = ../../bin/Debug
Release:DESTDIR = ../../bin/Release
INCLUDEPATH += "$$(BONJOUR_SDK_HOME)/Include"
}
else:DESTDIR = ../../bin

File diff suppressed because it is too large Load Diff

View File

@@ -1 +0,0 @@
lupdate -noobsolete gui.pro -ts gui.ts

View File

@@ -1,2 +0,0 @@
cd res/lang
lrelease *.ts

View File

@@ -1,59 +0,0 @@
<RCC>
<qresource prefix="/res">
<file>icons/16x16/synergy-connected.png</file>
<file>icons/16x16/synergy-disconnected.png</file>
<file>icons/64x64/video-display.png</file>
<file>icons/64x64/user-trash.png</file>
<file>icons/16x16/warning.png</file>
<file>icons/256x256/synergy.ico</file>
<file>image/about.png</file>
<file>lang/gui_ar.qm</file>
<file>lang/gui_bg-BG.qm</file>
<file>lang/gui_ca-AD.qm</file>
<file>lang/gui_cs-CZ.qm</file>
<file>lang/gui_cy.qm</file>
<file>lang/gui_da.qm</file>
<file>lang/gui_de.qm</file>
<file>lang/gui_es.qm</file>
<file>lang/gui_fi.qm</file>
<file>lang/gui_fr.qm</file>
<file>lang/gui_grk.qm</file>
<file>lang/gui_he.qm</file>
<file>lang/gui_hr-HR.qm</file>
<file>lang/gui_hu-HU.qm</file>
<file>lang/gui_id.qm</file>
<file>lang/gui_it.qm</file>
<file>lang/gui_ja-JP.qm</file>
<file>lang/gui_ko.qm</file>
<file>lang/gui_lt.qm</file>
<file>lang/gui_lv.qm</file>
<file>lang/gui_nl-NL.qm</file>
<file>lang/gui_no.qm</file>
<file>lang/gui_pes-IR.qm</file>
<file>lang/gui_pl-PL.qm</file>
<file>lang/gui_pt-BR.qm</file>
<file>lang/gui_pt-PT.qm</file>
<file>lang/gui_ro.qm</file>
<file>lang/gui_ru.qm</file>
<file>lang/gui_si.qm</file>
<file>lang/gui_sk-SK.qm</file>
<file>lang/gui_sl-SI.qm</file>
<file>lang/gui_sq-AL.qm</file>
<file>lang/gui_sr.qm</file>
<file>lang/gui_sv.qm</file>
<file>lang/gui_th-TH.qm</file>
<file>lang/gui_tr-TR.qm</file>
<file>lang/gui_uk.qm</file>
<file>lang/gui_ur.qm</file>
<file>lang/gui_mr.qm</file>
<file>lang/gui_vi.qm</file>
<file>lang/gui_zh-CN.qm</file>
<file>lang/gui_zh-TW.qm</file>
<file>lang/Languages.xml</file>
<file>icons/16x16/money.png</file>
<file>image/spinning-wheel.gif</file>
<file>icons/16x16/padlock.png</file>
<file>icons/16x16/synergy-transfering.png</file>
<file>icons/16x16/auto-config.png</file>
</qresource>
</RCC>

Binary file not shown.

Before

Width:  |  Height:  |  Size: 610 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 738 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 450 B

Some files were not shown because too many files have changed in this diff Show More