Class EMFFormsSWTLayoutDelayed

  • All Implemented Interfaces:
    EMFFormsSWTLayoutOptimizer

    public class EMFFormsSWTLayoutDelayed
    extends java.lang.Object
    implements EMFFormsSWTLayoutOptimizer
    This Layout Optimizer caches the incoming layout request for 200ms before triggering the layout.
    Since:
    1.12
    Author:
    Eugen Neufeld
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void layout​(org.eclipse.swt.widgets.Composite parent)
      This method will collect layoutrequest that happen in the same 200ms.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • EMFFormsSWTLayoutDelayed

        public EMFFormsSWTLayoutDelayed()
    • Method Detail

      • layout

        public void layout​(org.eclipse.swt.widgets.Composite parent)

        This method will collect layoutrequest that happen in the same 200ms. When there are multiple layoutrequest for the same composite in this time frame, the composite will only be layouted once.

        This will help to improve performance as layout request are usually expensive. Also it might be quite common that e.g. multiple hide rules are triggered by the same condition.

        Specified by:
        layout in interface EMFFormsSWTLayoutOptimizer
        Parameters:
        parent - the composite to layout