mirror of https://github.com/procxx/kepka.git
improved forwarded media display, 0.9.18
This commit is contained in:
parent
2c7fb82708
commit
f2824f79f6
|
@ -1323,7 +1323,7 @@ public:
|
||||||
return _caption.original();
|
return _caption.original();
|
||||||
}
|
}
|
||||||
bool needsBubble(const HistoryItem *parent) const {
|
bool needsBubble(const HistoryItem *parent) const {
|
||||||
return !_caption.isEmpty() || parent->toHistoryReply() || parent->viaBot();
|
return !_caption.isEmpty() || parent->toHistoryForwarded() || parent->toHistoryReply() || parent->viaBot();
|
||||||
}
|
}
|
||||||
bool customInfoLayout() const {
|
bool customInfoLayout() const {
|
||||||
return _caption.isEmpty();
|
return _caption.isEmpty();
|
||||||
|
@ -1331,9 +1331,6 @@ public:
|
||||||
bool hideFromName() const {
|
bool hideFromName() const {
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
bool hideForwardedFrom() const {
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
|
|
||||||
|
@ -1392,7 +1389,7 @@ public:
|
||||||
ImagePtr replyPreview();
|
ImagePtr replyPreview();
|
||||||
|
|
||||||
bool needsBubble(const HistoryItem *parent) const {
|
bool needsBubble(const HistoryItem *parent) const {
|
||||||
return !_caption.isEmpty() || parent->toHistoryReply() || parent->viaBot();
|
return !_caption.isEmpty() || parent->toHistoryForwarded() || parent->toHistoryReply() || parent->viaBot();
|
||||||
}
|
}
|
||||||
bool customInfoLayout() const {
|
bool customInfoLayout() const {
|
||||||
return _caption.isEmpty();
|
return _caption.isEmpty();
|
||||||
|
@ -1400,9 +1397,6 @@ public:
|
||||||
bool hideFromName() const {
|
bool hideFromName() const {
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
bool hideForwardedFrom() const {
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
|
|
||||||
|
@ -1628,7 +1622,7 @@ public:
|
||||||
return _caption.original();
|
return _caption.original();
|
||||||
}
|
}
|
||||||
bool needsBubble(const HistoryItem *parent) const {
|
bool needsBubble(const HistoryItem *parent) const {
|
||||||
return !_caption.isEmpty() || parent->toHistoryReply() || parent->viaBot();
|
return !_caption.isEmpty() || parent->toHistoryForwarded() || parent->toHistoryReply() || parent->viaBot();
|
||||||
}
|
}
|
||||||
bool customInfoLayout() const {
|
bool customInfoLayout() const {
|
||||||
return _caption.isEmpty();
|
return _caption.isEmpty();
|
||||||
|
@ -1636,9 +1630,6 @@ public:
|
||||||
bool hideFromName() const {
|
bool hideFromName() const {
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
bool hideForwardedFrom() const {
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
~HistoryGif();
|
~HistoryGif();
|
||||||
|
|
||||||
|
@ -2165,7 +2156,7 @@ public:
|
||||||
}
|
}
|
||||||
QString selectedText(uint32 selection) const;
|
QString selectedText(uint32 selection) const;
|
||||||
bool displayForwardedFrom() const {
|
bool displayForwardedFrom() const {
|
||||||
return via() || !_media || !_media->isDisplayed() || !_media->hideForwardedFrom();
|
return via() || !_media || !_media->isDisplayed() || (fwdFrom->isChannel() || !_media->hideForwardedFrom());
|
||||||
}
|
}
|
||||||
|
|
||||||
HistoryForwarded *toHistoryForwarded() {
|
HistoryForwarded *toHistoryForwarded() {
|
||||||
|
|
Loading…
Reference in New Issue