I don't know why but to fix it you should do:

$AnimateWindow->Call($window->{-handle}, $msec, AW_ACTIVATE | AW_CENTER);
$window->InvalidateRect(0);

Bye.

    Luigino Masarati
    OutSys snc

----- Original Message -----
From: "Brewster Rob-RBREWST1" <[EMAIL PROTECTED]>
To: "'Luigino Masarati'" <[EMAIL PROTECTED]>;
<perl-win32-gui-users@lists.sourceforge.net>
Sent: Friday, October 18, 2002 12:46 PM
Subject: RE: [perl-win32-gui-users] Animated windows


> I've been using this code with great success on Windows2000. (Really adds
a
> professional touch to the GUI!).
>
> Now I've added a menu button to my window I get a greyed out background on
> my TextField boxes. I've tried to update the box's colour but only seem to
> be able to update the background of the actual text not the whole box. Any
> ideas?
>
> Rob Brewster.
>
>
>
> # Menu options for GUI
> #=======================================
> $menu = Win32::GUI::MakeMenu(
>     "&Help"   => "Help",
>     " > -"       => 0,
>     " > E&xit"   => "Exit",
>     );
>
>
#===========================================================================
> ====
> # Creates the objects and labels for the GUI window 1
> #
>
#===========================================================================
> ====
> sub create_window1 {
>    # Create window
>    $window = new Win32::GUI::Window(-menu => $menu,
>                                     -title => "Test",
>                                     -pos => [ 100, 100 ],
>                                     -size => [ 500, 400 ],
>                                     -minsize => [ 500, 400],
>                                     -name => "Window",
>                                     );
>
>    $number= $window->AddTextfield (-text  => "(Enter No.)",
>                                    -name => "Number",
>                                    -left => 145,
>                                    -top => 40,
>                                    -height => 20,
>                                    -width => 100,
>                                    );
>
> }
>
>
> sub Window_Terminate {
>     return -1;
> }
>
> # Main function
> #===============================
> create_window1();
>
> $msec = 200;
> $AnimateWindow->Call($window->{-handle}, $msec, AW_ACTIVATE | AW_CENTER);
>
> Win32::GUI::Dialog();


Reply via email to