summaryrefslogtreecommitdiff
path: root/index.php
diff options
context:
space:
mode:
authorAndrew Dolgov <[email protected]>2022-02-24 21:07:53 +0300
committerAndrew Dolgov <[email protected]>2022-02-24 21:07:53 +0300
commit806b46d0c41836c7ed23486194c5d29b013639c0 (patch)
treef8f9504595ee127439b9c6a48f72f0f439a3ce57 /index.php
parentbd0af3ae9e27635330c922edaba49a2aedd7ed46 (diff)
* add actions dropdown to toggle combined mode
* hide 'toggle widescreen' menu item when in combined mode * unify some mode toggling code in App
Diffstat (limited to 'index.php')
-rw-r--r--index.php11
1 files changed, 10 insertions, 1 deletions
diff --git a/index.php b/index.php
index 2dbc078cd..37a3253b9 100644
--- a/index.php
+++ b/index.php
@@ -238,6 +238,13 @@
<div dojoType="fox.form.DropDownButton" class="action-button" title="<?= __('Actions...') ?>">
<span><i class="material-icons">menu</i></span>
<div dojoType="dijit.Menu" style="display: none">
+ <script type='dojo/method' event='onOpen' args='evt,a,b,c'>
+ const ws = this.getChildren().find((m) => m.id == 'qmcToggleWidescreen');
+
+ if (ws)
+ ws.attr('hidden', !!App.isCombinedMode());
+ </script>
+
<div dojoType="dijit.MenuItem" onclick="App.onActionSelected('qmcPrefs')"><?= __('Preferences...') ?></div>
<div dojoType="dijit.MenuItem" onclick="App.onActionSelected('qmcSearch')"><?= __('Search...') ?></div>
<div dojoType="dijit.MenuItem" disabled="1"><?= __('Feed actions:') ?></div>
@@ -248,7 +255,9 @@
<div dojoType="dijit.MenuItem" onclick="App.onActionSelected('qmcCatchupAll')"><?= __('Mark as read') ?></div>
<div dojoType="dijit.MenuItem" onclick="App.onActionSelected('qmcShowOnlyUnread')"><?= __('(Un)hide read feeds') ?></div>
<div dojoType="dijit.MenuItem" disabled="1"><?= __('Other actions:') ?></div>
- <div dojoType="dijit.MenuItem" onclick="App.onActionSelected('qmcToggleWidescreen')"><?= __('Toggle widescreen mode') ?></div>
+ <div dojoType="dijit.MenuItem" id="qmcToggleWidescreen" onclick="App.onActionSelected('qmcToggleWidescreen')">
+ <?= __('Toggle widescreen mode') ?></div>
+ <div dojoType="dijit.MenuItem" onclick="App.onActionSelected('qmcToggleCombined')"><?= __('Toggle combined mode') ?></div>
<div dojoType="dijit.MenuItem" onclick="App.onActionSelected('qmcHKhelp')"><?= __('Keyboard shortcuts help') ?></div>
<?php