#!/bin/sh
[ ! -s $HOME/.jwm/corners/lefttop ] && exit
set -a

start (){
	#delay to see if user really wants to activate corner app
	sleep 0.4
	#get mouseposition
	[ `getcurpos | cut -d' ' -f1` -gt 10 ] && exit
	[ `getcurpos | cut -d' ' -f2` -gt 10 ] && exit
	#execute user-defined command
	$HOME/.jwm/corners/lefttop
}

export Corner_LeftTop='
<window width-request="2" height-request="2">
 <text><label>""</label></text>
 <action signal="enter-notify-event">start</action>
</window>'
gtkdialog -p Corner_LeftTop --name=cornerlefttop
