summarylogtreecommitdiffstats
path: root/clicky_sticker_panel.patch
blob: 119fba17aa7cfb88c7a635fe15dc0231097fd91f (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
Description: open the sticker panel by clicking rather than hovering, disable persistent column
Credits: JuanPotato, novie

diff --git a/Telegram/SourceFiles/chat_helpers/tabbed_panel.cpp b/Telegram/SourceFiles/chat_helpers/tabbed_panel.cpp
index 8fba46c57..c7e9450fd 100644
--- a/Telegram/SourceFiles/chat_helpers/tabbed_panel.cpp
+++ b/Telegram/SourceFiles/chat_helpers/tabbed_panel.cpp
@@ -232,10 +232,12 @@ void TabbedPanel::leaveEventHook(QEvent *e) {
 }
 
 void TabbedPanel::otherEnter() {
+	return;
 	showAnimated();
 }
 
 void TabbedPanel::otherLeave() {
+	return;
 	if (preventAutoHide()) {
 		return;
 	}
diff --git a/Telegram/SourceFiles/history/history_widget.cpp b/Telegram/SourceFiles/history/history_widget.cpp
index a36a76b37..7321ecf9b 100644
--- a/Telegram/SourceFiles/history/history_widget.cpp
+++ b/Telegram/SourceFiles/history/history_widget.cpp
@@ -3924,6 +3924,7 @@ void HistoryWidget::onModerateKeyActivate(int index, bool *outHandled) {
 bool HistoryWidget::pushTabbedSelectorToThirdSection(
 		not_null<PeerData*> peer,
 		const Window::SectionShow &params) {
+	return true;
 	if (!_tabbedPanel) {
 		return true;
 	} else if (!peer->canWrite()) {
@@ -3969,19 +3970,7 @@ void HistoryWidget::toggleTabbedSelectorMode() {
 	if (!_peer) {
 		return;
 	}
-	if (_tabbedPanel) {
-		if (controller()->canShowThirdSection() && !Adaptive::OneColumn()) {
-			Core::App().settings().setTabbedSelectorSectionEnabled(true);
-			Core::App().saveSettingsDelayed();
-			pushTabbedSelectorToThirdSection(
-				_peer,
-				Window::SectionShow::Way::ClearStack);
-		} else {
-			_tabbedPanel->toggleAnimated();
-		}
-	} else {
-		controller()->closeThirdSection();
-	}
+	_tabbedPanel->toggleAnimated();
 }
 
 void HistoryWidget::recountChatWidth() {
diff --git a/Telegram/SourceFiles/history/view/controls/history_view_compose_controls.cpp b/Telegram/SourceFiles/history/view/controls/history_view_compose_controls.cpp
index 7edb1a78e..f93b4deb6 100644
--- a/Telegram/SourceFiles/history/view/controls/history_view_compose_controls.cpp
+++ b/Telegram/SourceFiles/history/view/controls/history_view_compose_controls.cpp
@@ -784,6 +784,7 @@ void ComposeControls::escape() {
 bool ComposeControls::pushTabbedSelectorToThirdSection(
 		not_null<PeerData*> peer,
 		const Window::SectionShow &params) {
+	return true;
 	if (!_tabbedPanel) {
 		return true;
 	//} else if (!_canSendMessages) {
@@ -834,19 +835,7 @@ void ComposeControls::toggleTabbedSelectorMode() {
 	if (!_history) {
 		return;
 	}
-	if (_tabbedPanel) {
-		if (_window->canShowThirdSection() && !Adaptive::OneColumn()) {
-			Core::App().settings().setTabbedSelectorSectionEnabled(true);
-			Core::App().saveSettingsDelayed();
-			pushTabbedSelectorToThirdSection(
-				_history->peer,
-				Window::SectionShow::Way::ClearStack);
-		} else {
-			_tabbedPanel->toggleAnimated();
-		}
-	} else {
-		_window->closeThirdSection();
-	}
+	_tabbedPanel->toggleAnimated();
 }
 
 void ComposeControls::updateHeight() {