This repository has been archived by the owner. It is now read-only.
Permalink
Browse files

#5657 Merge trial support

  • Loading branch information...
nlyan committed Oct 20, 2016
2 parents 984ca48 + 8688871 commit 7bae07d34ea37bb231173d30e801da8bf9d6e2d2
Showing with 1,200 additions and 1,076 deletions.
  1. +3 −0 .gitignore
  2. +2 −2 CMakeLists.txt
  3. +3 −3 src/cmd/synergyd/CMakeLists.txt
  4. +9 −6 src/gui/gui.pro
  5. +60 −76 src/gui/res/ActivationDialog.ui
  6. +1 −1 src/gui/res/CancelActivationDialog.ui
  7. +52 −1 src/gui/res/MainWindowBase.ui
  8. +1 −1 src/gui/res/ServerConfigDialogBase.ui
  9. +66 −113 src/gui/src/ActivationDialog.cpp
  10. +7 −8 src/gui/src/ActivationDialog.h
  11. +14 −26 src/gui/src/AppConfig.cpp
  12. +9 −12 src/gui/src/AppConfig.h
  13. +11 −22 src/gui/src/CoreInterface.cpp
  14. +1 −4 src/gui/src/CoreInterface.h
  15. +138 −0 src/gui/src/LicenseManager.cpp
  16. +24 −18 src/gui/src/{SubscriptionManager.h → LicenseManager.h}
  17. +150 −42 src/gui/src/MainWindow.cpp
  18. +18 −7 src/gui/src/MainWindow.h
  19. +0 −16 src/gui/src/QUtility.cpp
  20. +0 −1 src/gui/src/QUtility.h
  21. +1 −1 src/gui/src/SettingsDialog.cpp
  22. +1 −1 src/gui/src/SetupWizard.cpp
  23. +0 −167 src/gui/src/SubscriptionManager.cpp
  24. +8 −5 src/gui/src/main.cpp
  25. +1 −1 src/lib/CMakeLists.txt
  26. +2 −0 src/lib/server/CMakeLists.txt
  27. +31 −22 src/lib/server/Server.cpp
  28. +3 −2 src/lib/server/Server.h
  29. +32 −0 src/lib/shared/CMakeLists.txt
  30. +5 −5 src/{gui/src → lib/shared}/EditionType.h
  31. +264 −0 src/lib/shared/SerialKey.cpp
  32. +84 −0 src/lib/shared/SerialKey.h
  33. +14 −35 src/lib/synergy/ArgParser.cpp
  34. +1 −1 src/lib/synergy/ServerApp.cpp
  35. +1 −0 src/lib/synergy/ServerArgs.cpp
  36. +4 −2 src/lib/synergy/ServerArgs.h
  37. +0 −30 src/lib/synergy/SubscriptionKey.h
  38. +0 −199 src/lib/synergy/SubscriptionManager.cpp
  39. +0 −55 src/lib/synergy/SubscriptionManager.h
  40. +0 −42 src/lib/synergy/ToolApp.cpp
  41. +0 −1 src/lib/synergy/ToolApp.h
  42. +1 −6 src/lib/synergy/ToolArgs.cpp
  43. +0 −5 src/lib/synergy/ToolArgs.h
  44. +28 −20 src/test/integtests/net/NetworkTests.cpp
  45. +1 −1 src/test/unittests/CMakeLists.txt
  46. +147 −0 src/test/unittests/shared/SerialKeyTests.cpp
  47. +2 −2 src/test/unittests/synergy/ServerArgsParsingTests.cpp
  48. +0 −114 src/test/unittests/synergy/SubscriptionTests.cpp
