2013-09-10 215 views
0

我得到下面的警告當我嘗試編譯我的GWT項目:GWT編譯警告

Specify -logLevel DEBUG to see all errors. 
      [java]    
    [WARN] Unknown type 'com.google.gwt.editor.client.SimpleBeanEditorDriver' specified in deferred binding rule 
      [java] Scanning for additional dependencies: jar:file:<GWT_PATH>/2.4.0/gwt-user.jar!/com/google/gwt/cell/client/ButtonCellBase.java 
      [java]  Computing all possible rebind results for 'com.google.gwt.cell.client.ButtonCellBase.DefaultAppearance.Template' 
      [java]   Rebinding com.google.gwt.cell.client.ButtonCellBase.DefaultAppearance.Template 
      [java]    Invoking generator com.google.gwt.safehtml.rebind.SafeHtmlTemplatesGenerator 
      [java]    Constructing interface com.google.gwt.cell.client.ButtonCellBase.DefaultAppearance.Template 
      [java]     Generating method body for iconContentLayout() 
      [java]      
    [WARN] Template with variable in CSS attribute context: The template code generator cannot guarantee HTML-safety of the template -- please inspect manually or use Safe 
     Styles to specify arguments in a CSS attribute context 
      [java]      
    [WARN] Template with variable in CSS attribute context: The template code generator cannot guarantee HTML-safety of the template -- please inspect manually or use Safe 
     Styles to specify arguments in a CSS attribute context 
      [java]     Generating method body for iconWrapper() 
      [java]      
    [WARN] Template with variable in CSS attribute context: The template code generator cannot guarantee HTML-safety of the template -- please inspect manually or use Safe 
     Styles to specify arguments in a CSS attribute context 
      [java]      
    [WARN] Template with variable in CSS attribute context: The template code generator cannot guarantee HTML-safety of the template -- please inspect manually or use Safe 
      Styles to specify arguments in a CSS attribute context 
       [java] Compiling 6 permutations 
       [java]  Compiling permutation 0... 
       [java]  Compiling permutation 1... 
       [java]  Compiling permutation 2... 
       [java]  Compiling permutation 3... 
       [java]  Compiling permutation 4... 

誰能幫助我如何解決這個警告?

+0

可能重複[GWT「模板與CSS屬性上下文中的變量」警告是壞的?](http://stackoverflow.com/questions/8147978/gwt-template-with-variable-in-css-attribute-context -warning-is-bad) – otonglet

回答

0

該警告告訴您使用style='{theStyle}'其中theStyle是SafeStyles的一個實例,而不是使用類似style='width:{theWidth}'這樣的CSS格式。

+0

我的項目中有很多文件。我怎麼知道這個警告來自哪裏。你能舉一些例子嗎? 我一直在設置如下樣式: Button newBttn = new Button(); newBttn.setStyleName(「style1」); – Nikson