Android - Showing Dialog from custom component

Posted by Julian Arz on Stack Overflow See other posts from Stack Overflow or by Julian Arz
Published on 2010-06-15T18:49:15Z Indexed on 2010/06/15 18:52 UTC
Read the original article Hit count: 226

Filed under:

Hi! I am writing a custom component (derived from a relative layout) which has to show a dialog, Is there a way to do this using callbacks like oncreatedialog or onpreparedialog?

if not: if i have to create the dialog outside oncreatedialog, i have to "attach it to an Activity with setOwnerActivity(Activity)". How can the custom component access the activity it is used in, when it is used in the activity's xml-layout and not created from code?

© Stack Overflow or respective owner

Related posts about android