【发布时间】:2011-11-23 07:05:27
【问题描述】:
我正在尝试在新布局加载时使按钮可点击... 发生了什么......我在布局1上,我显示了一些按钮...... 当我按下一个按钮时,它会立即向我显示一个带有来自另一个 .xml 的按钮的新布局。 但它不会让我点击布局 2 上的任何内容。 我如何让它发生? 我的代码如下从布局 1 到布局 R.layout.fail。
Button SectiontwoButton = (Button) findViewById(R.id.Sectiontwo);
SectiontwoButton.setOnClickListener(new OnClickListener() {
private Uri Uri;
@Override
public void onClick(View v) {
setContentView(R.layout.fail);
Uri uri=Uri;
Intent i=new Intent(Intent.ACTION_VIEW, uri);
mSoundManager.playSound(1);
}
});
谢谢
瓦希德
【问题讨论】:
标签: android layout android-intent