首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >mgwt自定义样式

mgwt自定义样式
EN

Stack Overflow用户
提问于 2013-03-24 22:08:24
回答 1查看 642关注 0票数 1

我正在尝试使用如下所示的自定义样式(https://code.google.com/p/mgwt/wiki/Styling):

代码语言:javascript
复制
public class MGWTColorTheme implements MGWTTheme {

                private MGWTClientBundle bundle;

                public MGWTColorTheme() {
                        if (MGWT.getOsDetection().isIOs()) {
                                if (MGWT.getOsDetection().isRetina()) {
                                        bundle = (MGWTColorBundleRetina) GWT.create(MGWTColorBundleRetina.class);
                                } else {
                                        bundle = (MGWTColorBundleNonRetina) GWT.create(MGWTColorBundleNonRetina.class);
                                }
                        } else {
                                bundle = (MGWTColorBundleNonRetina) GWT.create(MGWTColorBundleNonRetina.class);
                        }

                }

                @Override
                public MGWTClientBundle getMGWTClientBundle() {
                        return bundle;
                }

        }

代码语言:javascript
复制
MGWTStyle.setTheme(new MGWTColorTheme());

当我加载我的应用程序时,我得到以下错误:

代码语言:javascript
复制
Rebinding com.googlecode.mgwt.ui.client.theme.mgwt.MGWTColorBundleNonRetina
Invoking generator com.google.gwt.resources.rebind.context.InlineClientBundleGenerator
Creating assignment for getButtonBarCss()
Replacing CSS class names
The following unobfuscated classes were present in a strict CssResource:
text
Fix by adding String accessor method(s) to the CssResource interface for obfuscated classes, or using an @external declaration for unobfuscated classes.
EN

回答 1

Stack Overflow用户

回答已采纳

发布于 2013-03-25 05:09:30

这看起来像是在使用一个不完整的主题,其中包含css文件中的css类,而这些css类没有在java接口中声明。

如果您想开始使用mgwt样式,您可以很容易地克隆themebase项目并从那里开始:

https://code.google.com/p/mgwt/source/checkout?repo=themebase

票数 3
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/15599458

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档