[android-beginners] I broke my project

2008-12-13 Thread Josh
Im not sure what i did but now every line of code that specifies a resource in the res folder is underlined in red. I tried to manually add the raw directory under res and ithe compiler could not resolve any of the items in the raw folder. i took one of eclipses suggestions to fix the

[android-beginners] Re: Assistance with understanding LunarLander code

2008-12-13 Thread steve_macleod
Hi, At what point does the surfaceCreated() method fire? I presume its after we add the callback interface with addCallback? On Dec 12, 5:19 pm, RichardS richardswingw...@googlemail.com wrote: Steve, This is my understanding of it: The file res/layout/lunar_layout.xml describes the layout

[android-beginners] Re: Assistance with understanding LunarLander code

2008-12-13 Thread Mark Murphy
RichardS wrote: Steve, I'm sure the instance is created by setContentView(R.layout.lunar_layout) so the constructor will have been run by the time we do mLunarView = (LunarView) findViewById(R.id.lunar) Correct. If you look in res/layout/lunar_layout.xml, you will see the declaration:

[android-beginners] Re: I broke my project

2008-12-13 Thread Josh Dobbs
I still cannot resolve this issue. Whenever i try to access something in my layout folder like this R.Layout.somelayout None of my layouts are suggested by autocomplete. Its as if my application lost reference to the layout folder. any suggestions would be appreciated ** ** btnGo =(Button)

[android-beginners] Re: I broke my project

2008-12-13 Thread Josh Dobbs
I got it! I don't know how this got in my activity but once i removed the following import everything went back to normal. import *android*.R; Thanks! On Sat, Dec 13, 2008 at 8:27 AM, Josh Dobbs joshdo...@gmail.com wrote: I still cannot resolve this issue. Whenever i try to access something

[android-beginners] Re: center the tablelayout

2008-12-13 Thread Mark Murphy
Josh Dobbs wrote: my view is comprised of a tablelayout. How can I set the table in the center of the screen? by default it looks to be left alligned. Have you tried adding android:layout_gravity=centerHorizontal to your TableLayout, to center it in the parent container? -- Mark

[android-beginners] Re: keeping an application in portrait mode

2008-12-13 Thread Mark Murphy
Josh wrote: How can I ensure that my application is always displayed in portrait orientation? http://androidguys.com/?p=2891 That post covers the use of android:screenOrientation=portrait to force an application to stay in portrait orientation regardless of the state of the keyboard. --

[android-beginners] Re: Android 1.0 SDK Released

2008-12-13 Thread fadden
On Dec 11, 6:17 pm, kenb k...@irider.com wrote: Don't Java compilers do these kinds of optimizations, assuming the fields aren't volatile? The common compilers (e.g. javac) do not. Some post-processors (e.g. ProGuard) might. --~--~-~--~~~---~--~~ You received

[android-beginners] what is Europa and Ganymede?

2008-12-13 Thread Sadashiv Nayak
What are the differences between   Eclipse 3.3 (Europa) and Eclipse 3.4 (Ganymede) ? I am planning to install Android SDK on vista.  Which one of these IDEs is reqeuired? Connect with friends all over the world. Get Yahoo! India Messenger at http://in.messenger.yahoo.com/?wm=n/

[android-beginners] Re: anyone buy an android dev phone?

2008-12-13 Thread Anodes
yep, same experience. i ordered mine sunday (dec 7), standard shipping...it arrived thurs the 11th. never got a tracking number, trying to track on brightstarcorp's site yielded nothing, calling them was pleasant but pointless. except i had entered the wrong suite# for delivery and they did

[android-beginners] Re: ListActivity with image and text

2008-12-13 Thread ribz
I want to load images into my list view from the web. I have a URLs of the images/thumbnails which I've retrieved from an rss feed and stored in a table. Is this possible with a list or cursor adapter or is there another way? What is a good way to prepare loading and display of a set of images?

[android-beginners] Re: Broken link in installation instructions

2008-12-13 Thread Croptop
On Dec 12, 1:06 am, Ratha Grimes ra...@ratha.com wrote: The link to install the ADT plugin for Eclipse seems to be broken. The documentation athttp://code.google.com/android/intro/installing.html provides the following link:https://dl-ssl.google.com/android/eclipse/ - which gives 404. I can't

[android-beginners] programming tutorials and free source code

2008-12-13 Thread Caragea Silviu
Hello guys , Some times ago I had launched a developers community , formed to provide a place where programmers around the world can meet and exchange ideas. My community address is http://www.intelliproject.net . If you are interested to join us and to share some of your source code and

[android-beginners] Re: Assistance with understanding LunarLander code

2008-12-13 Thread steve_macleod
Cheers, that makes sense. I didnt notice the reference to the class in the lunar_layour xml. On Dec 13, 3:58 pm, Mark Murphy mmur...@commonsware.com wrote: RichardS wrote: Steve, I'm sure the instance is created by setContentView(R.layout.lunar_layout) so the constructor will have been

[android-beginners] Re: keeping an application in portrait mode

2008-12-13 Thread Josh Dobbs
Thanks Mark! Is there a way to run the emulator in landscape mode to test? On Sat, Dec 13, 2008 at 8:38 AM, Mark Murphy mmur...@commonsware.comwrote: Josh wrote: How can I ensure that my application is always displayed in portrait orientation? http://androidguys.com/?p=2891 That post

[android-beginners] Re: keeping an application in portrait mode

2008-12-13 Thread Josh Dobbs
nevermind i figured it out. On Sat, Dec 13, 2008 at 9:40 AM, Josh Dobbs joshdo...@gmail.com wrote: Thanks Mark! Is there a way to run the emulator in landscape mode to test? On Sat, Dec 13, 2008 at 8:38 AM, Mark Murphy mmur...@commonsware.comwrote: Josh wrote: How can I ensure that

