Navigation

    mono community

    Mono

    • Login
    • Search
    • Categories
    • Recent
    • Popular
    • Search
    1. Home
    2. Jeff
    J
    • Chat with Jeff
    • Profile
    • Following
    • Followers
    • Topics
    • Posts
    • Best
    • Groups

    Jeff

    @Jeff

    0
    Reputation
    1
    Posts
    311
    Profile views
    0
    Followers
    0
    Following
    Joined Last Online

    Jeff Follow

    Posts made by Jeff

    • Persistance, and waking from sleep

      The boilerplate code which is generated from monomake generates:

      <code>
      void AppController::monoWakeFromSleep()
      {
      // Due to a software bug in the wake-up routines, we need to reset here!
      // If not, Mono will go into an infinite loop!
      mono::IApplicationContext::SoftwareResetToApplication();
      // We never reach this point in the code, CPU has reset!
      //
      // (Normally) after sleep, the screen memory has been cleared - tell the label to
      // draw itself again
      helloLabel.scheduleRepaint();
      }
      </code>

      ...so, since a reset is performed, why even have code after the reset? Wouldn't it be more accurate (and less confusing) to just have:

      <code>
      void AppController::monoWakeFromSleep()
      {
      // Due to a software bug in the wake-up routines, we need to reset here!
      // If not, Mono will go into an infinite loop!
      mono::IApplicationContext::SoftwareResetToApplication();
      // We never reach this point in the code, CPU has reset!
      }
      </code>

      OK, onto the real issue... I don't want to perform a reset when the wake button is pressed, and I want to persist some data. Is there a way to do this?

      posted in General Discussion
      J
      Jeff