Implement, and use internally, content_margins() from Widget.
Since AbstractScrollableWidget already has a method called content_size,
the convenience method, with the same name, in Widget has to be
explicitly called.
Derivatives of Core::Object should be constructed through
ClassName::construct(), to avoid handling ref-counted objects with
refcount zero. Fixing the visibility means that misuses like this are
more difficult.
This adds automatic scrolling when dragging items in TreeViews and other
widgets that inherit from AbstractView when the overloaded
accepts_drag() returns true. This is implemented in FileSystemModel to
allow directories and files to be dragged.
This commit adds a timer to AbstractScrollableWidget that can be used
when implementing automatic scrolling. By overriding
on_automatic_scrolling_timer_fired() we can calculate the scrolling
delta when dragging objects, and redraw as needed. A helper function,
automatic_scroll_delta_from_position() gives us a delta that
we can use to calculate speed and direction. By default
m_autoscroll_threshold is 20 pixels from the edge, and gives a linear
change in scroll delta.