mirror of
https://github.com/kotatogram/kotatogram-desktop
synced 2025-08-31 14:45:14 +00:00
Move discussion group link to three-dot menu.
This commit is contained in:
@@ -613,6 +613,16 @@ const ChannelData *PeerData::asMegagroup() const {
|
||||
: nullptr;
|
||||
}
|
||||
|
||||
ChannelData *PeerData::asBroadcast() {
|
||||
return isBroadcast() ? static_cast<ChannelData*>(this) : nullptr;
|
||||
}
|
||||
|
||||
const ChannelData *PeerData::asBroadcast() const {
|
||||
return isBroadcast()
|
||||
? static_cast<const ChannelData*>(this)
|
||||
: nullptr;
|
||||
}
|
||||
|
||||
ChatData *PeerData::asChatNotMigrated() {
|
||||
if (const auto chat = asChat()) {
|
||||
return chat->migrateTo() ? nullptr : chat;
|
||||
@@ -729,6 +739,10 @@ bool PeerData::isMegagroup() const {
|
||||
return isChannel() ? asChannel()->isMegagroup() : false;
|
||||
}
|
||||
|
||||
bool PeerData::isBroadcast() const {
|
||||
return isChannel() ? asChannel()->isBroadcast() : false;
|
||||
}
|
||||
|
||||
bool PeerData::canWrite() const {
|
||||
if (const auto user = asUser()) {
|
||||
return user->canWrite();
|
||||
|
Reference in New Issue
Block a user