When I write this code:
Display display = getWindowManager().getDefaultDisplay();
DisplayMetrics size = new DisplayMetrics();
display.
Eclipse doesn't pop up the functions of my display object. It shows these (new, nls, runnable, toarray) only:
How can I solve?
EDIT: Here are my imports:
import android.util.DisplayMetrics;
import android.view.Display;
import android.view.WindowManager;
If you have updated to Eclipse Kepler recently (or perhaps, even if you haven't!), make sure "Java Proposals" is ticked under "Java/Editor/Content Assist/Advanced"

EDIT: I did not notice that your code block was not within any method and just in the body of your class. Move it into onCreate() or some other lifecycle method and it will work.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With