Skip to content

Commit

Permalink
Expose drag cursor option
Browse files Browse the repository at this point in the history
  • Loading branch information
joeraz committed Nov 10, 2024
1 parent 91b1ba9 commit 673cb84
Show file tree
Hide file tree
Showing 8 changed files with 38 additions and 6 deletions.
5 changes: 4 additions & 1 deletion po/de_pysol.po
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ msgstr ""
"Project-Id-Version: PySol 0.0.1\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2021-12-10 10:19-0500\n"
"PO-Revision-Date: 2024-10-29 20:05-0400\n"
"PO-Revision-Date: 2024-11-10 18:26-0500\n"
"Last-Translator: H. Schaekel <[email protected]>\n"
"Language-Team: German\n"
"Language: de\n"
Expand Down Expand Up @@ -5452,6 +5452,9 @@ msgstr ""
msgid "&Sticky mouse"
msgstr ""

msgid "D&rag cards cursor"
msgstr ""

#: pysollib/ui/tktile/menubar.py:610
msgid "Use mouse for undo/redo"
msgstr ""
Expand Down
5 changes: 4 additions & 1 deletion po/fr_pysol.po
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ msgstr ""
"Project-Id-Version: 1.02\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2021-12-10 10:19-0500\n"
"PO-Revision-Date: 2024-10-29 20:06-0400\n"
"PO-Revision-Date: 2024-11-10 18:25-0500\n"
"Last-Translator: Eric Rausch <[email protected]>\n"
"Language-Team: French\n"
"Language: fr\n"
Expand Down Expand Up @@ -5498,6 +5498,9 @@ msgstr "&Pointer/Cliquer"
msgid "&Sticky mouse"
msgstr "&Sélection"

msgid "D&rag cards cursor"
msgstr ""

#: pysollib/ui/tktile/menubar.py:610
msgid "Use mouse for undo/redo"
msgstr "Souris pour annuler/répéter"
Expand Down
5 changes: 4 additions & 1 deletion po/it_pysol.po
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ msgstr ""
"Project-Id-Version: it_pysol\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2021-12-10 10:19-0500\n"
"PO-Revision-Date: 2024-10-29 20:06-0400\n"
"PO-Revision-Date: 2024-11-10 18:25-0500\n"
"Last-Translator: Giuliano Colla <[email protected]>\n"
"Language-Team: Italiano <[email protected]>\n"
"Language: it\n"
Expand Down Expand Up @@ -5563,6 +5563,9 @@ msgstr "&Punta e clicca"
msgid "&Sticky mouse"
msgstr "Mouse &appiccicoso"

msgid "D&rag cards cursor"
msgstr ""

#: pysollib/ui/tktile/menubar.py:610
msgid "Use mouse for undo/redo"
msgstr "Usa il mouse per annulla/ripristina"
Expand Down
5 changes: 4 additions & 1 deletion po/pl_pysol.po
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ msgstr ""
"Project-Id-Version: PySolFC\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2021-12-10 10:19-0500\n"
"PO-Revision-Date: 2024-10-29 20:06-0400\n"
"PO-Revision-Date: 2024-11-10 18:25-0500\n"
"Last-Translator: Jerzy Trzeciak <[email protected]>\n"
"Language-Team: Polish <[email protected]>\n"
"Language: pl\n"
Expand Down Expand Up @@ -5514,6 +5514,9 @@ msgstr "Wskaż i kliknij"
msgid "&Sticky mouse"
msgstr "Lepka my&sz"

msgid "D&rag cards cursor"
msgstr ""

#: pysollib/ui/tktile/menubar.py:610
msgid "Use mouse for undo/redo"
msgstr "Użyj myszy do cofania/powtarzania"
Expand Down
5 changes: 4 additions & 1 deletion po/pt_BR_pysol.po
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ msgstr ""
"Project-Id-Version: \n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2021-12-10 10:19-0500\n"
"PO-Revision-Date: 2024-10-29 20:07-0400\n"
"PO-Revision-Date: 2024-11-10 18:26-0500\n"
"Last-Translator: Matheus Knack <[email protected]>\n"
"Language-Team: \n"
"Language: pt_BR\n"
Expand Down Expand Up @@ -5520,6 +5520,9 @@ msgstr "&Aponar-e-Clicar"
msgid "&Sticky mouse"
msgstr "&Seleção"

