DulcetTone wrote:
> my app uses a small subset of Android's MediaPlaybackService (which
> underlies its Music app)

Bear in mind that this is not supported by the SDK, so I'm not surprised
you're encountering problems.

http://www.androidguys.com/2009/12/14/code-pollution-reaching-past-the-sdk/

> Since I cannot alter either version of the service, I feel I am stuck
> with a situation where a single interface file in my project must be
> two different versions, which it cannot.

Yes, I suspect you're probably stuck. There might be some tricks you can
pull by manually modifying the generated stub for your 2.aidl edition,
so the stub is named with the "2" but it uses the original name
everywhere else. This, of course, is terribly fragile.

> The workaround I have been thinking of is that I will keep my app so
> it can interface to Android 1.x's MediaPlayerService via the existing
> (working) interface, and have 2.x users download an additional package
> embodying a service of my own creation which serves as a front-end to
> Android 2.x's MediaPlayerService.  As this service will have a
> different name and I can write its interface entirely, my app will
> have its liberty to use it as a proxy for the underlying Android code.
> 
> The other approach is simply to have a 2.x version of my app that
> replaces the 1.x AIDL with the 2.x AIDL.  To me, that seems uglier.

The third option is for you to not use the built-in
MediaPlaybackService, but rather use your own copy. I have no idea how
easily their implementation can be teased out of the source code and
turned into something that works with the SDK.

The fourth option is for you to not use the built-in
MediaPlaybackService but roll your own media playback service.

IMHO, either of those two are preferable to using something you're not
supposed to be using.

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

Android Development Wiki: http://wiki.andmob.org
-- 
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

Reply via email to