Events snap to 1 minute boundries

My aim is to make the timeline work in seconds and not minutes. the renderer goes down to 1 second and the headings are correct but when I try to create a new event (by dragging on the timeline it always snaps to 1 minute boundaries.

When I create a new event the start and end date seem to have the start of timeline view and end of timeline view instead of the time I clicked on. As I drag along the screen it seems to snap to 1 minute boundaries.

Judging by the code a x_unit of “seconds” is not supported although I have found some places where I can inject my new “second” functionality e.g. scheduler.date[“add_second”].

So 2 questions:

  1. Is there any documentation describing what other hooks there are to help change the behaviour (like add_seconds)?
  2. Where in the code is the part that alters the newly created event’s start and end?

As far as I can see problem caused by the inner method that converts mouse position to the time. It returns intermediate value as number of minutes. So there is no way to use second precision.

In timeline.js

pos.y = Math.round((end_date-this._min_date)/(1000*60*this.config.time_step));

You can try set small value for time_step config, but I’m not sure that it will work correctly

scheduler.config.time_step = 1/60;

Thanks I figured it out in the end with the help of Firebug!
The time_step worked as expected, I found a bug where I was resetting :frowning: