I displayed the image gallary .when I click on the image in the image gallary it will be displayed on the full screen .
Gallery g=(Gallery)findViewById(R.id.gallery);
g.setAdapter(new ImageAdapter(this));
g.setOnItemClickListener(new OnItemClickListener() {
public void onItemClick(AdapterView parent, View v, int position, long id)开发者_如何学编程 {
Toast.makeText(sampledatabase.this, "" + position, Toast.LENGTH_SHORT).show(); });
}}
to let Activitty to open in full screen type this
getWindow().setFlags(
WindowManager.LayoutParams.FLAG_FULLSCREEN,
WindowManager.LayoutParams.FLAG_FULLSCREEN);
And to remove the title bar type this
requestWindowFeature(Window.FEATURE_NO_TITLE);
精彩评论