Hi Android Team! Same problem here. I need to identify which music is currently playing. I was using the MediaPlaybackService up to Froyo (I know, I couldn't be doing that..) and now my app doesn't work on Gingerbread. Any suggestions?
Thanks! On 7 jan, 16:22, Dennix <[email protected]> wrote: > I'm also facing this problem. I created a costumized music widget and > I use that service to control music and get track infos. > It works fine on 2.1 and 2.2, but on 2.3 I can't bind to that service > because it's not exported > > Looking manifest file in souce code I found: > > ------ > Froyo > : > <service android:name="com.android.music.MediaPlaybackService" > android:exported="true" /> > : > ------ > Gingerbread > : > <service android:name="com.android.music.MediaPlaybackService" > android:exported="false" /> > : > ------ > > So, android team, is it possible use that service? > I wouldn't like to create another playback service to my widget. > > //Dennis > > On 21 dez 2010, 06:38, Jaumard <[email protected]> wrote: > > > > > > > > > There is no way to do this in gingerbread? > > > On 20 déc, 21:51, Mark Murphy <[email protected]> wrote: > > > > Please understand that this is not part of the Android SDK. According > > > to the source code, it is not exported, and therefore is not available > > > outside of its process. > > > > On Mon, Dec 20, 2010 at 3:43 PM, neuromit <[email protected]> wrote: > > > > I'm trying to setup a service connection to control the stock android > > > > media player. This works great under 2.1 and 2.2. However, when I > > > > tried to run my application on the 2.3 emulator my application crashes > > > > and I get the following error: > > > > > ERROR/AndroidRuntime(466): Caused by: java.lang.SecurityException: Not > > > > allowed to bind to service Intent > > > > {cmp=com.android.music/.MediaPlaybackService } > > > > > Have the permissions to bind to the IMediaServiceConnetion been > > > > revoked for gingerbread? > > > > > Here is the code I'm running from my class that is a child of > > > > ServiceConnection > > > > > Intent i = new Intent(); > > > > i.setClassName("com.android.music", > > > > "com.android.music.MediaPlaybackService"); > > > > a.bindService(i, (ServiceConnection) this, 0); > > > > > -- > > > > You received this message because you are subscribed to the Google > > > > Groups "Android Developers" group. > > > > To post to this group, send email to [email protected] > > > > To unsubscribe from this group, send email to > > > > [email protected] > > > > 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 *Advanced* Android Development_ Version 1.9 > > > Available! -- You received this message because you are subscribed to the Google Groups "Android Developers" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en

