PanelExpanderButton的事件

PanelExpanderButton的点击范围太小,现在想和面板绑定,点击这个面板的时候,会触发这个面板下的PanelExpanderButton事件,先感谢各位的建议

Are you asking about how to handle a click event on some panel that is bigger than the “PanelExpanderButton” that you have in that panel? It really would help if you described your circumstances and what you want more completely, preferably with a small screenshot. That might reduce the guessing that I have to do.

I suppose you could implement your own GraphObject.click event handler that either:

我是想点击这块白色都区域,展开下面的详情

OK, then my previous answer does apply to your situation.

我将它绑定到白色区域了,能实现这个功能了,可是PanelExpanderButton本身点击不了了

OK, so now whenever the user clicks anywhere within the “Vertical” Panel, your click function will be called.

You may want to set click = null on the “PanelExpanderButton”, so that its click doesn’t happen and then bubble up to your handler, causing the panel visible property to be toggled twice.