【发布时间】:2016-11-20 12:53:28
【问题描述】:
我目前在每个表单的顶部都有我的应用程序徽标。由于它占用大量空间,我希望它的大小随着用户向下滚动的次数而缩小,就像许多应用程序一样。
我的徽标目前只是一个容器,其徽标添加到布局中的 NORTH。你们中是否有人已经实现了类似的东西并且可以给我一个提示如何实现这一点?
提前致谢。
【问题讨论】:
标签: codenameone
我目前在每个表单的顶部都有我的应用程序徽标。由于它占用大量空间,我希望它的大小随着用户向下滚动的次数而缩小,就像许多应用程序一样。
我的徽标目前只是一个容器,其徽标添加到布局中的 NORTH。你们中是否有人已经实现了类似的东西并且可以给我一个提示如何实现这一点?
提前致谢。
【问题讨论】:
标签: codenameone
查看此博客文章以获取 title animations。这是帖子中的相关代码:
Form hi = new Form("Shai's Social App", new BoxLayout(BoxLayout.Y_AXIS));
for(int iter = 0 ; iter < 100 ; iter++) {
hi.add(new Label("Social Data Goes here..."));
}
Toolbar tb = new Toolbar();
hi.setToolbar(tb);
ComponentAnimation cna = tb.createStyleAnimation("TitleAreaClean", 200);
ComponentAnimation title = tb.getTitleComponent().createStyleAnimation("TitleClean", 200);
hi.getAnimationManager().onTitleScrollAnimation(cna, title);
hi.show();
【讨论】: