开发者

Adding ToolTip (Description) to Vaadin ComboBox doesn't work, why?

开发者 https://www.devze.com 2023-04-11 17:54 出处:网络
I tried it with cb.setDescription(\"text\") but it has no effect. So I searched the web but couldn\'t fi开发者_运维百科nd anything about, why doesn\'t it work?

I tried it with cb.setDescription("text") but it has no effect. So I searched the web but couldn't fi开发者_运维百科nd anything about, why doesn't it work?

Here's the code:

ComboBox cb = new ComboBox();
cb.setSizeUndefined();`
cb.setInputPrompt("xyz");
cb.addItem("x");
cb.addItem("y");
cb.setItemCaption("x", "xxx");
cb.setItemCaption("y", "yyy");
cb.setInvalidAllowed(false);
cb.setNullSelectionAllowed(false);
cb.setNewItemsAllowed(false);
cb.setStyleName('xyz');
cb.select("x");
cb.setEnabled(false);
cb.setDescription("tooltiptext");
layout.addComponent(cb);        


May be it connected with this issue. Right now it shown only on mouse over for cobmobox button, but not textfield.


I dont belive you can have it setEditable(false) and get a caption so try with setEnabled(true) and also use setImmediate(true)

0

精彩评论

暂无评论...
验证码 换一张
取 消