Commit graph

82 commits

Author SHA1 Message Date
John Preston
a27ea2d631 Fix possible crash in mtpFileLoader.
If several cdn file parts hashes are received in getCdnFileHashesDone
and some middle one of them cancels the entire loader (for example
because of a file write error) a !_finished assert violation happens.
2017-12-08 17:13:13 +04:00
John Preston
68009b6fba Refactor userpic storage and access in PeerData. 2017-12-05 11:58:18 +04:00
John Preston
629c216a7f Fix storage size variables, use qint64.
Fixes #4110.
2017-12-03 20:51:31 +04:00
John Preston
001be82566 Add some more checks to file downloader. 2017-12-02 12:32:43 +04:00
John Preston
ad6ddcb507 Fix crash in selecting unsent messages.
Also add some more checks in file downloads and serialization.
2017-11-30 11:14:31 +04:00
John Preston
67d4eb688a Reverse user and chat profile photos. 2017-11-23 13:58:12 +04:00
John Preston
d93c1ccbaa Improve compile time. 2017-11-21 14:20:52 +04:00
John Preston
6ca105a290 Minimal layer 72 support. 2017-11-20 23:54:05 +04:00
John Preston
ac99318f34 Use ranges:: algorithms instead of base:: 2017-11-20 16:24:00 +04:00
John Preston
59938791ef Closed beta 1.1.23.6: Log crash info. 2017-11-18 00:04:22 +04:00
John Preston
554eb3a342 Move stickers state variables to AuthSessionData.
Also allow to click on the selected set when choosing megagroup
sticker set and allow to paste a t.me link to the set there.
2017-11-16 07:59:09 +04:00
John Preston
9a56b2d20f Move dialogsWidthRatio to AuthSessionData. 2017-11-16 07:59:09 +04:00
John Preston
aec496d520 Remove RTL Override symbols from filenames. 2017-11-16 07:59:09 +04:00
John Preston
a27edcad1c Extract SparseIdsList module from SharedMedia.
This way it can be reused in search results management.
2017-11-16 07:59:08 +04:00
John Preston
65cc4d3fbc Support item repaint in Info media overview. 2017-11-16 07:59:06 +04:00
John Preston
0c4bda71fd Remove some unused / rare phrases. 2017-11-16 07:59:05 +04:00
John Preston
d1687ab963 Improve info wrapping in section / layer.
Also move layerwidget to window/layer_widget.
Also replace ui/effects/widget_fade_wrap with ui/wrap/fade_wrap.
2017-11-16 07:59:05 +04:00
John Preston
086e46c162 Add and use only rpl::start_with_*() methods. 2017-11-16 07:59:05 +04:00
John Preston
ffc20e4492 Divide structs into several data/ modules. 2017-11-16 07:59:04 +04:00
John Preston
b9fb9af74f Info shared media and common groups counters. 2017-11-16 07:59:04 +04:00
John Preston
766e7dadb1 Use improved rpl::start(). 2017-11-16 07:59:03 +04:00
John Preston
f162462111 Move info between Layer and Narrow wrap. 2017-11-16 07:59:03 +04:00
John Preston
088d23d557 Start new Info section (profile + shared media). 2017-11-16 07:59:02 +04:00
John Preston
fbcd5e2f1e Try to use const-ref better in rpl. 2017-11-16 07:59:02 +04:00
John Preston
c302219f9e Use rpl in some widgets and effects. 2017-11-16 07:59:02 +04:00
John Preston
873ccf8096 Implement SharedMediaWithLastViewer using rpl. 2017-11-16 07:59:02 +04:00
John Preston
696478843e Implement UserPhotosViewer using rpl. 2017-11-16 07:59:02 +04:00
John Preston
2690618da2 Add Storage::UserPhotos and UserPhotosSlice. 2017-11-16 07:59:02 +04:00
John Preston
449986456e Add SharedMediaSliceMerged for migrated histories. 2017-11-16 07:59:02 +04:00
John Preston
2363a6bd44 Add SharedMediaSlice to observe shared media.
Start testing / using it in MediaView.
2017-11-16 07:59:02 +04:00
John Preston
41ed2d1b84 New storage for shared media messages index. 2017-11-16 07:59:02 +04:00
visuve
8c92f42de3 Fix uninitialized values
- Use C++11 default member initializers

Signed-off-by: Veli-Matti Visuri <veli-matti.visuri@cerescon.fi> (github: visuve)
2017-09-28 18:23:42 +03:00
John Preston
2e374e68c5 Fix working with layers.
Regression was introduced in df64c97.

New base::flags work correctly only if all mutually exclusive flag
values use mutually exclusive bits (a & b == 0 for exclusive (a, b)).

Closes #3856.
2017-09-03 22:49:33 +03:00
John Preston
df64c972d8 Replace QFlags with base::flags. 2017-09-03 15:45:47 +03:00
John Preston
c97227825f Send images as files if no way to send as photos.
Fixes #3710.
2017-08-30 19:15:44 +03:00
John Preston
25ffaaaa2d Replace t_assert() with Assert().
Also use this assertions for Expects(), Ensures() and Unexpected().
2017-08-30 19:15:42 +03:00
John Preston
b3da99c302 Replace gsl::not_null<T*> with just not_null<T*>. 2017-08-30 19:15:41 +03:00
John Preston
e13ed9b909 Remove main()->peerUpdated and some other signals. 2017-08-30 19:15:36 +03:00
John Preston
f2801d4775 Fix possible crash in file download after error.
Regression was introduced in 2fa2fa41c5.

In file download failed handler we suggest to try to load the file
once again to the same location. After some changes we started to
forget filename before failed handler. That resulted in large files
loading to memory instead of hard drive.

Add a precondition in FileLoader to prevent such bugs in the future.
2017-08-30 19:15:34 +03:00
John Preston
f7359093b4 Replace ContactsBox with PeerListBox in two cases.
- View contacts list in PeerListBox.
- Add participants when creating group / channel in PeerListBox.
2017-08-30 19:15:27 +03:00
John Preston
ab35829358 Remove App::app(), App::uploader(), App::api().
Also use Auth() instead of AuthSession::Current*().
2017-08-25 14:39:18 +03:00
John Preston
667eb288d7 Add faved stickers set loading and saving.
Also move stickers loading methods to ApiWrap.
2017-08-25 12:58:13 +03:00
John Preston
9d81ea59dd Attempt to fix an out of memory crash. 2017-08-01 21:14:43 +03:00
John Preston
80ee40eb18 Add debug info for out of memory crash. 2017-07-27 13:14:39 +03:00
John Preston
0e059ec788 Version 1.1.16: Add some debug info. 2017-07-26 17:56:01 +03:00
John Preston
2e0513a30f Check CDN file hashes. 2017-07-23 12:34:41 +03:00
John Preston
90311dbf24 Fix CDN file download. 2017-07-18 22:01:22 +03:00
John Preston
f316e3bd17 Add debug logs for window position and autoupdate. 2017-07-03 15:23:41 +03:00
John Preston
61659244b7 Add night mode switch to the main menu.
Also fix a bug with the default background applying.
2017-06-30 09:21:46 +03:00
John Preston
9e6f2a5d2e Remember connection type settings. 2017-06-30 09:21:43 +03:00