[android-beginners] Re: keeping an application in portrait mode

2008-12-13 Thread Josh Dobbs
It doesnt seem to work. I am able to launch the emulator in landscape however the app is also displayed in landscape even though the following line is in AndroidManifest.xml android:screenOrientation=portrait On Sat, Dec 13, 2008 at 9:43 AM, Josh Dobbs joshdo...@gmail.com wrote: nevermind i

[android-beginners] Re: keeping an application in portrait mode

2008-12-13 Thread Mark Murphy
Josh Dobbs wrote: It doesnt seem to work. I am able to launch the emulator in landscape however the app is also displayed in landscape even though the following line is in AndroidManifest.xml android:screenOrientation=portrait Visit: http://commonsware.com/Android/ Click on the Version

[android-beginners] Re: keeping an application in portrait mode

2008-12-13 Thread Mark Murphy
Josh Dobbs wrote: When I run the RotationFourDemo in landscape and portrait the app orientation changes orientation. That is totally wild. I have no explanation for the behavior you're seeing. I just now tested RotationFour on a G1, and the behavior matches my emulator -- the screen stays

[android-beginners] Understanding the basic overridden onCreate function

2008-12-13 Thread Doughy
I'm trying to understand the code for the basic onCreate function that is part of every application. @Override public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.main); } I understand the @Override, and the

[android-beginners] Re: Understanding the basic overridden onCreate function

2008-12-13 Thread Mark Murphy
Doughy wrote: I'm trying to understand the code for the basic onCreate function that is part of every application. @Override public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.main); } I understand

[android-beginners] Re: keeping an application in portrait mode

2008-12-13 Thread Josh Dobbs
I am using version 1.0_r1 of the sdk. I don't have a G1 but I my friend does and ill be able to test on it on monday. I noticed while testing on it yeasterday prior to implementing portrait only mode that when i switched to landscape on the phone the whole application would restart. Im hoping that

[android-beginners] Re: center the tablelayout

2008-12-13 Thread Josh Dobbs
I did try that and i get the following error at design time... Description Resource Path Location Type ERROR Error: String types not allowed (at 'layout_gravity' with value 'centerHorizontal'). main.xml line 3 aapt Problem On Sat, Dec 13, 2008 at 8:37 AM, Mark Murphy

[android-beginners] Re: keeping an application in portrait mode

2008-12-13 Thread Romain Guy
Hi Josh, I noticed while testing on it yeasterday prior to implementing portrait only mode that when i switched to landscape on the phone the whole application would restart. Im hoping that keeping it in portrait only will fix that issue however the app im working on is best suited for

[android-beginners] Re: center the tablelayout

2008-12-13 Thread Romain Guy
center_horizontal not centerHorizontal :) On Sat, Dec 13, 2008 at 9:42 PM, Josh Dobbs joshdo...@gmail.com wrote: I did try that and i get the following error at design time... Description Resource Path Location Type ERROR Error: String types not allowed (at 'layout_gravity' with value

[android-beginners] Re: Understanding the basic overridden onCreate function

2008-12-13 Thread Doughy
OK, I see. So basically, by calling super.onCreate (savedInstanceState) one is making sure that any code in the superclass gets run, and then the stuff that is custom to the new class. Thanks. On Dec 13, 1:31 pm, Mark Murphy mmur...@commonsware.com wrote: Doughy wrote: I'm trying to

[android-beginners] Re: center the tablelayout

2008-12-13 Thread Josh Dobbs
I tried that as well with no luck On Sat, Dec 13, 2008 at 12:44 PM, Romain Guy romain...@google.com wrote: center_horizontal not centerHorizontal :) On Sat, Dec 13, 2008 at 9:42 PM, Josh Dobbs joshdo...@gmail.com wrote: I did try that and i get the following error at design time...

[android-beginners] Re: center the tablelayout

2008-12-13 Thread Josh Dobbs
my mistake. i had tried center_Horizantal. i just changed it to center_horizontal and although i don't get an error it doesnt center the tablelayout in the middle of the display. On Sat, Dec 13, 2008 at 12:44 PM, Romain Guy romain...@google.com wrote: center_horizontal not centerHorizontal

[android-beginners] Re: center the tablelayout

2008-12-13 Thread Josh Dobbs
ok. Thanks! I got it to work ith wrap_content. On Sat, Dec 13, 2008 at 12:54 PM, Romain Guy romain...@google.com wrote: It will work only if your TableLayout has a width set to wrap_content, otherwise it will occupy the entire screen. On Sat, Dec 13, 2008 at 9:51 PM, Josh Dobbs

[android-beginners] Re: keeping an application in portrait mode

2008-12-13 Thread Josh Dobbs
If i dont keep it in portrait mode it doesnt scroll automatically when in landscape mode. Do i need to hadle scrolling in code? On Sat, Dec 13, 2008 at 12:43 PM, Romain Guy romain...@google.com wrote: Hi Josh, I noticed while testing on it yeasterday prior to implementing portrait only

[android-beginners] need clarification on resolving intents.

2008-12-13 Thread Anil
What if an intent matches two or more activities - how is it resolved? In the example provided on the intents page, http://code.google.com/android/reference/android/content/Intent.html both Noteslist and NoteEditor have type type android:value=vnd.android.cursor.dir/vnd.google.note / So in the

[android-beginners] Re: need clarification on resolving intents.

2008-12-13 Thread Mark Murphy
Anil wrote: What if an intent matches two or more activities - how is it resolved? In the example provided on the intents page, http://code.google.com/android/reference/android/content/Intent.html both Noteslist and NoteEditor have type type