开发者

Eclipse RCP: Activating a view from an Editor without losing focus

开发者 https://www.devze.com 2023-02-18 03:50 出处:网络
I have a Tree Table in SWT.I want to show a view when the user starts editing a field on the view.However, I have the problem that when I go into the Editor, the activation of the view 开发者_Python百

I have a Tree Table in SWT. I want to show a view when the user starts editing a field on the view. However, I have the problem that when I go into the Editor, the activation of the view 开发者_Python百科steals the focus of the editor, so I can't use it anymore.

What would be the correct way to activate a view from my Tree Cell Editor, without losing Focus?


The problem was using the method to showView() in the Active Page.

For this particular case, it is necessary to use the method bringToFront() instead of showView(), as bringToFront() does not steal the focus.

0

精彩评论

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