mirror of
https://github.com/AyuGram/AyuGramDesktop.git
synced 2026-07-25 06:54:43 +00:00
chore: add hint
This commit is contained in:
@@ -7990,6 +7990,7 @@ https://github.com/telegramdesktop/tdesktop/blob/master/LEGAL
|
|||||||
"ayu_DontSendUploadProgress" = "Don't Send Typing";
|
"ayu_DontSendUploadProgress" = "Don't Send Typing";
|
||||||
"ayu_SendOfflinePacketAfterOnline" = "Go Offline Automatically";
|
"ayu_SendOfflinePacketAfterOnline" = "Go Offline Automatically";
|
||||||
"ayu_GhostModeOptionLongTapDescription" = "Long-press any option to prevent it from changing when toggling Ghost Mode.";
|
"ayu_GhostModeOptionLongTapDescription" = "Long-press any option to prevent it from changing when toggling Ghost Mode.";
|
||||||
|
"ayu_GhostModeOptionShiftDescription" = "Click with SHIFT on any option to prevent it from changing when toggling Ghost Mode.";
|
||||||
"ayu_MarkReadAfterAction" = "Read on Interact";
|
"ayu_MarkReadAfterAction" = "Read on Interact";
|
||||||
"ayu_MarkReadAfterActionDescription" = "Automatically marks a message as read when you send a new one or tap a reaction.";
|
"ayu_MarkReadAfterActionDescription" = "Automatically marks a message as read when you send a new one or tap a reaction.";
|
||||||
"ayu_MarkReadAfterSend" = "Send";
|
"ayu_MarkReadAfterSend" = "Send";
|
||||||
|
|||||||
@@ -372,7 +372,11 @@ void BuildGhostEssentials(SectionBuilder &builder) {
|
|||||||
};
|
};
|
||||||
|
|
||||||
auto collapsible = AddCollapsibleToggle(
|
auto collapsible = AddCollapsibleToggle(
|
||||||
container, tr::ayu_GhostModeToggle(), std::move(checkboxes), true);
|
container,
|
||||||
|
tr::ayu_GhostModeToggle(),
|
||||||
|
std::move(checkboxes),
|
||||||
|
true,
|
||||||
|
tr::ayu_GhostModeOptionShiftDescription(tr::now));
|
||||||
state->refreshCheckboxes = std::move(collapsible.refresh);
|
state->refreshCheckboxes = std::move(collapsible.refresh);
|
||||||
if (wctx.highlights && collapsible.widget) {
|
if (wctx.highlights && collapsible.widget) {
|
||||||
wctx.highlights->push_back(std::make_pair(
|
wctx.highlights->push_back(std::make_pair(
|
||||||
|
|||||||
@@ -325,7 +325,8 @@ not_null<Ui::RpWidget*> AddInnerToggle(not_null<Ui::VerticalLayout*> container,
|
|||||||
CollapsibleToggleResult AddCollapsibleToggle(not_null<Ui::VerticalLayout*> container,
|
CollapsibleToggleResult AddCollapsibleToggle(not_null<Ui::VerticalLayout*> container,
|
||||||
rpl::producer<QString> title,
|
rpl::producer<QString> title,
|
||||||
std::vector<NestedEntry> checkboxes,
|
std::vector<NestedEntry> checkboxes,
|
||||||
bool toggledWhenAll) {
|
bool toggledWhenAll,
|
||||||
|
QString description) {
|
||||||
struct CheckboxEntry {
|
struct CheckboxEntry {
|
||||||
not_null<Ui::AbstractCheckView*> checkView;
|
not_null<Ui::AbstractCheckView*> checkView;
|
||||||
Ui::Checkbox *checkbox = nullptr;
|
Ui::Checkbox *checkbox = nullptr;
|
||||||
@@ -417,12 +418,6 @@ CollapsibleToggleResult AddCollapsibleToggle(not_null<Ui::VerticalLayout*> conta
|
|||||||
anim::type::normal);
|
anim::type::normal);
|
||||||
});
|
});
|
||||||
|
|
||||||
checkView->checkedChanges(
|
|
||||||
) | on_next([=](bool checked)
|
|
||||||
{
|
|
||||||
},
|
|
||||||
verticalLayout->lifetime());
|
|
||||||
|
|
||||||
checkView->checkedValue(
|
checkView->checkedValue(
|
||||||
) | on_next([=](bool enabled)
|
) | on_next([=](bool enabled)
|
||||||
{
|
{
|
||||||
@@ -440,6 +435,11 @@ CollapsibleToggleResult AddCollapsibleToggle(not_null<Ui::VerticalLayout*> conta
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (!description.isEmpty()) {
|
||||||
|
Ui::AddDividerText(verticalLayout, rpl::single(std::move(description)));
|
||||||
|
Ui::AddSkip(verticalLayout);
|
||||||
|
}
|
||||||
|
|
||||||
// Apply initial lock visuals.
|
// Apply initial lock visuals.
|
||||||
for (auto i = 0u; i < cState->entries.size(); ++i) {
|
for (auto i = 0u; i < cState->entries.size(); ++i) {
|
||||||
const auto &entry = cState->checkboxes[i];
|
const auto &entry = cState->checkboxes[i];
|
||||||
|
|||||||
@@ -51,7 +51,8 @@ struct CollapsibleToggleResult {
|
|||||||
CollapsibleToggleResult AddCollapsibleToggle(not_null<Ui::VerticalLayout*> container,
|
CollapsibleToggleResult AddCollapsibleToggle(not_null<Ui::VerticalLayout*> container,
|
||||||
rpl::producer<QString> title,
|
rpl::producer<QString> title,
|
||||||
std::vector<NestedEntry> checkboxes,
|
std::vector<NestedEntry> checkboxes,
|
||||||
bool toggledWhenAll);
|
bool toggledWhenAll,
|
||||||
|
QString description = QString());
|
||||||
|
|
||||||
void AddChooseButtonWithIconAndRightTextInner(not_null<Ui::VerticalLayout*> container,
|
void AddChooseButtonWithIconAndRightTextInner(not_null<Ui::VerticalLayout*> container,
|
||||||
not_null<Window::SessionController*> controller,
|
not_null<Window::SessionController*> controller,
|
||||||
|
|||||||
Reference in New Issue
Block a user