ErrorHandler of VideoView component

by Matthias » Wed, 21 Apr 2010 15:20:47 GMT


Sponsored Links
 Hi,
I am currently working with a videoview to show live broadcasts. For
this I want to adapt the error messages which are shown by the
videoview component, when an error occures (connection error, video
error etc..).

Is it ist possible to register another error handler to a videoview?

best regards Matthias

--



Other Threads

1. The "life cycle of a static"

When starting a new Activity, I want to pass a complex object and do
so by using this approach:

MyActivity.COMPLEX_OBJ = myComplexObj; // which is definitely NOT
NULL!
Intent intent = new Intent();
intent.setClass(this, MyActivity.class);
startActivity(intent);

and then in MyActivity:

@Override
public void onCreate(Bundle bundle) {
        if (COMPLEX_OBJ == null) {
                // report to Flurry
                ...
        }
        ...
}

When I've tested this on my devices, everything works fine.

However, from Flurry analytics, I see that COMPLEX_OBJ is sometimes
null! But I've checked my code 100 times and can say it is absolutely
not possible that COMPLEX_OBJ is being set with a non null value.

My initial guess was that onCreate() was being called before
startActivity() - is this possible? BTW, the activity is defined in
the Manifest without any intent filters.

Then I found this:

http://developer.android.com/intl/de/guide/appendix/faq/framework.html#3

which says:

"But, the life cycle of a static is not well under your control"

I thought if I set a static field then that will stay set as long as
the VM is alive. Or have a misunderstood something?

-- 

2. Out of Memory resuming application

Hi,

My application uses a single activity to switch between different
views. I premise I'm loading a good amount of bitmaps in one of this
view (say the gamescreen view) constructor but I recycle everything on
the onDetachedFromWindow method. All the Bitmaps are static and most
of them loaded with BitmapFactory.decodeResource method.

Furthermore I'm using a gallery wich content is a simple layout with
eight imagebuttons.

I know all the complications using this widget and all the risks of
using static bitmaps, but, I guess my problem does not entail them
because my application is running well if I try to switch between
these two view (and I've tried to do it about 30 times without
crashes!!!) but when I pause and resume the application two times
(pause->resume->pause->resume) I run out of memory, and often without
the crash message (it just stays on the actual view).

Thanks.

-- 

3. copy protection data loss?

4. How does a singleton behave in different processes

5. Process ID and App Name

6. Google Checkout Finally Arrives in Canada?

7. Setting screens size/scale on big screen devices