Re: [Interest] Signal with QString argument from another thread.

2015-10-07 Thread Matthew Woehlke
On 2015-10-06 16:42, Igor Mironchik wrote: > But I had next experience. QImage is implicitly shared too. But I had > following issue: > > I had a signal like this > > void mySignal( QImage ); > > and when I tried to use this image in the slot in another thread (queued > connection was used) im

Re: [Interest] Signal with QString argument from another thread.

2015-10-06 Thread Thiago Macieira
On Tuesday 06 October 2015 23:54:30 Igor Mironchik wrote: > > And QString, like other Qt value classes, should be treated like an int. > > You're not asking that question about an int argument, so you shouldn't > > have to ask about a QString argument. > > Not sure that I understood you correctly.

Re: [Interest] Signal with QString argument from another thread.

2015-10-06 Thread Thiago Macieira
On Tuesday 06 October 2015 23:42:55 Igor Mironchik wrote: > This problem occurs on Windows Surface only ( Qt 5.4.2 ). > > What is the problem in this situation? Probably a bug. -- Thiago Macieira - thiago.macieira (AT) intel.com Software Architect - Intel Open Source Technology Center ___

Re: [Interest] Signal with QString argument from another thread.

2015-10-06 Thread Igor Mironchik
On 06.10.2015 23:24, Thiago Macieira wrote: > On Tuesday 06 October 2015 19:43:03 Igor Mironchik wrote: >> Hi guys, >> >> Is it safe to use QString argument in queued slot when signal emitted >> from another thread? >> >> void mySignal( QString arg ); >> void mySlot( QString arg ); > Yes. All arg

Re: [Interest] Signal with QString argument from another thread.

2015-10-06 Thread Igor Mironchik
Hi. Thank you for yours explanations. But I had next experience. QImage is implicitly shared too. But I had following issue: I had a signal like this void mySignal( QImage ); and when I tried to use this image in the slot in another thread (queued connection was used) image was corrupted. An

Re: [Interest] Signal with QString argument from another thread.

2015-10-06 Thread Thiago Macieira
On Tuesday 06 October 2015 19:43:03 Igor Mironchik wrote: > Hi guys, > > Is it safe to use QString argument in queued slot when signal emitted > from another thread? > > void mySignal( QString arg ); > void mySlot( QString arg ); Yes. All arguments passed by value or by const-ref are copied into