[android-beginners] Re: Missing/Hidden/Dissappearing Button problem
Did you try passing the drawable on the Button XML? ... android:background=@drawable/attack_any / or you can only obtain the drawable at runtime? (dynamic drawable) On May 28, 1:43 pm, Tollas tolla...@gmail.com wrote: Button android:id=@+id/attack_ability_button android:layout_width=52dp android:layout_height=52dp android:layout_x=10dp android:layout_y=70dp/ final Button attack_ability_button = (Button)findViewById(R.id.attack_ability_button); attack_ability_button.setBackgroundDrawable(getResources().getDrawable(R.drawable.attack_any)); My problem is that when I use the attack_any drawable to create the button, it just isn't there. If I change to another image of the same size, the button shows up just fine. I've tried replacing the image file, renaming it, resizing it. Always with the same results. I tried using the attack_any drawable for another button and it disappears as well. I've also tried moving the button and changing its size, but the problem persists. I've even tried drawing the background in XML rather than java and it still will not show up. attack_any.png is a 60x60px image 1kb in size. Scroll View -Absolute Layout -- You received this message because you are subscribed to the Google Groups Android Beginners group. NEW! Try asking and tagging your question on Stack Overflow at http://stackoverflow.com/questions/tagged/android 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] [SCREENCAST] How to do Unit Testing for Android on Eclipse.
In case you're frustrated and gave up on setting up your unit tests, or if you're planning to do unit test driven development, I've made a screencast to illustrate how I managed to run unit tests (after a lot of reading all over the place, this is what worked for me) http://www.gubatron.com/blog/2010/05/02/how-to-do-unit-testing-on-android-with-eclipse/ Hope it will help a lot of new developers. Cheers, Gubatron -- You received this message because you are subscribed to the Google Groups Android Beginners group. NEW! Try asking and tagging your question on Stack Overflow at http://stackoverflow.com/questions/tagged/android 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] Searching Files that have been scanned by the MediaScanner
Is there a way to programatically search the files scanned by the MediaScanner? I see that you can only connect to it to let it know about new files it should scan. I thought I could use SearchManager, but I don't want to trigger the user interface I need to do something else with the search results. I'd like to have something like this: ListSearchFilter searchFilters; ... ListFile results = SearchIndex.search(keyword, searchFilters); or at least be able to iterate through all the scanned files, otherwise I'll have to scan myself and that's not the best idea. I've been looking at MediaStore and subclasses, but I see no search or iterative methods there (just a stupid keyFor(String name) method). I'd also like to be able to iterate through all the files that have been scanned. Can anybody point me to something similar. How can I get a hold of what MediaScanner has indexed, I need to iterate or search through those files. -- You received this message because you are subscribed to the Google Groups Android Beginners group. NEW! Try asking and tagging your question on Stack Overflow at http://stackoverflow.com/questions/tagged/android 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