On 18.05.2017 20:24, Kostas Michalopoulos via Lazarus wrote: > Yes the new code works perfectly fine here and is a better solution. My > original thought was to use pure Gtk but i forgot about gdk_ and only > looked for something like gtk_window_get_state - which i couldn't find :-). Thanks for feedback :) zeljko