Flip to ctrl-l to pop out search/list

symbol_search
Tyler Goodlet 2021-05-14 08:25:32 -04:00
parent 51c61587d2
commit 25dbe60c77
2 changed files with 7 additions and 4 deletions

View File

@ -724,7 +724,7 @@ class ChartView(ViewBox):
self._key_active = False
def keyPressEvent(self, ev):
def keyPressEvent(self, ev: QtCore.QEvent) -> None:
"""
This routine should capture key presses in the current view box.
@ -759,10 +759,10 @@ class ChartView(ViewBox):
if mods == QtCore.Qt.AltModifier:
pass
# ctlr-k
if key == QtCore.Qt.Key_K and ctrl:
# ctlr-l for "lookup" -> open search / lists
if ctrl and key == QtCore.Qt.Key_L:
search = self._chart._lc.chart_space.search
search.focus()
search.bar.focus()
# esc
if key == QtCore.Qt.Key_Escape or (ctrl and key == QtCore.Qt.Key_C):
@ -809,5 +809,6 @@ class ChartView(ViewBox):
# elif ev.key() == QtCore.Qt.Key_Backspace:
# self.scaleHistory(len(self.axHistory))
else:
# maybe propagate to parent widget
ev.ignore()
self._key_active = False

View File

@ -402,7 +402,9 @@ async def start_order_mode(
# each clearing tick is responded individually
elif resp in ('broker_filled',):
action = msg['action']
# TODO: some kinda progress system
order_mode.on_fill(
oid,