Page 1 of 1

Can't find a good event for when the splitter is dropped after dragging

Posted: Wed Sep 04, 2024 8:11 pm
by amorimluc

In order to save user settings for where they place the splitter between the grid and the gantt chart I need an event that triggers when the splitter is dropped at the desired location. The 'resize' event triggers right after the user starts dragging, so it's always off and not where they drop it. Would appreciate help with this.


Re: Can't find a good event for when the splitter is dropped after dragging

Posted: Thu Sep 05, 2024 8:56 am
by tasnim

Hi,

You can find all the splitter events here https://bryntum.com/products/grid/docs/api/Core/widget/Splitter#events

Here is an example of how to listen for splitter events

new Splitter({
	appendTo : 'container',
	listeners : {
		drop() {...}
	}
})

If you have any other questions or concerns, please don't hesitate to reach out to us.


Re: Can't find a good event for when the splitter is dropped after dragging

Posted: Thu Sep 05, 2024 11:50 am
by amorimluc

I'm not using any Splitter object like that though. I mean just the default splitter vertical bar that separates the left grid from the right timeline in the Gantt chart. How can I set a drop even on that vertical bar?


Re: Can't find a good event for when the splitter is dropped after dragging

Posted: Thu Sep 05, 2024 2:33 pm
by ghulam.ghous

Hi there,

PLease use this event on gantt:

    listeners : {
        splitterDragStart : (props) => {
            console.log('Splitter Drag Start: ', props);
        },
        splitterDragEnd : (props) => {
            console.log('Splitter Drag End: ', props);
        }
    },

https://bryntum.com/products/gantt/docs/api/Grid/feature/RegionResize#eventhandler-onSplitterDragEnd
https://bryntum.com/products/gantt/docs/api/Grid/feature/RegionResize#eventhandler-onSplitterDragStart

Regards,
Ghous


Re: Can't find a good event for when the splitter is dropped after dragging

Posted: Thu Sep 05, 2024 2:52 pm
by amorimluc

That worked, thank you.