本文介绍了Eclipse 错误:未处理的事件循环异常没有更多句柄的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我使用 Swing 和 MigLayout 构建了一个 GUI.

I've built a GUI using Swing and the MigLayout.

我在 Windows 7 Ultimate 上使用 Eclipse 4.2.2(64 位).每次我单击返回窗口以编辑我的代码时,都会出现一个弹出窗口,然后提示我重新启动 Eclipse,并且事件日志显示以下内容:

I am using Eclipse 4.2.2 (64-bit) on Windows 7 Ultimate.Every time I click back into the window to edit my code, a popup comes up, then I'm prompted to restart Eclipse, and the Event log says the following:

 org.eclipse.swt.SWTError: No more handles
    at org.eclipse.swt.SWT.error(SWT.java:4387)
    at org.eclipse.swt.SWT.error(SWT.java:4276)
    at org.eclipse.swt.SWT.error(SWT.java:4247)
    at org.eclipse.swt.widgets.Widget.error(Widget.java:468)
    at org.eclipse.swt.widgets.Control.createHandle(Control.java:704)
    at org.eclipse.swt.widgets.Label.createHandle(Label.java:199)
    at org.eclipse.swt.widgets.Control.createWidget(Control.java:744)
    at org.eclipse.swt.widgets.Control.<init>(Control.java:112)
    at org.eclipse.swt.widgets.Label.<init>(Label.java:101)
    ...

我附上了错误消息的屏幕截图.有没有其他人在 Eclipse 中遇到过这个错误?您知道解决方法或修复方法吗?

I'm attaching screenshots of the error messages.Has anyone else encountered this bug with Eclipse? Do you know of a work-around or a fix?

推荐答案

有一个解决方法:将 Java 编辑器更改为 WindowBuilder.

There is a workaround: Change the Java editor to WindowBuilder.

Eclipse →窗户→首选项 →文件关联 →,选择 WindowBuilder Editor 作为 Java 默认编辑器.

Eclipse → Windows → Preferences → File Associations →, choose WindowBuilder Editor as Java default editor.

这篇关于Eclipse 错误:未处理的事件循环异常没有更多句柄的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

08-18 09:08