Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7039947
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 28, 20262026-05-28T01:51:34+00:00 2026-05-28T01:51:34+00:00

I am creating a AppWidget that consists of a ImageView that gets filled with

  • 0

I am creating a AppWidget that consists of a ImageView that gets filled with a custom rendered bitmap. This widget is refreshed every minute (using the AlarmManager).

All the rendering and storage is done in the AppWidgetProvider.

Being a good citizen I wanted to minimize CPU usage etc, so I had my Paint objects and other pre-calculated values stored in static fields in the AppWidgetProvider.

However, it turns out that my AppWidget process is very eager to die on me when it’s hanging around with the cool kids doing nothing. I understand this is standard behaviour. However, with it’s tragic death, it also takes my precious statically stored objects with it into the grave, never to be seen again, which is a lot less convenient.

My mourning doesn’t solve anything, so I wonder: is there a way to deal with this? Or is there just no way to do that, and should I fall back to reinitializing everything on every redraw?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-28T01:51:35+00:00Added an answer on May 28, 2026 at 1:51 am

    Not a real solution, but I solved it by not caching all the stuff.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I am creating a appwidget that consists of a single custom view called Foo.
I am creating an AppWidget that allows users to skin the widget and download
I'm having trouble starting a Service to update an AppWidget that I'm creating as
I'm creating an app widget that queries data from a database, and uses a
Creating Traversals for Binary Search Tree with Recursion. void inOrder(void (*inOrderPtr)(T&)) { if(this->left !=
Creating liquid layouts is an immense pain. Now, I totally understand that tables should
(creating a separate question after comments on this: Javascript redeclared global variable overrides old
I'm creating both an appWidget container and appWidgets. I have a problem which I
I'm creating an appwidget, where the user should be able to configure it before
Creating a calculator-like dialog, I noticed that quickly clicking on a button in IE

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.