Android的工作室:如何调试Android SDK中的一步一步的旧版本旧版本、工作室、Android、SDK

2023-09-06 07:33:37 作者:不忘初心.

我有一个Android项目目标定位在Android SDK V21。现在我需要它与Android 4.4(即SDK V20)的设备上进行调试。我如何告诉机器人工作室附上源的老版本的内部类,这样我可以通过这些步骤?

I have an Android project targetting the Android SDK v21. Now I need to debug it on a device with Android 4.4 (i.e. SDK v20). How do I tell Android Studio to attach an older version of the source to the internal classes so that I can step through them?

推荐答案

在这里,最好的解决办法是设置编译SDK版本为20。这样构建工具将使用SDK版本编译20你的项目,你可以调试你的应用程序。

Here the best solution is to set compile SDK version to 20. So that build tools will compile your project using SDK version 20 and you can debug your app.

当你在项目中使用几个模块,你需要设置相同的编译SDK版本为每个模块。

When you use several modules in your project you need to set same compile SDK version to each module.