HAL  v4.5.0-130-g83e8bfb3f
The Hardware Analyzer - a comprehensive reverse engineering and manipulation framework for gate-level netlists.
hal::xilinx_toolbox::GuiLayoutLocker Class Reference

Suppresses layout updates of the GUI for as long as the object exists. More...

#include </home/runner/work/hal/hal/plugins/xilinx_toolbox/include/xilinx_toolbox/utils/gui_layout_locker.h>

Collaboration diagram for hal::xilinx_toolbox::GuiLayoutLocker:
Collaboration graph

Public Member Functions

 GuiLayoutLocker ()
 Suppress layout updates of the GUI until the locker is destroyed. More...
 
 ~GuiLayoutLocker ()
 Release the lock and let the GUI update the views that changed in the meantime. More...
 
 GuiLayoutLocker (const GuiLayoutLocker &)=delete
 
GuiLayoutLockeroperator= (const GuiLayoutLocker &)=delete
 

Detailed Description

Suppresses layout updates of the GUI for as long as the object exists.

A netlist modification that touches many gates makes the GUI re-layout its graph views once per change, which can dominate the runtime of the modification itself. Holding a locker defers those updates until it goes out of scope, at which point every affected view is updated once.

Locks nest, so it is safe to hold more than one at a time. Does nothing if no GUI is running, which makes it safe to use from code that also runs headless.

Definition at line 52 of file gui_layout_locker.h.

Constructor & Destructor Documentation

◆ GuiLayoutLocker() [1/2]

hal::xilinx_toolbox::GuiLayoutLocker::GuiLayoutLocker ( )

Suppress layout updates of the GUI until the locker is destroyed.

Definition at line 35 of file gui_layout_locker.cpp.

References hal::UIPluginInterface::set_layout_locker().

◆ ~GuiLayoutLocker()

hal::xilinx_toolbox::GuiLayoutLocker::~GuiLayoutLocker ( )

Release the lock and let the GUI update the views that changed in the meantime.

Definition at line 43 of file gui_layout_locker.cpp.

References hal::UIPluginInterface::set_layout_locker().

◆ GuiLayoutLocker() [2/2]

hal::xilinx_toolbox::GuiLayoutLocker::GuiLayoutLocker ( const GuiLayoutLocker )
delete

Member Function Documentation

◆ operator=()

GuiLayoutLocker& hal::xilinx_toolbox::GuiLayoutLocker::operator= ( const GuiLayoutLocker )
delete

The documentation for this class was generated from the following files: