diff --git a/ndrop b/ndrop index 2199082..5a010ac 100755 --- a/ndrop +++ b/ndrop @@ -155,8 +155,8 @@ CLASS="$1" COMMANDLINE="${*:1}" ACTIVE_WORKSPACE=$(active_workspace) ACTIVE_WORKSPACE_ID=$(niri msg --json workspaces | jq -r ".[] | select(.is_focused==true) | .id") -ACTIVE_OUTPUT=$(niri msg --json focused-output | jq -r ".name") -NDROP_OUTPUT=$(niri msg --json workspaces | jq -r ".[] | select(.name==\"ndrop\") | .output") +# ACTIVE_OUTPUT=$(niri msg --json focused-output | jq -r ".name") +# NDROP_OUTPUT=$(niri msg --json workspaces | jq -r ".[] | select(.name==\"ndrop\") | .output") case "$1" in epiphany) @@ -225,6 +225,7 @@ if [[ -n ${WINDOW_ID} ]]; then notify_low "ndrop: Matched focused target on active ws '${ACTIVE_WORKSPACE}'; move target to 'ndrop'" fi niri msg action move-window-to-workspace --window-id "${WINDOW_ID}" "ndrop" + niri msg action focus-workspace-previous # For good multi-monitor support, we need something like this in niri. # if [[ "$ACTIVE_OUTPUT" != "$NDROP_OUTPUT" ]]; then # niri msg action focus-monitor "${ACTIVE_OUTPUT}"