getter for ncurses mutex
not sure if the best solution, but works for the moment
This commit is contained in:
parent
f48641bb58
commit
870fa80fc7
|
@ -27,6 +27,11 @@ namespace krikkel::NCurses
|
||||||
visibleStack.push_back(stackElement);
|
visibleStack.push_back(stackElement);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
std::recursive_mutex *TilingWindowManager::getNCursesMutex()
|
||||||
|
{
|
||||||
|
return ncursesMutex;
|
||||||
|
}
|
||||||
|
|
||||||
void TilingWindowManager::hideWindow(Window *window)
|
void TilingWindowManager::hideWindow(Window *window)
|
||||||
{
|
{
|
||||||
if(window->hidden)
|
if(window->hidden)
|
||||||
|
|
|
@ -36,7 +36,9 @@ namespace krikkel::NCurses
|
||||||
typedef std::pair<Window *, windowDimension> WindowStackElement;
|
typedef std::pair<Window *, windowDimension> WindowStackElement;
|
||||||
|
|
||||||
TilingWindowManager(NCursesWindow *rootWindow, std::recursive_mutex *ncursesMutex);
|
TilingWindowManager(NCursesWindow *rootWindow, std::recursive_mutex *ncursesMutex);
|
||||||
|
std::recursive_mutex *getNCursesMutex();
|
||||||
void addWindow(Window *window, windowDimension size = -1);
|
void addWindow(Window *window, windowDimension size = -1);
|
||||||
|
|
||||||
int resize(int rows, int cols) override;
|
int resize(int rows, int cols) override;
|
||||||
int refresh() override;
|
int refresh() override;
|
||||||
void updateLayout();
|
void updateLayout();
|
||||||
|
@ -45,6 +47,7 @@ namespace krikkel::NCurses
|
||||||
void showWindow(Window *window);
|
void showWindow(Window *window);
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
|
/// @todo rename to `nCursesMutex`?
|
||||||
std::recursive_mutex *ncursesMutex;
|
std::recursive_mutex *ncursesMutex;
|
||||||
std::list<WindowStackElement> stack, visibleStack;
|
std::list<WindowStackElement> stack, visibleStack;
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue