Does thread #2 have access to CCoeEnv of thread #1
| Wed, 2003-05-07 18:25 | |
|
I have an app with a UI that creates another thread (#2). Thread #2 has no UI, but needs to have access to the process' CCoeEnv object. Calling CCoeEnv::Static() in thread #2 gives me an invalid environment. Any attempt to use the CCoeEnv object returned, results in a GPF (emulator).
My question is: Can thread #2 use thread #1's CCoeEnv if I pass #2 the pointer to #1's object as a parameter to the RThread::Create() function? I'm going to begin writing the code for it but if somebody can tell me I'm wasting my time, please do |
|






Forum posts: 37
ouseka
You can try passing the CCoeEnv pointer from the app thread to the second thread on creation and see if it is usuable. There may be some issues, but worth a try.
Forum posts: 3
I also tried to create a new CCoeEnv object in the second thread and it appears to work (at least the limited number of functions that I use), but when I delete it, I get an ALLOC: xxxxxxxx error. I even tried calling DestroyEnvironment() on it before deleting it but no help.
Forum posts: 723
Gabor Torok
Software architect, Agil Eight (http://www.agileight.com/)
Blog: http://mobile-thoughts.blogspot.com/