GWT 2.6编译时出现GXT-3.0.1错误 [英] GWT 2.6 with GXT-3.0.1 error in compile

查看:136
本文介绍了GWT 2.6编译时出现GXT-3.0.1错误的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

由于GWT的2.6.0版本放弃了ie6浏览器的支持,我当前使用GXT的项目也无法编译,出现以下错误:

 加载继承模块'com.sencha.gxt.ui.GXT'
加载继承模块'com.sencha.gxt.data.Data'
加载继承模块com.sencha .gxt.core.Core'
[错误]以前未定义ie6的值。
[错误]第96行:处理元素'set-property'时出现意外异常

i尝试设置
< set-property name =gxt.user.agentvalue =safari3,safari4,safari5,chrome,air,gecko1_8,gecko1_9/> < extend-property name =user.agent...... />
但没有任何成功。是否有任何解决方法?

解决方案

GWT 2.6.0对GWT 2.4.0和2.5.1进行了几次重大更改 - 这些并不影响所有库,但它们确实影响GXT 2和3。GWT 2.6.0中打破GXT库等代码更改包括:


  • 更改排列( ie6 opera )不见了, ie10 被添加,注意opera的新版本是基于webkit的,并且不需要它们自己的排列)
  • 元素添加了新的最终方法hasClassName和toggleClassName,它们不能用XElement方法编译
  • 删除字符串utils方法,切换到更新版本的Guava(现在使用这些方法)






看到一个upvote,所以我知道这个问题在几个月后仍然在读者中,所以编辑这个指出GXT 3.1.0在maven central中支持GWT 2.6.0,2.6.1,以及截至周五,sup端口GWT 2.7.0-SNAPSHOT。我不能保证它是完全面向未来的,但只要GWT中没有公共方法发生变化,就不可能在GWT 2.7系列中再次破坏。

since the 2.6.0 release of GWT which dropped support of ie6 browser my current project which also uses GXT is failing to compile with the following error:

Loading inherited module 'com.sencha.gxt.ui.GXT'
        Loading inherited module 'com.sencha.gxt.data.Data'
           Loading inherited module 'com.sencha.gxt.core.Core'
              [ERROR] The value ie6 was not previously defined.
              [ERROR] Line 96: Unexpected exception while processing element 'set-property'

i tried to set <set-property name="gxt.user.agent" value="safari3, safari4, safari5, chrome, air, gecko1_8, gecko1_9"/> and the <extend-property name="user.agent" ....../> but without any success. Are there any workarounds on this?

解决方案

GWT 2.6.0 has several breaking changes over GWT 2.4.0 and 2.5.1 - these don't affect all libraries, but they do affect both GXT 2 and 3. Code changes in GWT 2.6.0 that break libraries like GXT include:

  • Changing permutations (ie6 and opera are gone, ie10 was added, note that newer versions of opera are webkit based and do not need their own permutation)
  • Element added new final methods hasClassName and toggleClassName that can't compiled with XElement methods of the same name
  • String utils methods removed, switched to newer version of Guava (which now uses those methods)

Saw an upvote, so I know this is still getting readers months later, so editing this to point out that GXT 3.1.0 is in maven central and supports GWT 2.6.0, 2.6.1, and as of Friday anyway, supports GWT 2.7.0-SNAPSHOT. I can't promise it is totally future-proof, but as long no public methods in GWT change, it isn't likely to break again in the GWT 2.7 series.

这篇关于GWT 2.6编译时出现GXT-3.0.1错误的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