Warning: file_get_contents(/data/phpspider/zhask/data//catemap/9/java/367.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181

Warning: file_get_contents(/data/phpspider/zhask/data//catemap/6/eclipse/8.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Java GWTQuery用户界面错误与.dialog()_Java_Eclipse_Gwt_Gwtquery - Fatal编程技术网

Java GWTQuery用户界面错误与.dialog()

Java GWTQuery用户界面错误与.dialog(),java,eclipse,gwt,gwtquery,Java,Eclipse,Gwt,Gwtquery,我试图在开普勒使用带有GWTQuery用户界面的对话框,但无法找出问题所在。我尽我所能地遵循在那里找到的指示。我有以下代码设置 gwt.xml <inherits name='gwtquery.plugins.UiGoogleCdn' /> <inherits name='gwtquery.plugins.UiEmbedded' /> 我在项目的html中有以下内容 <div style="display: none;" class="gwt-

我试图在开普勒使用带有GWTQuery用户界面的对话框,但无法找出问题所在。我尽我所能地遵循在那里找到的指示。我有以下代码设置

gwt.xml

    <inherits name='gwtquery.plugins.UiGoogleCdn' />  
    <inherits name='gwtquery.plugins.UiEmbedded' />
我在项目的html中有以下内容

<div style="display: none;" class="gwt-DlgBox">This is a test to see if this shows up</div>
调试时,我得到错误:第80行:引用方法“com.google.gwt.query.client.Function.f(Lcom/google/gwt/user/client/Event;Ljava/lang/Object;)”:无法解析方法

当我通过代码x=1时;这是正确的,但是.dialog()行失败,出现上述错误

当我尝试编译它时,我得到以下错误

[错误]jar:file:/C:/src/gwtquery-ui-r146.jar中的错误/gwtquery/plugins/ui/UiWidget.java' [错误]第80行:引用方法'com.google.gwt.query.client.Function.f(Lcom/google/gwt/user/client/Event;Ljava/lang/Object;)':无法解析方法

任何帮助都将不胜感激。是的,我是GWT的新手,只是不明白我错过了什么


谢谢。

如果您使用的是gwtquery 1.4.2,那么这可能就是问题所在。我通过降级到gwtquery 1.3.3解决了这个问题

<div style="display: none;" class="gwt-DlgBox">This is a test to see if this shows up</div>
@UiHandler("btnShow")
public void btnShow(ClickEvent event)
{
        int x = 0;
    try
    {
            x = $(".gwt-DlgBox").length();
        $(".gwt-DlgBox").as(Ui).dialog();
    }
    catch(Throwable e)
    {
        e=e;  // just so I can debug break here.
    }
}