Commit graph

2374 commits

Author SHA1 Message Date
23rd
63b5eb66ff Provided Window::SessionController to FastShareMessage. 2022-03-06 18:11:47 +03:00
23rd
b9f6591734 Moved out FastShareMessage from history_message. 2022-03-06 18:11:47 +03:00
23rd
fa50a5962c Removed Window::SessionNavigation from ShareBox. 2022-03-06 18:11:47 +03:00
23rd
dd6501ef8f Added ability to provide style to schedule box. 2022-03-06 18:11:47 +03: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
Ilya Fedin
1c8d4ee7ab Get rid of Q_OBJECT in HistoryInner 2022-03-05 16:47:38 +04:00
23rd
bc6d69319c Provided window controller to box of converting channel to gigagroup. 2022-03-04 11:25:10 +03:00
23rd
ed5b83bc62 Fixed unexpected copyright reason from top bar in sections. 2022-03-02 06:11:44 +03:00
23rd
e44961e571 Fixed display of userpic for sponsored messages in channels. 2022-03-01 12:52:31 +03:00
Klemens Nanni
6decece009 Remove unused variables 2022-02-28 23:11:07 +03:00
John Preston
282b3592c2 Show toast about jump-to non-existent message. 2022-02-28 19:53:14 +03:00
23rd
40d97bc6a4 Added ability to start video chat with RTMP as well. 2022-02-28 16:54:08 +03:00
John Preston
664774f474 Fix group call bar with requests bar. 2022-02-28 12:53:50 +03:00
23rd
5718789d53 Replaced Ui::InformBox and Ui::ConfirmBox with GenericBox. 2022-02-28 09:08:01 +03:00
23rd
6478b7b129 Added menu to HistoryView::TopBarWidget for starting of livestream. 2022-02-28 08:05:02 +03:00
23rd
166d844d55 Divided showing of peer menu from top bar into two methods. 2022-02-28 08:04:46 +03:00
23rd
a3d00b1953 Replaced args for Calls::Instance::startOrJoinGroupCall with struct. 2022-02-28 08:04:46 +03:00
John Preston
a61048d219 Fix scroll state management in Downloads. 2022-02-27 20:26:52 +03:00
John Preston
dde4868540 Add phrases to lang.string. 2022-02-27 20:26:52 +03:00
John Preston
e89c95551f Show correct downloads elements context menu. 2022-02-27 20:26:52 +03:00
John Preston
daadf7e2a1 Allow goToMessageClickHandler to switch accounts. 2022-02-27 20:26:52 +03:00
23rd
1da5e7d1f7 Added ability to chose copyright as reason for message report. 2022-02-25 19:41:16 +03:00
23rd
9bc48f4aba Fixed links position of inline keyboard when reactions aren't in bubble. 2022-02-25 19:41:16 +03:00
23rd
4dee21c0e6 Added userpics support to sponsored messages. 2022-02-25 19:41:16 +03:00
23rd
2e40798e8e Added simple animation of GIFs sending. 2022-02-25 19:41:16 +03:00
23rd
0dc2e1a5ae Migrated SendingInfoTo from using of end geometry to end point. 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
a0a857a6db Added simple animation of stickers sending from autocomplete field. 2022-02-25 19:41:16 +03:00
23rd
0a2fbb0d70 Added simple animation of stickers sending from inline bots. 2022-02-25 19:41:16 +03:00
23rd
2632ec45bd Added support to skip parts of gifs drawing. 2022-02-25 19:41:16 +03:00
23rd
9d164dc33c Added clearing of message sending animations on escape from section. 2022-02-25 19:41:15 +03:00
23rd
cf5f5f75bc Added permanent info display to webm stickers with right action. 2022-02-25 19:41:15 +03:00
23rd
40875ac8ff Added simple animation of static stickers sending to replies section. 2022-02-25 19:41:15 +03:00
23rd
afdfe1c2e8 Added ability to provide custom view to sending animation controller. 2022-02-25 19:41:15 +03:00
23rd
d633860e1d Added simple animation of static stickers sending. 2022-02-25 19:41:15 +03:00
23rd
b46adec413 Added initial controller of message sending animations. 2022-02-25 19:41:15 +03:00
23rd
298c5026be Added ability to count inner geometry in HistoryView::Element. 2022-02-25 19:41:15 +03:00
23rd
7cd14b8c4e Renamed anim::interpolateF to anim::interpolateToF. 2022-02-25 19:41:15 +03:00
John Preston
9d200017c3 Support two new message report reasons. 2022-02-25 19:41:15 +03:00
John Preston
91c46dbc85 Allow Info::Media::ListWidget use different data providers. 2022-02-25 19:41:15 +03:00
John Preston
ffd65e1fe4 Fix slide animations with new layer rounding. 2022-02-25 14:14:43 +03:00
John Preston
c39f15bd71 Fix build with VS 2022 17.1. 2022-02-25 14:14:43 +03:00
John Preston
1501a6d8fc Don't check config.phonecalls_enabled value. 2022-02-25 14:14:41 +03:00
Ilya Fedin
5d5b964f4e Don't block main queue with drag operation 2022-02-22 12:45:35 +03:00
John Preston
95e806cb89 Play webm stickers only once if looping is disabled. 2022-02-10 19:11:21 +03:00
John Preston
b4a49de819 Fix possible incorrect links in service messages. 2022-02-10 19:11:21 +03:00
John Preston
4f4ef941c6 Move SendPreloadRequest out of HistoryWidget. 2022-02-10 15:20:37 +03:00
John Preston
7228752a01 Check only for existing unread reactions. 2022-02-10 14:09:22 +03:00
John Preston
a5483a5113 Fix build on Linux. 2022-02-08 19:17:44 +03:00
John Preston
d89d8b09da Preload chats in support switch. 2022-02-08 00:24:11 +03:00