in reply to Re: Wx::ProgressDialog, please help
in thread Wx::ProgressDialog, please help

That's strange that it works for you.

I just tried yours and I get the same thing. The window is there, but no widgets get drawn until the whole thing is done.

I'm on Wx-0.20 and wxGTK-2.4.2-3.fr on teh lunix, but it also doesn't work right in windows: Wx-0.19 with wxMSW-2.4.2 (binary). I tried both mine and yours in windows a second ago.

However, in windows, it doesn't dork around drawing an empty window, it simply sagfaults and kills perl.exe. The 215789 example does work great in windows and gtk.

So, now I'm guessing that progressdialogs can be made to work without a parent window, but it's flaky and partly luck based?

Replies are listed 'Best First'.
Re^3: Wx::ProgressDialog, please help
by PodMaster (Abbot) on Jul 27, 2004 at 13:12 UTC
    Try this version :)
    package crap; use strict; use warnings; use Wx qw[ wxPD_CAN_ABORT wxPD_APP_MODAL wxPD_ELAPSED_TIME wxPD_EST +IMATED_TIME wxPD_REMAINING_TIME ]; use base qw(Wx::ProgressDialog); sub new { my $class = shift; my $max = shift || 10; my $vars = (wxPD_CAN_ABORT| wxPD_APP_MODAL|wxPD_ELAPSED_TIME| wx +PD_ESTIMATED_TIME| wxPD_REMAINING_TIME); my $this = $class->SUPER::new("xp6 progres ($max)", "the progres +s ($max)", $max, undef, $vars); $this->Show(1); return $this; } my $c = crap->new(); for(0 .. 10){ $c->Update($_,"the progress ($_/10)",); select undef,undef,undef,0.3; }
    BTW - for posterity, I have WXMSW-2.5.2, Wx-0.20 .

    It could be a wxGtk bug, you should ask on the wxper-users list.

    MJD says "you can't just make shit up and expect the computer to know what you mean, retardo!"
    I run a Win32 PPM repository for perl 5.6.x and 5.8.x -- I take requests (README).
    ** The third rule of perl club is a statement of fact: pod is sexy.

      Same thing. It doesn't draw the progress (or anything else) at all until it gets to Update(10) under my .20/2.5.3 GTK install and simply sagfaults under .19/2.5.2 windows install.

      I find it crazy and random that it DOES work for you.

      I wonder if it's my perl version.
      lunix: v5.8.3 built for i686-linux-thread-multi
      winblows: v5.8.3 built for MSWin32-x86-multi-thread

      could be the 5.8.3, could be the threads... What perl version are you using?

      And thanks for your help btw... I will try the list also.

        ActivePerl 5.8.4. I don't think it's 5.8.3 or the threads.

        In your first reply you say Wx-0.19 with wxMSW-2.4.2, but now you say Wx-0.19 with wxMSW-2.5.2, which is it? Did you compile it yourself?

        Its got nothing to do with luck. I think wxGtk2.4 may have a bug, in which case you need to get the 2.5.x version and recompile.

        As for your windows install I think you got some bad binaries, where'd you get'em?

        I hope you contact the list, Good luck

        MJD says "you can't just make shit up and expect the computer to know what you mean, retardo!"
        I run a Win32 PPM repository for perl 5.6.x and 5.8.x -- I take requests (README).
        ** The third rule of perl club is a statement of fact: pod is sexy.