Overview
Examples
Screenshots
Comparisons
Applications
Download
Documentation
Tutorials
Bazaar
Status & Roadmap
FAQ
Authors & License
Forums
Funding Ultimate++
Search on this site
Search in forums












SourceForge.net Logo
Home » U++ Library support » U++ Library : Other (not classified elsewhere) » bug with displayPopUp with MT
bug with displayPopUp with MT [message #22755] Tue, 11 August 2009 16:32 Go to next message
cocob is currently offline  cocob
Messages: 156
Registered: January 2008
Experienced Member
I have some problems with my multithreaded app.

It seems to be related with tooltips when somes Ctrl are not totally initialized by the other thread.

For the moment i have solved my problems (crashs) with this fix.

LabelBase.cpp line 449:

void DisplayPopup::Paint(Draw& w)
{
	Rect r = GetSize();
	w.DrawRect(r, SColorPaper);
	if(display) display->PaintBackground(w, r, value, ink, paper, style);
	r.left += margin;
	if(display) display->Paint(w, r, value, ink, paper, style);
}
Re: bug with displayPopUp with MT [message #22758 is a reply to message #22755] Tue, 11 August 2009 19:38 Go to previous messageGo to next message
mirek is currently offline  mirek
Messages: 13975
Registered: November 2005
Ultimate Member
cocob wrote on Tue, 11 August 2009 10:32

I have some problems with my multithreaded app.

It seems to be related with tooltips when somes Ctrl are not totally initialized by the other thread.

For the moment i have solved my problems (crashs) with this fix.

LabelBase.cpp line 449:

void DisplayPopup::Paint(Draw& w)
{
	Rect r = GetSize();
	w.DrawRect(r, SColorPaper);
	if(display) display->PaintBackground(w, r, value, ink, paper, style);
	r.left += margin;
	if(display) display->Paint(w, r, value, ink, paper, style);
}



Do you conform to synchronization rules?

Any Ctrl related operation needs GuiLock, are you aware about that?

Mirek
Re: bug with displayPopUp with MT [message #22762 is a reply to message #22755] Wed, 12 August 2009 09:13 Go to previous messageGo to next message
cocob is currently offline  cocob
Messages: 156
Registered: January 2008
Experienced Member
Yes i use guilock when it is necessary.

cocob
Re: bug with displayPopUp with MT [message #22765 is a reply to message #22755] Wed, 12 August 2009 10:13 Go to previous messageGo to next message
mirek is currently offline  mirek
Messages: 13975
Registered: November 2005
Ultimate Member
Never mind, problem confirmed, working on it.

Mirek

[Updated on: Wed, 12 August 2009 10:54]

Report message to a moderator

Re: bug with displayPopUp with MT [message #22777 is a reply to message #22765] Thu, 13 August 2009 21:00 Go to previous message
mirek is currently offline  mirek
Messages: 13975
Registered: November 2005
Ultimate Member
Well, this one was hard. It took me 5 hour to figure out what is going on and another 10 hours to fix it.

The basic problem is that MT in Win32 is really stupid and we have to do a lot of uninntuitive workaround to get it working. And in these workarounds, we had bugs...

Anyway, all should be fine now. Please check.

Given the complexity of the issue, I expect to fix more bugs there in the future. But for now, reported issue is solved.

Mirek
Previous Topic: Using openssl functions on U++
Next Topic: Named HTML Colors [FEATURE REQUEST].
Goto Forum:
  


Current Time: Wed Apr 24 22:04:10 CEST 2024

Total time taken to generate the page: 0.01902 seconds