1
0
mirror of https://github.com/qTox/qTox.git synced 2024-03-22 14:00:36 +08:00
Commit Graph

7296 Commits

Author SHA1 Message Date
Anthony Bilinski
746314baf2
fix(history): move stuck action messages to broken_messages table
Before a bug in qTox would make it possible for a user to try to send an empty
action type message. This would fail to send at toxcore, but still be persisted
in history, causing it to fail every time FauxOfflineEngine tried to resend
it. Moving these stuck messages into the broke_messages table will stop qTox
from attempting to deliver them on each connect, and display in the GUI to
users that the messages aren't really pending anymore.
2019-10-20 02:35:20 -07:00
Anthony Bilinski
89e94b6f89
fix(chatform): don't try to send empty action messages
Otherwise sending just "/me " calls down to core with 0-length action, which
causes a toxcore send error.

There may be messages that are stuck in history as pending with "/me " content,
causing them to fail to send on every start. Those should be moved to the new
broken_messages table, similar to stuck pending messages from #5776. There's no
reason this fix to stop adding more broken messages needs to wait on the
history fix, though.
2019-10-20 02:35:20 -07:00
Anthony Bilinski
1a726b54cd
fix(history): display broken messages UI with error icon
Allows users to still see their broken messages in the chatlog, but in a way
that's clear that they haven't been delivered and won't be sent.
2019-10-20 02:34:48 -07:00
Anthony Bilinski
527c7d2d3c
refactor(history): represent message state as enum class
ensures that only one state is set at a time, avoids managing multiple bools
2019-10-20 02:34:48 -07:00
Anthony Bilinski
f6a15366ef
fix(history): select broken messages from History, track in ChatLogMessage 2019-10-20 02:34:48 -07:00
Anthony Bilinski
cd75618e38
refactor(history): rename pending message variables
"Sent" to "Delivered", since that's what we're tracking also rename "isOffline"
to "isPending", which is boolean the same, but "isOffline" was opposite of its
correct value before, so boolean reverse the assignment.
2019-10-20 02:34:47 -07:00
Anthony Bilinski
b28dc30061
fix(history): move stuck pending message into broken_messages table
Fix #5776

Due to a long standing bug, faux offline message have been able to become stuck
going back years. Because of recent fixes to history loading, faux offline
messages will correctly all be sent on connection, but this causes an issue of
long stuck messages suddenly being delivered to a friend, out of context,
creating a confusing interaction. To work around this, this upgrade moves any
faux offline messages in a chat that are older than the last successfully
delivered message, indicating they were stuck, to a new table,
`broken_messages`, preventing them from ever being sent in the future.
2019-10-20 02:34:47 -07:00
Anthony Bilinski
f72f3f714d
fix(history): handle errors during db upgrade 2019-10-20 02:34:47 -07:00
Anthony Bilinski
dacfcdadac
refactor(history): apply db schema upgrade one version at a time
This allows upgrade steps to query the db at the last version and run C++ code
on the results, then do a single transaction to make the upgrade, instead of
all actions of each upgrade step being required to be part of the overall
upgrade transaction.
2019-10-20 02:34:47 -07:00
Anthony Bilinski
996b17b1d1
refactor(test): allow generic schema creation and verification in for db schema 2019-10-20 02:34:47 -07:00
Mick Sayson
dbef0b7508
fix(offlinemsg): fix offline message dispatching on history load
* Fix callback hookup order in ChatHistory
* Add correct call to SessionChatLog to insert an unfinished message
* Fix incorrect logic in parsing History database response
2019-10-20 02:34:47 -07:00
Anthony Bilinski
86b55a0fb0
fix(db): show full sqlite error message 2019-10-20 02:34:46 -07:00
Anthony Bilinski
d98fe85a58
fix(db): prepare and execute queued statements one at a time
* Allows for queued preparations to depend on the execution of previous statements
2019-10-20 02:34:46 -07:00
Anthony Bilinski
8f44fb6355
Merge pull request #5894
jenli669 (1):
      fix(loginScreen): make loginScreen return values comply with Qt standards
2019-10-18 17:25:37 -07:00
jenli669
b4bc09345c
fix(loginScreen): make loginScreen return values comply with Qt standards
This commit makes LoginScreen return QDialog::Rejected (0) and
QDialog::Accepted (1) instead of C standard return values. This should be more
robust with regards to special cases in Qt implementation.

