2
0
mirror of https://github.com/telegramdesktop/tdesktop synced 2025-08-31 14:38:15 +00:00

Allow fix chats order and auto switch (support).

This commit is contained in:
John Preston
2018-09-29 15:18:26 +03:00
parent 29432d5d6a
commit 25cefc6eab
16 changed files with 238 additions and 47 deletions

View File

@@ -15,6 +15,14 @@ https://github.com/telegramdesktop/tdesktop/blob/master/LEGAL
class ApiWrap;
enum class SendFilesWay;
namespace Ui {
enum class InputSubmitSettings;
} // namespace Ui
namespace Support {
enum class SwitchSettings;
} // namespace Support
namespace Data {
class Session;
} // namespace Data
@@ -68,6 +76,26 @@ public:
SendFilesWay sendFilesWay() const {
return _variables.sendFilesWay;
}
void setSendSubmitWay(Ui::InputSubmitSettings value) {
_variables.sendSubmitWay = value;
}
Ui::InputSubmitSettings sendSubmitWay() const {
return _variables.sendSubmitWay;
}
void setSupportSwitch(Support::SwitchSettings value) {
_variables.supportSwitch = value;
}
Support::SwitchSettings supportSwitch() const {
return _variables.supportSwitch;
}
void setSupportFixChatsOrder(bool fix) {
_variables.supportFixChatsOrder = fix;
}
bool supportFixChatsOrder() const {
return _variables.supportFixChatsOrder;
}
ChatHelpers::SelectorTab selectorTab() const {
return _variables.selectorTab;
}
@@ -183,6 +211,10 @@ private:
= kDefaultThirdColumnWidth; // per-window
rpl::variable<Calls::PeerToPeer> callsPeerToPeer
= Calls::PeerToPeer();
Ui::InputSubmitSettings sendSubmitWay;
Support::SwitchSettings supportSwitch;
bool supportFixChatsOrder = true;
};
rpl::event_stream<bool> _thirdSectionInfoEnabledValue;