summaryrefslogtreecommitdiffstats
AgeCommit message (Collapse)Author
2018-02-27Fix a crash that occurs with closed chat tabs after resizing trellisThanos Doukoudakis
This patch address an issue where, after resizing trellis in a smaller grid size, all closed tabs widgets (ChatWindows, Debug Console etc) that were in a grid cell that got removed, were being destroyed leading to some crashes whenever the widget was used again. Test-Information: Tested the changes in windows with Qt 5.8 and Ubuntu 17.10 with Qt 5.9.1. Tested the client behaviour when opening, closing and re-opening multiple tabs (chat windows, debug console, File transfer overview), before and after resizing the trellis. Change-Id: I923299fe90aa39737d6a3e0ace107018f126880e
2018-02-13Start Chat options greyed out after first useThanos Doukoudakis
This patch will reset the options to add users the default status, whenever the QtUserSearchWindow is reset. Test-Information: Tested the changes in Windows 10 (64 bit) with Qt 5.8.0, in a server environment that does not allow starting a new chat with more than one participant, after closing and reopening the window. Change-Id: Iff6dd75a5751e7e8871069387749b94b789320a9
2018-01-30Change the program name of the windows installerThanos Doukoudakis
During the UAC dialog in windows, the program name appears to have a random value. This patch will make it use "Swift Installer" instead. Test-Information: Tested the changes during installation and uninstallation on Windows 7 (64 bit) and Windows 10 (64 bit) Change-Id: I001ed9e644b123f62b9168115ce06803d2b4bd20
2018-01-18Return focus to highlight rules dialog after picking a colourThanos Doukoudakis
This patch fixes an issue where the Highlight and notification configuration window was losing focus after picking a colour for some of the highlight rules. Test-Information: Tested the changes and that the highlight rules dialog is no longer pushed back after picking a colour. Tested on MacOS (10.10.5) with Qt 5.5.1 and on Windows 10 with Qt 5.9. Change-Id: I509bb3f79e2f8e121dafe178e52a0aac5271ee1b
2017-12-07Remove shortcut for changing trellis layoutTobias Markmann
It is rarely used and conflicts with Polish keyboard layout on Windows. Test-Information: Verified that shortcut is gone and the description text is sensible on macOS 10.13.1 with Qt 5.4.2. Change-Id: I79ede2827e2e5f7b9afcb3bbd2669e5bf83f091f
2017-11-22Fix Emoji crash on insertionJoanna Hulboj
Swift would crash randomly when user clicked to insert an Emoji. It was happening because we would delete the emojisGrid_ while it was still in use (was closing). Test-Information: Tested on Windows 10 and Ubuntu 16.04. Tested by inserting an Emoji from the Emoji selector. This action does not result in crash any more. Change-Id: I6c0b84ea8969c7f7a4c3bfa700e345cdf63325e6
2017-11-09Fix loading translations when detected automaticallyTobias Markmann
Test-Information: Tested with Dutch and German user accounts on Mac OS X 10.10. Change-Id: I9c6d5fdac19abcf4db98034dbd6620732f0caba1
2017-11-07Add missing Qt translatable strings to QtStrings.hTobias Markmann
Strings in the context menu of the chat input and the dialog buttons in the highlight editor are now translatable. Test-Information: Tested on macOS 10.13.1 with Qt 5.4.2. Tested with a newer upcoming German translation file. Change-Id: Ie2c5ec1d9615bfe5ac69dad7df3c96a6f1600225
2017-11-07Enable translatability of QtSoundSelectionStyledItemDelegateTobias Markmann
This adds a missing Q_OBJECT macro. Test-Information: Build and tested on macOS 10.13.1 with Qt 5.4.2 that with `--language de` passed to Swift the German translations are shown in the highlighting editor. Change-Id: Ibe9975786f5a228fb14b61c01ce71db06354762b
2017-09-24Fix 'Start chat...' dialog disappearing after adding participantTobias Markmann
Qt deprecated Q_WS_* defines to detect the windowing system at compile time. Changed the code to use Q_OS_MAC to enable the workaround for macOS. Test-Information: Tested with Qt 5.4.2 and Qt 5.8.0 on macOS 10.12.6. Change-Id: I49953f084ad6003c08b02550741dc16ef5df21fe
2017-08-16Fix inverted logging assert conditionThanos Doukoudakis
This patch will fix a bug where SWIFT_LOG_ASSERT was logging the wrong information. Test-Information: Tested the logging assertion on Windows 10 (Qt 5.7) during the client exit. Change-Id: I7bffbe52a0b28c7577b1bad165313ea64a3f8e46
2017-08-15Force a build to stop if signing of the packages fails.Thanos Doukoudakis
This patch will make the build attempt to sign the package 3 times. If none of the attempts are successful, the build will stop and flag the error. Test-Information: Tested packaging on Windows 10 (Qt 5.7), when the package signing succeeds (signed installer package), fails (build stops) or not required (unsigned installer package). Change-Id: Idf1f708dda50e67e54866ca598cc5160e4ea76eb
2017-08-15Improve Swift’s interactions with Smart CardsThanos Doukoudakis
This patch improves logging and refactors SchannelContext and CAPICertificate classes, to improve logging and how Swift interacts with smart cards. Test-Information: Tested on Windows 10 (Qt 5.7) Change-Id: Ic4d306beafb9e5d253731769f222e6949995d5e7
2017-08-08Enable log information export to a fileThanos Doukoudakis
This patch introduces the “logfile” argument to the client, which can be used to specify a file path for a log file, where all logging information will be stored. Test-Information: Tested on windows 10 and Ubuntu 17.04 Change-Id: I6a2f14585a72f25e7e78d79cb633e1ddc4d43c3b
2017-07-18Replace assert() with SWIFT_LOG_ASSERT for loading fontsTobias Markmann
Test-Information: Builds on macOS 10.12.5 with Qt 5.4.2. Change-Id: Ifc49064c6a8ca2f0be52d8ddd8f0c7791230430f
2017-07-06Fix a crash that occurs when resizing chat layoutThanos Doukoudakis
This patch fixes a client crash that was caused when the chat layout was resized to a size that would make some of the chat window out of range. Test-Information: Tested on Ubuntu 16.04 LTS (Qt5.5.1) and Windows 10 (Qt5.7.1) Change-Id: I900c1efcf3c9ae3c416fb4e2d19bd47bf27bbaee
2017-06-26Use size_t instead of int in SpellParser::PositionPairTobias Markmann
Use of int required a lot of casts when using the indices with std::string methods. Furthermore code used -1 as error code, which should have used std::optional for invalid PoistionPair instnaces. Test-Information: All tests pass on Debian Stretch with clang-3.9. Change-Id: Ic5c44ed606deb58b6123d654f25fc50f047dfbc8
2017-06-26Fix compiler warnings raise by Clang on LinuxTobias Markmann
Clang raises warnings about unused members and macros on Linux. These are fixed with this change. Test-Information: Tested with clang-3.9 on Debian Stretch. Change-Id: I87bc0606cfd14365330aaad4ed433d3bca2d5330
2017-05-15Disconnect potentially connected slots from signals in dtorTobias Markmann
SWIFT-247 Test-Information: Tests pass and builds on macOS 10.12.4 with Qt 5.4.2. Change-Id: I39b62f53c62fba972e6a29e89cd00fb3b4e1a5b5
2017-05-15Use QPointer to prevent access to potentially freed QtTreeWidgetTobias Markmann
As the QtTreeWidget and the QtFilterWidget are siblings in their parent widget, it might happen that the QtTreeWidget is deleted before the QtFilterWidget. Using Pointer, we are able to detect this case and can prevent accessing the already deleted QtTreeWidget. QtFilterWidget cannot be made the child of the QtTreeWidget in this case, so this fix uses the QPointers approach as a workaround. SWIFT-247 Test-Information: Tests pass and builds on macOS 10.12.4 with Qt 5.4.2. Change-Id: I3a60006519b580010718c4d2aa94638555c0afdf
2017-05-15Unregister as event filter in QtFilterWidget dtorTobias Markmann
When QtFilterWidget is deleted, it is still registered as event filter and events might be sent to an already deleted QtFilterWidget, causing a crash. SWIFT-247 Test-Information: All unit tests pass, roster filtering still works, and Swift does not crash on exit on macOS 10.12.4 with Qt 5.4.2. Change-Id: I84a7e1af64d1376db3dfdd0fd7cf95b547cca9a1
2017-05-11Change the setting that specifies the font size.Thanos Doukoudakis
This fix changes and reset the setting that stores the font size. Test-Information Tested and verified the changes to Windows with Qt5.7 and Linux with Qt5.5 Change-Id: Ia71ba986e33e7f9421ef616c22d5b1af6e5c2b4a
2017-05-08Fix an issue when sending a file in a chatThanos Doukoudakis
When you drop a file in the chat input, the file path was being sent to the chat, instead of initialising a file transfer. This patch fixes this issue and starts the file transfer. Test-Information: Tested on Windows 10 with Qt5.7. Drag a file and drop in the chat input. Change-Id: Ie6c31e0ba56ac7171442370bf7d8edbefce208d6
2017-05-04Fix recent chat entries being incorrectly displayedJoanna Hulboj
Recent chat entries were displayed as a randomly generated numbers instead of impromptus (if invitees were offline). Title displayed in the Recent Chat List for MUC is now based on both the occupants and invitees. To do that a collection with all the invitees is being stored (new) along the occupants (existing). Test-Information: From Swift menu choose Actions, Start Chat... Add some offline contacts to the List of Participants and press Finish. Recent chat entry will have correct name (combined of contact names). Change-Id: Ie076165e8dbb493aa261cc49ca3ab1e0c1c542a8
2017-05-03Change the default font size in chat viewThanos Doukoudakis
This will make the default font size in chat view to match the one in roster. This fix also decreases the font scaling step to half, and lowers the minimum font scale. Test-Information: Tested and verified the changes to Windows with Qt5.7. Change-Id: If5873049af4e82fba871e5d2687575aa88b533c9
2017-04-20Add missing include for QFileDeviceTobias Markmann
Test-Information: Builds on macOS 10.12.4 with Qt 5.4.2. Change-Id: Id9715062e25c1d541020408a517e0974ce92c886
2017-04-18Don't pass the impromptu MUC 'reason' as the room JIDThanos Doukoudakis
Changing the constructor of the CreateImpromptuMUCUIEvent class not to accept default values to its parameters. This approach is less prone to mistakes, like forgetting an argument. This commit fixes SWIFT-271 bug, where only two arguments were being passed in the constructor. As a result the reason string was used to create a room JID, making the room unusable. By passing an empty string, the room JID created is not valid, and when ChatsManager handles the event, it will generate a new valid room JID. Test information: Unit test pass. Tested the creation of new impromptu chat with with windows 10 (qt5.7). Change-Id: I4ce9ee7db14b9125970a03f19d1ac0c32e1b5a0e
2017-04-12Assert first page in QtUserSearchWindow wizard based on typeTobias Markmann
Converted enum to C++11 enum class in process. Coverity raised this issue. Test-Information: All unit tests pass. Using the “Add Contact…” and “Start Chat…” dialogs did not crash. Tested on macOS 10.12.4 with Qt 5.4.2. Change-Id: I0409688b001d1eaaf5fa77a25b1158ce9e611c77
2017-04-10Only add existing environment variables to QtUI test envTobias Markmann
Furthermore extended the list of potential environment variables based on what the qt4.py tool creates. Fix for commit ed2226782ac15345aeb8e615b41d30e5aab67b51. Test-Information: Tested on Windows 8 with VS2013 with Qt 5.4.2 and on macOS 10.12.4 with Qt 5.5.1. Change-Id: Ib52084ca0e1505fe943c33fa74f479e360d834fe
2017-04-10Make the default chat view font to render thicker on WindowsThanos Doukoudakis
Added a font-weight property on the body style to enhance the default font weight (400) only on Windows, in order to improve the look of the chat view. If the font-weight is being defined in any other styles rules with higher priority, this default value will be overwritten. Test-Information: Tested with with windows 10 (qt5.4.2), Windows 10 (qt5.7), Ubuntu 16.04.2 (qt5.5) Change-Id: Iafd969cff487a907d136b9d2d8b393a90681216f
2017-04-07Do not grey out chat view after clearingJoanna Hulboj
Test-Information: Run Swift, open chat window, enter a message and send it. Right click on chat view and choose Clear. Chat log in a view will be cleared but it will stay white. On the top of the chat view will be a message: e.g. Starting chat with test - test@test.isode.net: Offline. Change-Id: Ie453602e2f2b14e3ecca699821521ad33937ccf6
2017-04-07Make day change chat system message DST awareTobias Markmann
Moved the code for day change message handling from Swift/Controllers to Swift/QtUI. Use QDateTime in local time time spec, which allows DST aware calculation of the duration to the next midnight. Added Swift Qt UI unit tests, which are build when Qt has been successfully detected. Test-Information: Added unit tests for duration to next midnight calculation. Set clock shortly before midnight and verified that a single day change message is added to the chat log at midnight. Tested on macOS 10.12.4 with Qt 5.4.2. Change-Id: I34d69eaa3272981fd220a7963a0417f73ff78e68
2017-04-04Change ‘User’ to ‘Nickname’ in highlight dialogTobias Markmann
Test-Information: Build on macOS 10.12.4 and verified the change in the UI. Change-Id: I8ec472158682e951fe358197c0939f451ade8c54
2017-04-04Open 1:1 chat to real JIDs from MUC rooms (not PMs) when possibleThanos Doukoudakis
Opens the chat with the user JID instead of the MUC JID. Does not affect existing behaviour on normal one2one chats. Test-Information: Builds on Windows and unit test pass. Tested the behaviour on single chats from contacts list (roster), start new chat with one and multiple users. Also tested on MUC rooms that are non-anonymous, semi-anonymous and anonymous. Change-Id: I2b8fbacb1fa640167ec196d4215a13ad4905d45c
2017-04-04Remove superfluous duplicated variable in QtDNDTabBar codeTobias Markmann
Coverity raised this issue. Test-Information: Swift and unit tests still build on macOS 10.12.4. Drag and drop of tabs still work. Change-Id: I64bdb973da73a4f2b5ed514583c4f8740adc77b4
2017-04-04Test against dialog type instead of nullptr in QtUserSearchWindowTobias Markmann
If the dialog is not of type AddContact, firstMultiJIDPage_ is initialised and this states more clearly that the reset is only done when the dialog is in this mode. Coverity raised this issue. Test-Information: Added a user from search and started a chat from user search. All unit tests pass on macOS 10.12.4. Change-Id: I55f6df5b4f48e2c6718922846a424bf17f363b16
2017-03-31Handle potential boost::bad_any_cast exceptionTobias Markmann
Coverity raised this issue. Test-Information: Builds and unit tests pass on macOS 10.12.4. Switching different application languages via --language parameter still works and passing numbers as languages has it correctly fallback to the default system language. Change-Id: Ide1ffdba7a13c27856304aa96b78067147568a95
2017-03-30Fix access to potential unavailable page in QtUserSearchWindowTobias Markmann
Adding searched JIDs to the list of JIDs only makes sense for cases where there is a multi JID page in the first place. Coverity raised this issue. Test-Information: All unit tests pass on macOS 10.12.4 and the “Add Contact” and “Start Chat” dialogs using a user search still work. Change-Id: Icde63f13a2f83690b3189a9c91237eadd6b5218b
2017-03-29Initialise timerId member in QtGridSelectionDialogTobias Markmann
Coverity raised this issue. Test-Information: All unit tests passed on macOS 10.12.4. Change-Id: Id65cdc5e0175ba7773d32b6dddbc9b4af6789019
2017-03-15Add link to https://swift.im/ to about dialogTobias Markmann
In addition, fix display of Swift icon in about dialog. Test-Information: Build on macOS 10.12.3 with Qt 5.4.2 and verified that the icon is display in the about dialog and clicking the link opens the Swift website in the default browser. Change-Id: If13e03bfa976354aeba1de9be4bcb1edabaa5403
2017-03-14Show correct avatars for file-transfer messagesTobias Markmann
Previously we simply showed our default avatar. With this change we will use the same avatar as we use for normal chat messages. Test-Information: Tested on macOS 10.12.3 with Qt 5.5.1 by exchanging files between two Swift instances. Change-Id: I20b953a67a290820900b5b35861c1e17f72148bd
2017-03-14Fix incorrect default chat view font sizeTobias Markmann
A chat font size value of 2 represents the native default font size on the system, which should be the default font size for the chat view on first install. We allow this to be reduced to 0 and increased without a limit. Furthermore the settings key was changed so that Swift 3 users will automatically use the default size when they first open a newer Swift. Test-Information: Tested on Ubuntu 16.04.02 after clearing the local Swift config. Change-Id: I3426001eb302e22134c40bc4a479f15684ca2001
2017-03-14Fix default avatar rendering on WindowsTobias Markmann
Swift installed from our Windows installer packages would not display the default avatar, due to missing Qt5Svg module. Test-Information: Build Windows installer package on Windows 8, with VS 2013 and Qt 5.4.2. Qt5Svg.dll is installed and default avatars are displayed in the roster. Change-Id: Iaa0fb0b013fc32d9d84897e83902ae7487fe72d7
2017-03-07Use text-based emoticons on Linux and WindowsTobias Markmann
The new unicode-based emoji dialog currently only provides a good experience on macOS. This commit enables the unicode-based emoji dialog on macOS and uses the text-based emoticons on Linux and Windows. Test-Information: Tested on macOS 10.12.3 with Qt 5.5.1 and Windows 8 with Qt 5.5.1. Change-Id: Ibee20eacafa5788bcdf5a46e1ceac713a28a0383
2017-03-07Do not color highlight mentions of the own nickname by defaultTobias Markmann
In the default highlight configuration, mentions of the own nickname should only cause a notification sound and a system notification. Test-Information: Tested mention notifications in a test MUC room and verified that only sound and system notifications are issued in the default highlight configurations. Tested on macOS 10.12.3 with Qt 5.5.1. Change-Id: I44a276ab740d7495930c935a89a2ef81219e24df
2017-03-06Fix emoji dialog crash when there are no recent emojisTobias Markmann
The dialog would crash if the user has not selected an emoji ever before through the dialog. Test-Information: Cleared recent list and opened the dialog. Without this patch it would crash, since there are no items in the emojiLayout. Now it does not crash anymore, on macOS 10.12.3 with Qt 5.5.1. Change-Id: Ie736b5af7fe8b2b2c14fcac94b7e4f3bc13f4b84
2017-03-03Allow pasting a newline separated list of JIDs in blocking dialogTobias Markmann
Furthermore the dialog will alphabetically sort the list of blocked JIDs before showing it in the dialog. Test-Information: Tested on macOS 10.12.3 with Qt 5.7.1 that it sorts the list it receives from the server before presenting it in the UI. Successfully pasted a newline spereated list of JIDs in the dialog. Change-Id: I8fe6969821bccad0193180cee9433da43285aaef
2017-03-03Change Enter Room... QWidget to QDialogJoanna Hulboj
Test-Information: Tested under Linux i3 tiling windows manager. Run Swift, from the menu choose Actions, Enter Room... Enter Room... dialog is displayed as a floating window in a tiling manager. Change-Id: I31dc4f8caa04fe137e89f2bcb12852cd0b709bab
2017-03-01Remove support for selecting custom notification soundsTobias Markmann
Test-Information: Tested on macOS 10.12.3 with Qt 5.7.1 that the custom sound menu item was gone. Change-Id: I75186d1a3b74db751fbdd5aaf54402f23f74661b
2017-02-28Do not reset font size when clearing chat viewJoanna Hulboj
Test-Information: From Swift open any chat window, type something, right click on chat view and increase font size 3 times, then right click on chat view and choose Clear. Chat log in a view will be cleared, again type something the form size stays the same as before clearing the log view. Change-Id: I8c057dbd4ed52e5d1efce7064d79b9f7244b3d32