[android-beginners] How to know deletion of Media Store.
Hello Everyone, I want to access from Media Store such as all audio, video and images.. I can access all information of Media Store and I want to know this problems. If some file is deleted and updated , how do I know ? All tables of primary key is not auto increment. So far, I cannot know changes of these files. Please , kindly reply me and post my mail. Thanks Ni -- 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
Re: [android-beginners] why Java, not Python?
To my knowledge, Java is simply faster. That, and Python is also rather "big". With any luck, Unladen Swallow might find its way onto our devices.. then perhaps we can get Python onto Android. Personally, i would give my right leg for Python on android. (And by that, i mean Python working as well as, or better, than Java. Not that python scripting project, heh.) On Sun, Nov 22, 2009 at 4:07 PM, Shawn Brown wrote: > > Again, not trying to start any arguments, just curious if > > anyone has any background on this. > > Well consider that Google AppEngine started in python and then added > java support. In some ways, the python version is more advanced. > > I don't know why java was chosen but you have to believe that python > was looked at seriously as well and for some reason ... I don't know > the exact reasoning though. > > Shawn > > -- > 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 > -- Lee Olayvar -- 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: why Java, not Python?
It has to do with how scripted oop languages are implemented..in tis case Python is implemented via C. Most mobile app languages base don C have higher learning curves and break easier..such as Symbian C, and Apple's own Objective C for iPhone.. While the learning curve to python might be lower keeping it somehow working on mobile its a very daunting task Java was originally designed for small devices.. On Nov 22, 6:07 pm, Shawn Brown wrote: > > Again, not trying to start any arguments, just curious if > > anyone has any background on this. > > Well consider that Google AppEngine started in python and then added > java support. In some ways, the python version is more advanced. > > I don't know why java was chosen but you have to believe that python > was looked at seriously as well and for some reason ... I don't know > the exact reasoning though. > > Shawn -- 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] Custom inputType
I have editText which accepts numeric details with an optional text suffix, (ie. 90.895t). I am using addTextChangedListeners and pattern/match to ensure correct data entry. Planning to call text soft keyboard in number/symbol view initally, with text view obtainable from this keyboard. I have tried inputType variations, with the only suitable view being datetime, this however only allows enrty text entry in the datetime format. As the pre-existing attributes are ignored if inputType has been defined, there is no way of tweaking inputType attributes? Or is there a simpler way of calling up specific soft keyboards (numeric, symbol, 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
Re: [android-beginners] Restore factory settings
I‘m not sure, but if you can see the logcat while you click restore button in system setting, you may see action name that which you need~ 2009/11/21 Nemat > Hi friends > > > I have to restore factory settings of phone programmatically..Is > that possible?if yes,How can we do tht? > > Thanks in Advance > Nemat > > -- > 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 -- 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
Re: [android-beginners] building GUIs (manually? or with some tool?)
Hai friend , I am a android beginner i hav gone through this tool . for me its very helpful -Thanks ayyappa On Sat, Nov 21, 2009 at 5:25 PM, Marton Kodok wrote: > http://www.droiddraw.org/ > > 2009/11/21 Esmail > > Do most people developing applications for Android code the >> XML layouts manually or are they using a tool for to help them >> with this? The whole XML based interface thing is new to me >> (I can see the benefits of separating the interface from the >> code though) >> >> Currently I am working under Windows XP with Eclipse. >> >> Thanks. >> >> >> Sorry this is cross-posted, I am a beginner but I am also curious >> what more experienced developers do with regard to this question. >> >> -- >> 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 > > > > > -- > Márton > > -- > 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 > -- ayyappa(9912416054) -- 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
Re: [android-beginners] why Java, not Python?
This is my theory. One of the creators of Android company, which android is based on, came from an company called Danger in mountain view. Danger made the sidekick - The applications made on the sidekick are all done in java. http://developer.danger.com/site/faq/show#q5 An natural evolution of the client side language for android based on the founders experience would be java. Tom On Sun, Nov 22, 2009 at 4:07 PM, Shawn Brown wrote: >> Again, not trying to start any arguments, just curious if >> anyone has any background on this. > > Well consider that Google AppEngine started in python and then added > java support. In some ways, the python version is more advanced. > > I don't know why java was chosen but you have to believe that python > was looked at seriously as well and for some reason ... I don't know > the exact reasoning though. > > Shawn > > -- > 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 > -- Tom Chen Software Architect GOGII, Inc t...@gogii.net 650-468-6318 -- 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] Error in helloandroid tutorial
Hi all, I met the following error message appared on the emulator screen. "There's a big error message saying that 'Application Android Keyboard (in process com.android.inputmethod.latin) is not responding.' and asking whether i want to force close it or wait." Anybody knows why? 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] licence apache 2.0
Hi, I'm getting good results in the creation of a program with Android but so far I have taken just pieces of code from ApiDemos, Notepads, etc.. . I saw that the code of these programs is released under Apache License 2.0. I looked at the license in English but I understand (i am italian) that i just simply insert the top of each java file this code: Copyright [] [name of copyright owner] Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You May Obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. And 'so or is there more? thanks Hello -- 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] ANDROID_SWT on Vista
Hi, Can't seem to get out of the gate with the setup. I am running Windows Vista on a x64 machine. I am getting an error message trying to open the android.bat file. Here is all the info I think is pertinent. I hope someone has an idea what I am doing wrong. I asure you, the swt.jar file does exist in the location that it says it does not exist. Also, I have tried this both as admin and as my regular user account, which is an admin. Thanks in advance for any assistance. --Error Message-- Starting Android SDK and AVD Manager SWT folder 'C:\Program Files\android-sdk-windows\tools\lib\x86_64;' does not exist. Please set ANDROID_SWT to point to the folder containing swt.jar for your platform. --Installed folders-- Andriod SDK: C:\Program Files\android-sdk-windows Java SE SDK: C:\Program Files (x86)\Java\jdk1.6.0_17 --System Variables-- ANDROID_SWT: C:\Program Files\android-sdk-windows\tools\lib\x86_64 Path: %SystemRoot%\system32;%SystemRoot%;%SystemRoot%\System32\Wbem;C: \Program Files (x86)\CyberLink\Power2Go;C:\Program Files (x86)\ATI Technologies\ATI.ACE\Core-Static;c:\Program Files (x86)\Microsoft SQL Server\90\Tools\binn\;C:\Program Files (x86)\QuickTime\QTSystem\;C: \Program Files\android-sdk-windows\tools;C:\Program Files (x86)\Java \jdk1.6.0_17\bin -Guido -- 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: New project in Eclipse error
I am having the same issue. I double checked the setup under the help tab and still get the same error. Have you found a solution to this problem. On Nov 10, 7:16 am, Scott wrote: > Most likely a humanerrorsince I'm totally new toEclipsehere. I was > following the directions > athttp://developer.android.com/guide/developing/eclipse-adt.html > and got to Step 2 only to see > > "The location of the AndroidSDKhas not been setup. Please go to > Preferences > Android and set it up" > > I realize this is probably a stupid question that's been answered > (maybe I didn't go far enough back looking for an answer?) but any > help is appreciated helping me at least start the "Hello World" > project =) -- 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: Can't update view
Can anyone answer this questions or is this not a beginner question? On Nov 4, 3:14 am, keyvez wrote: > I am populating (through inflation) an XML file and then I want to > update the textSize of each TextView and redraw it, but it's not > updating the view with new textSize. > > Here is the code: > > public class Contacts extends ListActivity { > private SimpleCursorAdapter mAdapter; > private Integer totalContactsMade; > > /** Called when the activity is first created. */ > @Override > public void onCreate(Bundle savedInstanceState) { > super.onCreate(savedInstanceState); > Cursor cursor = getContentResolver().query(People.CONTENT_URI, > null, null, null, People.NAME + " ASC"); > startManagingCursor(cursor); > > String[] columns = new String[] { People.NAME}; > int[] names = new int[] {R.id.row_entry}; > > mAdapter = new SimpleCursorAdapter(this, R.layout.main, > cursor, columns, names); > setListAdapter(mAdapter); > > Integer contactCount = getListView().getCount(); > > for(Integer i=0; i > LinearLayout layout = (LinearLayout) > mAdapter.getView(i, null, > null); > if(layout != null) { > TextView view = (TextView) > layout.findViewById(R.id.row_entry); > if(view != null) { > view.setTextSize(6.0f); > view.requestFocus(); > view.getParent().requestLayout(); > view.requestLayout(); > view.postInvalidate(); > > // I have tried to invalidate > the layout also, but it doesn't work > layout.requestFocus(); > layout.requestLayout(); > layout.postInvalidate(); > } > } > > } > > } -- 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
Re: [android-beginners] Need some help with the GUI
why not split your code into different activity? It will be easy to coding~ 2009/11/21 Breezy > What's the best way to handle this scenario? > > I've an app I'm working on that will have 3 different screens (layouts > essentially). One will be a search box with a couple radio buttons > and a search button. One will be a results list (I'm liking listview > for this, sound good?). One will be the whichever result the user > selects and display the data which will be several lines of > information and possibly a picture. > Also at the top of each screen will be a header, similar to that of a > webpage with frames and will be static while each of the three screens > scrolls below. I would like the main header to have an onclick > function to show the search screen again. > > Any suggestions on this? > > I have the search screen in a linearlayout now but when I click the > search button I got the search screen to dissappear but the results > screen doesn't show. The header stays at the top though and if > clicked shows the search screen. I do that with setVisibility() but > that may be a bad practice. I was able to test my search > functionality out with toasts to see if it works and it does, but I > need to display my results, not just flash them at the user lol! > > Any suggestions? > > Here's my code thus far below... Keep in mind I just have the header, > search and search results screens but the search results screen is > just a textview. > > > http://schemas.android.com/apk/res/ > android" > android:layout_width="fill_parent" > android:layout_height="fill_parent" > android:orientation="vertical" > > android:layout_width="wrap_content" > android:layout_height="wrap_content" > android:text="TITLE WILL GO HERE" > android:textColor="#A4C17F" > android:textStyle="bold" > android:textSize="23sp" > android:width="400sp" > android:background="#E0DB97" > android:shadowColor="#00"> > android:layout_width="wrap_content" > android:layout_height="wrap_content" > android:text="SUBTITLE WILL GO HERE." > android:textSize="12sp" > android:width="400sp" > android:background="#E0DB97" > android:textColor="#00"/> > > http://schemas.android.com/apk/res/ > android" > android:layout_width="fill_parent" > android:layout_height="fill_parent" > android:orientation="vertical" > android:id="@+id/searchboxLL"> > android:layout_height="wrap_content" > android:id="@+id/spacer" > android:height="40sp"> > android:layout_height="wrap_content" > android:id="@+id/search_label" > android:text="Search Books" > android:paddingLeft="10sp" > android:textColor="#FF" > android:textSize="14sp"> > android:layout_width="wrap_content" > android:layout_height="wrap_content" > android:width="390sp"> > > android:layout_width="fill_parent" > android:layout_height="wrap_content" > android:orientation="horizontal" > id="@+id/searchtypes"> > > android:layout_height="wrap_content" android:id="@+id/bauthor" > android:text="Author"> > android:layout_width="wrap_content" > android:layout_height="wrap_content" android:text="Title"> RadioButton> > android:layout_width="wrap_content" > android:layout_height="wrap_content" android:text="ISBN"> RadioButton> > > > android:layout_width="wrap_content" > android:layout_height="wrap_content" android:text="Search Books" > android:cursorVisible="true" android:textColor="#7B905F"/> > > > > http://schemas.android.com/apk/res/ > android" > android:layout_width="fill_parent" > android:layout_height="fill_parent" > android:orientation="vertical" > android:id="@+id/searchresultsLL"> > > android:layout_width="wrap_content" > android:layout_height="wrap_content" > android:text="Search Results Here." > android:textSize="12sp" > android:width="400sp" > android:height="50sp" > android:textColor="#FF" /> > > > > > > -- > 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 > andr
[android-beginners] Re: "Hello World" not even running in Emulator
I have run the emulator for one day!But it still shows the image of the picture "android2" On 11月21日, 上午1时46分, Justin Anderson wrote: > The emulator takes extremely long to load. If you have a phone, you would > notice that the second android image that you reference is the initial boot > up screen for the phone. Just wait longer. Depending on your machine > speed, os, etc... I have heard the emulator startup time can take any where > from a few minutes to hours. On my machine it takes about 2 minutes. > > Also, this question has been asked several times. Please search the group > before posting redundant questions... Especially if they have already been > answered. > > -- > There are only 10 types of people in the world... > Those who know binary and those who don't. > -- > > On Fri, Nov 20, 2009 at 5:05 AM, Mr. Baseball 34 > wrote: > > > I have Eclipse Galileo JDK6.17 with Android 1.5R3. I can't even get the > > Hello World app running correctly. > > A Lot of messages say to wait for the emulator, well when it first comes > > up, it shows attachment > > android1.png (also posted here:. > >http://www.delphicommunity.com/android1.png) > > > I will wait for a while and the screen will clear then it shows the > > attachment android2.png > > (also posted here:http://www.delphicommunity.com/android2.png). > > > Any ideas as to why it won't even work for this simple little app? > > > -- > > 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 -- 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] about /system/bin/playmp3
hi all: in init.rc service bootsound /system/bin/playmp3 user media group audio oneshot but where the sourcecode about playmp3? 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: using a simpleCursorAdapter to bind data from a database to a spinner
I'm having the same problem, did you ever figure it out? On Oct 15, 1:33 pm, JasonMP wrote: > Im trying to fill a spinner with data from a table. That part works > fine. What i cant figure out is how to use the selection made through > the spinner. if i use : > String someString = (String) classSpin.getSelectedItem().toString(); > i get some sort of SQL reference. Am i missing a step? Im new to > both java and android so i hope this is something very obvious im > missing. > > heres some of my code for the spinner: > > Cursor classCur = db.getClasses(); > startManagingCursor(classCur); > from = new String[]{DBAdapterStats2.KEY_CLASS}; > to = new int[]{android.R.id.text1}; > SimpleCursorAdapter classAdapter = new SimpleCursorAdapter(this, > android.R.layout.simple_spinner_item, classCur, from, to); > classAdapter.setDropDownViewResource > (android.R.layout.simple_spinner_dropdown_item); > classSpin.setAdapter(classAdapter); -- 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] activating g1 without wifi
Someone please help me. I am trying to register my g1 through a wifi. It is rc29 but i can't get it to shell to my mac. i type in the commands in my terminal after I download android-sdk-mac but it says command not found. I think it is because the new version of android- sdk-mac doesn't have adb in tools but i am not sure. Someone please 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
Re: [android-beginners] why Java, not Python?
Anybody know what the number of Python developers vs. the number of Java developers? I would think that Java would have more developers. Maybe they were trying to go with the biggest developer base in hopes to get more apps up and running quickly. Ryan On Sun, Nov 22, 2009 at 7:07 PM, Shawn Brown wrote: > > Again, not trying to start any arguments, just curious if > > anyone has any background on this. > > Well consider that Google AppEngine started in python and then added > java support. In some ways, the python version is more advanced. > > I don't know why java was chosen but you have to believe that python > was looked at seriously as well and for some reason ... I don't know > the exact reasoning though. > > Shawn > > -- > 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 -- 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: Android 2.0 SDK is here!
wow Gr8 btw how i can see Android 2.0 emulator on Windows 7 -- 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] android-sdk-mac_x86-1.5_r3.zip
I need the android-sdk-mac_x86-1.5_r3.zip file. the developers page only has the new version and I need the original version of the file. If anyone has it PLEASE let me know. -- 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: Delayed actions
Answered it myself: timer.schedule(new TimerTask(...)) On Nov 20, 8:53 am, dumontf wrote: > Hello, > > I am trying to get 4 sounds to play in sequence. Something along the > lines of: > > playSound(1) > delay(100) > playSound(2) > delay(100) > playSound(3) > delay(100) > playSound(4) > > Is there a way to add delay in Android or to schedule an action in the > future? Thanks for any 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] Runtime Exception before OnCreate()
I'm trying to run (debug) my Android application in Eclipse for the first time. Each time I run it I get a RuntimeException before the OnCreate() method of the initial activity is invoked. I have no idea why. Thread Group [main] Thread [<3> main] (Suspended (exception RuntimeException)) ActivityThread$PackageInfo.makeApplication(boolean) line: 509 ActivityThread.handleBindApplication(ActivityThread$AppBindData) line: 3943 ActivityThread.access$2900(ActivityThread, ActivityThread $AppBindData) line: 119 ActivityThread$H.handleMessage(Message) line: 1859 ActivityThread$H(Handler).dispatchMessage(Message) line: 99 Looper.loop() line: 123 ActivityThread.main(String[]) line: 4310 Method.invokeNative(Object, Object[], Class, Class[], Class, int, boolean) line: not available [native method] Method.invoke(Object, Object...) line: 521 ZygoteInit$MethodAndArgsCaller.run() line: 860 ZygoteInit.main(String[]) line: 618 NativeStart.main(String[]) line: not available [native method] Thread [<13> Binder Thread #2] (Running) Thread [<11> Binder Thread #1] (Running) -- 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: "Hello World" not even running in Emulator
There now seem to be many of us who are experiencing this behaviour. I have an emulator running now which has been running for over 24 hours and still has not displayed the home page. I have a gut feeling that it is a video card issue, although I have only two data points so far: 1. Dell laptop circa 2002 running Ubuntu 9.04. Emulator gets as far as animated logo. 2. Generic desktop, P4 machine running Ubuntu 9.04. Emulator boots up in under 2 minutes. -David On Nov 20, 12:46 pm, Justin Anderson wrote: > The emulator takes extremely long to load. If you have a phone, you would > notice that the second android image that you reference is the initial boot > up screen for the phone. Just wait longer. Depending on your machine > speed, os, etc... I have heard the emulator startup time can take any where > from a few minutes to hours. On my machine it takes about 2 minutes. > > Also, this question has been asked several times. Please search the group > before posting redundant questions... Especially if they have already been > answered. > > -- > There are only 10 types of people in the world... > Those who know binary and those who don't. > -- > > On Fri, Nov 20, 2009 at 5:05 AM, Mr. Baseball 34 > wrote: > > > I have Eclipse Galileo JDK6.17 with Android 1.5R3. I can't even get the > > Hello World app running correctly. > > A Lot of messages say to wait for the emulator, well when it first comes > > up, it shows attachment > > android1.png (also posted here:. > >http://www.delphicommunity.com/android1.png) > > > I will wait for a while and the screen will clear then it shows the > > attachment android2.png > > (also posted here:http://www.delphicommunity.com/android2.png). > > > Any ideas as to why it won't even work for this simple little app? > > > -- > > 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 -- 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] Launching Raw Contact Picker in Android 2.0
I would like to know if it's possible to launch the Contact Picker and allow the user to choose a specific phone # or email address from a Contact. I know how to launch the contact list, but all that lets the user do is choose a specific contact. I need to be able to let the user choose a specific phone # or email address in the case where a Contact has multiple phone #s and email addresses. -- 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] Beginning to use OpenGL ES on Android
Hello Everyone! The more I study the examples in the ApiDemo folder, the more I'm beginning to understand how everything is meant to work. I do need some minor clarification on something. In the docs there is this quick snippet: "Here's how to use the API at an extremely high level: 1. Write a custom View subclass. 2. Obtain a handle to an OpenGLContext, which provides access to the OpenGL functionality. 3. In your View's onDraw() method, get a handle to a GL object, and use its methods to perform GL operations. For an example of this usage model (based on the classic GL ColorCube), showing how to use it with threads can be found in com.android.samples.graphics.GLSurfaceViewActivity.java." I'm not following how this creates a thread. Reading over thread creation, there's both a Handle and Thread object created... with is not done here. My apologies if this is a bit of an ignorant question, but I'm just as new to Java as I am to Android. (I'm intermediate with C and have used OpenGL). The TriangleActivity.java with the StaticTriangleRenderer.java is a great example to learn from, but I'm still not sure how this makes use of a thread. Or perhaps... is the thread creation handled somehow in the renderer that I'm not following? Thanks everyone, -- 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: Installing ADT in Eclipse 3.5.1 (Ubuntu)
Android Development on UB2 9.1 I followed the below procedures and installation succeed: 1. update Ubuntu sudo apt-get update && sudo apt-get upgrade 2. install JAVA sudo apt-get install sun-java6-jdk java -version javac -version 3. install Eclipse At Ubuntu Softwar Center / Programming 4. Install Android SDK - Download and install Android SDK at http://developer.android.com - unzip to my home directory or other you like - at home, edit .bashrc eg. sudoedit .bashrc Add the following line at the very bottom of the .bashrc file: export PATH=${PATH}:/home/kris/android-sdk-linux_x86-1.5_r1/tools 5. Eclipse option install Go to System -> Administration -> Synaptic Package Manager and search for "eclipse" Then mark "eclipse" for install. * This package provides the whole Eclipse SDK, along with the Java Development Tools (JDT) and the Plugin Development Environment (PDE). 6. Eclipse plugin Help/Install New Software/Add Available Software Add available software site http://download.eclipse.org/releases/galileo http://dl.google.com/eclipse/plugin/3.5 http://dl-ssl.google.com/android/eclipse/ 7. Install Android Package Window / Android SDK and AVD Manager Available Packages Cheers On Nov 21, 6:36 am, Eno wrote: > I add the site and in the Install Details screen runs into an error: > > "Cannot complete the install because one or more required items could > not be found. > Software being installed: Android Development Tools > 0.9.4.v200910220141-17704 > (com.android.ide.eclipse.adt.feature.group0.9.4.v200910220141-17704) > Missing requirement: Android Development Tools > 0.9.4.v200910220141-17704 > (com.android.ide.eclipse.feature.group0.9.4.v200910220141-17704 > requires 'org.eclipse.gef 0.0.0' but it could not be found" -- 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] Help! My simple app works in Eclipse Emulator but not on droid
My simple app - with no fancy stuff - just one preferences screen and simple while loop logic keeps crashing on my droid though it works fine in the emulator ... I've tried everything I could find online for possible answers, I think... is there something very basic I'm missing? I get a blank screen showing the app title and nothing else! It hangs forever before crashing! Thank you so much for helping! Anyone? -- 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] Programmatically setting the layout_above value
Hello, I need to dynamically change the layout_above value for a ListView within a RelativeLayout. I know that within the XML, all you need is android:layout_above="@id/myid", but what is the equivalent if I want to do this in my java code? Thanks, Becca -- 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] Selecting which applications load on power-up
Whenever I start up my HTC Hero, many applications start automatically. How do I select/deselect which ones do this? -- 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: ADT Plugin for Eclipse on Ubuntu 9.10
I am running Ubuntu 9.10 with eclipse (3.5.1) installed from the Ubuntu repository. I have been able to add the Android Plugin but when I try to create an Android project: File->New->Project...->Android->Android Project->Next It brings up a "New Android Project" dialog. However the "Build Target" list is empty. How do I get entries added to the "Build Target" list? I have downloaded the Android SDK. Do I need to download the ADT plugin in separately? -- 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] UNIX domain socket used on PhoneFactory.java
Hi, I am looking on the PhoneFactory.java file and I found the following code: try { // use UNIX domain socket to // prevent subsequent initialization new LocalServerSocket ("com.android.internal.telephony"); } catch (java.io.IOException ex) { hasException = true; } I searched through the code looking for some reference to that socket name but I find nothing.I am not expert with domain sockets but I found that all I need to do is open a socket connection to the socket using the domain as reference and you are all set. Could someone please explain me how this works and where this socket is actually being used? Thank you! -- 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] A webview has a white line at the right side
Hello! I'm trying using webview in an android application, but there is one strange thing - a white vertical line at the right side of emulator's screen. I tried different layouts, different web-pages - nothing helps. You can see an image on the link below: http://picasaweb.google.com/m.kokho/RecentlyUpdated#5406296875878909314 layout/main.xml: http://schemas.android.com/apk/res/ android" android:layout_width="fill_parent" android:layout_height="fill_parent" android:orientation="vertical" > java code: public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.main); //or like this: setContentView(new WebView(this)); // init fields: webview = (WebView) findViewById(R.id.webview); // setup webview: final WebSettings webSettings = webview.getSettings(); webSettings.setSavePassword(false); webSettings.setSaveFormData(false); webSettings.setJavaScriptEnabled(true); webSettings.setSupportZoom(false); webview.setWebChromeClient(new MyWebChromeClient()); webview.setWebViewClient(new MyWebViewClient()); webview.loadUrl("file:///android_asset/index3.html"); } -- 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
Re: [android-beginners] I just gotta say
Wayne Wenthin wrote: > Sometimes it pays to go back and read "books" I just restarted Mark > Murphy's Busy Coders book and picked up some great tips. Thanks! > Of course I no longer support 1.5 doing them but hey... Well, further back in the book, there are some tips for supporting multiple API versions. They may or may not help you, depending on what new stuff you're trying to use. -- Mark Murphy (a Commons Guy) http://commonsware.com | http://twitter.com/commonsguy _Android Programming Tutorials_ Version 1.0 Available! -- 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] android sdk in /usr/local
I am trying to run android-sdk in linux under a diretory structure that would all the sdk to be installed and used by multiple people. I have already resolved the export GDK_NATIVE_WINDOWS=true problem. I used root to update the sdk. No I have something like: drwxr-xr-x 7 root root 4096 2009-11-20 17:26 android-sdk-linux/ drwxr-xr-x 2 root root 4096 2009-11-20 16:20 android-sdk-linux/add- ons/ drwxr-xr-x 13 root root 4096 2009-11-20 17:26 android-sdk-linux/docs/ drwxr-xr-x 3 root root 4096 2009-11-20 16:20 android-sdk-linux/tools/ drwxr-xr-x 6 root root 4096 2009-11-20 17:23 android-sdk-linux/ platforms/ drwxr-xr-x 8 root root 4096 2009-11-20 17:22 android-sdk-linux/ platforms/android-1.1/ drwxr-xr-x 8 root root 4096 2009-11-20 17:21 android-sdk-linux/ platforms/android-1.5/ drwxr-xr-x 8 root root 4096 2009-11-20 17:21 android-sdk-linux/ platforms/android-1.6/ drwxr-xr-x 8 root root 4096 2009-11-20 17:23 android-sdk-linux/ platforms/android-2.0/ Now when I type sudo /usr/local/android-sdk-linux/tools/android list I get: Available Android targets: id: 1 or "android-2" Name: Android 1.1 Type: Platform API level: 2 Revision: 1 Skins: HVGA-L, HVGA (default), QVGA-L, QVGA-P, HVGA-P id: 2 or "android-3" Name: Android 1.5 Type: Platform API level: 3 Revision: 1 Skins: HVGA-L, HVGA (default), QVGA-L, QVGA-P, HVGA-P id: 3 or "android-4" Name: Android 1.6 Type: Platform API level: 4 Revision: 1 Skins: WVGA854, HVGA (default), WVGA800, QVGA id: 4 or "android-5" Name: Android 2.0 Type: Platform API level: 5 Revision: 1 Skins: WVGA854, HVGA (default), WQVGA432, WVGA800, WQVGA400, QVGA Available Android Virtual Devices: All good but when I run as a user: /usr/local/android-sdk-linux/tools/ android I get: mpo...@vmhost:/usr/local$ /usr/local/android-sdk-linux/tools/android list Available Android targets: Available Android Virtual Devices: What is not working? -- 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] my trouble in displaying "hello,Android"
Hi,I'm a beginner of Android,I use eclipse3.5+ADT 0.9.4+Android SDK2.0 As I followed the guide of SDK to display my first "hello Android",I met with a problem the edited code is as follows: package com.android.hello; import android.app.Activity; import android.os.Bundle; import android.widget.TextView; public class HelloAndroid extends Activity { /** Called when the activity is first created. */ @Override public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); TextView tv = new TextView(this); tv.setText("Hello, Android"); setContentView(tv); } } When I run the program,the output the console is: [2009-11-04 21:18:01 - HelloAndroid] -- [2009-11-04 21:18:01 - HelloAndroid] Android Launch! [2009-11-04 21:18:01 - HelloAndroid] adb is running normally. [2009-11-04 21:18:01 - HelloAndroid] Launching: com.android.hello.helloworld [2009-11-04 21:18:01 - HelloAndroid] Automatic Target Mode: launching new emulator. [2009-11-04 21:18:01 - HelloAndroid] Launching a new emulator. [2009-11-04 21:18:06 - HelloAndroid] New emulator found: emulator-5554 [2009-11-04 21:18:06 - HelloAndroid] Waiting for HOME ('android.process.acore') to be launched... it just keeps hanging there for hours,what is the problem with my emulator? -- 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] Access to exchange email server
I am trying to use Locale to change my exchange email server when I go from 3G coverage to WiFI coverage inside my corporate building. Anyone have any idea where that is stored and how to access it? -- 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: Trouble passing a KML file to the DDMS Location Emulator
If you are getting KML from Google Earth then you may have to replace the default namespace with the following: http://earth.google.com/kml/2.x";> On Sep 25, 3:29 pm, "tarek.attia" wrote: > Hey,,Did you know how to do tht,,i'm facing the same > problem?,,, > > Please anybody Help me out > > On Aug 20, 8:44 pm, AKA wrote: > > > I'm sure this must be a simple/dumb thing I'm doing wrong, as I'm > > unable to find anyone else posting about this problem...so, my > > apologies in advance if this is a stupid question. > > > Basically, I'm trying to send mock location data to the Android > > Emulator via the DDMS application. I can successfully send locations > > one by one, using the "Manual Location" tab in DDMS. However, I can't > > get *any*KMLfiles to even show up in DDMS when I load them...I have > > tried many differentKMLfiles, including the simple example files > > provided by Google. > > > I am pretty sure I am doing something wrong, as I am quite new to > > Android. For example, I can't even get the DDMS window built in to > > Eclipse to show me the location-spoofing screen. I am running DDMS > > from the console. > > > Thanks in advance for any help you might be able to offer! > > > Best, > > > AKA > > -- 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] surfaceCreated() and CreateSurface() in camera preview application
I have some questions regarding the code below for camera preview applicaiton. I am hoping someone can help me out. Thanks in advance. 1. How does surfaceCreated() and CreateSurface() relate? Is this surface created via createSurface() from SurfaceFlinger client to SurfaceFlinger server? If so, there must be 2 buffers (frame buffers from display driver if there is hw acceleration or if it is the emulator, it will be from ashmem) associated with this surface: surface BB (for composition) and surface FB (for display). Am I correct? Can you please confirm? 2. How does the rendering buffer (frame buffer BB and frame buffer FB) get allocated in the camera preview application? Are they allocated by the application? 3. How does this surface relate to the preview buffers? Are the preview buffers allocated by the Camera Service during startPreview? private class CameraSurfaceView extends SurfaceView implements SurfaceHolder.Callback { private SurfaceHolder mHolder; private Camera camera = null; public CameraSurfaceView(Context context) { super(context); mHolder = getHolder(); mHolder.addCallback(this); mHolder.setType(SurfaceHolder.SURFACE_TYPE_PUSH_BUFFERS); } public void surfaceCreated(SurfaceHolder holder) { camera = Camera.open(); try { camera.setPreviewDisplay(mHolder); } catch (Exception e) { Log.e("Camera", "Failed to set camera preview display", e); } } } Thank you very much for your help. an -- 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] downloading and Building Android source for ARM9
Hi, Can anyone please help me in downloading and building the Android source for ARM 9 platform. My main aim is to download the Android image to the ARM board and to boot the device with Android. Please help me doing this. thanks Anks -- 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
Re: [android-beginners] "Hello World" not even running in Emulator
the emulator startup time can take any where from a few minutes to hours. Now that has to be the most ludicrous thing I've ever heard. What is the problem that it takes so long? -- 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] Network down issue
Hi, In my application i get response from web service and show its result from resultant stream at activity, i get stream as try { String connectTo = webService + webServiceMethod + queryString; connectTo = connectTo.replaceAll(" ", "%20"); URL url = new URL(connectTo); URLConnection ucon = url.openConnection(); ucon.setConnectTimeout(15000); ucon.connect(); InputStream is = ucon.getInputStream(); BufferedInputStream bis = new BufferedInputStream(is); return bis; } catch (SocketTimeoutException e) { throw e; } catch (MalformedURLException e) { throw e; } catch (IOException e) { throw e; } If emulator/device is connected with internet then this code work fine but if i disconnect internet and try to connect any URL then it keep continue to wait even few minutes, however i set connection timeout 15 seconds. This feel really bad. I want a smart solution, if internet is down or disconnected this code will throw SocketTimeOut exception or notify me AFTER 15 seconds that net is down. Ali Adnan. -- 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: Android SDK and AVD Manager Failed to fetch URL:HTTPS SSL error
You can try two things (or both): 1. Start the android command in the following way: GDK_NATIVE_WINDOWS=true android 2. Change the permissions on the directory ~/.android (temporarily) to 777: chmod 777 ~/.android It should now be possible to force the HTTPS connection to be an HTTP connection. Don't forget to change the permissions on the ~/.android directory back to 555. -- 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: "cannot find symbol" error when build CTS after update few source code
Anybody has worked on CTS? I tried many times, but failed. On Nov 20, 3:36 pm, Chenny wrote: > Dear friends, > > I am working the CTS test. And I would like to update some source code > for my own codec test. So "final int resid = R.raw.testvideo;" from > "MediaPlayerTest.java" has been modified as "final int resid = > R.raw.testvideompeg4;". And clip "testvideompeg4.3gp" has been put > into the relevant folder *\cts\tests\res\raw > > But when build, it is failed. And the error info as: > cts/tests/tests/media/src/android/media/cts/MediaPlayerTest.java:486: > cannot find symbol > symbol : variable testvideompeg4 > location: class com.android.cts.stub.R.raw > final int resid = > R.raw.testvideompeg4; ^ > 1 error > > Anybody has investigate CTS also? How could I design my own CTS? Any > clue is appreciated. > > Thanks very much! -- 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
Re: [android-beginners] why Java, not Python?
> Again, not trying to start any arguments, just curious if > anyone has any background on this. Well consider that Google AppEngine started in python and then added java support. In some ways, the python version is more advanced. I don't know why java was chosen but you have to believe that python was looked at seriously as well and for some reason ... I don't know the exact reasoning though. Shawn -- 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: Absolutely Infuriating
The missing member variable is in one of the tutorials. It isn't in the API demos. On Nov 22, 1:44 pm, Indicator Veritatis wrote: > So how was it that he got this error, and you did not? You did say the > API demos all compiled for you "out of the box", didn't you? Yet they > were missing this declaration of mTabHost, and the package imports. > > On Nov 19, 11:17 pm, Lance Nanek wrote: > > > >http://developer.android.com/guide/tutorials/views/hello-tabwidget.html > > >mTabHost will not resolve > > > That one can be fixed by adding this member variable above the > > onCreate function: > > private TabHost mTabHost; > > > The class will need to be imported as well. The imports above the > > class declaration should look like this: > > import android.app.TabActivity; > > import android.os.Bundle; > > import android.widget.TabHost; > > > On Nov 18, 6:11 pm, Captain Heff wrote: > > > > The API Demos also work for me, however, they're quite a large and > > > unorganised package. As a newbie to both Java and XML, I find tracking > > > down the information I need to make my own tabs in that mess quite > > > difficult. > > > > Instead I have tried to > > > use:http://developer.android.com/guide/tutorials/views/hello-tabwidget.html > > > - the Android dev guide to using tabs. > > > It gives me the error that mTabHost will not resolve. I'm unsure how > > > to fix this as I still can't figure out how to create tabs. Hence why > > > I'm looking for a simple example about tabs. > > > > I also tried two other > > > sources:http://jsharkey.org/blog/2008/02/07/using-android-tabhost/ > > > I figure that I'm copy pasting his code into the wrong place, because > > > it gives all kinds of errors. Some about the XML being wrong, and more > > > variable will not resolve errors. > > > > The third one I tried was about dynamic tabs, a link I found in this > > > site, but that one does not run. > > > > On Nov 19, 1:50 am, Lance Nanek wrote: > > > > > The API demos (platforms/android-2.0/samples/ApiDemos in the SDK > > > > directory) have 3 different tabs examples and compile and run fine for > > > > me. What error are you getting? > > > > > On Nov 17, 10:17 pm, Captain Heff wrote: > > > > > > Every single example of using Tabs - be it the example provided on the > > > > > Android dev site, to random samples found through Google - will not > > > > > compile in Eclipse, and furthermore, not run in the Android VM. This > > > > > makes it insanely hard to actually understand how to use this feature. > > > > > > Can anyone give me a quick once-over of how tabs work? -- 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: random problem
True. Even then, this is probably not the code he really wants. Instead of using casts on a Random method returning doubles, he could use the java.lang.util.Random.nextInt() method to get an integer in the range he specifies. Then instead of "(int( (Math.random()*9)+1" he could have, after a declaration like "Random mRandGen = new Random();", mRandGen.nextInt(9) +1; to return a random integer from 1 to 10. Code w/o casts is generally better than code with casts. Unless, of course, it resorts to drastic contortions to avoid the case. But such is not the case here., On Nov 19, 11:10 pm, Lance Nanek wrote: > The value of this expression will always be zero: > (int) Math.random() > > Casting to an integer removes the fractional portion. Casting has a > higher operator precedence than multiplication or addition, so happens > first in your full expression. Parentheses could be used to alter when > the cast happens, however. Like this: > (int) (Math.random() * 9) + 1 > > On Nov 18, 11:00 am, Jags wrote: > > > I am fairly new to android and java > > > i tried following code to generate different random numbers in the > > ranges of 1 - 9 > > > i wrote following code > > > int i = (int) Math.random() * 9 + 1; > > while (i == previousIndex) { > > i = (int) Math.random() * 9 + 1; > > } > > > always i is getting 0 and goes to infinite loop, why so ? > > > sorry for a novice question though :P -- 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] why Java, not Python?
Not trying to start a flame war here, just curious about the decision to use Java as the main language for Android development instead of Python. For one Python is one of the main languages used by Google, and both languages are byte-code interpreted. Python has a very rich set of libraries which make it easy to do things quite succinctly. For instance if I wanted to know how old a friend's baby exactly is I could do something like: from datetime import datetime start = datetime(2009, 10, 3, 9, 45, 0, 0) age = datetime.now() - start print 'Birthday/time :', start print 'Baby's exact age:', age Perhaps I don't know Java well enough, but this would be much more verbose/complex to do in Java. Again, not trying to start any arguments, just curious if anyone has any background on this. 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: Absolutely Infuriating
So how was it that he got this error, and you did not? You did say the API demos all compiled for you "out of the box", didn't you? Yet they were missing this declaration of mTabHost, and the package imports. On Nov 19, 11:17 pm, Lance Nanek wrote: > >http://developer.android.com/guide/tutorials/views/hello-tabwidget.html > >mTabHost will not resolve > > That one can be fixed by adding this member variable above the > onCreate function: > private TabHost mTabHost; > > The class will need to be imported as well. The imports above the > class declaration should look like this: > import android.app.TabActivity; > import android.os.Bundle; > import android.widget.TabHost; > > On Nov 18, 6:11 pm, Captain Heff wrote: > > > The API Demos also work for me, however, they're quite a large and > > unorganised package. As a newbie to both Java and XML, I find tracking > > down the information I need to make my own tabs in that mess quite > > difficult. > > > Instead I have tried to > > use:http://developer.android.com/guide/tutorials/views/hello-tabwidget.html > > - the Android dev guide to using tabs. > > It gives me the error that mTabHost will not resolve. I'm unsure how > > to fix this as I still can't figure out how to create tabs. Hence why > > I'm looking for a simple example about tabs. > > > I also tried two other > > sources:http://jsharkey.org/blog/2008/02/07/using-android-tabhost/ > > I figure that I'm copy pasting his code into the wrong place, because > > it gives all kinds of errors. Some about the XML being wrong, and more > > variable will not resolve errors. > > > The third one I tried was about dynamic tabs, a link I found in this > > site, but that one does not run. > > > On Nov 19, 1:50 am, Lance Nanek wrote: > > > > The API demos (platforms/android-2.0/samples/ApiDemos in the SDK > > > directory) have 3 different tabs examples and compile and run fine for > > > me. What error are you getting? > > > > On Nov 17, 10:17 pm, Captain Heff wrote: > > > > > Every single example of using Tabs - be it the example provided on the > > > > Android dev site, to random samples found through Google - will not > > > > compile in Eclipse, and furthermore, not run in the Android VM. This > > > > makes it insanely hard to actually understand how to use this feature. > > > > > Can anyone give me a quick once-over of how tabs work? -- 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: Trouble with updating widgets
Hi, onUpdate will never fire if you are using onReceive at all. If you override onRecieve you have to handle all the messages yourself inside it, include the update message. -niko On Nov 18, 6:03 pm, DMc wrote: > Hello, > > I am trying to create a widget which updates at a user defined period, > following this > tutorial:http://www.developer.com/ws/article.php/10927_3833306_2/Creating-a-Ho... > > All has been going well but I cannot get the onReceive and onUpdate > events to fire on the Provider. > > This is the code to set up my AlarmManager > > Intent widgetUpdate = new Intent(); > > widgetUpdate.setAction > (AppWidgetManager.ACTION_APPWIDGET_UPDATE); > > widgetUpdate.putExtra(AppWidgetManager.EXTRA_APPWIDGET_ID, > appWidgetId ); > > widgetUpdate.setData(Uri.withAppendedPath(Uri.parse > (ProfileDisplayWidgetProvider.URI_SCHEME + "://widget/id/"), > String.valueOf(appWidgetId))); > > PendingIntent newPending = PendingIntent.getBroadcast > (getApplicationContext(), 0, widgetUpdate, > PendingIntent.FLAG_UPDATE_CURRENT); > > AlarmManager alarms = (AlarmManager) getApplicationContext > ().getSystemService(Context.ALARM_SERVICE); > > alarms.setRepeating(AlarmManager.ELAPSED_REALTIME, > SystemClock.elapsedRealtime(), 15 * 1000, newPending); > > If I remove the widgetUpdate.setData() line, then the onReceive event > fires, but not the onUpdate. With that line in, nothing fires. > > Could anyone give me any pointers on possible ways to fix this. > > Thanks > > David -- 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: Tab views, onStart() ???
Jason In my application i hva etwo tabs. One for inttant queue and one for disc queue(netflix) as the user presses the tabs (back and forth) the listview on each tab refreshes. You can use onTabCHanged to keep control of which tab the user is on, and call a custom method to re-populate the listview. I promise you can do this without bothering with any of the higher activity flow methods (onStart..etc) public void onTabChanged(String tabId) { //this may get called when setting up layout, so only listen if user's session is active if(sessionStatus==SESSION_ACTIVE){ FlurryAgent.onEvent("onTabChanged"); if (mTabHost.getCurrentTab() == TAB_INSTANT) { if (canWatchInstant) { queueType = NetFlixQueue.QUEUE_TYPE_INSTANT; loadQueue(); } else { showCustomDialog( "Restricted", "According to Netflix this user does not have \"Watch Instantly\" rights\nPress 'Back' to return to your Disc Queue"); mTabHost.setCurrentTab (TAB_DISC); } } else if (mTabHost.getCurrentTab() == TAB_DISC) { queueType = NetFlixQueue.QUEUE_TYPE_DISC; loadQueue(); } } } /* loadQueue makes an API call to get fresh or cached data, and then calls redrawQueue to actually repopulate the currently displayed tab. */ protected void redrawQueue() { switch (mTabHost.getCurrentTab()) { case TAB_DISC: mListView = (ListView) findViewById (R.id.discqueue); mListView.setAdapter(new ArrayAdapter(this, android.R.layout.simple_list_item_1, NetFlix.discQueue .getDiscs())); break; case TAB_INSTANT: mListView = (ListView) findViewById (R.id.instantqueue); mListView.setAdapter(new ArrayAdapter(this, android.R.layout.simple_list_item_1, NetFlix.instantQueue .getDiscs())); break; } mListView.setTextFilterEnabled(true); mListView.setOnItemClickListener(this); // register for long hold on menu items registerForContextMenu(mListView); } Enjoy. On Nov 22, 4:21 am, Lance Nanek wrote: > I'm using an activity that extends android.app.Activity for the > contents of each tab. Only the activity that hosts the tabs extends > android.app.TabActivity. > > It might be worth checking to make sure that you tested onResume and > not onStart. As you can see in the logs above, onStart only gets > called the first time you go to a tab that isn't started using > FLAG_ACTIVITY_CLEAR_TOP, just like you mentioned seeing. > > On Nov 21, 6:27 pm, JasonMP wrote: > > > Interesting. Are you using separate TabActivities for each tab or do > > you have them all called from a resource file with || > > findViewById()? > > > I tested it too...albeit probably not a very accurate way...with just > > having it make a simple Toast in the onResume() and onCreate() > > callbacks and would only get the Toast displayed the first time I went > > to that tab after starting the app. > > > On Nov 20, 9:50 pm, Lance Nanek wrote: > > > > Hmm, I'm definitely seeing onResume getting called in a quick test app > > > with logging of life cycle methods for the activities in the tabs. > > > > That said, you can get even more life cycle methods called each time > > > by using the Intent.FLAG_ACTIVITY_CLEAR_TOP flag like in the API > > > demos:http://developer.android.com/intl/zh-CN/guide/samples/ApiDemos/src/co... > > > > I'll attach the logs below for starting on the first tab, then going > > > to the others in this order: > > > second, third, first, second, third > > > > The activity for the third tab is being launched with the clear top > > > flag. > > > > I/LifeCycleLogger: first tab( 1904): onCreate > > > I/LifeCycleLogger: first tab( 1904): onContentChanged > > > I/LifeCycleLogger: first tab( 1904): onStart > > > I/LifeCycleLogger: first tab( 1904): onPostCreate > > > I/LifeCycleLogger: first tab( 1904): onResume > > > I/LifeCycleLogger: first tab( 1904): onPostResume > > > I/LifeCycleLogger: tabs( 1904): Startup and showing first tab > > > complete. > > > I/LifeCycleLogger: first tab( 1904): onSaveInstanceState > > > I/LifeCycleLogger: first tab( 1904): onPause > > > I/LifeCycleLogger: second tab( 1904): onCreate
[android-beginners] wifi configuration
Hi Does someone has a clue how to configure the WiFiManager and what are the basic parameters to be set before calling 'addNetwork' method? Thanks/Regards -- 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: Tab views, onStart() ???
I'm using an activity that extends android.app.Activity for the contents of each tab. Only the activity that hosts the tabs extends android.app.TabActivity. It might be worth checking to make sure that you tested onResume and not onStart. As you can see in the logs above, onStart only gets called the first time you go to a tab that isn't started using FLAG_ACTIVITY_CLEAR_TOP, just like you mentioned seeing. On Nov 21, 6:27 pm, JasonMP wrote: > Interesting. Are you using separate TabActivities for each tab or do > you have them all called from a resource file with || > findViewById()? > > I tested it too...albeit probably not a very accurate way...with just > having it make a simple Toast in the onResume() and onCreate() > callbacks and would only get the Toast displayed the first time I went > to that tab after starting the app. > > On Nov 20, 9:50 pm, Lance Nanek wrote: > > > Hmm, I'm definitely seeing onResume getting called in a quick test app > > with logging of life cycle methods for the activities in the tabs. > > > That said, you can get even more life cycle methods called each time > > by using the Intent.FLAG_ACTIVITY_CLEAR_TOP flag like in the API > > demos:http://developer.android.com/intl/zh-CN/guide/samples/ApiDemos/src/co... > > > I'll attach the logs below for starting on the first tab, then going > > to the others in this order: > > second, third, first, second, third > > > The activity for the third tab is being launched with the clear top > > flag. > > > I/LifeCycleLogger: first tab( 1904): onCreate > > I/LifeCycleLogger: first tab( 1904): onContentChanged > > I/LifeCycleLogger: first tab( 1904): onStart > > I/LifeCycleLogger: first tab( 1904): onPostCreate > > I/LifeCycleLogger: first tab( 1904): onResume > > I/LifeCycleLogger: first tab( 1904): onPostResume > > I/LifeCycleLogger: tabs( 1904): Startup and showing first tab > > complete. > > I/LifeCycleLogger: first tab( 1904): onSaveInstanceState > > I/LifeCycleLogger: first tab( 1904): onPause > > I/LifeCycleLogger: second tab( 1904): onCreate > > I/LifeCycleLogger: second tab( 1904): onContentChanged > > I/LifeCycleLogger: second tab( 1904): onStart > > I/LifeCycleLogger: second tab( 1904): onPostCreate > > I/LifeCycleLogger: second tab( 1904): onResume > > I/LifeCycleLogger: second tab( 1904): onPostResume > > I/LifeCycleLogger: tabs( 1904): Changed to tab: second tab > > I/LifeCycleLogger: second tab( 1904): onSaveInstanceState > > I/LifeCycleLogger: second tab( 1904): onPause > > I/LifeCycleLogger: third tab( 1904): onCreate > > I/LifeCycleLogger: third tab( 1904): onContentChanged > > I/LifeCycleLogger: third tab( 1904): onStart > > I/LifeCycleLogger: third tab( 1904): onPostCreate > > I/LifeCycleLogger: third tab( 1904): onResume > > I/LifeCycleLogger: third tab( 1904): onPostResume > > I/LifeCycleLogger: tabs( 1904): Changed to tab: third tab > > I/LifeCycleLogger: third tab( 1904): onSaveInstanceState > > I/LifeCycleLogger: third tab( 1904): onPause > > I/LifeCycleLogger: first tab( 1904): onResume > > I/LifeCycleLogger: first tab( 1904): onPostResume > > I/LifeCycleLogger: tabs( 1904): Changed to tab: first tab > > I/LifeCycleLogger: first tab( 1904): onSaveInstanceState > > I/LifeCycleLogger: first tab( 1904): onPause > > I/LifeCycleLogger: second tab( 1904): onResume > > I/LifeCycleLogger: second tab( 1904): onPostResume > > I/LifeCycleLogger: tabs( 1904): Changed to tab: second tab > > I/LifeCycleLogger: second tab( 1904): onSaveInstanceState > > I/LifeCycleLogger: second tab( 1904): onPause > > I/LifeCycleLogger: third tab( 1904): onStop > > I/LifeCycleLogger: third tab( 1904): onDestroy > > I/LifeCycleLogger: third tab( 1904): onCreate > > I/LifeCycleLogger: third tab( 1904): onContentChanged > > I/LifeCycleLogger: third tab( 1904): onStart > > I/LifeCycleLogger: third tab( 1904): onPostCreate > > I/LifeCycleLogger: third tab( 1904): onResume > > I/LifeCycleLogger: third tab( 1904): onPostResume > > I/LifeCycleLogger: tabs( 1904): Changed to tab: third tab > > > On Nov 20, 1:40 pm, JasonMP wrote: > > > > presumably, except my code that I place in the onResume never gets run > > > when the tabs are switched. > > > > On Nov 20, 1:27 pm, Lance Nanek wrote: > > > > > Doesn't onPause get called on the activity whose tab you are leaving > > > > and onResume get called for the activity whose tab you are going to? > > > > > On Nov 20, 11:22 am, JasonMP wrote: > > > > > > Eddie, > > > > > > The onTabChanged must be called from with my main TabActivity correct? > > > > > > If this is the case this isn't the solution I'm looking for. I have a > > > > > TabHost that run a new activity in a tab. From within that activity I > > > > > will the screen with a ListView. I need to be able to refresh that > > > > > ListView each time the user selects that tab. > > > > > > On Nov 20, 10:25 am, JasonMP wrote: > > > > > > > Hey, Thanks Eddie. > > > > > > > On Nov 20, 10:18 am, Smelly Eddie wrote: > > > > > > > > Hmmm.. > > > > > >