msgid "D&rag cards cursor"
msgstr ""

#: pysollib/ui/tktile/menubar.py:610
msgid "Use mouse for undo/redo"
msgstr "Use mouse para desfazer/refazer"
Expand Down
3 changes: 3 additions & 0 deletions po/pysol.pot
Original file line number Diff line number Diff line change
Expand Up @@ -5246,6 +5246,9 @@ msgstr ""
msgid "&Sticky mouse"
msgstr ""

msgid "D&rag cards cursor"
msgstr ""

#: pysollib/ui/tktile/menubar.py:610
msgid "Use mouse for undo/redo"
msgstr ""
Expand Down
5 changes: 4 additions & 1 deletion po/ru_pysol.po
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ msgstr ""
"Project-Id-Version: \n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2021-12-10 10:19-0500\n"
"PO-Revision-Date: 2024-10-29 20:07-0400\n"
"PO-Revision-Date: 2024-11-10 18:24-0500\n"
"Last-Translator: Skomoroh <[email protected]>\n"
"Language-Team: Russian <[email protected]>\n"
"Language: ru\n"
Expand Down Expand Up @@ -5588,6 +5588,9 @@ msgstr ""
msgid "&Sticky mouse"
msgstr "&Липкая мышь"

msgid "D&rag cards cursor"
msgstr ""

#: pysollib/ui/tktile/menubar.py:610
msgid "Use mouse for undo/redo"
msgstr "Использовать мышь для отмены/повтора"
Expand Down
11 changes: 11 additions & 0 deletions pysollib/ui/tktile/menubar.py
Original file line number Diff line number Diff line change
Expand Up @@ -348,6 +348,7 @@ def _createTkOpt(self):
tree_icon_style=tkinter.StringVar(),
mouse_type=tkinter.StringVar(),
mouse_undo=tkinter.BooleanVar(),
mouse_dragcursor=tkinter.BooleanVar(),
negative_bottom=tkinter.BooleanVar(),
pause=tkinter.BooleanVar(),
theme=tkinter.StringVar(),
Expand Down Expand Up @@ -422,6 +423,7 @@ def _setOptions(self):
tkopt.splashscreen.set(opt.splashscreen)
tkopt.mouse_type.set(opt.mouse_type)
tkopt.mouse_undo.set(opt.mouse_undo)
tkopt.mouse_dragcursor.set(opt.dragcursor)
tkopt.negative_bottom.set(opt.negative_bottom)
for w in TOOLBAR_BUTTONS:
tkopt.toolbar_vars[w].set(opt.toolbar_vars.get(w, False))
Expand Down Expand Up @@ -851,6 +853,10 @@ def _createMenubar(self):
value='sticky-mouse',
command=self.mOptMouseType)
submenu.add_separator()
submenu.add_checkbutton(
label=n_("D&rag cards cursor"),
variable=self.tkopt.mouse_dragcursor,
command=self.mOptMouseDragCursor)
submenu.add_checkbutton(
label=n_("Use mouse for undo/redo"),
variable=self.tkopt.mouse_undo,
Expand Down Expand Up @@ -2013,6 +2019,11 @@ def mOptMouseType(self, *event):
return
self.app.opt.mouse_type = self.tkopt.mouse_type.get()

def mOptMouseDragCursor(self, *event):
if self._cancelDrag(break_pause=False):
return
self.app.opt.dragcursor = self.tkopt.mouse_dragcursor.get()

def mOptMouseUndo(self, *event):
if self._cancelDrag(break_pause=False):
return
Expand Down

0 comments on commit 673cb84

Please sign in to comment.