summaryrefslogtreecommitdiffstats
AgeCommit message (Collapse)Author
2014-10-17Implement support for displaying nickname changes.Tobias Markmann
This implements Swiften API for changing nicknames in MUC and correctly detecting nick name changes. In addition Swift now displays nickname changes as such and not as join/leave of a user. In addition, handling of nickname changes is integrated in ChatsManager and ChatControllers so that they are forwarded to PM chats of MUCs. Test-Information: Added unit tests for change of own nickname and nickname changes of others. Tested correct detection of nickname changes in a MUC with a Psi user changing its nickname and Swift correctly detecting and displaying it. Change-Id: I3287ba6ceeccd3be5cfb591acd6f88bffc9a43b2
2014-10-17Make core.c generation compatible with Python 2.4Edwin Mons
generate_embedded_lua in Sluift/SConscript used a bytearray, which wasn't available until Python 2.6. Modified the code to use the string data instead of a bytearray. Test-information: Builds on OS X 10.9 and CentOS 5.9 sluift binary works on both platforms Change-Id: Iae29f76e32c8b7a827bc438caf09457b259446ca
2014-10-16Specify minimal Windows API version for Windows builds.Tobias Markmann
This sets _WIN32_WINNT and NTDDI_VERSION defines. The minimal version required is Windows Vista since smart card support requires this version. Test-Information: With these defines Swift/-en builds successfully on Windows 8.1 with VisualStudio Express 2013 for Desktop. Change-Id: I8745f201559cd9c401caef7661f09939dffae38f
2014-10-16Change text in blocking list editor from 'click' to 'double-click' to reflectTobias Markmann
actual behavior. Test-Information: Swift's blocking list UI works as descibed in the text displayed in the UI. Change-Id: Ic10d907d89dfc43b97aa21132ceb58210de807b4
2014-10-16Add missing shebang to Boost update script.Tobias Markmann
Test-Information: Without it would lead to executing failures for users of non-bash shells. Now it works nicely for these users. Change-Id: I63ef0c91d88800b382714692c0a37f6dcb14c283
2014-10-16Fix user experience issues related to blocking list editor.Tobias Markmann
This commit enables complete keyboard accessibility for editing the block list including list navigation via cursor keys, editing via enter key and deletion via backspace. The placeholder item for adding new items is now non-removable and is indicated as such. The 'Save'-button is disabled during processing of a request. The window is closed on 'Save' if no changes have been made or the changes have been applied successfully. On failure the error message is shown in the window. A description text has been added at the top to tell the user about the use of the dialog. Test-Information: Success cases have been tested by running Swift and do change the blocking list via mouse and keyboard and doing no changes at all. Error cases have been tested using a server adjustment which replys with IQ errors on any blocklist change. Change-Id: I028a9dd15e66ba7363a30b66c5d5a15ba2a5a518
2014-10-14Remove empty fields from XEP-0055 search query before sending it over the wire.Tobias Markmann
This clears both, empty fields of XEP-0004 data forms and the XEP-0055 predefiened fixed form. Test-Information: Verified using Swift's debug console and M-Link. Change-Id: I3cd2314abfe5111f66569d39aae9b8587157ec07
2014-10-14Fix tab order of join room dialog.Tobias Markmann
Test-Information: Run Swift and verify that tabbing through the join room dialog goes through the widgets from left to right and from top to buttom. Change-Id: I8acb0e10860970e758ff66318760dceeda9cfe0b
2014-10-13Correctly set 'jabber:client' namespace on message/presence/IQ stanzas for ↵Tobias Markmann
BOSH connections. Test-Information: Tested with Swift and interoperability against Psi. Swift debug log now correctly shows the namespace being set. Previously Psi did not display the body of messages due to them being in the worng namespace. Now as they are in the correct namespace messages are displayed correctly by Psi. Change-Id: I547e335100abebfcf170cf7f41b86fd2dbb01692
2014-10-13Regress Python requirement to 2.4 againKevin Smith
Test-information: Ran through the configuration step on a machine with only Python 2.4 Change-Id: I3d5ba54395ede875c7f21c2769151fe6d308e760
2014-10-10Fix JID auto-complete item select not working when adding a contact.Richard Maudsley
Test-Information: Confirm that clicking a suggested user fills the JID box on the "Add User" dialog. Confirm that JID suggestion functions normally in other places. Change-Id: Ic1a5c30b95416fd46bc22a612793621e9501d770
2014-10-09Prevent renaming of 'Contacts' roster group used for groupless contacts.Tobias Markmann
Test-Information: Verified by running Swift and checking that you cannot rename 'Contacts' group anymore. Other groups are still renameable. Change-Id: I97a79feb92d65d6dcdf914fb47b13ee268d271c3
2014-10-08Explain the use of preffered stars in 'Edit Profile' dialog if they are checked.Tobias Markmann
Test-Information: Verified this works by running Swift and editing a profile. Change-Id: I965ef374ceed2ba5b3225070931b6c06e3b9e800
2014-10-08Update vCard cache on 'Show Profile' if cached vCard is older than 5 minutes.Tobias Markmann
Store last write time in memory in VCardStorage. VCardManager::getVCardAndRequestWhenNeeded will check an optional parameter and the last write time to determine if the cached vCard is fresh enough. Test-Information: ALl unit tests still run fine and tested that it fetches the vCard again when you open the 'Show Profile' dialog after 5 minutes. Change-Id: I27d7f931188a43aa090348014bcdbdf6d534c5a0
2014-10-08Prevent multiple chat window alerts being shown with the same message.Richard Maudsley
Test-Information: Enable message delivery receipts, check that only a single alert is displayed for repeated messages. Change-Id: Ifb9f8bd74e592147745f95678f94c21563d301a5
2014-10-07Fix clang compiler warning related to inititalization order of members in ctor.Tobias Markmann
Change-Id: I5cbbacce8dc75a38646ebfdc72e5a2c9aec184f6
2014-10-07Fix QLayout related warning.Tobias Markmann
QVBoxLayout was initialized with a widget which automatically tries to make the new layout the main layout of the widget. However, this is not intended. This bug was introduced in cc379dc. Test-Information: Before a warning "QLayout: Attempting to add QLayout..." was printed to stdout when joining a MUC; now this warning is gone. Change-Id: Ie680b188e108a3d825fb98947f2829d3c12955f7
2014-10-07Add tooltip to preferred stars of profile editor to describe what it's for.Tobias Markmann
Change-Id: I937c39406ec3ae58cd7c0d8311543bcbb684fda0
2014-10-07Hide unchecked preferred stars in profile editor where there is only one field.Tobias Markmann
Hide the preferred stars in profile editor if it is not checked and there is only one field of a field type in the vCard. Example: If you have only one eMail in your vCard it does not make much sense to mark it preferred. If it is already marked as preferred we will still display it as such. Test-Information: Manually tested it via editing a vCard of a test account. On addition or deletion of fields other fields are checked and stars hidden/shown on demand. Change-Id: I4704d52518e662f7e3a168ed2b42602383b2153f
2014-10-06Do not send chat state notifications to blocked contacts.Tobias Markmann
Test-Information: Started a chat session; then blocked the contact. Previously chat state notifications were send when typing. Now they are not send anymore. Change-Id: Id68f3faee4829e99cbfe1535f48346a8c27712d3
2014-10-06Fix detailed name not being shown in profiles.Tobias Markmann
Test-Information: Tested by running Swift and verifying that the detailed name (prefix, given, middle, family, suffix) is shown. Change-Id: Iacd3f88dc58f3a797cb5854f7ee4800515202c04
2014-10-06Allow scons to not require an IDN libraryKevin Smith
This will clearly break all the tests, Swift, Sluift etc., but is useful if someone wants to use Swiften and inject their own IDN provider. Test-information: Compiles with Isode's IDN provider Change-Id: Ia55991054f42f332bf34b653d7b55f64f654820e
2014-10-06Fix own avatar in contact list header not updated on VCard edit.Tobias Markmann
Commit 14fd8e changed the JID comparison to JID::WithResource. However, we want JID::WithoutResource because a) handleAvatarChanged is called with a bare resource when our own avatar changes and b) we also want the avatar in the contact list header be updated if another of our resources changes it. Test-Information: Changed own avatar to a different avatar or cleared it. Before the avatar in the contact list header was not updated; now it is. Change-Id: Ie84b6cb10b528f75c1c76c7ceae558f00380d99f
2014-10-06Always bring 'Edit contact' window to the top on 'Edit contact' so it is visibleTobias Markmann
to the user and has focus. Test-Information: Checked via running Swift and testing in different scenarios (minimizing, background) that this functionality works. Change-Id: I49ed16b09d23acd052c387c3c1c4fe60f2aa9415
2014-10-03Suggest MUC occupants when typing in highlight editor JID boxRichard Maudsley
Test-Information: Join several MUCs and confirm that MUC occupants are suggested along with recent contacts. Confirm that clicking or pressing return adds the selected contact to the edit field. Check that QtSuggestingJIDInput in Start Chat dialog still functions as before, and that MUC users are not suggested here. Change-Id: Ieadc95d55c764e1fa48c949cca4d5e0aa5f19615
2014-10-01Disable drag of text and images (like avatars) in chat views.Tobias Markmann
Change-Id: I74ba85f84c9e4775b472e7366f3f1b7572489512
2014-10-01Port many of Isode's local fixes upstreamKevin Smith
Includes fixes to: Build with new Visual Studio and Boost Avoid error caused when Avahi is present but Qt is not Make declaration of XMPPRosterImpl::addContact consistent with implementation Includes enhancements to: Allow user-configurable mt.exe Allow splitting openssl paths Allow disabling gconf lookup Make idn support optional Allow disabling various library detections Remove use of non-Python2.4 features in sconscripts Test-Information: Builds Change-Id: Iee91ee80291a8bdf87cc169c915e4dad1cc1055b
2014-10-01Render selected highlight item rule in italicRichard Maudsley
Test-Information: Verify that this is just a cosmetic change and does not effect operation of highlight dialog. Change-Id: Ie0fd14bb5d90a3cfae1797bbe3daa7e724987584
2014-10-01Fix resizability behavior of 'Edit Bookmark'-Dialog.Tobias Markmann
The dialog is now only resizable in width and the line edit fields resize with the dialog size without leaving awkward whitespace. Test-Information: Checked via running Swift and testing that the fields resize in width and the dialog is fixed in height. Change-Id: Idd7417720438f20fa051a823df40d89545db9078
2014-09-30Always bring profile window to the top on 'Show Profile' so it is visible to theTobias Markmann
user and has focus. Test-Information: Checked via running Swift and testing in different scenarios that this functionality works. This includes situations where the profile window has been closed, minimised or put in the background. Change-Id: I367ef555fabe32f7ec1d09e7ff72b17d2071e134
2014-09-21Add Czech translationRemko Tronçon
Thanks to Roman Štefko. Change-Id: I509152cb44bcd81b37be4d2c905e9fab51e1a3d1
2014-09-20Fix ASAN-reported heap-use-after-free bug.Tobias Markmann
ChatListModel used to notify Qt about its changed items via layoutChanged() signals. However, not only the layout changed but most times also the items and corrosponding QModelIndex objects and their internal pointers. After layout changed Qt tried to access now invalid QModelIndex objects and their internal pointers pointed to freed memory. Test-Information: Checked via ASAN. The previously perfect reproducable report by joining a MUC from the bookmarks went away. Change-Id: I71d2aa7e66a6b4caf2a9e0f68552ff5174291e1e License: This patch is BSD-licensed, see Documentation/Licenses/BSD-simplified.txt for details.
2014-09-18Only allocate BlockResponder and UnblockResponder once. Fixes ASANTobias Markmann
heap-used-after-free report. Tested via ASAN, report gone after applying this change. It previously occured during machine sleep/resume or logout/login. Change-Id: I8af6a3c290457a4a98f94486a225f9dfb92ca885 License: This patch is BSD-licensed, see Documentation/Licenses/BSD-simplified.txt for details.
2014-09-18Fix memory leak of mucRecentsMenu_ in QtChatListWindow.Tobias Markmann
Verified with clang's ASAN on linux. Change-Id: I12cb3f1e672adf35aec8eee9dece3e669af5c2cc License: This patch is BSD-licensed, see Documentation/Licenses/BSD-simplified.txt for details.
2014-09-17Handle Isode's IQ ForwardingKevin Smith
Change-Id: I3b358e6a60f1ff546f2e578b6e0a54072b4c6da5
2014-09-16Add Subject element convertor to SluiftEdwin Mons
Test Information: MAM queries now return a payload of _type='subject'. Change-Id: I4fe4eb5105f4f19d146e4cca741d35bb7760cf6c
2014-09-16Fix boost::optional abuses that stop compilation with latest boostKevin Smith
Test-Information: Compiles and unit tests pass with boost 1.56 Change-Id: I6525399babc5f6c88fb499af80e9f07c1c4d0cdb
2014-08-21Clean up compilation errors in Swiften due to boost 1.56Kevin Smith
Can no longer implicitly convert boost::optional to bool temporaries. Also fixed assorted uses of cerr where logging was appropriate. Test-Information: Swiften compiles against boost 1.56 (link fails for me so far) Change-Id: Iec058af933a82a987da64291435a475f8b40ef96
2014-08-10Fix invalid characters being allowed in JID domainsRichard Maudsley
Test-Information: Prepare valid and invalid JIDs and make sure that isValid() is reported correctly. Added unit tests. Change-Id: Ic4d86f8b6ea9defc517ada2f8e3cc54979237cf4
2014-08-10Address memory leakKevin Smith
I'd rather do this with shared_ptr, as there's an ownership transfer. This just gets it into somewhere we'll remember it Change-Id: I5f6872bce8070cbcce44de84eff5e9ed83f88fb9
2014-08-10Fix blocklist not being requested on reconnect.Richard Maudsley
Test-Information: Connect client and confirm that blocklist is requested only once. Reconnect client and confirm that blocklist is requested again. Change-Id: Iebf38c9f3c1ff9749c239b6cf785feb7a539a9b1
2014-08-03Allow injection of flags into unit test checkerKevin Smith
Some projects (e.g. Eve-Xin) piggy-back on Swift's build system, but are unable to do the same with unit tests until this patch (because the checker will need to link against the unknown library to test it). This patch allows them to set INJECTED_UNITTEST_FLAGS, which will get included in the checker's compilation if set. Test-Information: Added unit test to Eve-Xin, which builds and runs. Change-Id: I58ffb2043b968144ad10096b83ac9d88f54f72f3
2014-08-01Fix memory leaks reported by ASAN in some unit tests.Tobias Markmann
Change-Id: Ic9c31a8e2378110df7f368437b66ff4b51cfd665 License: This patch is BSD-licensed, see Documentation/Licenses/BSD-simplified.txt for details.
2014-08-01Fix issue in QtUtilities reported by ASAN.Tobias Markmann
Change-Id: I3e7d65efb4b66897abf735eb9f759122fdf50b89 License: This patch is BSD-licensed, see Documentation/Licenses/BSD-simplified.txt for details.
2014-07-29Fix rule for highlighting messages from individual sender JID or MUC nick.Richard Maudsley
Test-Information: Set up rule to highlight chat messages from a sender. Confirm that when this is enabled the entire message text from that sender is highlighted and messages from other senders are displayed normally. Same test for Room/MUC messages. Confirm that for MUC nicks the comparison is case insensitive. Confirm that URL parsing and emoticon parsing stills works within highlighted messages. Change-Id: I5bbf013df8efdd76f876c020fd3097adbfb45760
2014-07-29Add ability to reorder highlight rules list.Richard Maudsley
Test-Information: Add several highlight rules. Verify that the up and down buttons reorder the items in the list. Change-Id: I6272799e2b2767ddfa01068c2ffcd1fb4651e11d
2014-07-29Prevent nick highlight rule highlighting the entire message and remove ↵Richard Maudsley
default highlight colours Test-Information: Add a nick highlight rule. Verify that it is triggered correctly in MUCs and that only the nick text is highlighted. Added unit tests. Change-Id: I9af1c900f4767383745afd36a5eadbe08f606432
2014-07-29Fix DNS resolution on Android.Richard Maudsley
Test-Information: Try accessing local hosts on a local network and make sure that the local DNS server is queried. Change-Id: Ie594b3eed5772c58d46ec1a4435b2df24d6d8212
2014-07-29Add close button to chat window alerts.Richard Maudsley
Test-Information: Check that close button is functional. Change-Id: I45078cb50e410365704e6a8b2444e1a4b15db068
2014-07-29Fix renaming contact group makes blocked user appear to be unblocked.Richard Maudsley
Test-Information: Block a user and rename the group then verify that the user still appears as blocked in the roster. Try renaming a group with several users in various states of blocked and unblocked and verify that the states are preserved after renaming. Change-Id: I93ff721b053f299d5f1c3f62dd8687f021701fe1