2
0
mirror of https://github.com/kotatogram/kotatogram-desktop synced 2025-08-31 06:35:14 +00:00

new photo viewer done, testing, added compressed checkbox in send-from-clipboard

This commit is contained in:
John Preston
2014-08-11 13:03:45 +04:00
parent f62db48251
commit d26afe1b64
29 changed files with 1274 additions and 491 deletions

View File

@@ -155,7 +155,7 @@ SettingsInner::SettingsInner(SettingsWidget *parent) : QWidget(parent),
if (_self) {
_nameText.setText(st::setNameFont, _nameCache, _textNameOptions);
PhotoData *selfPhoto = _self->photoId ? App::photo(_self->photoId) : 0;
if (selfPhoto && selfPhoto->date) _photoLink = TextLinkPtr(new PhotoLink(selfPhoto));
if (selfPhoto && selfPhoto->date) _photoLink = TextLinkPtr(new PhotoLink(selfPhoto, _self));
MTP::send(MTPusers_GetFullUser(_self->inputUser), rpcDone(&SettingsInner::gotFullSelf));
connect(App::main(), SIGNAL(peerPhotoChanged(PeerData *)), this, SLOT(peerUpdated(PeerData *)));
@@ -257,7 +257,7 @@ void SettingsInner::peerUpdated(PeerData *data) {
if (_self->photoId) {
PhotoData *selfPhoto = App::photo(_self->photoId);
if (selfPhoto->date) {
_photoLink = TextLinkPtr(new PhotoLink(selfPhoto));
_photoLink = TextLinkPtr(new PhotoLink(selfPhoto, _self));
} else {
_photoLink = TextLinkPtr();
MTP::send(MTPusers_GetFullUser(_self->inputUser), rpcDone(&SettingsInner::gotFullSelf));
@@ -612,7 +612,7 @@ void SettingsInner::gotFullSelf(const MTPUserFull &self) {
App::feedUsers(MTP_vector<MTPUser>(QVector<MTPUser>(1, self.c_userFull().vuser)));
PhotoData *selfPhoto = _self->photoId ? App::photo(_self->photoId) : 0;
if (selfPhoto && selfPhoto->date) {
_photoLink = TextLinkPtr(new PhotoLink(selfPhoto));
_photoLink = TextLinkPtr(new PhotoLink(selfPhoto, _self));
} else {
_photoLink = TextLinkPtr();
}