[android-beginners] Bug in the MediaStore Content Provider ?

2009-06-03 Thread xinit

Hello

My mp3 application is using the MediaStore content provider and I
noticed strange behaviour that is even reproducible on the native
android mp3 player.

1) Start emulator with SD card and some songs already on it
2) Start native mp3 player
3) See the songs that you have
4) Now push a new song to the SDC card
5) Restart the native MP3 player

Result: The new song is not visible. If I restart the emulator then
the song will be visible

Expected Result : The new song should be visible and accesible from
the conent provider after after it has been added to sdcard.

I first of all reproduced on my application, but I see that it also
effects the native player which must be using the MediaStore content
provider aswel.

This behaviour looks like a bug to me ?

I am using 1.5r2 of the SDK

Thanks !
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "Android Beginners" group.
To post to this group, send email to android-beginners@googlegroups.com
To unsubscribe from this group, send email to
android-beginners-unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-beginners?hl=en
-~--~~~~--~~--~--~---



[android-beginners] onListItemClick() does not work if I extend ArrayAdapter

2009-06-08 Thread xinit

Hi,

I am a bit puzzled, because it seems that if I extend ArrayAdapter
then onListItemClick will not fire.
For example:

//init 2 arrays that I will parse into my own ArrayAdapter that
  String [] Artist = {"test 1", "test 2", "test 3", "test 4", "test
5"};
  String [] Song = {"test 1", "test 2", "test 3", "test 4", "test 5"};

 MyDoubleTextViewAdapter dta = new MyDoubleTextViewAdapter(this,
R.layout.row,  Artist, Song);

setListAdapter(dta);

//This code will display the ListView pefectly. However if I want the
items in the list to be clicked then I should overide the
onListItemClick

protected void onListItemClick(ListView l, View v, int position, long
id) {
 Log.d("LOG", "FIRE  " );
 super.onListItemClick(l, v, position, id);

}


Basically the onListItemClick never fires.

If I change the code so that it does not extend ArrayAdapter and pass
through one Array object

  setListAdapter(new ArrayAdapter(this,
android.R.layout.simple_list_item_1, Artist));

Then the onListItemClick Works !

So what is the problem with onListItemClick and extending
ArrayAdapter ??


Thanks
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "Android Beginners" group.
To post to this group, send email to android-beginners@googlegroups.com
To unsubscribe from this group, send email to
android-beginners-unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-beginners?hl=en
-~--~~~~--~~--~--~---



[android-beginners] Re: onListItemClick() does not work if I extend ArrayAdapter

2009-06-08 Thread xinit

Thank you !!!
Yes that was my mistake.


On Jun 8, 7:01 pm, Romain Guy  wrote:
> It has nothing to do with extending ArrayAdapter. It must be because
> your list items contain focusable elements.
>
>
>
>
>
> On Mon, Jun 8, 2009 at 10:04 AM, xinit wrote:
>
> > Hi,
>
> > I am a bit puzzled, because it seems that if I extend ArrayAdapter
> > then onListItemClick will not fire.
> > For example:
>
> > //init 2 arrays that I will parse into my own ArrayAdapter that
> >  String [] Artist = {"test 1", "test 2", "test 3", "test 4", "test
> > 5"};
> >  String [] Song = {"test 1", "test 2", "test 3", "test 4", "test 5"};
>
> >     MyDoubleTextViewAdapter dta = new MyDoubleTextViewAdapter(this,
> > R.layout.row,  Artist, Song);
>
> > setListAdapter(dta);
>
> > //This code will display the ListView pefectly. However if I want the
> > items in the list to be clicked then I should overide the
> > onListItemClick
>
> > protected void onListItemClick(ListView l, View v, int position, long
> > id) {
> >         Log.d("LOG", "FIRE  " );
> >         super.onListItemClick(l, v, position, id);
>
> >    }
>
> > Basically the onListItemClick never fires.
>
> > If I change the code so that it does not extend ArrayAdapter and pass
> > through one Array object
>
> >  setListAdapter(new ArrayAdapter(this,
> > android.R.layout.simple_list_item_1, Artist));
>
> > Then the onListItemClick Works !
>
> > So what is the problem with onListItemClick and extending
> > ArrayAdapter ??
>
> > Thanks
>
> --
> Romain Guy
> Android framework engineer
> romain...@android.com
>
> Note: please don't send private questions to me, as I don't have time
> to provide private support.  All such questions should be posted on
> public forums, where I and others can see and answer them- Hide quoted text -
>
> - Show quoted text -
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "Android Beginners" group.
To post to this group, send email to android-beginners@googlegroups.com
To unsubscribe from this group, send email to
android-beginners-unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-beginners?hl=en
-~--~~~~--~~--~--~---



[android-beginners] Problem calling openStream() FileNotFoundException

2009-06-12 Thread xinit

Hello

I am starting Android and am using SDK 1.5 r2 and hope someone can
suggest to me where problem could lie.

The following code does two simple things, Create URL object and then
return InputStream by using openStream().

When I call openStream() I get a io.FileNotFoundException.

Here is sample code:

try {
URL feed = new URL("http://news.google.co.uk/news?
pz=1&ned=uk&hl=en&output=rss");


try {

InputStream is = feed.openStream();



} catch (IOException e) {
// TODO Auto-generated catch block
Log.d("LOG", e.toString());
}

My manifest contains the Internet permission:

 


The problem is as though the DNS cant resolve the domain ?

Any ideas ??

Thanks for your help




--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "Android Beginners" group.
To post to this group, send email to android-beginners@googlegroups.com
To unsubscribe from this group, send email to
android-beginners-unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-beginners?hl=en
-~--~~~~--~~--~--~---



[android-beginners] Re: Problem calling openStream() FileNotFoundException

2009-06-12 Thread xinit

Hi Mark,

Thanks for respose !

I run some tests and its a bit more confusing:

1) If I set the URL to another site for example "http://
newsrss.bbc.co.uk/rss/newsonline_uk_edition/uk/rss.xml" then it works.
So I think the setup of my Emulator and network is good.

2)So I put the Google News RSS URL directly into the emulator's
browser. The page resolves but is incorrect, its the standard news
html page But it is not the RSS raw text file that I would see on IE
on my pc browser. So I think the google server is doing something to
the request.

3)So navigating on the Emulators browser i select the RSS feed option
which displays the raw rss text file in the browser. I copy that URL
into my application and rerun application and I get the same error.

So I guess this is an issue with the way Google have setup there
server ?


Regards




On Jun 12, 12:24 pm, Mark Murphy  wrote:
> xinit wrote:
> > Hello
>
> > I am starting Android and am using SDK 1.5 r2 and hope someone can
> > suggest to me where problem could lie.
>
> > The following code does two simple things, Create URL object and then
> > return InputStream by using openStream().
>
> > When I call openStream() I get a io.FileNotFoundException.
>
> > Here is sample code:
>
> > try {
> >            URL feed = new URL("http://news.google.co.uk/news?
> > pz=1&ned=uk&hl=en&output=rss");
>
> >                    try {
>
> >                            InputStream is = feed.openStream();
>
> >                    } catch (IOException e) {
> >                            // TODO Auto-generated catch block
> >                            Log.d("LOG", e.toString());
> >                    }
>
> > My manifest contains the Internet permission:
>
> >  
>
> > The problem is as though the DNS cant resolve the domain ?
>
> > Any ideas ??
>
> Have you tried putting that URL in the Browser app? I know it will not
> display properly, but it will indicate whether your emulator/device can
> access that specific domain given the nature of your Internet connection.
>
> --
> Mark Murphy (a Commons 
> Guy)http://commonsware.com|http://twitter.com/commonsguy
>
> Need help for your Android OSS project?http://wiki.andmob.org/hado- Hide 
> quoted text -
>
> - Show quoted text -
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "Android Beginners" group.
To post to this group, send email to android-beginners@googlegroups.com
To unsubscribe from this group, send email to
android-beginners-unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-beginners?hl=en
-~--~~~~--~~--~--~---



[android-beginners] Re: without Absolutelayout, how to put widget on arbitary coordinate

2009-12-14 Thread xinit
Hi,

Try using drawdroid.org GUI designer.
absoluteLayout maybe deprecated but its still supported so may work if
you want to target a specific device.

Rgds

Gerard

On Dec 10, 1:46 am, Shawn Field  wrote:
> Hi All,
>
> Since the absolutelayout is deprecated, are there any way to put a
> widget on arbitary X,Y ?

-- 
You received this message because you are subscribed to the Google
Groups "Android Beginners" group.
To post to this group, send email to android-beginners@googlegroups.com
To unsubscribe from this group, send email to
android-beginners+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-beginners?hl=en


[android-beginners] ID3 Tags

2009-03-14 Thread xinit

Hello

I am looking into Media API's for playing music on Android.
Can someone please help me to explain how I can extract ID3
information from an MP3 File ?

I think the android.provider.MediaStore provides the API's but I cant
figure out how to use these API's.
Does anyone know of some examples or a tutorial on this ?

Or if someone someone can shed some light on this and share some basic
code that would be great

Thanks

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "Android Beginners" group.
To post to this group, send email to android-beginners@googlegroups.com
To unsubscribe from this group, send email to
android-beginners-unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-beginners?hl=en
-~--~~~~--~~--~--~---