mirror of
https://github.com/AyuGram/AyuGramDesktop.git
synced 2025-06-05 06:33:57 +02:00
Use in-class initializers for bitfields.
This commit is contained in:
parent
fe025e3c44
commit
f13e28a9c5
5 changed files with 21 additions and 36 deletions
|
@ -433,21 +433,11 @@ PeerListRow::PeerListRow(not_null<PeerData*> peer)
|
||||||
|
|
||||||
PeerListRow::PeerListRow(not_null<PeerData*> peer, PeerListRowId id)
|
PeerListRow::PeerListRow(not_null<PeerData*> peer, PeerListRowId id)
|
||||||
: _id(id)
|
: _id(id)
|
||||||
, _peer(peer)
|
, _peer(peer) {
|
||||||
, _hidden(false)
|
|
||||||
, _initialized(false)
|
|
||||||
, _isSearchResult(false)
|
|
||||||
, _isSavedMessagesChat(false)
|
|
||||||
, _isRepliesMessagesChat(false) {
|
|
||||||
}
|
}
|
||||||
|
|
||||||
PeerListRow::PeerListRow(PeerListRowId id)
|
PeerListRow::PeerListRow(PeerListRowId id)
|
||||||
: _id(id)
|
: _id(id) {
|
||||||
, _hidden(false)
|
|
||||||
, _initialized(false)
|
|
||||||
, _isSearchResult(false)
|
|
||||||
, _isSavedMessagesChat(false)
|
|
||||||
, _isRepliesMessagesChat(false) {
|
|
||||||
}
|
}
|
||||||
|
|
||||||
PeerListRow::~PeerListRow() = default;
|
PeerListRow::~PeerListRow() = default;
|
||||||
|
|
|
@ -263,11 +263,11 @@ private:
|
||||||
base::flat_set<QChar> _nameFirstLetters;
|
base::flat_set<QChar> _nameFirstLetters;
|
||||||
int _absoluteIndex = -1;
|
int _absoluteIndex = -1;
|
||||||
State _disabledState = State::Active;
|
State _disabledState = State::Active;
|
||||||
bool _hidden : 1;
|
bool _hidden : 1 = false;
|
||||||
bool _initialized : 1;
|
bool _initialized : 1 = false;
|
||||||
bool _isSearchResult : 1;
|
bool _isSearchResult : 1 = false;
|
||||||
bool _isSavedMessagesChat : 1;
|
bool _isSavedMessagesChat : 1 = false;
|
||||||
bool _isRepliesMessagesChat : 1;
|
bool _isRepliesMessagesChat : 1 = false;
|
||||||
|
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
|
@ -126,12 +126,7 @@ MembersRow::MembersRow(
|
||||||
not_null<MembersRowDelegate*> delegate,
|
not_null<MembersRowDelegate*> delegate,
|
||||||
not_null<PeerData*> participantPeer)
|
not_null<PeerData*> participantPeer)
|
||||||
: PeerListRow(participantPeer)
|
: PeerListRow(participantPeer)
|
||||||
, _delegate(delegate)
|
, _delegate(delegate) {
|
||||||
, _sounding(false)
|
|
||||||
, _speaking(false)
|
|
||||||
, _raisedHandStatus(false)
|
|
||||||
, _skipLevelUpdate(false)
|
|
||||||
, _mutedByMe(false) {
|
|
||||||
refreshStatus();
|
refreshStatus();
|
||||||
_aboutText = participantPeer->about();
|
_aboutText = participantPeer->about();
|
||||||
}
|
}
|
||||||
|
|
|
@ -210,11 +210,11 @@ private:
|
||||||
crl::time _speakingLastTime = 0;
|
crl::time _speakingLastTime = 0;
|
||||||
uint64 _raisedHandRating = 0;
|
uint64 _raisedHandRating = 0;
|
||||||
int _volume = Group::kDefaultVolume;
|
int _volume = Group::kDefaultVolume;
|
||||||
bool _sounding : 1;
|
bool _sounding : 1 = false;
|
||||||
bool _speaking : 1;
|
bool _speaking : 1 = false;
|
||||||
bool _raisedHandStatus : 1;
|
bool _raisedHandStatus : 1 = false;
|
||||||
bool _skipLevelUpdate : 1;
|
bool _skipLevelUpdate : 1 = false;
|
||||||
bool _mutedByMe : 1;
|
bool _mutedByMe : 1 = false;
|
||||||
|
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
|
@ -32,14 +32,14 @@ struct GroupCallParticipant {
|
||||||
uint64 raisedHandRating = 0;
|
uint64 raisedHandRating = 0;
|
||||||
uint32 ssrc = 0;
|
uint32 ssrc = 0;
|
||||||
int volume = 0;
|
int volume = 0;
|
||||||
bool sounding : 1;
|
bool sounding : 1 = false;
|
||||||
bool speaking : 1;
|
bool speaking : 1 = false;
|
||||||
bool additionalSounding : 1;
|
bool additionalSounding : 1 = false;
|
||||||
bool additionalSpeaking : 1;
|
bool additionalSpeaking : 1 = false;
|
||||||
bool muted : 1;
|
bool muted : 1 = false;
|
||||||
bool mutedByMe : 1;
|
bool mutedByMe : 1 = false;
|
||||||
bool canSelfUnmute : 1;
|
bool canSelfUnmute : 1 = false;
|
||||||
bool onlyMinLoaded : 1;
|
bool onlyMinLoaded : 1 = false;
|
||||||
bool videoJoined = false;
|
bool videoJoined = false;
|
||||||
bool applyVolumeFromMin = true;
|
bool applyVolumeFromMin = true;
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue