src/components/bar.cpp
/**
 * Event handler for XCB_ENTER_NOTIFY events
 *
 * Used to brighten the window by setting the
 * _NET_WM_WINDOW_OPACITY atom value
 */
Event handler for XCB_ENTER_NOTIFY events
Used to brighten the window by setting the
_NET_WM_WINDOW_OPACITY atom value
Event handler for XCB_ENTER_NOTIFY events Used to brighten the window by setting the _NET_WM_WINDOW_OPACITY atom value
void bar::handle(const evt::enter_notify&) {
  if (m_opts.dimmed) {
    m_dim_timer->start(25, 0, [this]() {
      m_opts.dimmed = false;
      m_sig.emit(dim_window{1.0});
    });
  } else if (m_dim_timer->is_active()) {
    m_dim_timer->stop();
  }
}
void bar :: handle ( const evt :: enter_notify & ) { if ( m_opts . dimmed ) { m_dim_timer -> start ( 25 , 0 , [ this ] ( ) { m_opts . dimmed = false ; m_sig . emit ( dim_window { 1.0 } ) ; } ) ; } else if ( m_dim_timer -> is_active ( ) ) { m_dim_timer -> stop ( ) ; } }
Event handler for XCB_ENTER_NOTIFY events
 Used to brighten the window by setting the
 _NET_WM_WINDOW_OPACITY atom value
Event handler for XCB_ENTER_NOTIFY events Used to brighten the window by setting the _NET_WM_WINDOW_OPACITY atom value