There is a grey line on the EditText’s on On android 4.0.4 (Galaxy S3) You can see it at:
https://www.dropbox.com/s/c4xz2yjaw1fbamr/Screenshot_2012-10-10-11-59-29.png
There is no problem with Galaxy S(Android 2.3.3) you can see at:
https://www.dropbox.com/s/1l6a7u9f8ey7q76/device-2012-10-10-120640.png
I create them with the following code. I don’t do anything about it on XML files. What could be wrong with it?
Thanks
for (int i = 0; i < editTexts.length; i++) {
EditText rowEditText = new EditText(getBaseContext());
rowEditText.setSingleLine(true);
rowEditText.setTextColor(Color.BLACK);
rowEditText.setImeOptions(EditorInfo.IME_ACTION_NEXT);
filters[0] = new InputFilter.LengthFilter(10);
rowEditText.setFilters(filters);
rowEditText.setHint((i + 1) + ".Oyuncu");
LinearLayout.LayoutParams layoutParams=new LinearLayout.LayoutParams((int) (metrics.widthPixels * (0.6f)), (int) (metrics.heightPixels * (0.07f)));
spinnerlayout.addView(rowEditText,layoutParams);
editTexts[i] = rowEditText;
}
I found the problem.
The code was like this:
I changed to:
Lesson learned: don’t use getBaseContext() or getApplicationContext() in an activity