gpt4 book ai didi

android - 有没有办法让 Eclipse 将您的自定义 View 检测为其父布局?

转载 作者:太空狗 更新时间:2023-10-29 13:40:38 26 4
gpt4 key购买 nike

我创建了一个扩展 RelativeLayout 的自定义 View ,并在 xml 布局文件中添加了它的完整名称,它工作正常我只是问有没有办法让 Eclipse 将我的父布局检测为 RelativeLayout 以便自动-完成并建议与 RelativeLayout 相关的标签不给我空白建议,并说 eclipse 不知道该组件的任何直接子项。

<com.mypackage.myview> 
<!-- I want eclipse to detect that myView which is in com.mypackage extends RelativeLayout and show the suggestions such as Layout_align_parent_left-->
<Button ............... />
<TextView..................../>
</com.mypackage.myview>

最佳答案

这是旧版 ADT 中的错误,现已修复。

Reference

关于android - 有没有办法让 Eclipse 将您的自定义 View 检测为其父布局?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/6235998/

26 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com