Le Lundi 11 Septembre 2006 12:31, Jean-Pierre Vidal a écrit :
> Le Lundi 11 Septembre 2006 01:41, Slaven Rezic a écrit :
[...]
> > It seems to me that you need to ensure that the position of the mouse
> > pointer for the test. One solution would be using cursor warp or
> > Tk::CursorControl, or maybe by using a global grab, or just stretch
> > the test window to the whole screen.
> 
> Thanks for help, Slaven. I can reproduce failure now.

I think it is not the good ng to discuss this (ptk group would be better?). In 
case you are interested, there is my solution:

The failure always appears at test #67; at this point I simulate a key 
press, obviously addressed to the window focused:

        $mw->eventGenerate('<Shift_L>');

I think I forgot to give anyway the focus to the main window.
I tryed this:

        $mw->focusForce;
        $mw->eventGenerate('<Shift_L>');

This works even if the window loose the focus... except on a manual desktop 
change (e.g. on linux). I found this workaround:

        if ($mw->ismapped) {
                $mw->focusForce;
                $mw->eventGenerate('<Shift_L>');
        ...             
        }
        else {
                print "some tests skipped... main window is not mapped\n";
        }


I will upload a new version on CPAN soon.
Thank you again for help.
Regards,

Jean-Pierre Vidal

Reply via email to