Hello all, I have my own search function and it’s a sidebar tab. I’m trying to hijack the ctrl-shift-f shortcut to
- Change to the tab
- Delete it’s contents
- Activate (focus) the edit-text
Here’s what I’m trying to do:
<$action-setfield $tiddler="$:/state/tab/sidebar--595412856" $value="$:/organizer/tabs/search"/>
<$action-setfield $tiddler="$:/temp/mysearch" $value=""/>
<$action-sendmessage $message="tm-focus-selector" $param=".edit-search"/>
It’s the focus piece that doesn’t work. If I do it again the focus works (after already on the right tab). So it’s not broken code, just not running sequentially? I thought the issue would be solved by modifying it per https://tiddlywiki.com/#ActionWidget%20Execution%20Modes using
\define tv-action-refresh-policy() always
… but it seems to be something else.