Re: [android-developers] Dynamically including a custom view defined in another app

2011-03-10 Thread Mark Murphy
On Thu, Mar 10, 2011 at 11:44 AM, Mark Carter mjc1...@googlemail.com wrote:
 Suppose I have one app who's functionality can be accessed entirely through
 a single custom view (which does not take up the whole screen, because it
 needs to be displayed with something else).
 Now suppose I have another app which wants to be able to show that custom
 view within one of its own activities.  Both apps are mine.
 What is the best way to do this?

You can't. At best, you can load resources from the other app, but not
Java code.

 Would Fragments be a possibility for this?

No, sorry.

-- 
Mark Murphy (a Commons Guy)
http://commonsware.com | http://github.com/commonsguy
http://commonsware.com/blog | http://twitter.com/commonsguy

Android Training Worldwide: http://commonsware.com/training

-- 
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en


Re: [android-developers] Dynamically including a custom view defined in another app

2011-03-10 Thread Mark Carter
How about TabActivity? Doesn't that do something similar to what I'm talking
about (i.e. using a portion of the screen to show something
created/controlled by (potentially) another app)?

On 11 March 2011 00:25, Mark Murphy mmur...@commonsware.com wrote:

 On Thu, Mar 10, 2011 at 11:44 AM, Mark Carter mjc1...@googlemail.com
 wrote:
  Suppose I have one app who's functionality can be accessed entirely
 through
  a single custom view (which does not take up the whole screen, because it
  needs to be displayed with something else).
  Now suppose I have another app which wants to be able to show that custom
  view within one of its own activities.  Both apps are mine.
  What is the best way to do this?

 You can't. At best, you can load resources from the other app, but not
 Java code.

  Would Fragments be a possibility for this?

 No, sorry.

 --
 Mark Murphy (a Commons Guy)
 http://commonsware.com | http://github.com/commonsguy
 http://commonsware.com/blog | http://twitter.com/commonsguy

 Android Training Worldwide: http://commonsware.com/training

 --
 You received this message because you are subscribed to the Google
 Groups Android Developers group.
 To post to this group, send email to android-developers@googlegroups.com
 To unsubscribe from this group, send email to
 android-developers+unsubscr...@googlegroups.com
 For more options, visit this group at
 http://groups.google.com/group/android-developers?hl=en


-- 
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Re: [android-developers] Dynamically including a custom view defined in another app

2011-03-10 Thread Mark Murphy
On Thu, Mar 10, 2011 at 12:54 PM, Mark Carter mjc1...@googlemail.com wrote:
 How about TabActivity? Doesn't that do something similar to what I'm talking
 about (i.e. using a portion of the screen to show something
 created/controlled by (potentially) another app)?

TabActivity cannot display something from another app.

-- 
Mark Murphy (a Commons Guy)
http://commonsware.com | http://github.com/commonsguy
http://commonsware.com/blog | http://twitter.com/commonsguy

Android Training Worldwide: http://commonsware.com/training

-- 
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en


Re: [android-developers] Dynamically including a custom view defined in another app

2011-03-10 Thread Justin Anderson
And TabActivity doesn't fully support displaying activities... That
functionality is left over from very early Android development days and
there are all sorts of little gotchas and subtleties when using them to
display activities.

Really, each tab in a TabActivity should be a View and then it works much
more nicely.

Thanks,
Justin Anderson
MagouyaWare Developer
http://sites.google.com/site/magouyaware


On Thu, Mar 10, 2011 at 10:58 AM, Mark Murphy mmur...@commonsware.comwrote:

 On Thu, Mar 10, 2011 at 12:54 PM, Mark Carter mjc1...@googlemail.com
 wrote:
  How about TabActivity? Doesn't that do something similar to what I'm
 talking
  about (i.e. using a portion of the screen to show something
  created/controlled by (potentially) another app)?

 TabActivity cannot display something from another app.

 --
 Mark Murphy (a Commons Guy)
 http://commonsware.com | http://github.com/commonsguy
 http://commonsware.com/blog | http://twitter.com/commonsguy

 Android Training Worldwide: http://commonsware.com/training

 --
 You received this message because you are subscribed to the Google
 Groups Android Developers group.
 To post to this group, send email to android-developers@googlegroups.com
 To unsubscribe from this group, send email to
 android-developers+unsubscr...@googlegroups.com
 For more options, visit this group at
 http://groups.google.com/group/android-developers?hl=en


-- 
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en