On 26/07/07, Marc Nürnberger <[EMAIL PROTECTED]> wrote:
Hi there,
first of all thanks for your quick answers.
Geoffrey Spear wrote:
> I don't have a solution for your freezing problem, but you should be
> able to replace "C:/Docume~1/$ENV{'USERNAME'}/Anwendungsdaten" with
> "$ENV{'APPDATA'}" and have it work in any locale.
I could do that, but because of the used glob() function I can't.
Because C:\Documents and Settings\ contains whitespaces which glob()
can't handle (as far as I read everywhere). It would end up with
C:\Documents all the time.
But I need the glob() here to get into the <random_number>.default
Firefox profile folder.
I did something "easier"... I rebuilt the GUI with another button which
opens a file browser. Now I can select the cookie file on my own. ;)
#!perl -w
use strict;
use warnings;
use Win32 qw(CSIDL_APPDATA);
print Win32::GetShortPathName(Win32::GetFolderPath(CSIDL_APPDATA)), "\n";
__END__
That will get what you need, and work for all versions of Win32 from
Win95 through Vista - $ENV{APPDATA} will only work from Win2K(?)
onwards.
Jason Plum wrote:
> This is not a GUI issue per se, as it is the fact that your routine
> runs
> synchronous, in the main thread of the application. To remove this lag
> (and
> the delayed drawing of the window) you will need to do some looking
> through
> the mail archives and find how to write this into a separate thread.
Hmm... i will try to read me into this
Thanks for your help. :)
Looking at your original code, I'm not sure what you think the problem
is. Presumably the delay is while the file is fetched from the remote
site - you leave the GUI up, but it will be non-responsive. If you
just want to dismiss the GUI, then add
$main->Hide()
after your Win32::GUI::Dialog(); line.
Regards,
Rob.