#8 Screen update in test and drill

open
nobody
None
3
2010-04-27
2009-08-22
No

The following behavior was seen on a iPhone device with OS version 3.01 and svn 799 (karatasi 1.3 release candidate):
(a) in test and drill, the screen update is sometimes too late: for a moment it shows the previous question or answer after flipping the card, then the new question or answer
(b) sometimes it turns the card too late: for a moment it displays the new backside and then flips the card to show it again.
Behavior (a) was seen also on another device iPodTouch with OS version 3.0 and svn 800 (essentially the same karatasi version).
Behavior (b) was never seen on this second device.
Note: this bug has a long history.
See #2812456 which came up with the upgrade to OS 3.0 but was fixed in svn 733 (rather a workaround than a fix!).
See also #2516318.

Discussion

  • Christa Runge

    Christa Runge - 2009-08-23

    svn 816: prepared some ideas to resolve this.
    Need to test them on both devices (OS 3.0 and OS 3.01).

     
  • Christa Runge

    Christa Runge - 2009-08-24

    Fixed by workaround in svn 818.
    Essentially, it seems to be a race condition, and I have only added some delays to reduce the risk of this race condition (actually, it still happens from time to time!).
    Tracker closed, but moved to "API issues" as the reason seems to be a bug in the OS (or, we have not yet understood how to use it?)
    We want to animate the transition between two UIWebViews. Our implementation worked fine with OS 2.2 but fails since OS 3.0. With OS 2.2, the implementation was as follows:
    - we load the new content to a UIWebView which is not part of the view hierarchy in the window, and wait for the notification 'webViewDidFinishLoad' to the delegate
    - on the notification we begin the animation (flip, cache=YES), remove the old UIWebView and add the new UIWebView, and commit
    Since OS 3.0 this does no longer work. The UIWebView sends the notification, but it seems to update the animation layer not before I add the view to the hierarchy. So the current implementation is a sfollows:
    - load the new content to UIWebView which is not part of the view hierarchy
    - wait for the notification 'webViewDidFinishLoad'
    - add the UIWebView to the view hierarchy (so it starts to update the animation layer), send it to the background (in order to display the content not too early)
    - wait (currently this delay is 55 ms)
    - hope that the animation layer is now updated and start the animation. Remove the UIWebView with previos content and commit.

     
  • Christa Runge

    Christa Runge - 2009-08-24
    • labels: 1165545 -->
    • milestone: 905964 -->
    • status: open --> closed
     
  • Christa Runge

    Christa Runge - 2009-09-27

    Improved in svn 1337 - 1347. Actually, the contentView now gets a setNeedsDisplay message, which seems to help.

     
  • Christa Runge

    Christa Runge - 2009-09-29

    Reopened with low prio, as the behavior is not quite satisfactory. From time to time the card content is shown too early.

     
  • Christa Runge

    Christa Runge - 2009-09-29
    • priority: 5 --> 3
    • status: closed --> open
     
  • Christa Runge

    Christa Runge - 2009-09-30

    svn 1389 seems to be acceptable for the next release, although it is not perfect (in rare cases the new content appears too late). Keep this tracker open.
    Note: The current implementation uses a delay where it should be a notification from the animation layer.

     
  • Christa Runge

    Christa Runge - 2009-10-01

    svn 1389 is not ok. For a while the flip animation is perfect, but then it gets out of synch, it loads the content often too late, and sometimes too early. Once out of synch, this remains until restart of the application. Stop and restart the test / drill does not help, nor close and reopen the database or use another database.
    This seems worse with the iPhone (low memory?).
    Note: it looks as if an unexpected event occurs in the state machine.
    Idea: make the state machine more robust (explicit states).

     
  • Christa Runge

    Christa Runge - 2009-10-01

    Improvement in svn 1392, seems to behave well. Needs to be watched for a longer time in action.
    Note: it is definitely not perfect, sometimes it still shows the content too late - but we hope the best.

     
  • Christa Runge

    Christa Runge - 2009-12-29

    Still an issue with OS 3.1.2

     
  • Christa Runge

    Christa Runge - 2010-04-27
    • assigned_to: ndegendogo --> nobody
     

Log in to post a comment.

Get latest updates about Open Source Projects, Conferences and News.

Sign up for the SourceForge newsletter:





No, thanks