问题描述
我一遍又一遍地遇到这种烦恼,但一直无法在这里找到解决方案或答案:
I have run into this annoyance over and over again and have been unable to find a solution or an answer here for it:
当我在我的应用程序中创建一个包然后在其中添加一个包时,如果我的目录中没有文件,它会在 Android Studio 的左侧导航中自动折叠我的包.这会阻止我将其他子包添加到父包中,而无需手动解决文件系统中的问题.
When I create a package in my application and then add a package within it, if I do not have a file in the directory already it will auto collapse my package in the left-side navigation of Android Studio. This prevents me from adding other sub-packages to the parent package, without manually resolving the issue within the file system.
例如:
我想要的是:
-presentation
-screens
-devicescreen
-adapters
-presenters
-views
推荐答案
在 1:Project
视图中,您已打开 Hide Empty Middle Packages
.你需要把它关掉.一旦关闭,它将显示为Compact Empty Middle Package
.请看附上的截图.
In the 1:Project
view, you have Hide Empty Middle Packages
turned ON. You need to turn it off. Once turned off it will be shown as Compact Empty Middle Package
. Please look at the screenshot attached.
这篇关于如何防止 Android Studio 在项目导航中自动折叠我的包?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!