Commit graph

341 commits

Author SHA1 Message Date
fourtf 9874bd779a formatted all files with clang 9 2019-09-26 00:51:05 +02:00
fourtf 456065f508 moved resources out of Application 2019-09-22 10:54:32 +02:00
fourtf da4714944d small fixes in Image 2019-09-22 10:54:32 +02:00
fourtf 758a6bb41c NetworkRequest onError now uses NetworkResult 2019-09-19 19:03:50 +02:00
fourtf 3ab7362304 Merge branch 'master' into irc-support 2019-09-18 13:03:16 +02:00
fourtf 07133166d9 added setting to show unhandled irc commands 2019-09-18 11:11:50 +02:00
fourtf 04f8875c4d fixes #1303 now searches using search text instead of message text 2019-09-15 18:29:50 +02:00
Leon Richardt 720e5aa25f Improvements to Message Search (#1237)
* Ran clang-format

* Implement user-specific search in message history

This functionality was originally requested in #1236.

This commit changes the SearchPopup::performSearch method so that only
messages from specific users can be shown.

In order to filter for a specific user, enter their username with a
leading '@' in the search popup. You can also add an additional search
phrase which will also be considered in the search.

* Naive implementation for "from:" tags

Rebase later?

* Cleverer (?) version using Predicates

Commit adds two POC predicates: one for the author of messages, and one
for substring search in messages.

Problems/TODOs:
* Best way to register new predicates?
* Clean up tags (e.g. "from:") or not?
* Test combinations of different predicates

* Add a predicate to check for links in messages

* Remove a dumb TODO

* Rewrite SearchPopup::performSearch to be cleaner

* Ran clang-format on all files

* Remove TODO I missed earlier

* Forgot to run clang-format

peepoSadDank

* Re-use {}-initialization

Was accidentally removed when fixing earlier merge conflict.

* Does this fix line endings?

No diffs are shown locally, hopefully Git doesn't lie to me.

* Rename "predicates" directory to "search"

Resolving one conversation in the review of #1237.

* Use LinkParser in LinkPredicate

Resolving a conversation in the review of #1237.

* Predicates: Use unique_ptr instead of shared_ptr

Resolves a conversation in the review of #1237.

* Refactor of SearchPopup and AuthorPredicate

Resolving some points from the review in #1237.

* Moved parsing of comma-seperated values into AuthorPredicate
  constructor.
* Rewrite SearchPopup::parsePredicates as suggested.
* Deleted now redundant methods in SearchPopup.

* MessagePredicate::appliesTo now takes a Message&

... instead of a MessagePtr.

This resolves a conversation in the review of #1237.

* Run clang-format on two files I missed

* AuthorPredicate: Check for displayName & loginName

Resolving conversation on #1237.
2019-09-09 15:21:49 +02:00
Leon Richardt b06eb9df83 Normalize line endings in already existing files 2019-09-08 22:27:57 +02:00
Rasmus Karlsson 57ba829775 Remove previously added includes to Image 2019-09-08 14:08:18 +02:00
Rasmus Karlsson dbce128cc3 Remove "custom on success" logic from Image.
Create a new message element and message layout element type for mod badges.
2019-09-08 14:08:18 +02:00
Rasmus Karlsson 256a65a12e Load mod badge information from the FFZ API instead of assuming the URL.
This lets us load all sizes of the emote if they are available.

Channel with all versions of the mod badge: https://api.frankerfacez.com/v1/room/pajlada
Channel with only one version of the mod badge: https://api.frankerfacez.com/v1/room/apa420
Channel with no mod badge: https://api.frankerfacez.com/v1/room/forsen
2019-09-08 14:08:18 +02:00
fourtf a268abfd4c Allow searching in LogsPopup 2019-09-04 00:29:58 +02:00
fourtf d709b98331 switched order in loaded image selection 2019-08-21 02:21:12 +02:00
fourtf e140905faf ? 2019-08-21 02:16:33 +02:00
fourtf 3b3791e43a Special message when login expired. 2019-08-21 02:00:42 +02:00
fourtf 6d9545157e Fixes #1215 Allow previewing badges 2019-08-21 01:52:01 +02:00
fourtf dbc20baa65 fixed emote preview not using 3x images 2019-08-21 01:44:19 +02:00
fourtf f3e48c1325 smoll changes 2019-08-21 00:07:59 +02:00
fourtf 7643c0d20d fixed deleting QTimer on wrong thread 2019-08-20 23:46:27 +02:00
fourtf 14222f84f2 made caller/concurrent rules tighter 2019-08-20 23:46:27 +02:00
fourtf 4713862620 load cache files async 2019-08-20 22:16:17 +02:00
fourtf 4f6c1a8519 added NetworkRequest builder functions 2019-08-20 22:16:17 +02:00
fourtf 18f3a816ed re-enabled loading recent messages concurrently
@pajlada please check if the code can stay commented out
2019-08-13 15:03:33 +02:00
fourtf 6274c05520 Fixed always loading 1x, 2x and 3x images 2019-08-13 13:51:27 +02:00
fourtf 23f1ec9ac2 Fixed using non existant 2x and 3x versions of ffz emotes and badges 2019-08-13 13:00:16 +02:00
Rasmus Karlsson cd5972522b reformat 2019-08-11 21:08:18 +02:00
fourtf e7d9422431 fixes for last commit 2019-08-01 13:30:58 +02:00
fourtf fff979b3c0 lock SignalVector with shared_lock to allow reading on other threads 2019-07-31 22:50:12 +02:00
TranRed d725155569 Added setting and functionality to highlight inline whispers
Inline whispers will be displayed with highlighted background color.

New Flag needed to differentiate between normal whisper (highlighted) and whisper with mention.
2019-07-14 16:35:32 +02:00
Rasmus Karlsson 27114c5154 Restore option to disable emote images
Condensed into a single option, which will disable/enable all emote and emoji images

Also moved badges into their own element
2019-06-22 14:34:54 +02:00
Rasmus Karlsson 64dc7f5d73 Fix a bug with messages jumping if you were scrolled up
The bug appeared every 100 messages (so whenever a chunk was deleted)

To fix this, we only perform the first chunk offset increment if the
item we deleted was not the last item in a chunk
2019-06-22 13:04:31 +02:00
Rasmus Karlsson c631434cee Make use of our "Chunk" and "ChunkVector" aliases better 2019-06-22 13:03:57 +02:00
rexim a569985315 Remove dead code 2019-06-11 23:20:04 +07:00
rexim 959aa4616f pixmap() -> imagePreview() 2019-06-11 23:20:04 +07:00
rexim aa4e7f13e7 Get rid of dynamic_cast 2019-06-11 23:20:04 +07:00
rexim d4a6defed6 Introduce a way to extract QPixmap from ImageLayoutElement
Probably should be a part of MessageLayoutElement interface, but good
for now
2019-06-11 23:20:04 +07:00
apa420 9a7365821d Fixed issue #1071 (#1073) 2019-05-18 17:37:26 +02:00
Rasmus Karlsson 1a7a5409ab do a full reformat according to our current .clang-format 2019-05-10 23:31:10 +02:00
apa420 834b1f3c53 Option to hide system moderation messages (#1066) 2019-05-10 23:16:34 +02:00
23rd 9654650bee Renamed variables to clear some warnings. 2019-05-10 22:18:05 +02:00
23rd efec76df5b Removed unused local vars. Slightly refactored code. 2019-05-10 22:18:05 +02:00
TranRed cff1aa0959 changed some variables to const 2019-05-04 11:40:52 +02:00
TranRed 7ad6db550d made links in system messages clickable
needed to make sub ticket in sub only chat accessible.
2019-05-04 11:40:52 +02:00
Rasmus Karlsson 30430b0fb3 this ctor was used to create a system message
we now only use the ctor that takes an explicit SystemMessageTag
2019-05-02 00:28:53 +02:00
TranRed b33478d8c6 stored original message text in message 2019-05-01 16:43:52 +02:00
hemirt e0e7d366d3 remove useless comment 2019-04-29 20:33:04 +02:00
hemirt 56956eea58 remove weeb hate 2019-04-28 23:23:04 +02:00
fourtf 9be0d7d458 removed red stripes and connected tape cut visuals 2019-04-17 17:02:13 +02:00
pajlada 97faec15e0
Merge pull request #979 from hemirt/whispers
do not disable whispers on clears and timeouts
2019-04-16 15:06:42 +02:00