Android 按钮未在honeyconb中显示

Android 按钮未在honeyconb中显示,android,button,android-3.0-honeycomb,Android,Button,Android 3.0 Honeycomb,这是我自定义的“更改密码”对话框 最后两个按钮btnChangePwd和btnCancelPwd在wildfire(android 2.2)中正确显示,但在galay选项卡(android 3.1)中没有正确显示。它只是一片空白 守则的其他部分包括: final Dialog dialog = new Dialog(this, R.style.FullHeightDialog); final View passwordDialog = LayoutInflater.from(this).in

这是我自定义的“更改密码”对话框


最后两个按钮btnChangePwd和btnCancelPwd在wildfire(android 2.2)中正确显示,但在galay选项卡(android 3.1)中没有正确显示。它只是一片空白

守则的其他部分包括:

final Dialog dialog = new Dialog(this, R.style.FullHeightDialog);
final View passwordDialog = LayoutInflater.from(this).inflate(R.layout.newpassword, null);
dialog.setContentView(passwordDialog);


<resources>
    <style name="FullHeightDialog" parent="android:style/Theme.Dialog">
        <item name="android:windowNoTitle">true</item>
    </style>
</resources>
final Dialog=new Dialog(这个,R.style.FullHeightDialog);
最终视图passwordDialog=LayoutInflater.from(this).flate(R.layout.newpassword,null);
setContentView(密码对话框);
真的

实际上,我认为这是2.2中的一个bug。Wildfire,因为xml的指定方式,这些按钮永远不会出现。问题是:

<TableLayout android:layout_width="fill_parent" android:layout_height="fill_parent" android:layout_margin="5dp" android:stretchColumns="1">


参见关于布局高度的部分?这意味着这将填充父级,接下来的按钮将被从屏幕上推出。在emulator中,无论使用什么版本,都会发生这种情况。将其更改为“包装内容”将显示按钮。

感谢您指出这一点。我的错。但令人惊讶的是,height=“fill\u parent”非常适合对话框,而不是活动。(这个更改并没有解决我的问题!)哇,真奇怪,它在emulator for 3.2的对话框中为我解决了这个问题。如果我离开填充父项,则不会显示任何按钮,如果我更改为换行内容,则会显示这些按钮。我想我得在我的账单上试一下,看看为什么它不能解决这个问题。
<TableLayout android:layout_width="fill_parent" android:layout_height="fill_parent" android:layout_margin="5dp" android:stretchColumns="1">