Commit Graph

390 Commits

Author SHA1 Message Date
John Preston 7f6c163449 Fix crash in video userpics.
Fixes #24665.
2022-06-22 12:03:47 +04:00
23rd 6d4506f8aa Fixed display of most of multiline toasts in corresponding window. 2022-06-15 14:06:32 +03:00
23rd 236b7bbf28 Fixed display of toast about copying post link in corresponding window. 2022-06-14 14:24:21 +03:00
John Preston 1b604bed0b Fix bottom shadow in premium settings. 2022-06-10 12:05:16 +04:00
23rd c9ef5e47fe Migrated from frequency timer to simple animation for item highlighting. 2022-06-05 09:11:10 +03:00
23rd ba7422805b Moved items highlighting to separate management module. 2022-06-05 09:11:10 +03:00
John Preston be16a7725c Show premium stickers toast on double click. 2022-05-26 12:30:50 +04:00
John Preston 73bacfc650 Animate video userpics in chat history. 2022-05-19 17:27:03 +04:00
John Preston dd05fb4d14 Show limit toasts and boxes. 2022-05-19 17:27:02 +04:00
John Preston 5adf95fc28 Display premium stickers in comments/pinned/scheduled. 2022-05-19 17:27:02 +04:00
John Preston a079139c3b Sync premium sticker effect with sticker frame index. 2022-05-19 17:27:01 +04:00
John Preston 323cb78f22 Paint effects in correct places. 2022-05-19 17:27:01 +04:00
John Preston 935fb79c52 Play premium sticker effects. 2022-05-19 17:27:01 +04:00
John Preston d87c9c72fb Update API scheme on layer 142: Premium reactions. 2022-05-19 17:27:01 +04:00
23rd 5261e962e2 Removed Ui::show from menu item for poll stopping. 2022-04-19 09:39:01 +04:00
23rd af0a2f182c Removed Ui::show from ShowReportItemsBox. 2022-04-19 09:39:01 +04:00
23rd e3ac84a849 Moved boxes for reporting messages or peers to separated file. 2022-04-19 09:39:01 +04:00
23rd 148a173474 Removed animation when removing reaction with double click. 2022-04-15 13:11:32 +03:00
23rd 4304071d18 Added ability to configure quick action on double click. 2022-04-13 15:06:23 +04:00
23rd 9510d38929 Fixed reply on double click with protected content. 2022-04-12 17:35:51 +03:00
23rd cf6b995c50 Moved out saving of ringtones to api toggling media module. 2022-04-07 19:18:47 +03:00
23rd 7b307a9e54 Added ability to save audio from chat as custom notification sound. 2022-04-06 15:21:37 +03:00
John Preston 98f2f6d4c0 Always try to save original photo bytes to disk. 2022-03-07 11:09:14 +04:00
Magnus Groß 4dd14b81e1 Do not remove notification reference on NotificationClosed
In general we need to keep a reference to the notification id, so that
we can delete the notification later from history - unless the
NotificationClosed reason was that the user actively dismissed it, in
which case it is not kept in history anyway (so we can dismiss our
reference too).

-- Background --
Some desktop environments such as KDE keep a history of notifications.
An API is provided to delete notifications from that history by calling
the org.freedesktop.Notifications.CloseNotification endpoint with the ID
of that notification. If the notification was already closed (timed
out), then this will delete the notification from history.

The intent is to clear these notifications from the notification history
as soon as a chat with notifications originating from that person is
opened, as the user is then not interested anymore in those
notifications and to prevent unnecessary clutter in the history widget.
It is also cleared when the chat is read on another device.

-- Problem --
Telegram already has all the code in place to support this
functionality, but unfortunately this did not work on Linux before,
because we listen to the NotificationClosed signal and remove our
reference to the notification id from our internal manager as soon as we
get that signal. This means that we do not clear that notification from
history once we open the chat with that person (unless we open the chat
before the notification has timed out, i.e. if we didn't get the
NotificationClosed signal).

-- Fix --
To fix this, we keep our notification reference (if the notification was
not dismissed by the user), which means that our reference will be kept
around until we open the chat with that person (or close Telegram
entirely).

Since all the needed functionality for deleting notifications was
already in place, this patch is quite short as we only need to keep the
reference around longer than we did before this patch.

Note also that code is already in place to clear notifications for
messages that were read on another device: History::inboxRead() calls
Core::App().notifications().clearIncomingFromHistory()

Fixes #17111
2022-03-05 16:51:02 +04:00
John Preston dde4868540 Add phrases to lang.string. 2022-02-27 20:26:52 +03:00
23rd 4dee21c0e6 Added userpics support to sponsored messages. 2022-02-25 19:41:16 +03:00
23rd 6939da2fd2 Fixed simple animation of message sending with custom chat themes. 2022-02-25 19:41:16 +03:00
23rd d633860e1d Added simple animation of static stickers sending. 2022-02-25 19:41:15 +03:00
Ilya Fedin 5d5b964f4e Don't block main queue with drag operation 2022-02-22 12:45:35 +03:00
John Preston 4f1e04cf9e Animate reactions when reading. 2022-01-28 19:10:07 +03:00
John Preston 8f33d5903d Display unread reactions badge in chats list. 2022-01-28 19:10:07 +03:00
John Preston e9c79886d2 Track unread mentions and unread reactions the same way. 2022-01-28 19:10:07 +03:00
John Preston 63d15e4479 Support Webm sticker display in chat history. 2022-01-28 19:10:07 +03:00
John Preston 28f2c213f7 Remove app module. Support delayed quit by Cmd+Q on macOS. 2022-01-27 15:54:20 +03:00
23rd 59ed41abfe Added ability to select links and monospaced text with pressed Alt key. 2022-01-26 10:39:57 +03:00
23rd 0143d22a21 Split qt_adapters to separated files. 2022-01-26 10:33:28 +03:00
John Preston 9a451a1423 Don't suggest "Set As Quick" on already quick. 2022-01-17 19:21:34 +03:00
John Preston 1657c2c7f2 Fix context menu on sent images / documents. 2022-01-17 19:21:34 +03:00
John Preston 1060b04b1e Reacted users list on inline reaction right click. 2022-01-14 21:55:48 +03:00
John Preston 5eb210ec12 "Set As Quick" context menu in reactions dropdown. 2022-01-14 21:55:48 +03:00
John Preston f24f78c0cc Use click handler property instead of dynamic cast. 2022-01-14 21:55:48 +03:00
John Preston 490e688a91 Add reaction animations to comments. 2022-01-14 21:55:48 +03:00
John Preston 34c36d77c3 Paint reaction animations above everything. 2022-01-14 21:55:47 +03:00
John Preston 0ab26f0c82 Initial reaction effects implementation. 2022-01-14 21:55:47 +03:00
John Preston e032dbf383 Cache reaction lottie in Window::SessionController. 2022-01-14 21:55:47 +03:00
John Preston 963694330d Correctly apply reaction restrictions. 2022-01-14 21:55:47 +03:00
John Preston 8788692fb3 Fix crash in sending a reaction. 2022-01-05 15:14:39 +03:00
John Preston cb8f86bc8d Attach main views to correct HistoryInner-s. 2022-01-05 00:11:29 +03:00
John Preston 611be90880 Rewrite sponsored to use fake sender names. 2021-12-31 16:07:36 +03:00
John Preston cd0db53bac For non-bubble messages reaction to the left of info. 2021-12-31 02:40:03 +03:00