mirror of
https://github.com/telegramdesktop/tdesktop
synced 2025-09-01 06:55:58 +00:00
global shortcuts with loading from .json map
This commit is contained in:
@@ -517,7 +517,7 @@ bool MainWidget::onShareUrl(const PeerId &peer, const QString &url, const QStrin
|
||||
}
|
||||
History *h = App::history(peer);
|
||||
h->setMsgDraft(new HistoryDraft(url + '\n' + text, 0, MessageCursor(url.size() + 1, url.size() + 1 + text.size(), QFIXED_MAX), false));
|
||||
h->setEditDraft(Nil);
|
||||
h->setEditDraft(nullptr);
|
||||
bool opened = history.peer() && (history.peer()->id == peer);
|
||||
if (opened) {
|
||||
history.applyDraft();
|
||||
@@ -812,6 +812,18 @@ void MainWidget::notify_automaticLoadSettingsChangedGif() {
|
||||
history.notify_automaticLoadSettingsChangedGif();
|
||||
}
|
||||
|
||||
void MainWidget::cmd_search() {
|
||||
history.cmd_search();
|
||||
}
|
||||
|
||||
void MainWidget::cmd_next_chat() {
|
||||
history.cmd_next_chat();
|
||||
}
|
||||
|
||||
void MainWidget::cmd_previous_chat() {
|
||||
history.cmd_previous_chat();
|
||||
}
|
||||
|
||||
void MainWidget::notify_historyItemResized(const HistoryItem *item, bool scrollToIt) {
|
||||
if (!item || ((history.peer() == item->history()->peer || (history.peer() && history.peer() == item->history()->peer->migrateTo())) && !item->detached())) {
|
||||
history.notify_historyItemResized(item, scrollToIt);
|
||||
|
Reference in New Issue
Block a user