391 Commits

Author SHA1 Message Date
Christopher Eby
ce7c5000db Reorganize PlaybackService
The old organization reflected a mystical thread barrier that does not really
exist. The new organization is more typical of the other classes
2010-04-04 10:40:40 -05:00
Christopher Eby
8231667d19 Don't disable the library menu entry when there are no songs 2010-04-04 10:20:16 -05:00
Christopher Eby
95b94f5921 Set the no media flag in setCurrentSong rather than in getSong
Avoids an infinite loop on startup with no media
2010-04-04 10:16:45 -05:00
Christopher Eby
238beaaef6 Combine code to handle playback control buttons 2010-04-04 10:10:39 -05:00
Christopher Eby
6753a30877 Add vertical padding to the seek bar 2010-04-04 01:06:04 -05:00
Christopher Eby
9e8bc71904 Allow the song info to be shown below the cover instead of on top of it
The complexity of the cover view drawing routines is getting a bit ridiculous..
2010-04-04 01:01:24 -05:00
Christopher Eby
124780de98 Make sure we are actually starting up in onCreate
Not just changing configurations
2010-04-03 23:14:55 -05:00
Christopher Eby
85876e1b0f Set a title in the song selector context menu 2010-04-03 23:14:55 -05:00
Christopher Eby
e08a39cacf Update the readme 2010-04-03 20:13:47 -05:00
Christopher Eby
9298542e7c Further organize strings 2010-04-03 17:50:31 -05:00
Christopher Eby
4957916360 Add preference to open song selector on startup 2010-04-03 17:49:00 -05:00
Christopher Eby
0ab6b3e6c9 Reword the mini player preference 2010-04-03 17:29:52 -05:00
Christopher Eby
e94cf2b443 Organize translatable strings 2010-04-03 17:24:22 -05:00
Christopher Eby
2147dd52cb Update the cover view when the queue changes
This became necessary after the coversion of song selector to a dialog, but was
never added
2010-04-03 17:17:49 -05:00
Christopher Eby
35ba1a0704 Limit the view being expanded to synchronously
The old array adapter prevented a flicker from many songs being displayed to just a few songs being dispalyed after expanding an item. This restores that behavior.
2010-04-03 11:22:37 -05:00
Christopher Eby
126760692f Make the expander flag in MediaAdapter a boolean
Historical reasons had it as a reference. This reference is not necessary now
2010-04-03 11:03:10 -05:00
Christopher Eby
8f76a2be25 Subclass MediaAdapter for songs
Override the sort order when limiting by album to sort by track number
2010-04-03 10:59:04 -05:00
Christopher Eby
f5f86018ec Reset the last acted id when the song selector is opened 2010-04-03 10:39:30 -05:00
Christopher Eby
043b5c18b0 Remove the dialer input preference
It is not hooked up to anything anymore since supporting it with an SQl query
would be complicated.
2010-04-03 10:39:26 -05:00
Christopher Eby
e21e1c6532 Rework MediaAdapter to be backed by a Cursor instead of an array
This reduces memory requirements and amount of code
2010-04-03 10:38:46 -05:00
Christopher Eby
0571a3189c Covert ids from int to long
MediaStore keeps ids as longs. It is unlikely that someone will have more than 65k songs... but you never know
2010-04-03 10:16:37 -05:00
Christopher Eby
a3ded6499c Retrieve a random song by selecting a random row from a query of all songs
This means we don't have to keep a long array of song ids around. Speed change is not significant
2010-04-03 10:13:14 -05:00
Christopher Eby
81fa1dd75f Make double tap song selector dismissal activate for any action 2010-04-02 11:16:01 -05:00
Christopher Eby
ededdcf716 Load preferences in onStart in song selector
So the app doesn't need to be restarted to reload these preferences
2010-04-02 11:12:20 -05:00
Christopher Eby
7791663e29 Load dialog code in onCreate
Historical cruft allowed this to creep into the constructor
2010-04-02 11:10:55 -05:00
Christopher Eby
6c58ca2d82 Convert default action preference to use integer strings
Might as well break some more preferences while we're at it
2010-04-02 11:00:09 -05:00
Christopher Eby
b275d5a1b9 Remove debug output 2010-04-02 10:51:46 -05:00
Christopher Eby
efef58276e Allow the notification to never be shown 2010-04-02 10:51:23 -05:00
Christopher Eby
2116ca6fa6 Remove oldState in the changed broadcast
It is not really all that useful
2010-03-28 21:45:17 -05:00
Christopher Eby
e11c0fec25 Move song randomization into Song 2010-03-28 18:37:20 -05:00
Christopher Eby
dc2d1ddbcc Simplify state loading code 2010-03-28 18:14:17 -05:00
Christopher Eby
6a32d69816 Keep Random instance in ContextApplication 2010-03-28 18:07:01 -05:00
Christopher Eby
9183f01fc9 Lazy load mActivities in ContextApplication 2010-03-28 18:04:00 -05:00
Christopher Eby
001215190e Return updateState to old behavior 2010-03-26 22:05:00 -05:00
Christopher Eby
210e2c5513 Change event_loaded to replace_song 2010-03-26 21:57:20 -05:00
Christopher Eby
5528749b59 setCurrentSong on startup
Uhhh where did it go?
2010-03-26 21:47:34 -05:00
Christopher Eby
a76ac9e7c1 Handle the context menu in song selector properly 2010-03-26 21:19:11 -05:00
Christopher Eby
df27c4323a Open the playback activity any time the last played item is pressed
Not just within half a second
2010-03-25 22:47:33 -05:00
Christopher Eby
8b9f851fae Flip around the choose songs check 2010-03-25 22:04:24 -05:00
Christopher Eby
8d738567f1 Handle null intents in onStart 2010-03-25 21:57:34 -05:00
Christopher Eby
b5480992b9 Change togglePlayback to toggleFlag 2010-03-21 22:33:12 -05:00
Christopher Eby
c3f955155f Make the service state a set of flags
I like flags
2010-03-21 22:29:26 -05:00
Christopher Eby
456f3d2504 Double tap inside song selector dismisses it
This doesn't work as well as I would like due to the way Android handles
focusing clicks.. but it's something
2010-03-21 21:40:39 -05:00
Christopher Eby
11b62deb6a Fix the SongSelector background on Android 1.5
Android 1.5 takes a black background to be translucent for some reason
2010-03-21 21:31:17 -05:00
Christopher Eby
aac448f5f7 Add icons to the menu, change the order and rename "media library" to "choose songs" 2010-03-21 21:13:57 -05:00
Christopher Eby
e150b9210c Only display the icon as the cover in the widget when loading from state 2010-03-21 17:45:38 -05:00
Christopher Eby
696e65a18a Cancel the notification through updateState on service destruction
The avoids a flicker to the paused notification if destroyed while playing
2010-03-21 17:43:32 -05:00
Christopher Eby
1d629c7fa2 Update the notification properly when the song changes
Clearly I don't look at the notification very often :)
2010-03-21 17:41:45 -05:00
Christopher Eby
f19927e97e Increase the double-tap time for the widget
This really just needs to be a long press... but I don't think there is any way
to accomplish this inside a RemoteView
2010-03-21 17:31:49 -05:00
Christopher Eby
0542c93faf Don't clear covers on stop 2010-03-21 17:21:29 -05:00