|
|
@@ -196,7 +196,9 @@ struct Window::PrivateData { |
|
|
|
puglSetSpecialFunc(fView, onSpecialCallback); |
|
|
|
puglSetReshapeFunc(fView, onReshapeCallback); |
|
|
|
puglSetCloseFunc(fView, onCloseCallback); |
|
|
|
#ifndef DGL_FILE_BROWSER_DISABLED |
|
|
|
puglSetFileSelectedFunc(fView, fileBrowserSelectedCallback); |
|
|
|
#endif |
|
|
|
|
|
|
|
puglCreateWindow(fView, nullptr); |
|
|
|
|
|
|
@@ -1022,10 +1024,12 @@ struct Window::PrivateData { |
|
|
|
handlePtr->onPuglClose(); |
|
|
|
} |
|
|
|
|
|
|
|
#ifndef DGL_FILE_BROWSER_DISABLED |
|
|
|
static void fileBrowserSelectedCallback(PuglView* view, const char* filename) |
|
|
|
{ |
|
|
|
handlePtr->fSelf->fileBrowserSelected(filename); |
|
|
|
} |
|
|
|
#endif |
|
|
|
|
|
|
|
#undef handlePtr |
|
|
|
|
|
|
@@ -1085,9 +1089,10 @@ void Window::repaint() noexcept |
|
|
|
// (void)name; |
|
|
|
// } |
|
|
|
|
|
|
|
#ifndef DGL_FILE_BROWSER_DISABLED |
|
|
|
bool Window::openFileBrowser(const FileBrowserOptions& options) |
|
|
|
{ |
|
|
|
#ifdef SOFD_HAVE_X11 |
|
|
|
# ifdef SOFD_HAVE_X11 |
|
|
|
using DISTRHO_NAMESPACE::String; |
|
|
|
|
|
|
|
// -------------------------------------------------------------------------- |
|
|
@@ -1145,11 +1150,12 @@ bool Window::openFileBrowser(const FileBrowserOptions& options) |
|
|
|
// show |
|
|
|
|
|
|
|
return (x_fib_show(pData->xDisplay, pData->xWindow, /*options.width*/0, /*options.height*/0) == 0); |
|
|
|
#else |
|
|
|
# else |
|
|
|
// not implemented |
|
|
|
return false; |
|
|
|
#endif |
|
|
|
# endif |
|
|
|
} |
|
|
|
#endif |
|
|
|
|
|
|
|
bool Window::isVisible() const noexcept |
|
|
|
{ |
|
|
@@ -1280,9 +1286,11 @@ void Window::onClose() |
|
|
|
{ |
|
|
|
} |
|
|
|
|
|
|
|
#ifndef DGL_FILE_BROWSER_DISABLED |
|
|
|
void Window::fileBrowserSelected(const char*) |
|
|
|
{ |
|
|
|
} |
|
|
|
#endif |
|
|
|
|
|
|
|
bool Window::handlePluginKeyboard(const bool press, const uint key) |
|
|
|
{ |
|
|
|