From b4ee29873d1a59ed46fd803ae210359e35643bfb Mon Sep 17 00:00:00 2001
From: Julian Stiller <julian.stiller@avanquest.com>
Date: Sun, 13 Apr 2025 17:21:16 +0200
Subject: [PATCH] feat: resize target window to some defaults for now

---
 ndrop | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/ndrop b/ndrop
index 5a010ac..16e474c 100755
--- a/ndrop
+++ b/ndrop
@@ -239,6 +239,7 @@ if [[ -n ${WINDOW_ID} ]]; then
       fi
       niri msg action move-window-to-workspace --window-id "${WINDOW_ID}" "${ACTIVE_WORKSPACE}"
       niri msg action focus-window --id "${WINDOW_ID}"
+      niri msg action set-window-width 90% && niri msg action set-window-height 70%
       exit 0
     fi
   fi
@@ -251,6 +252,7 @@ else
   else
     # shellcheck disable=SC2086 # when quoting COMMANDLINE the execution of the command fails
     $COMMANDLINE || notify "ndrop: Error executing given command" "$COMMANDLINE"
+    niri msg action set-window-width 90% && niri msg action set-window-height 70%
   fi
   if $VERBOSE; then notify_low "ndrop: No running program matches class '$CLASS'." "Currently active classes are '$(niri msg --json windows | jq -r '.[] | .app_id' | sort | tr '\n' ' ')'. Executed '$COMMANDLINE' in case it was not running already."; fi
 fi