summaryrefslogtreecommitdiffstats
AgeCommit message (Collapse)Author
2016-05-26Fix MUC invitation request being overwritten by presence changeTobias Markmann
After an initial presence change, when a client received a MUC invite, a potential following offline presence could replace the previous MUC invite request in the chat view. This commit fixes the issue. Test-Information: Added unit test verifying the new behavior. Verified absence of described bug in Swift GUI. All tests pass on OS X 10.11.5. Change-Id: I8fd9c7ad3f5f5009f48fc3d86017cd94e1998f01
2016-05-26Bring existing dialog to front on open of "Start Chat…" dialogTobias Markmann
Test-Information: Tested on OS X 10.11.5 with Qt 5.4.2. Change-Id: Ic751fec01cfe6417bb5db17364f5eb69a2037895
2016-05-26Add minidump analysis python script for Windows crash dumpsTobias Markmann
This script takes a Swift version and minidump file path as arguments and will checkout the corresponding source, fetch and extract the corresponding installer, fetch and extract the corresponding debug symbols to finally run the Windows SDK command line debugger (cdb) to write a human readable stack trace and further info to a txt file. Test-Information: Tested it successfully on Windows 10 with various minidumps. Change-Id: I5915255dfb23e6b45c1273a3c1c42cc83125df57
2016-05-26Fix setting recent search server when doing a local user searchTobias Markmann
Test-Information: Builds on OS X 10.11.5. Tested that the recent search server field in the 'Start Chat…" dialog is not set, if you search locally. Searching on remote servers still adds the server to the recent search server list. Change-Id: I62e21339b055ec826f450b8bfb2c662d1df5e84b
2016-05-25Remove unnecessary include of iostream headerTobias Markmann
Move std::cout/cerr logging to SWIFT_LOG. Test-Information: Builds and all tests pass on OS X 10.11.5. Change-Id: I0a0c24654a8b3abf3244a79fd6d970eee90559d0
2016-05-04Fix /me message handling for highlighted messagesTobias Markmann
Test-Information: Added a unit test to test for the fix. Tests pass on OS X 10.11.4. Change-Id: Ibf071ae47663bfefdc856339932de6a1fe4a642d
2016-04-29Improve README.md quick start section and parallel build textTobias Markmann
Test-Information: None. Change-Id: I7725ec51a943fe298d25d0498e08f448f8b490fb
2016-04-29Restructure and reword project documentationTobias Markmann
Restructured project documentation into two basically two files at the top level. README.md giving a rough project overview and information and providing all information needed to build Swift, its requirements and where to get them for all desktop platforms. DEVELOPMENT.md is targeted at developers, describing the build system, how to build only parts of the project. This document also described how to build Swiften on Android and iOS, and also covers testing and packaging guidelines. Test-Information: None. Change-Id: Ic47bef6524888db972332b23e6510d10234f7808
2016-04-28Change remaining std::auto_ptr usage to std::unique_ptrTobias Markmann
Test-Information: Builds and tests pass on Ubuntu 16.04. Change-Id: If8da50619b0e029437b3b9d6b146f2ed49b5bf60
2016-04-26Fix scons2ninja.py due to recent change in RCC usageTobias Markmann
Test-Information: Successfully ran ./BuildTools/scons2ninja.py and ninja on OS X 10.11.4. Change-Id: I725182a0628dec7e9237e802e009da0f6b4a50c2
2016-04-26Make remaining UI strings in QtHighlightEditor translatableTobias Markmann
Test-Information: Builds on OS X 10.11.4 with Qt 5.4.2 and the short description still shows the strings in the UI. Checked that update_translations=1 shows the newly translatable strings. Change-Id: I7acc1058fbb07a5f1ed630c5cc95493f2bc79770
2016-04-25Convert hard tabs to four spaces in all our SConscript/*.py filesTobias Markmann
Test-Information: Test that it still builds and unit test pass on OS X 10.11.4. Change-Id: I2eb4a0b707991aee553db36a8cd1ae28b813acab
2016-04-25Add Lato font and use it in chat view themeTobias Markmann
The font has been imported from the TTF version available from http://www.latofonts.com/lato-free-fonts/ . This commit also adds default parameters to all Qt resource compiler calls, so that files that compress by more than 5% are compressed with the highest compression level. Ideally this will lead to smaller resource C++ source code files that will require less runtime memory when compiled. VS's cl.exe is particular resource hungry. Test-Information: Started Swift and verified the new font is used correctly in chat views. Change-Id: I0b450819b0f50041e768deca6e0ef5619b45d7bf
2016-04-25Fix detection of vertical scroll bar position in chat viewsTobias Markmann
Chat views are expected to remember the scroll position. If the user scrolled all the way down, the view should keep scrolled all the way down, even if the windows is resized, new messages are added or the user enters a multi line message in the message input box. Qt WebKit only provides reliable scroll position updates in their web environment. This requires to have scroll changes call a JS hook that calls our C++ signal. Test-Information: Tested and verified the following cases for correct behavior: * entering a multi line message keeping the view scrolled down * resizing the window and keeping it scrolled down * receiving messages and the view keeps being scrolled down * verified that view does not scroll down if it is not yet on resize of the window, entering multi line messages, and receiving new messages Change-Id: I579a07d0b073c34e7a46b0fde1bc09f3da08d5da
2016-04-25Update 3rdParty lcov to version 1.12Tobias Markmann
The old version caused errors when running BuildTools/Coverage/GenerateCoverageResults.sh. Test-Information: Successfully ran BuildTools/Coverage/GenerateCoverageResults.sh on OS X 10.11.4. Change-Id: If6f53a85e8051388c6d5b17d980f0c3fa8e65b6e
2016-04-25Require a configured TLS backend to buildTobias Markmann
Converted relevant SCons files from hard tabs to space based indentation with 4 spaces width. Test-Information: Tested that build failed with misconfigured OpenSSL backend (providing tls_backend=openssl on OS X and no information on where to find it). Tested that build succeeds on OS X 10.11.4. Change-Id: I17f85ca3194f100f63361a8c94667d7aa76e811a
2016-04-22Increase top margin on follow up messagesTobias Markmann
This is needed because our warning icon is larger than the success check mark icon. Without it the swatch of the follow up messages is inside the message area. Test-Information: Tested on OS X 10.11.4. Change-Id: I4d0b0c62ba1101ee2f2114311696c939249bab7f
2016-04-22Mark file-transfer notice as read when chat window is activatedTobias Markmann
Applied some foreach modernization in process. Test-Information: Tested by sending files between two Swift instances and verifying the new behavior works as expected. Tested on OS X 10.11.4 with Qt 5.4.2. Change-Id: Ie3f9c2126d946d9041b08be98a19cbfb468871f3
2016-04-14Fix delayed login/roster resize on window resize in netbook modeTobias Markmann
If you resize the window in netbook mode, the splitter inside only resizes to the new geometry if it is clicked or moved. This is due to overriding resizeEvent hook of QSplitter in QtSingleWindow but not notifying QSplitter's resizeEvent hook in the new method. Test-Information: Tested on OS X 10.11.4 with Qt 5.4.2. Opened Swift in netbook mode and resize the window. The login screen is resized as the window is resized. The login screen used to only resize if you moved the splitter. Change-Id: I7715e1cdcb4c0e672e233a9f76fad3ef5fe70d25
2016-04-14Set QT_SELECT environment variable during scons buildTobias Markmann
This enables building on Gentoo. Test-Information: A user successfully built with this patch and both Qt4 and Qt5 installed. Change-Id: I81ada408d34208bbba22d30de5f4ecd0060e223f
2016-04-14Fix bug of /me commands not being shown as actionsTobias Markmann
Test-Information: Added a test case that verifies this behavior. This test case succeeded before the refactoring in 74e5131 and now succeeds again. Tested Swift UI 1-to-1 and MUC messages with /me commands. Tested on OS X 10.11.4 with open-source clang. Change-Id: I270a0b4e2ddc595919646bddcc5e1f27074c9e1f
2016-04-12Use C++11 threading library instead of Boost.ThreadTobias Markmann
This cuts down our dependency on Boost further. Another benefit is that mutex classes of C++11 standard library are recognized by TSAN. Test-Information: Unit and integration tests pass on OS X 10.11.4. Change-Id: Id4dcdb42e3d5155e107ce1d7618acbf26f913b6f
2016-04-11Drop executable permission on source filesMichael Vetter
Drop executable rights on Swiften/Network/UnboundDomainNameResolver.* License: This patch is BSD-licensed, see Documentation/Licenses/BSD-simplified.txt for details. Change-Id: Ie6e6eab48b96dff64e82e76615c51863baf37816
2016-04-11Add missing dependency to InstallSwiftDependenciesMichael Vetter
On openSUSE python-xml is needed for scons during build time. License: This patch is BSD-licensed, see Documentation/Licenses/BSD-simplified.txt for details. Change-Id: Ie93221df781b142b4c9b07e5b7ad716bd9185341
2016-04-08Fix code in response to compiler warnings by clangTobias Markmann
Test-Information: Builds on OS X 10.11.4 with Apple clang and clang master. Change-Id: I012577e29c6fcf2fb452b4f13912aaeb37250fb5
2016-04-07Increase unread marker height to not overlap with messagesTobias Markmann
Test-Information: Tested unread marker with very narrow chat views. The unread marker label does not overlap with the message. Change-Id: I531c47bc440ad6b8a45ac9c679f736d695207b0f
2016-04-07Fix building with system boost on Debian 8.4Tobias Markmann
The signals library is still called signals and not signals2. Test-Information: Builds and unit tests pass on Debian 8.4 with system GCC. Change-Id: I1d1b3f6bade979bc8a181915176b84be0ddf6597
2016-04-06Fix include case typoTobias Markmann
Test-Information: Builds on Debian 8.4 and unit tests pass. Change-Id: I154f70606de33b57c8dd4a5d9431a14f537ad50f
2016-04-06Move ack indicator position and reduce height of followup messagesTobias Markmann
This patch moves the message receipt/ack indicator into the colored swatch right of the avatar. This allows followup messages to be reduced in their height so they consume less space. Test-Information: Tested 1-to-1 and MUC chats that the patch works as expected. Change-Id: I8bb3ccdc36338b1c1f4361b323ca09ffac30336a
2016-04-06Break long words (e.g. URLs) in chat view to prevent overflowsTobias Markmann
This prevents a horizontal scroll bar as long as there is space for the message block. If it is resized to a size that only allows horizontal space for the dark side block, then there will still be a horizontal scroll bar. Test-Information: Tested in various chat rooms by resizing the splitter between chat view and occupant list. Change-Id: Ibdf6a9554adcbd7580cb9b40eaffff6279a184b0
2016-04-06Add distcc support to our SCons scriptTobias Markmann
Just pass distcc=1 and set cxx=distcc clang++ and cc=distcc clang and use an appropriate parallelization argument (-j). Converted hard tabs to spaces in the process. Test-Information: Used distcc with -j 10 to build the whole Swift project with unit tests in 13 minutes across 2 hosts. Change-Id: Ib6b63b5079872632a11c0fd28eb90b8901b956df
2016-04-05Migrate to Boost.Signals2 from Boost.SignalsTobias Markmann
Boost.Signals was deprecated and is not improved further. This patch removes Boost.Signals from 3rdParty and adds Boost.Signals2 and its dependencies. Also removed the Qt signals compatibility file Swiften/Base/boost_bsignals.h. Test-Information: Build and ran unit tests on OS X 10.11.4. Confirmed successful login using Swift client. Change-Id: Ie6e3b2d15aac2462cda95401582f5287a479fb54
2016-04-04Modernize code to use range based for loops using clang-tidyTobias Markmann
Run 'clang-tidy -fix -checks=modernize-loop-convert' on all source code files on OS X. This does not modernize platform specific code on Linux and Windows Test-Information: Code builds and unit tests pass on OS X 10.11.4. Change-Id: I65b99e0978cfab8ca6de2a3e5342e7a81416c12c
2016-04-04Apply automated clang-tidy fixes and add missing includesTobias Markmann
Test-Information: Builds on OS X 10.11.4 and unit tests pass. Change-Id: I8775e8d1e3addbc88b220c1cc618637f706daca2
2016-04-04Modernize code to use C++11 shared_ptr instead of Boost'sTobias Markmann
This change was done by applying the following 'gsed' replacement calls to all source files: 's/\#include <boost\/shared_ptr\.hpp>/\#include <memory>/g' 's/\#include <boost\/enable_shared_from_this\.hpp>/\#include <memory>/g' 's/\#include <boost\/smart_ptr\/make_shared\.hpp>/\#include <memory>/g' 's/\#include <boost\/make_shared\.hpp>/\#include <memory>/g' 's/\#include <boost\/weak_ptr\.hpp>/\#include <memory>/g' 's/boost::make_shared/std::make_shared/g' 's/boost::dynamic_pointer_cast/std::dynamic_pointer_cast/g' 's/boost::shared_ptr/std::shared_ptr/g' 's/boost::weak_ptr/std::weak_ptr/g' 's/boost::enable_shared_from_this/std::enable_shared_from_this/g' The remaining issues have been fixed manually. Test-Information: Code builds on OS X 10.11.4 and unit tests pass. Change-Id: Ia7ae34eab869fb9ad6387a1348426b71ae4acd5f
2016-04-01Modernize code to use C++11 nullptr using clang-tidyTobias Markmann
Run 'clang-tidy -fix -checks=modernize-use-nullptr' on all source code files on OS X. This does not modernize platform specific code on Linux and Windows Test-Information: Code builds and unit tests pass on OS X 10.11.4. Change-Id: Ic43ffeb1b76c1a933a55af03db3c54977f5f60dd
2016-04-01Specifically handle Slimber/Limber in FixIncludes.pyTobias Markmann
Additionally improve handling of the corresponding header. Test-Information: This version of FixIncludes has been used in the recent include fixing of all source files in the repository. Change-Id: I70c8ef0a51d8e1a3b458fbd6f886c7d5b5259949
2016-03-31Convert tabs to 4 spaces for all source filesTobias Markmann
Removed trailing spaces and whitespace on empty lines in the process. Changed CheckTabs.py tool to disallow hard tabs in source files. Test-Information: Manually checked 30 random files that the conversion worked as expected. Change-Id: I874f99d617bd3d2bb55f02d58f22f58f9b094480
2016-03-31Stop building some TLS providers as always staticKevin Smith
Thanks to Manfred Urban for reporting that dynamic libraries weren't working. Test-Information: Swiften Builds on OS X with swiften_dll=True Change-Id: I31e40ac118b9be6b43803a2bbcbfef3a9f9f9d21
2016-03-30Apply consistent #include grouping and sorting styleTobias Markmann
Changed "" style includes to <> style. Test-Information: Build with Clang 3.9.0 and ran all tests on OS X 10.11.4. Change-Id: Ic05e53f2e5dba39cc1307b116fc5f17b62ab9eb8
2016-03-29Refactored keyword highlightingTobias Markmann
This commit changes the ChatWindow/ChatView APIs to not pass highlights actions as additional parameters but instead they are now part of the ChatWindow::ChatMessage and its parts. This allows the controllers to do highlighting in one single place and play sound actions on the highlighted message in a single place. On a highlighted message only unique sounds are played and they are played in sequence of the rules that matched the message. Test-Information: Adjusted the existing unit tests accordingly. Added unit tests that check reduplication of highlight action sounds and that the sound actions are emitted correctly. Manually verified that highlight sound actions with and without duplicated sounds are audible on OS X 10.11.3. Change-Id: I68c88e0d285d79d87b2997ed29d92b140480b394
2016-03-29Replace chat view theme with one based on the new designTobias Markmann
This also removes the old chat theme resources and some code in QtWebKitChatView that was required for compatibility to Adium-style themes. The new code uses a CSS style in the header to change the font size and does not iterate the whole DOM tree itself anymore. Added new resources for failed and successful asks. Test-Information: Tested MUCs, PMs, message correction and file-transfers with the new chat theme. Change-Id: If922a972c658189444e60a7b00e5e5e96661620d
2016-03-17Tidy XEP-0141 codeTim Robbings
This change addresses some feedback the previous XEP-0141 commit (a39d650). Test-information: Ran the CPPUnit tests, these completed successfully. Change-Id: I2caf1eb1349f7527bd9af8ce8adfb194391253e4
2016-03-17Put Sluift headers in their own group with FixIncludes.pyTobias Markmann
Test-Information: Ran FixIncludes over some Sluift files and it sorted them as expected, meaning not grouped together with project external includes. Change-Id: I035381f4560b3c13f1a1feaefad7ecd8e268640b
2016-03-17Cleanup #pragma pollution in Sluift element convertorsTobias Markmann
There were a lot #pramas to ignore unused private field warnings. The pragmas and the unused fields have been removed. Test-Information: Build on OS X 10.11.3 with XCode Clang. Change-Id: Ie2f5398771088f93631c0f2c03d3cfdcca94cee6
2016-03-17Don't allow JIDs with explicitly empty resourcesKevin Smith
A JID may have no resource, but may not have an empty resource. Mark such JIDs as invalid. Test-Information: Added a unit test for the failure case (and made it pass). Other unit tests still pass Change-Id: I4fb300f716e635a3f8f02843891f25218da77130
2016-03-17Add .clang-format configuration file for Swift projectsTobias Markmann
Test-Information: Applied it on 50 random source and header files. The result looked pretty much like the style we currently use. Change-Id: I23806261a22330acfcbb8f197f76d35227e32d6d
2016-03-15Explicitly convert between nullable and non-nullable on OS XTobias Markmann
Clang was complaining about implicit conversions between nullable and non-nullable NSString pointers. Adjusted our std::string -> NSString* conversion utilities to check for nil and return an empty std::string in that case. Replaced uses of [NSString stringWithUTF8String] with our STD2NSSTRING macro. Turned std::string <-> NSString* conversion macros into functions. Test-Information: Builds without the warning on OS X 10.11.3 and Swift runs without issues. Change-Id: I949f2f3332018391aead58ef362764f4b7955b01
2016-03-14Build all Swift projects as C++11Tobias Markmann
Added a SCons compiler test so that the build process fails early if C++11 is not supported. Remove C++11 checks as we now default to C++11 and they are not needed anymore. Ignore a Clang warning if building 3rdParty Boost. Test-Information: Tested build and unit tests on OS X 10.11.3. Change-Id: Icbecbd1e25e8d8bbe5f402f75355373a86b5f8a1
2016-03-11Fix translatability of vCard editor popup menu itemsTobias Markmann
Previously a preprocess macro expansion variable was passed into Qt's tr() function. Qt's translation tool did not pick these stings up. Test-Information: Builds on OS X 10.11.3 with Qt 5.4.2. Provided german translations for some of the items in the popup menu and then ran Swift with --language de. The translated popup menu items were correctly translated in the UI as expected. Change-Id: I50aeac9dd7277e1ce07b5a362c7474962dbcfad4