Fixes #5781
2019-10-18 16:24:53 -07:00
Anthony Bilinski
a44cce65be
fix(travis): update pyenv to python 3.7 after updating ubuntu to 16.04
3.6 can no longer be found, causing CI failures
2019-10-17 10:44:58 -07:00
Anthony Bilinski
e85d3f522a
fix(icon): use Qt tray icon in all cases, remove platform specific backends
qTox added specialized tray icon backends over time to work around bugs with
the default implementation, since then our GTK+2 backend has stopped working,
our appindicator backend was never selected by default by cmake, and
statusnotifier was never selected at SystemTrayIcon construction, leaving us
only ever using the broken GTK+2 backend, or theoretically the Unity backend,
which I didn't see selected on Ubuntu 16.04 Unity. In all other cases we would
fall back to the Qt backend.

Qt icon has improved over time, and our platform specific icons have become
stale, with GTK+2 becoming deprecated and GTK+3 not having a similar feature,
QSystemTrayIcon has been tested on a variety of DEs and works as well or better
in all cases, as shown in the table at
https://github.com/qTox/qTox/issues/5881#issuecomment-541892457

Fix #5881
Fix #5859
2019-10-16 13:27:29 -07:00
Anthony Bilinski
93c9eef51f
fix(ci): fix travis' window build in debian docker by upgrading libseccomp2
seccomp is used by the docker host, and the default version shipped with
Ubuntu 16.04 does not support syscalls used by Qt5's configure inside the
docker container. Upgrading libseccomp2 resolves this issue.

Fix #5874
2019-10-13 14:35:54 -07:00
Anthony Bilinski
16de5f8549
chore(ci): update travis to ubuntu 16.04, since 14.04 is EOL
Ubuntu has Qt 5.5.1 in its repos, so PPA is no longer required.
2019-10-10 14:11:21 -07:00
Jimi Huotari
c20e1c20e3
refactor(Qt): use 'storeRelaxed()' and 'loadRelaxed()'
This fixes build with Qt 5.14 by replacing the deprecated
QAtomic::load() and store() functions with the new ones.

- https://code.qt.io/cgit/qt/qtbase.git/commit/?h=5.14&id=79bdc7cf
2019-10-09 23:19:27 -07:00
Jimi Huotari
489d07c0eb
refactor(Qt): use 'QLatin1String' instead of 'QLatin1Literal' part 2
This is required when building against Qt 5.14.
2019-10-09 23:19:27 -07:00
Maxim Biro
710c32ded0
feat: add Fcitx and Uim support to AppImage 2019-10-09 23:19:27 -07:00
Maxim Biro
2419b62762
fix(build): fix OpenAL Soft failing to build with newer CMake 2019-10-09 23:19:27 -07:00
Maxim Biro
8be99c0861
fix(build): fix SQLCipher build issue with OpenSSL 1.1.1 on Windows 2019-10-09 23:19:27 -07:00
Maxim Biro
39122d741a
chore(windows): update VPX to 1.8.1 2019-10-09 23:19:27 -07:00
Maxim Biro
a7555c6925
chore(windows): update FFmpeg to 4.2.1 2019-10-09 23:19:26 -07:00
Maxim Biro
003f8ca988
chore(windows): update OpenSSL to 1.1.1d 2019-10-09 23:19:26 -07:00
Maxim Biro
13f147141d
chore(windows): update Qt to 5.12.5 2019-10-09 23:19:26 -07:00
Maxim Biro
6bb2c7c629
feat(build): use Debian Buster for Windows cross-compilation 2019-10-09 23:19:26 -07:00
Jimi Huotari
f9488bf966
refactor(Qt): use 'asprintf' instead of 'sprintf'
Deprecated since Qt 5.14.

- https://code.qt.io/cgit/qt/qtbase.git/commit/?h=5.14&id=f8f592d5
2019-10-09 23:19:26 -07:00
Jimi Huotari
7f74d41586
refactor(Qt): use 'QLatin1String' instead of 'QLatin1Literal'
This is an undocumented Qt 2/3/4 remnant, deprecated in Qt 5.14.

