I'm trying to make my Activity
translucent, i.e. see-through, but it's not working. It's always opaque. That's my code so far:
public class SvetlinTranslucentActivity extends Activity {
/** Called when the activity is first created. */
@Override
public void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
Window w = getWindow();
w.setFormat(PixelFormat.RGBA_8888);
w.addFlags(WindowManager.LayoutParams.FLAG_DIM_BEHIND);
w.setBackgroundDrawable(new ColorDrawable(0x00FF0000));
}
}
I've been looking at the code from the official API demos but still no success.