mirror of
https://github.com/ankitects/anki.git
synced 2025-09-19 14:32:22 -04:00
Remove preview button from browser.py top bar
This commit is contained in:
parent
ece753991e
commit
28278fcc40
3 changed files with 2 additions and 22 deletions
|
@ -622,12 +622,6 @@ class Browser(QMainWindow):
|
||||||
# pylint: disable=unnecessary-lambda
|
# pylint: disable=unnecessary-lambda
|
||||||
# actions
|
# actions
|
||||||
f = self.form
|
f = self.form
|
||||||
qconnect(f.previewButton.clicked, self.onTogglePreview)
|
|
||||||
f.previewButton.setToolTip(
|
|
||||||
tr(TR.BROWSING_PREVIEW_SELECTED_CARD, val=shortcut("Ctrl+Shift+P"))
|
|
||||||
)
|
|
||||||
f.previewButton.setShortcut("Ctrl+Shift+P")
|
|
||||||
|
|
||||||
qconnect(f.filter.clicked, self.onFilterButton)
|
qconnect(f.filter.clicked, self.onFilterButton)
|
||||||
# edit
|
# edit
|
||||||
qconnect(f.actionUndo.triggered, self.mw.onUndo)
|
qconnect(f.actionUndo.triggered, self.mw.onUndo)
|
||||||
|
@ -877,8 +871,8 @@ QTableView {{ gridline-color: {grid} }}
|
||||||
None,
|
None,
|
||||||
"preview",
|
"preview",
|
||||||
lambda _editor: self.onTogglePreview(),
|
lambda _editor: self.onTogglePreview(),
|
||||||
"Preview Selected Card",
|
tr(TR.BROWSING_PREVIEW_SELECTED_CARD, val=shortcut("Ctrl+Shift+P")),
|
||||||
"Preview",
|
tr(TR.ACTIONS_PREVIEW),
|
||||||
id="previewButton",
|
id="previewButton",
|
||||||
disables=False,
|
disables=False,
|
||||||
rightside=False,
|
rightside=False,
|
||||||
|
|
|
@ -114,19 +114,6 @@
|
||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item row="0" column="3">
|
|
||||||
<widget class="QPushButton" name="previewButton">
|
|
||||||
<property name="text">
|
|
||||||
<string>ACTIONS_PREVIEW</string>
|
|
||||||
</property>
|
|
||||||
<property name="shortcut">
|
|
||||||
<string notr="true">Ctrl+Shift+P</string>
|
|
||||||
</property>
|
|
||||||
<property name="checkable">
|
|
||||||
<bool>true</bool>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="0" column="0">
|
<item row="0" column="0">
|
||||||
<widget class="QPushButton" name="filter">
|
<widget class="QPushButton" name="filter">
|
||||||
<property name="text">
|
<property name="text">
|
||||||
|
|
|
@ -307,7 +307,6 @@ class BrowserPreviewer(MultiCardPreviewer):
|
||||||
|
|
||||||
def _on_finished(self, ok):
|
def _on_finished(self, ok):
|
||||||
super()._on_finished(ok)
|
super()._on_finished(ok)
|
||||||
self._parent.form.previewButton.setChecked(False)
|
|
||||||
|
|
||||||
def _on_prev_card(self):
|
def _on_prev_card(self):
|
||||||
self._parent.editor.saveNow(
|
self._parent.editor.saveNow(
|
||||||
|
|
Loading…
Reference in a new issue