Why super.onDestroy() in java - Android goes on top in destructors? -


i new in java development! may tell me... according logic super.ondestroy(); in destructors goes on top? example:

protected void ondestroy() {             super.ondestroy();     releasemediaplayer(); } 

and not

protected void ondestroy() {             releasemediaplayer();     super.ondestroy(); } 

like c++, obj-c, pascal, etc ??

it depends on want in ondestroy. super.ondestroy (in order):

  • dismiss dialogs activity managing.
  • close cursors activity managing.
  • close open search dialog

if logic put inside ondestroy has 3 things android does, may have worry order. otherwise, , in of cases, not matter.


Comments

Popular posts from this blog

c# - Binding a comma separated list to a List<int> in asp.net web api -

Delphi 7 and decode UTF-8 base64 -

html - Is there any way to exclude a single element from the style? (Bootstrap) -