- https://code.qt.io/cgit/qt/qtbase.git/commit/?h=5.14&id=3e75c296
- https://code.qt.io/cgit/qt/qtbase.git/commit/?h=5.14&id=45373c19
2019-10-09 23:19:26 -07:00
Anthony Bilinski
731a49854a
fix(core): avoid logging which bootstrap node is being connected to
Errors are parsed and printed, but which specific node is being connected to
isn't very relevant to any errors that would occur, and the nodes list is
already updated to prune offline nodes based on nodes.tox.chat periodically.
This provides some extra privacy about which connections are being made,
even though the bootstrap nodes are already public.
2019-10-09 23:18:34 -07:00
Anthony Bilinski
fe9d83d881
chore(tools): allow merging PR to whatever branch is checked out
Useful for either dev testing or merging PRs to dev branches. Also stop
updating local repo state beyond merging the PR.
2019-10-09 23:16:33 -07:00
Anthony Bilinski
e97b270584
fix(osx): create /usr/local/sbin directory for brew package installation
ffmpeg dependency unbound attempts to symlink to /usr/local/sbin, failing if
the directory does not exist. /usr/local/sbin does not exist by default on
10.13 High Sierra, so prompt to create it if it doesn't exit, and create it for
travis CI automatically.
2019-10-09 23:15:23 -07:00
Anthony Bilinski
8e597ed736
chore(travis): make travis happy by having some output - but not too much
Fix #5515

brew install might take a long time to build Qt or ffmpeg. Travis kills us if
we don't output for 10 minutes. Travis also kills us if we output too much, so
verbose isn't an option. So just output some dots...
2019-10-09 23:07:24 -07:00
Anthony Bilinski
6fb5b205f4
fix(ci): upgrade travis to xcode9.3 to get macos 10.13 with brew support
Brew now only officially supports Mac OS 10.13-10.15, which means our
previously used 10.12 had fewer binary packages available, meaning we had to
compile more ourselves, causing CI to timeout.
https://docs.travis-ci.com/user/reference/osx#macos-version
https://github.com/Homebrew/brew/pull/6500

Fix #5515
2019-10-09 16:15:16 -07:00
Anthony Bilinski
da4928b704
fix(icon): make busy notification icon translucent in middle 2019-10-03 22:34:00 -07:00
Anthony Bilinski
b95bac238d
fix(chatlog): update precise selection when chatlog content changes
Fix #5769. Precise selections (within one chatline) need to be invalidated when
the line they are apart of is removed from the chatlog.
2019-09-28 18:00:20 -07:00
Anthony Bilinski
08b2c848e2
refactor(chatlog): use enum class instead of enum to avoid implicit casts 2019-09-28 17:07:06 -07:00
Anthony Bilinski
e4f73011f9
fix(core): don't log critical on every group join
It's expected behaviour that the peer is unknown when first joining a group.

Fix #5118
2019-09-17 00:45:17 -07:00
Anthony Bilinski
3d7a872f1a
fix(core): save tox profile when updating group or friend states
Makes sure persistent groups are stored in the case of a qTox crash.
2019-09-15 19:04:02 -07:00
Anthony Bilinski
f7a2a7d648
fix(widget): only change group title once
Before we were connecting the same signal to the same slot for each group we created.
2019-09-15 19:04:02 -07:00
Anthony Bilinski
602671c9dc
fix(core): don't set core status on connect, just update UI 2019-09-15 19:04:02 -07:00
Anthony Bilinski
f846b6cdaa
Merge pull request #5819
TriKriSta (1):
      fix: hide current date at the top of the chat
2019-09-15 18:46:21 -07:00
TriKriSta
bbbbc6aade
fix: hide current date at the top of the chat 2019-09-15 17:31:45 -07:00
Anthony Bilinski
31f1c746b6
Merge pull request #5827
Mick Sayson (1):
      fix(chatlog): Prepare geometry changes on chatline proxy
2019-09-14 12:38:15 -07:00
Mick Sayson
74d0b47ceb fix(chatlog): Prepare geometry changes on chatline proxy
Closes #5818. If output of boundingRect() changes for a QGraphicsItem
prepareGeomeotryChange() must be called.
2019-09-13 14:41:10 -07:00
jenli669
bd034e130d
docs(usermanual): Add information about commandline options 2019-09-02 21:05:04 -07:00
jenli669
31fec7488f
feat(proxy): provide commandline tools for proxy settings 2019-09-02 21:05:01 -07:00
sudden6
2ea5030958
fix(widget): don't try to play audio if it's disable 2019-08-30 14:07:19 +02:00