I'm testing an app (on UIQ 2.1, P910) using Lowmem and its throwing WSERV 10
Panic, meaning "Attempted to activate an already active graphics context".
I do have a place in the code where I manually activate the graphics context
to do some offline bitmap construction, but I also deactivate it accordinly,
after having painted the bitmap onto the screen.
To be safer, I totally commented this function (which actually activates the
graphics context) and ran Lowmem with the new sis file, but I still seem to
be getting this WSERV 10 Panic. As usual, the app runs fine during normal
operation. After this panic, lowmem kills all further tests with KErrEof
(-25). Has anyone seen this before.. ?
thanks,
Kishore.
If you don't get any answer from this in the next few days, email me at
[email][email protected][/email] with windows and target version of your app. I may
not be able to help with the WSERV issue, but I should be able to tell you
whats going on with the KErrEof.
Regards
H
"Kishore Raja" <[email protected]> wrote in message
news:Q%23AGpmwiGHA.1760@extapps30...
> I'm testing an app (on UIQ 2.1, P910) using Lowmem and its throwing WSERV
10
> Panic, meaning "Attempted to activate an already active graphics context".
> I do have a place in the code where I manually activate the graphics
context
> to do some offline bitmap construction, but I also deactivate it
accordinly,
> after having painted the bitmap onto the screen.
>
> To be safer, I totally commented this function (which actually activates
the
> graphics context) and ran Lowmem with the new sis file, but I still seem
to
> be getting this WSERV 10 Panic. As usual, the app runs fine during normal
> operation. After this panic, lowmem kills all further tests with KErrEof
> (-25). Has anyone seen this before.. ?
>
> thanks,
> Kishore.
>
>
>
> I'm testing an app (on UIQ 2.1, P910) using Lowmem and its throwing WSERV
> 10 Panic, meaning "Attempted to activate an already active graphics
> context". I do have a place in the code where I manually activate the
> graphics context to do some offline bitmap construction, but I also
> deactivate it accordinly, after having painted the bitmap onto the screen.
Some time ago I implemented an example app that handles pointer events
(including drag) on UIQ2.1, and may leave while handling the drag event.
Also, graphics context was activated in pointer down, drag and up. Thus, if
a leave happened in handling drag, graphics context was left activated and
as the next pointer down occurred, there was WSERV 10 panic.
I solved this so that in pointer events (down event code below), I pushed
the CCoeControl based view object into the cleanupstack using
CleanupClosePushL:
ClaimPointerGrab(ETrue);
SetPointerCapture(ETrue);
ActivateGc();
CleanupClosePushL(*this); // the Close will be called.
The Close in the view was implemented like this:
void CDrawCanvasView::Close()
{
DeactivateGc();
SetPointerCapture(EFalse);
iPointerIsDown = EFalse;
}
Similar code regarding activating the graphics context was implemented in
pointer drag event (without pointer grabbing/capturing). Of course you need
to CleanupStack::Pop if all goes well, not leaving the view on the cleanup
stack.
So now, if a leave happens, the graphics context is deactivated, thus
avoiding the WSERV 10 panic. Is there a possibility that in your code a
similar approach is possible? You said that you do bitmap construction,
which at least could cause a leave in OOM.
-- Antti