Commit Graph

132 Commits

Author SHA1 Message Date
John Preston 2c5d990e1c Implement full theming of attachments in stories. 2023-07-20 07:20:08 +04:00
John Preston 65afa2c402 Detach ComposeControls from SessionController. 2023-05-17 15:51:52 +04:00
John Preston ff4af1b9bc Fix pasting images from Firefox on Windows.
Fixes #10564.

Together with the image data Firefox sets to the clipboard an URLs list
which has a path to local temp file, created from that image.

Reading images from disk is slower + sometimes the content of the file
is wrong so for this case we prefer to read the image data directly.
2023-03-08 16:10:36 +04:00
23rd a7e2de53f5 Moved out size of result file for userpic to public interface. 2023-02-02 22:12:31 +04:00
23rd f077c555e2 Moved out styles of ripples with shadowFg color to single place. 2023-02-02 22:12:31 +04:00
23rd dad9f4b87d Flipped icon for rotation button in photo editor. 2023-01-09 09:05:06 +04:00
John Preston 84288112fc Allow sending photos larger 1280 (experimental).
Improves #6520.
2023-01-02 14:26:41 +04:00
John Preston 17f40d6a1f Don't lose focus when showing image editor. 2022-12-28 13:05:23 +04:00
John Preston 2364b0ad4e Show additional information in userpic suggest / accept. 2022-12-26 14:24:07 +04:00
John Preston 1d7ad701b4 Implement blurred background for photo editor. 2022-12-26 14:24:07 +04:00
John Preston 9513aaa768 Allow accepting video userpic suggestions. 2022-12-26 14:24:07 +04:00
23rd a3a48a38c8 Replaced callback for box showing with dedicated class in photo editor. 2022-12-26 14:24:07 +04:00
John Preston ae819eb1a6 Open settings when done changing photo. 2022-12-26 14:24:05 +04:00
John Preston 48cf0a4382 Implement suggested profile photo message. 2022-12-26 14:24:05 +04:00
John Preston cb653df0f6 Support adaptive forum userpic rounding radius. 2022-12-05 16:18:10 +04:00
John Preston 0dd45de254 Remember scroll state between topic openings. 2022-11-03 16:29:40 +04:00
John Preston 749fb52113 Implement animated spoilers. 2022-09-18 16:52:30 +04:00
John Preston bc340d75c4 Insert / Copy emoji from pack preview. 2022-09-14 14:45:23 +04:00
Ilya Fedin e20840b4d4 Use KUrlMimeData for clipboard xdg-desktop-portal integration 2022-08-30 20:25:10 +04:00
John Preston f8e22210e7 Move Webm sticker to UnwrappedMedia. 2022-08-04 13:35:34 +03:00
John Preston 2d6008f6ca Fix custom emoji in edit caption / send files box. 2022-07-26 20:12:13 +03:00
John Preston 6dedf7c63e Update API scheme to layer 143. 2022-05-19 17:27:02 +04:00
Ilya Fedin 387914be31 Replace style sheet in Editor::Paint 2022-05-02 16:01:36 +04:00
23rd 3cb595c3c9 Added ability to set profile photo from camera. 2022-03-14 11:57:34 +03:00
John Preston 32d09f189b Use rpl::empty instead of rpl::empty_value(). 2022-03-11 09:56:29 +04:00
23rd f74a75da75 Fixed display photo with modifications as file in attach media preview. 2022-03-04 18:58:07 +03:00
23rd 0e08cffedb Fixed error display in EditCaptionBox. 2022-03-04 18:58:07 +03:00
23rd 5718789d53 Replaced Ui::InformBox and Ui::ConfirmBox with GenericBox. 2022-02-28 09:08:01 +03:00
John Preston a6621233d0 Show first frame of webm in photo editor. 2022-01-28 19:10:07 +03:00
John Preston 8b7d2c880e Support rendering Webm videos with alpha. 2022-01-28 19:10:07 +03:00
John Preston 3ff17a8789 Refactor image transformation interfaces. 2022-01-21 15:33:44 +03:00
23rd 1ec2ecac11 Fixed render of scene from photo editor for grayscaled images.
Fixed #23889.
2022-01-13 04:20:15 +03:00
John Preston f1244e19a1 Fix build for Windows. 2022-01-12 13:07:00 +03:00
23rd 39d5d3a1cf Moved some photo editor files to td_ui. 2022-01-12 11:54:25 +03:00
23rd f8be5731a5 Moved out extracting of attached stickers from Scene to FileLoadTask. 2022-01-12 11:54:25 +03:00
23rd 889d7c0c15 Added undo and redo shortcuts to photo editor. 2022-01-12 11:54:24 +03:00
John Preston bfdbb64295 Move some Settings icons to a subfolder. 2021-12-29 21:22:33 +03:00
John Preston b773bb6e70 Add icons to the media viewer menus. 2021-12-29 21:22:33 +03:00
Ilya Fedin 847c01d605 Add Qt 6 support
Tested only on Linux so far
2021-10-21 13:15:00 +04:00
23rd 80461bd9fe Moved ConfirmBox to Ui namespace. 2021-10-19 06:34:27 +03:00
23rd 6148edbc7d Moved ConfirmBox to td_ui. 2021-10-19 06:34:27 +03:00
John Preston 84f561b251 Don't use MTP* in the image editor. 2021-10-04 23:47:33 +04:00
John Preston 19ce1edc16 Use base::SafeRound instead of std::round.
Previous assertion violations because of NaN from std::round were
in video streaming, see commits 27d58ba07b, 8f5830d520.

Now the crashes happened in the ConvertScale() call from a background
thread when preparing an image from clipboard for sending to a chat.
2021-09-27 12:13:57 +04:00
John Preston 132f127f3f Add some assertions to debug a crash. 2021-09-24 08:44:22 +04:00
John Preston c79cd0b692 Use Images::Read instead of App::readImage. 2021-08-11 18:55:08 +03:00
Ilya Fedin 79cc797aff Fix -Wunused-variable warnings 2021-07-13 21:43:34 +03:00
Ilya Fedin b6881022ce Allow to build with -Werror and clang
Fixes -Wdeprecated-enum-enum-conversion, -Wdeprecated-declarations, -Wrange-loop-construct, -Winconsistent-missing-override
2021-07-13 21:32:06 +03:00
23rd 7526964904 Simplified calculation of minimum crop size in photo editor.
It also fixes cropping of images with unbalanced ratios.
2021-07-09 13:15:31 +03:00
23rd 6b93d8dc41 Refactored and fixed saving scene states between modes in photo editor. 2021-07-09 12:49:07 +03:00
23rd 9be122710d Moved SaveState from Editor::BaseItem to Editor::NumberedItem. 2021-07-09 12:49:07 +03:00