2014-04-15 51 views
6

我正在使用android studio 0.5.4。 我嘗試安裝crashlytics插件。我已經下載它並得到CrashlyticsAndroidStudioPlugin.zip。我已安裝它setttings > Plugins > Install plugin form disk > "OK". crashlytics按鈕已出現在工具欄上。但是,當我選擇myAndroidProject然後單擊「紅色crashlytics按鈕,」我得到了這些錯誤消息:Crashlytics Android Studio無法運行:NoClassDefFoundError:javax/swing/SwingUtilities

[ 596982] ERROR - llij.ide.plugins.PluginManager - javax/swing/SwingUtilities 
java.lang.NoClassDefFoundError: javax/swing/SwingUtilities 
     at com.crashlytics.tools.ide.app.Launcher.asyncShowShell(Launcher.java:1 
16) 
     at com.crashlytics.tools.intellij.app.CrashlyticsBridgeImpl.asyncShowPar 
entedShell(CrashlyticsBridgeImpl.java:179) 
     at com.crashlytics.tools.intellij.app.CrashlyticsBridgeImpl.access$000(C 
rashlyticsBridgeImpl.java:36) 
     at com.crashlytics.tools.intellij.app.CrashlyticsBridgeImpl$2.setSelecte 
d(CrashlyticsBridgeImpl.java:168) 
     at com.crashlytics.tools.intellij.actions.CrashlyticsAction.setSelected(
CrashlyticsAction.java:59) 
     at com.intellij.openapi.actionSystem.ToggleAction.actionPerformed(Toggle 
Action.java:42) 
     at com.intellij.openapi.actionSystem.ex.ActionUtil.performActionDumbAwar 
e(ActionUtil.java:164) 
     at com.intellij.openapi.actionSystem.impl.ActionButton.actionPerformed(A 
ctionButton.java:170) 
     at com.intellij.openapi.actionSystem.impl.ActionButton.performAction(Act 
ionButton.java:133) 
     at com.intellij.openapi.actionSystem.impl.ActionButton.processMouseEvent 
(ActionButton.java:311) 
     at java.awt.Component.processEvent(Component.java:6292) 
     at java.awt.Container.processEvent(Container.java:2234) 
     at java.awt.Component.dispatchEventImpl(Component.java:4883) 
     at java.awt.Container.dispatchEventImpl(Container.java:2292) 
     at java.awt.Component.dispatchEvent(Component.java:4705) 
     at java.awt.LightweightDispatcher.retargetMouseEvent(Container.java:4898 
    ) 
     at java.awt.LightweightDispatcher.processMouseEvent(Container.java:4533) 

     at java.awt.LightweightDispatcher.dispatchEvent(Container.java:4462) 
     at java.awt.Container.dispatchEventImpl(Container.java:2278) 
     at java.awt.Window.dispatchEventImpl(Window.java:2739) 
     at java.awt.Component.dispatchEvent(Component.java:4705) 
     at java.awt.EventQueue.dispatchEventImpl(EventQueue.java:746) 
     at java.awt.EventQueue.access$400(EventQueue.java:97) 
     at java.awt.EventQueue$3.run(EventQueue.java:697) 
     at java.awt.EventQueue$3.run(EventQueue.java:691) 
     at java.security.AccessController.doPrivileged(Native Method) 
     at java.security.ProtectionDomain$1.doIntersectionPrivilege(ProtectionDo 
main.java:75) 
     at java.security.ProtectionDomain$1.doIntersectionPrivilege(ProtectionDo 
main.java:86) 
     at java.awt.EventQueue$4.run(EventQueue.java:719) 
     at java.awt.EventQueue$4.run(EventQueue.java:717) 
     at java.security.AccessController.doPrivileged(Native Method) 
     at java.security.ProtectionDomain$1.doIntersectionPrivilege(ProtectionDo 
main.java:75) 
     at java.awt.EventQueue.dispatchEvent(EventQueue.java:716) 
     at com.intellij.ide.IdeEventQueue.defaultDispatchEvent(IdeEventQueue.jav 
a:697) 
     at com.intellij.ide.IdeEventQueue._dispatchEvent(IdeEventQueue.java:520) 

     at com.intellij.ide.IdeEventQueue.dispatchEvent(IdeEventQueue.java:335) 
     at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThre 
ad.java:201) 
     at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread. 
java:116) 
     at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThre 
ad.java:105) 
     at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:101) 

     at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:93) 
     at java.awt.EventDispatchThread.run(EventDispatchThread.java:82) 
Caused by: java.lang.ClassNotFoundException: javax.swing.SwingUtilities not foun 
d by com.crashlytics.tools.intellij.core [1] 
     at org.apache.felix.framework.BundleWiringImpl.findClassOrResourceByDele 
gation(BundleWiringImpl.java:1460) 
     at org.apache.felix.framework.BundleWiringImpl.access$400(BundleWiringIm 
pl.java:72) 
     at org.apache.felix.framework.BundleWiringImpl$BundleClassLoader.loadCla 
ss(BundleWiringImpl.java:1843) 
     at java.lang.ClassLoader.loadClass(ClassLoader.java:357) 
     ... 42 more 
[ 597364] ERROR - llij.ide.plugins.PluginManager - Android Studio (Preview) 0.5 
.4 Build #AI-135.1101912 
[ 597365] ERROR - llij.ide.plugins.PluginManager - JDK: 1.8.0 
[ 597366] ERROR - llij.ide.plugins.PluginManager - VM: Java HotSpot(TM) Server 
VM 
[ 597367] ERROR - llij.ide.plugins.PluginManager - Vendor: Oracle Corporation 
[ 597368] ERROR - llij.ide.plugins.PluginManager - OS: Windows 7 
[ 597368] ERROR - llij.ide.plugins.PluginManager - Last Action: Actions.Crashly 
tics.CrashlyticsAction 

有人能幫助我嗎?你有沒有得到這些錯誤信息? 僅供參考:我正在使用Windows 7並使用java jdk1.8.0.

+0

同樣的問題給我。我使用Ubuntu 13.04和jdk 1.8.0。 – anp8850

回答

5

我一直在環顧四周,我認爲Java 8有一些事情要做。我看到有幾個人有這個問題。人們常說的事情是他們擁有Java 8.我剛剛檢查了Java 1.7.0_55。它似乎解決了這個問題。

+0

它的工作原理。謝謝@ slai47。 我嘗試安裝我的舊jdk:jdk1.6.0_27,並且不要忘記在我們安裝android studio時設置的windows環境變量,JAVA_HOME變量中更改路徑,將其從jdk 1.8.0路徑更改爲我的路徑jdk1.6.0路徑。它的工作原理。 –

+0

我解決了刪除Oracle Java 8然後:sudo aptitude install openjdk-7-jdk –