View
@@ -1,7 +1,10 @@
config.h
+.DS_Store
*.pyc
+*.o
*~
\.*.swp
+*build-gui-Desktop_Qt*
/bin
/lib
/build
View
@@ -17,8 +17,8 @@
# Version number for Synergy
set(VERSION_MAJOR 1)
set(VERSION_MINOR 8)
-set(VERSION_REV 4)
-set(VERSION_STAGE stable)
+set(VERSION_REV 5)
+set(VERSION_STAGE rc1)
set(VERSION "${VERSION_MAJOR}.${VERSION_MINOR}.${VERSION_REV}")
cmake_minimum_required(VERSION 2.6)
@@ -1,11 +1,11 @@
# 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
@@ -35,7 +35,7 @@ else()
endif()
target_link_libraries(synergyd
- arch base common io ipc mt net platform synergy ${libs} ${OPENSSL_LIBS})
+ arch base common io ipc mt net platform synergy shared ${libs} ${OPENSSL_LIBS})
if (WIN32)
ADD_CUSTOM_COMMAND(
View
@@ -7,7 +7,8 @@ DEFINES += VERSION_REVISION=\\\"$$QMAKE_VERSION_REVISION\\\"
DEPENDPATH += . \
res
INCLUDEPATH += . \
- src
+ src \
+ ../lib/shared/
FORMS += res/MainWindowBase.ui \
res/AboutDialogBase.ui \
res/ServerConfigDialogBase.ui \
@@ -60,11 +61,12 @@ SOURCES += src/main.cpp \
src/Fingerprint.cpp \
src/SslCertificate.cpp \
src/WebClient.cpp \
- src/SubscriptionManager.cpp \
src/ActivationNotifier.cpp \
src/ActivationDialog.cpp \
src/CancelActivationDialog.cpp \
- src/FailedLoginDialog.cpp
+ src/FailedLoginDialog.cpp \
+ ../lib/shared/SerialKey.cpp \
+ src/LicenseManager.cpp
HEADERS += src/MainWindow.h \
src/AboutDialog.h \
src/ServerConfig.h \
@@ -101,18 +103,19 @@ HEADERS += src/MainWindow.h \
src/DataDownloader.h \
src/AddClientDialog.h \
src/CommandProcess.h \
- src/EditionType.h \
src/ProcessorArch.h \
src/CoreInterface.h \
src/Fingerprint.h \
src/SslCertificate.h \
src/WebClient.h \
- src/SubscriptionManager.h \
src/ActivationNotifier.h \
src/ElevateMode.h \
src/ActivationDialog.h \
src/CancelActivationDialog.h \
- src/FailedLoginDialog.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 {
@@ -6,100 +6,31 @@
<rect>
<x>0</x>
<y>0</y>
- <width>440</width>
- <height>314</height>
+ <width>410</width>
+ <height>211</height>
</rect>
</property>
<property name="windowTitle">
<string>Activate Synergy</string>
</property>
<layout class="QVBoxLayout" name="verticalLayout">
<item>
- <widget class="QRadioButton" name="m_pRadioButtonActivate">
+ <widget class="QLabel" name="label">
<property name="font">
<font>
<weight>75</weight>
<bold>true</bold>
</font>
</property>
<property name="text">
- <string>&amp;Account login</string>
- </property>
- <property name="checked">
- <bool>true</bool>
- </property>
- </widget>
- </item>
- <item>
- <layout class="QFormLayout" name="formLayout_2">
- <property name="fieldGrowthPolicy">
- <enum>QFormLayout::AllNonFixedFieldsGrow</enum>
- </property>
- <property name="horizontalSpacing">
- <number>20</number>
- </property>
- <property name="verticalSpacing">
- <number>10</number>
- </property>
- <item row="0" column="0">
- <widget class="QLabel" name="m_pLabelEmail">
- <property name="text">
- <string>Email:</string>
- </property>
- </widget>
- </item>
- <item row="0" column="1">
- <widget class="QLineEdit" name="m_pLineEditEmail">
- <property name="sizePolicy">
- <sizepolicy hsizetype="Expanding" vsizetype="Fixed">
- <horstretch>0</horstretch>
- <verstretch>0</verstretch>
- </sizepolicy>
- </property>
- <property name="echoMode">
- <enum>QLineEdit::Normal</enum>
- </property>
- </widget>
- </item>
- <item row="1" column="0">
- <widget class="QLabel" name="label_3">
- <property name="text">
- <string>Password:</string>
- </property>
- </widget>
- </item>
- <item row="1" column="1">
- <widget class="QLineEdit" name="m_pLineEditPassword">
- <property name="sizePolicy">
- <sizepolicy hsizetype="Expanding" vsizetype="Fixed">
- <horstretch>0</horstretch>
- <verstretch>0</verstretch>
- </sizepolicy>
- </property>
- <property name="echoMode">
- <enum>QLineEdit::Password</enum>
- </property>
- </widget>
- </item>
- </layout>
- </item>
- <item>
- <widget class="QRadioButton" name="m_pRadioButtonSubscription">
- <property name="font">
- <font>
- <weight>75</weight>
- <bold>true</bold>
- </font>
- </property>
- <property name="text">
- <string>&amp;Serial key</string>
+ <string>Serial key</string>
</property>
</widget>
</item>
<item>
<widget class="QLabel" name="label_5">
<property name="text">
- <string>Found on your &lt;a href=&quot;https://symless.com/account/?source=gui&quot;&gt;account&lt;/a&gt; page.</string>
+ <string>&lt;html&gt;&lt;head/&gt;&lt;body&gt;&lt;p&gt;This can be found on your &lt;a href=&quot;https://symless.com/account/?source=gui&quot;&gt;&lt;span style=&quot; text-decoration: underline; color:#0000ff;&quot;&gt;account&lt;/span&gt;&lt;/a&gt; page.&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;</string>
</property>
<property name="openExternalLinks">
<bool>true</bool>
@@ -109,7 +40,7 @@
<item>
<widget class="QTextEdit" name="m_pTextEditSerialKey">
<property name="enabled">
- <bool>false</bool>
+ <bool>true</bool>
</property>
<property name="html">
<string>&lt;!DOCTYPE HTML PUBLIC &quot;-//W3C//DTD HTML 4.0//EN&quot; &quot;http://www.w3.org/TR/REC-html40/strict.dtd&quot;&gt;
@@ -123,6 +54,57 @@ p, li { white-space: pre-wrap; }
</property>
</widget>
</item>
+ <item>
+ <widget class="QWidget" name="m_trialWidget" native="true">
+ <layout class="QHBoxLayout" name="horizontalLayout_5">
+ <property name="leftMargin">
+ <number>2</number>
+ </property>
+ <property name="topMargin">
+ <number>0</number>
+ </property>
+ <property name="rightMargin">
+ <number>0</number>
+ </property>
+ <property name="bottomMargin">
+ <number>8</number>
+ </property>
+ <item>
+ <widget class="QLabel" name="label_3">
+ <property name="text">
+ <string/>
+ </property>
+ <property name="pixmap">
+ <pixmap resource="Synergy.qrc">:/res/icons/16x16/money.png</pixmap>
+ </property>
+ </widget>
+ </item>
+ <item>
+ <widget class="QLabel" name="m_trialLabel">
+ <property name="text">
+ <string>&lt;html&gt;&lt;head/&gt;&lt;body&gt;&lt;p&gt;Your trial has expired. &lt;a href=&quot;http://symless.com/pricing?src=gui&quot;&gt;&lt;span style=&quot; text-decoration: underline; color:#0000ff;&quot;&gt;Buy now!&lt;/span&gt;&lt;/a&gt;&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;</string>
+ </property>
+ <property name="openExternalLinks">
+ <bool>true</bool>
+ </property>
+ </widget>
+ </item>
+ <item>
+ <spacer name="horizontalSpacer">
+ <property name="orientation">
+ <enum>Qt::Horizontal</enum>
+ </property>
+ <property name="sizeHint" stdset="0">
+ <size>
+ <width>40</width>
+ <height>20</height>
+ </size>
+ </property>
+ </spacer>
+ </item>
+ </layout>
+ </widget>
+ </item>
<item>
<widget class="QDialogButtonBox" name="buttonBox">
<property name="orientation">
@@ -135,7 +117,9 @@ p, li { white-space: pre-wrap; }
</item>
</layout>
</widget>
- <resources/>
+ <resources>
+ <include location="Synergy.qrc"/>
+ </resources>
<connections>
<connection>
<sender>buttonBox</sender>
@@ -19,7 +19,7 @@
<property name="text">
<string>Are you sure?
-If you don't activate Synergy you'll be missing out on some great features</string>
+If you don't activate Synergy you'll be missing out on some great features.</string>
</property>
<property name="wordWrap">
<bool>true</bool>
@@ -27,6 +27,57 @@
</property>
<widget class="QWidget" name="centralwidget">
<layout class="QVBoxLayout" name="verticalLayout_2">
+ <item>
+ <widget class="QWidget" name="m_trialWidget" native="true">
+ <layout class="QHBoxLayout" name="horizontalLayout_5">
+ <property name="leftMargin">
+ <number>2</number>
+ </property>
+ <property name="topMargin">
+ <number>0</number>
+ </property>
+ <property name="rightMargin">
+ <number>0</number>
+ </property>
+ <property name="bottomMargin">
+ <number>8</number>
+ </property>
+ <item>
+ <widget class="QLabel" name="label_3">
+ <property name="text">
+ <string/>
+ </property>
+ <property name="pixmap">
+ <pixmap resource="Synergy.qrc">:/res/icons/16x16/warning.png</pixmap>
+ </property>
+ </widget>
+ </item>
+ <item>
+ <widget class="QLabel" name="m_trialLabel">
+ <property name="text">
+ <string>&lt;html&gt;&lt;head/&gt;&lt;body&gt;&lt;p&gt;&lt;span style=&quot; font-weight:600;&quot;&gt;%1&lt;/span&gt; days of your Synergy Pro trial remain. &lt;a href=&quot;http://symless.com/pricing?src=gui&quot;&gt;&lt;span style=&quot; text-decoration: underline; color:#0000ff;&quot;&gt;Buy now!&lt;/span&gt;&lt;/a&gt;&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;</string>
+ </property>
+ <property name="openExternalLinks">
+ <bool>true</bool>
+ </property>
+ </widget>
+ </item>
+ <item>
+ <spacer name="horizontalSpacer">
+ <property name="orientation">
+ <enum>Qt::Horizontal</enum>
+ </property>
+ <property name="sizeHint" stdset="0">
+ <size>
+ <width>40</width>
+ <height>20</height>
+ </size>
+ </property>
+ </spacer>
+ </item>
+ </layout>
+ </widget>
+ </item>
<item>
<widget class="QWidget" name="m_pWidgetUpdate" native="true">
<layout class="QHBoxLayout" name="horizontalLayout_2">
@@ -40,7 +91,7 @@
<number>0</number>
</property>
<property name="bottomMargin">
- <number>7</number>
+ <number>8</number>
</property>
<item>
<widget class="QLabel" name="m_pIconUpdate">
@@ -17,7 +17,7 @@
<item>
<widget class="QTabWidget" name="m_pTabWidget">
<property name="currentIndex">
- <number>2</number>
+ <number>0</number>
</property>
<widget class="QWidget" name="m_pTabScreens">
<attribute name="title">
Oops, something went wrong.

0 comments on commit 7bae07d

Please sign in to comment.