Re: [android-developers] Why is ActivityGroup deprecated?

2012-11-23 Thread Franzi Roesner
Thanks, that post didn't come up in my searches, hence I asked here.

On Friday, November 23, 2012 3:23:44 AM UTC-8, TreKing wrote:

 On Fri, Nov 23, 2012 at 1:37 AM, Franzi Roesner 
 franzi@gmail.comjavascript:
  wrote:

 Right, my question is, why are Fragments better / why were they created?


 See this original post from Dianne Hackborn on the introduction of 
 Fragments:

 http://android-developers.blogspot.com/2011/02/android-30-fragments-api.html

 You can also consult the documentation to read up on the topic. Your 
 questions should be answered implicitly as you understand better what they 
 do and what they're for.

 Also, this, :)
 http://lmgtfy.com/?q=why+fragments


 -
 TreKing http://sites.google.com/site/rezmobileapps/treking - Chicago 
 transit tracking app for Android-powered devices

  

-- 
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

[android-developers] Why is ActivityGroup deprecated?

2012-11-22 Thread Franzi Roesner
Hi,

I know that ActivityGroup is deprecated, and that Fragments should be used 
instead. My question is out of curiosity: why was it deprecated?


Thanks!
Franzi

-- 
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] Why is ActivityGroup deprecated?

2012-11-22 Thread Franzi Roesner
Right, my question is, why are Fragments better / why were they created?

On Thursday, November 22, 2012 5:03:33 PM UTC-8, TreKing wrote:

 On Thu, Nov 22, 2012 at 7:21 PM, Franzi Roesner 
 franzi@gmail.comjavascript:
  wrote:

 I know that ActivityGroup is deprecated, and that Fragments should be 
 used instead. My question is out of curiosity: why was it deprecated?


 For exactly the reason you stated: Fragments should be used instead. The 
 deprecated status is a clear indication to developers not to use it and use 
 the newer, better thing instead.


 -
 TreKing http://sites.google.com/site/rezmobileapps/treking - Chicago 
 transit tracking app for Android-powered devices

  

-- 
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

[android-developers] sending custom parcelable to another application

2012-03-21 Thread Franzi Roesner
Hi,

I'm trying to send a custom Parcelable to another application (in another 
process). 

I have a client and a remote service, as well as an abstract class (say, 
AbstractCustomParcelable) that I added to the Android framework itself (for 
research purposes). The remote service should receive an object from the 
client that is an instantiation of this abstract class, and then call a 
method on it.

The problem is that if I extend AbstractCustomParcelable in the client 
(say, MyCustomParcelable) and then pass it to the service (by putting it in 
a Bundle with some other stuff and sending it via a Message), I get a 
ClassNotFoundError in the service:

android.os.BadParcelableException: ClassNotFoundException when 
unmarshalling: com.my.package.Client$MyCustomParcelable

I've done some searches and it appears I need to do something with the 
classloader, but I'm not sure where to set which classloader, and nothing 
I've tried has worked so far (e.g., doing 
setClassLoader(MyCustomParcelable.class.getClassLoader()) on the Bundle). 
Is there a way to make this work?


Thanks in advance!

Franzi

-- 
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

[android-developers] Re: sending custom parcelable to another application

2012-03-21 Thread Franzi Roesner
I figured this out, in case someone else needs this one day. In the remote 
service, I did:

Context c = createPackageContext(com.my.package, 
Context.CONTEXT_IGNORE_SECURITY | Context.CONTEXT_INCLUDE_CODE);
bundle.setClassLoader(c.getClassLoader());


However, what are the security implications of this (particularly the 
CONTEXT_IGNORE_SECURITY flag)?

Thanks!

Franzi

On Wednesday, March 21, 2012 9:36:19 AM UTC-7, Franzi Roesner wrote:

 Hi,

 I'm trying to send a custom Parcelable to another application (in another 
 process). 

 I have a client and a remote service, as well as an abstract class (say, 
 AbstractCustomParcelable) that I added to the Android framework itself (for 
 research purposes). The remote service should receive an object from the 
 client that is an instantiation of this abstract class, and then call a 
 method on it.

 The problem is that if I extend AbstractCustomParcelable in the client 
 (say, MyCustomParcelable) and then pass it to the service (by putting it in 
 a Bundle with some other stuff and sending it via a Message), I get a 
 ClassNotFoundError in the service:

 android.os.BadParcelableException: ClassNotFoundException when 
 unmarshalling: com.my.package.Client$MyCustomParcelable

 I've done some searches and it appears I need to do something with the 
 classloader, but I'm not sure where to set which classloader, and nothing 
 I've tried has worked so far (e.g., doing 
 setClassLoader(MyCustomParcelable.class.getClassLoader()) on the Bundle). 
 Is there a way to make this work?


 Thanks in advance!

 Franzi



-- 
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

[android-developers] SecurityManager

2012-02-02 Thread Franzi Roesner
Hi,

I'm wondering about the Java SecurityManager within Android. I
understand that it doesn't provide the isolation/security required by
Android (and that java.lang.System throws an exception if you try to
setSecurityManager), but I'm wondering what the consequences of using
it (in addition to existing mechanisms) would be. In particular, I'm
modifying Android for some research
purposes and I'd like to be able to prevent the use of reflection to
access non-public methods, which can usually be done with a
SecurityManager. Is there another way to do this?

Thanks!
Franzi

-- 
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


[android-developers] Re: SecurityManager

2012-02-02 Thread Franzi Roesner
I'll try that, thanks!


Franzi

On Feb 2, 3:07 pm, Mark Murphy mmur...@commonsware.com wrote:
 Probably not at the SDK level. You may have better luck inquiring on
 one of the Google Groups for the open source project
 (http://source.android.com).









 On Thu, Feb 2, 2012 at 5:38 PM, Franzi Roesner franzi.roes...@gmail.com 
 wrote:
  Hi,

  I'm wondering about the Java SecurityManager within Android. I
  understand that it doesn't provide the isolation/security required by
  Android (and that java.lang.System throws an exception if you try to
  setSecurityManager), but I'm wondering what the consequences of using
  it (in addition to existing mechanisms) would be. In particular, I'm
  modifying Android for some research
  purposes and I'd like to be able to prevent the use of reflection to
  access non-public methods, which can usually be done with a
  SecurityManager. Is there another way to do this?

  Thanks!
  Franzi

  --
  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

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

 _The Busy Coder's Guide to Android Development_ Version 3.7 Available!

-- 
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


[android-developers] android.view vs android.widget

2012-01-16 Thread Franzi Roesner
Hi,

In android.view.LayoutInflater, non-fully qualified classes are
expanded to android.view.ClassName -- why not
android.widget.ClassName for classes that are in the widget package?

(Some context, if helpful: I'm working on a research project that
involves making some changes to the UI toolkit, and now I'm getting
errors like java.lang.ClassNotFoundException:
android.view.LinearLayout for a number of widget class while booting.
If I change LayoutInflator to expand names to android.widget.ClassName
it works, but that seems like a change I shouldn't be making, so I've
clearly broken something else I don't know about.)


Thanks!
Franzi

-- 
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