#! /bin/bash
#Translated for Russian by Pro and vkvkvk.
export delete_box="
<window title=\"Pschedule - планировщик заданий\">
 <vbox>
  <frame  Удаление >
   <pixmap icon_size=\"6\"><input file stock=\"gtk-clear\"></input></pixmap>
   <text use-markup=\"true\"><label>\"<b>Удалить выбранное задание?</b>\"</label></text>
  </frame>
  <hbox>
   <button>
    <input file icon=\"gtk-no\"></input>
    <label>Нет</label>
    <action type=\"exit\">no</action>
   </button>
   <button>
    <input file icon=\"gtk-yes\"></input>
    <label>Да</label>
    <action type=\"exit\">yes</action>
   </button>
  </hbox>
 </vbox>
</window>"
I=$IFS; IFS=""
for STATEMENTS in  $(gtkdialog3 --program=delete_box --center); do
	eval $STATEMENTS
done
IFS=$I
if [ "$EXIT" = "yes" ]; then
	TMP=`echo "$TREE" | cut -d " " -f 6-`
	cat /var/spool/cron/crontabs/$USER | grep -wv "$TMP" | grep -v "^$" > /var/spool/cron/crontabs/$USER
	killall -q crond; crond #restart cron
fi
