Omnidome
Fulldome Mapping Software Toolkit
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
Public Member Functions | Private Attributes
omni::ui::mixin::Locked Class Reference

Mixin with a function to lock the widget temporarily. More...

#include <Locked.h>

Inheritance diagram for omni::ui::mixin::Locked:
Inheritance graph
[legend]

Public Member Functions

template<typename F >
void locked (F f)
 Lock widget and execute given functor. More...
 
bool isLocked () const
 Return true if widget is locked. More...
 

Private Attributes

bool locked_ = false
 Flag which sets if widgets are currently locked. More...
 

Detailed Description

Mixin with a function to lock the widget temporarily.

Member Function Documentation

bool omni::ui::mixin::Locked::isLocked ( ) const
inline

Return true if widget is locked.

41  {
42  return locked_;
43  }
bool locked_
Flag which sets if widgets are currently locked.
Definition: Locked.h:47
template<typename F >
void omni::ui::mixin::Locked::locked ( f)
inline

Lock widget and execute given functor.

31  {
32  bool _oldLocked = locked_;
33 
34  locked_ = true;
35  f();
36  locked_ = _oldLocked;
37  }
bool locked_
Flag which sets if widgets are currently locked.
Definition: Locked.h:47

Field Documentation

bool omni::ui::mixin::Locked::locked_ = false
private

Flag which sets if widgets are currently locked.


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