Thema: Delphi Bitmap in Thread laden

Einzelnen Beitrag anzeigen

Gruber_Hans_12345

Registriert seit: 14. Aug 2004
1.426 Beiträge
 
Delphi 2007 Professional
 
#10

Re: Bitmap in Thread laden

  Alt 17. Mär 2009, 09:00
Also ich habe das Gefühl, es hat mit irgendwas anderes zu tun hier ...

habe im hautpthread jetzt ein lock eingebaut, das gewartet wird, bis das bild da ist ...
Delphi-Quellcode:
        finally
            LeaveCriticalSection(imgLoader.fCS);

            // Hauptthread blockieren, bis image geladen ist
            sleep(100);
            EnterCriticalSection(imgLoader.fCS);
            LeaveCriticalSection(imgLoader.fCS);

            trCheckLoadImage.Interval := 2000;
            trCheckLoadImage.Enabled := TRUE;
        end;
und es funktioniert auch nicht?
Gruss Hans

2B or not 2B, that is FF
  Mit Zitat antworten Zitat