thanhlamcltv91 / kraigsandroid

Automatically exported from code.google.com/p/kraigsandroid
0 stars 0 forks source link

Add scroll bars to media picker lists. #9

Open GoogleCodeExporter opened 8 years ago

GoogleCodeExporter commented 8 years ago
What steps will reproduce the problem?
1.go to settings -> tones 
2.note that internal tab is empty 
3.

What is the expected output? What do 
you see instead?
I expect to see a list of the standard 
alarm sounds instead I there seems to 
be an "invisible" list I can scroll and the 
green bar seems to be moving down a 
list but I can't choose anything 

What version of the product are you 
using? On what operating system?
1.4 on HTC Desire Android 2.1 - update1

Please provide any additional 
information below.
In debug mode I can see that the path to 
alarm sounds is nothing I can find on my 
phone. My path to alarm sounds is /
system/media/audio/alarms. My other 
mp3s it can find perfectly .
I think your app is awesome could I just 
get the sounds to work as I wish.

Original issue reported on code.google.com by ander...@gmail.com on 31 May 2010 at 9:09

GoogleCodeExporter commented 8 years ago
It sounds like the media library of your phone may have been corrupted.  There 
is a 
global database that is maintained by the operating system's media service.  
The alarm 
klock app simply displays the information in that database.  'name' is a 
required 
field in this database, so I'm not sure how it could return empty strings in 
the 
normal case.  Did you ever use any programs that could have changed this 
database, 
like a custom media player or ringtone downloader?

Original comment by kraigs.a...@gmail.com on 1 Jun 2010 at 1:57

GoogleCodeExporter commented 8 years ago
I have tried uninstalling ringdroid and 
such with out luck. Tried un- and 
reinstalling alarm klock but nothing 
changes.
Alarm klock can play one of the default 
alarms in /system/media/audio/alarms.
Other ringtone software has been able to 
find it as well as my file manager.
If it is the database I would really 
appreciate any tips you or anyone else 
might have as to how I might solve it

Original comment by ander...@gmail.com on 2 Jun 2010 at 9:02

GoogleCodeExporter commented 8 years ago
The titles are populated using the content provider 
android.provider.MediaStore.Audio.Media.INTERNAL_CONTENT_URI

The UI displays the field returned in MediaStore.MediaColumns.TITLE, which I 
believe 
is a required field.

Do you know how these media files were added to your phone?  Perhaps the 
MediaStore 
was not properly updated when they were added?

Original comment by kraigs.a...@gmail.com on 4 Jun 2010 at 3:11

GoogleCodeExporter commented 8 years ago
I just trying to use the default alarm 
sounds provided by HTC/Android so they 
come with the phone. The mp3s I've 
loaded the phone's sdcard with works 
fine in alarm klock. And, as I've  said 
before, the standard alarm program finds 
the alarm sounds.

Original comment by ander...@gmail.com on 5 Jun 2010 at 11:54

GoogleCodeExporter commented 8 years ago
Solved!
Even though I feel like complete idiot I need to post this :-)
Scrolling was the issue.
I inadvertently scrolled under "internal" and Presto there all the sounds were.
Since I couldn't see any scroll bar and all the first sounds were nameless it 
appeared empty but no no now I have plenty of tones to choose from. All that 
remains is to figure out why some songs have no name in the database.
Suggestion:
Add scroll bar if not for weird cases such as mine then because it's nicer :-)
Sorry to have bothered you all 

Original comment by ander...@gmail.com on 15 Jun 2010 at 8:30

GoogleCodeExporter commented 8 years ago
Good point.  The media picker dialog was just a quick hack that I threw 
together.  The android API didn't have anything that you could use to select 
media, so this is what I could come up with quickly.  I didn't notice the lack 
of scroll bar before, but it definitely makes sense to add one.  I'll give it a 
whirl...

Original comment by kraigs.a...@gmail.com on 22 Jun 2010 at 4:37

GoogleCodeExporter commented 8 years ago
Did a bit of digging here, and I'm not exactly sure why the scroll bars aren't 
there.  Will revisit.

Notes:
The setVerticalScrollBarEnabled() method doesn't seem to work. 
android:scrollbars="vertical" worked when defined in the xml for the 
MediaSongsView but not for the ViewFlipper.  Try playing with the 
android:scrollbarAlwaysDrawVerticalTrack attribute.

Original comment by kraigs.a...@gmail.com on 6 Jul 2010 at 9:22

GoogleCodeExporter commented 8 years ago

Original comment by kraigs.a...@gmail.com on 6 Jul 2010 at 9:22