2017-09-03 70 views
0

今天我有一個Android Studio/libGDX的問題。 我無法導入任何android-things,如「android.os.Handler」。Android Studio&libGDX - android.os。*無法實現(所有android無法實現)

截圖:

enter image description here

我希望你能幫助我。 :)) 有一個愉快的一天。

//編輯: 這裏的控制檯: console errors

+0

你是在'core module'中導入嗎? – Aryan

+0

你好Abhishek雅利安和首先,謝謝你的評論。嗯,是的,我正在導入核心模塊:截圖:https://image.prntscr.com/image/_NxE6kBnTo6UEh0G3LOU4w.png – Kenox

回答

1

無法訪問/進口的Android任何類別的android module

可能的原因插件Android是禁用或刪除/損壞

從您的Android Studio主屏幕中刪除

配置 - >插件 - > Android的

然後確定,然後重新啓用插件


編輯

從您的評論您正在訪問的Android API在core module

您無法訪問核心模塊內的Android API。核心模塊是所有平臺的通用部分。

通過interfacing您可以使用訪問平臺特定的代碼。

+0

嘿! :) - 感謝您的評論 - 但我已經檢查過所有插件:屏幕截圖:https://image.prntscr.com/image/vozEFCrjTjGW0ceGadlOQg.png – Kenox

+0

我不明白。 :( - 我怎樣才能解決它?我讀了鏈接,但它並沒有那麼有用,但謝謝!:) – Kenox

+0

你不能在'核心模塊'中使用android API的'Handler' – Aryan