Signed-off-by: falkTX <falktx@falktx.com>pull/272/head
@@ -31,8 +31,10 @@ ImageAboutWindow::ImageAboutWindow(Window& parentWindow, const Image& image) | |||||
{ | { | ||||
// TODO set transient | // TODO set transient | ||||
Window::setResizable(false); | Window::setResizable(false); | ||||
Window::setSize(image.getSize()); | |||||
Window::setTitle("About"); | Window::setTitle("About"); | ||||
if (image.isValid()) | |||||
Window::setSize(image.getSize()); | |||||
} | } | ||||
ImageAboutWindow::ImageAboutWindow(TopLevelWidget* const parentTopLevelWidget, const Image& image) | ImageAboutWindow::ImageAboutWindow(TopLevelWidget* const parentTopLevelWidget, const Image& image) | ||||
@@ -41,8 +43,10 @@ ImageAboutWindow::ImageAboutWindow(TopLevelWidget* const parentTopLevelWidget, c | |||||
{ | { | ||||
// TODO set transient | // TODO set transient | ||||
Window::setResizable(false); | Window::setResizable(false); | ||||
Window::setSize(image.getSize()); | |||||
Window::setTitle("About"); | Window::setTitle("About"); | ||||
if (image.isValid()) | |||||
Window::setSize(image.getSize()); | |||||
} | } | ||||
void ImageAboutWindow::setImage(const Image& image) | void ImageAboutWindow::setImage(const Image& image) | ||||
@@ -121,6 +121,10 @@ void Window::setSize(const uint width, const uint height) | |||||
{ | { | ||||
DISTRHO_SAFE_ASSERT_UINT2_RETURN(width > 1 && height > 1, width, height,); | DISTRHO_SAFE_ASSERT_UINT2_RETURN(width > 1 && height > 1, width, height,); | ||||
// FIXME add default and min props for this | |||||
if (pData->minWidth == 0 && pData->minHeight == 0) | |||||
puglSetDefaultSize(pData->view, width, height); | |||||
puglSetWindowSize(pData->view, width, height); | puglSetWindowSize(pData->view, width, height); | ||||
} | } | ||||
@@ -196,7 +196,11 @@ void UI::onResize(const ResizeEvent& ev) | |||||
if (uiData->resizeInProgress) | if (uiData->resizeInProgress) | ||||
return; | return; | ||||
uiData->setSizeCallback(ev.size.getWidth(), ev.size.getHeight()); | |||||
const uint width = ev.size.getWidth(); | |||||
const uint height = ev.size.getHeight(); | |||||
pData->window.setSize(width, height); | |||||
uiData->setSizeCallback(width, height); | |||||
} | } | ||||
#endif // !DISTRHO_PLUGIN_HAS_EXTERNAL_UI | #endif // !DISTRHO_PLUGIN_HAS_EXTERNAL_UI | ||||