To improve repaint performance, the manager
view allows you to skip some of the repaint requests.
When you manipulate a graphic object in a
manager view, the repaint requests are sent to all views that are
attached to the same manager. The view in which you are
manipulating the graphic object should be refreshed as often as
possible, so that you receive feedback on your manipulation in real
time. This view is called the main view.
During the manipulation, it is unlikely that
you would pay attention to the other views attached to the same
manager. Therefore, it is not essential to keep refreshing these
auxiliary view as often as the main view. It is the main view that
holds the focus of the manipulation.
In a typical configuration you have the main
view showing a region of a large map and an auxiliary overview
showing where the region occurs in the map. When you zoom or
manipulate objects in the main view, you do not need the overview
to be refreshed as often as the main view.
To save CPU processing time and to gain
fluidity in the main view, the refresh rate of the auxiliary views
can be reduced.
When the refresh delay is set, the manager
view will skip some repeated repaint requests if the delay has not
elapsed since the last time the view was refreshed. You can adjust
the setting of this parameter between 300ms and 800ms according to
your needs. For example, to set the delay to 300ms, use the manager
view method:
setRepaintSkipThreshold(300);
The default value is 0, which disables this
feature.
Important
You should use this feature with caution.
In certain circumstances it might skip some desired repaint
requests and pollute the view until the delay elapses.
To avoid skipping desired repaints, you can temporarily turn the
view repaint mode to DIRECT_REDRAW. Repaints are skipped only
under THREADED_REDRAW mode.