ya thanks i have got it...actually i was taking it like it will return the whole window object but later i knew that it will return a focused view only.. am currently trying to take object of OEM screen while incoming call....but not getting it in nay way..i want to do override/overlay the OEM screen with my apps screen if u can help in this thing please guide me in which way i should make efforts...
On Tue, Jul 20, 2010 at 10:49 PM, TreKing <[email protected]> wrote: > On Mon, Jul 19, 2010 at 4:47 AM, A N K ! T <[email protected]>wrote: > >> while am trying to fetch current focus object i.e View ,,,,by >> usinggetcurrent focus method ...but view object not getting any value it is >> showing null value >> > > Step 1: Read the documentation: > Activity.getCurrentFocus<http://developer.android.com/reference/android/app/Activity.html#getCurrentFocus%28%29> > > "Calls > getCurrentFocus()<http://developer.android.com/reference/android/view/Window.html#getCurrentFocus%28%29> > on > the Window of this Activity to return the currently focused view." > > OK, so let's look at > Window.getCurrentFocus<http://developer.android.com/reference/android/view/Window.html#getCurrentFocus%28%29> > : > > "Return the view in this Window that currently has focus, or null if there > are none." > > Oh, so if there is no focus, you get null. Since you are getting null, you > have no focused view. Problem solved. > > please let me know what shu i do now > > > Check for null. > > Time taken posting on the group: about a day and a half. > Time taken reading the documentation: about a minute and a half. > > > ------------------------------------------------------------------------------------------------- > TreKing <http://sites.google.com/site/rezmobileapps/treking> - Chicago > transit tracking app for Android-powered devices > > -- > You received this message because you are subscribed to the Google > Groups "Android Developers" group. > To post to this group, send email to [email protected] > To unsubscribe from this group, send email to > [email protected]<android-developers%[email protected]> > For more options, visit this group at > http://groups.google.com/group/android-developers?hl=en -- Thanks & Regards Ankit Awasthi Bangalore Contact No.: 07676955989 E-mail : [email protected] -- You received this message because you are subscribed to the Google Groups "Android Developers" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en

