I have a custom list view adapter *public* *class* CustomListAdapter *extends* ArrayAdapter<String>
that I use to modify list view cells. Now I have the need to modify some cells' content based on a global variable from the SharedPreferences. However, the adapter tells me it doesn't understand getApplication() so SharedPreferences settings = PreferenceManager.getDefaultSharedPreferences(getApplication()); doesn't work. How else am I supposed to get the application context ? via a static variable in the application singleton? -- You received this message because you are subscribed to the Google Groups "Android Developers" group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en