diff --git a/vcl/inc/unx/gtk/gtkinst.hxx b/vcl/inc/unx/gtk/gtkinst.hxx index a597e5be2436..6446122611e5 100644 --- a/vcl/inc/unx/gtk/gtkinst.hxx +++ b/vcl/inc/unx/gtk/gtkinst.hxx @@ -33,6 +33,7 @@ #include #include #include +#include #include #include #include @@ -343,6 +344,12 @@ public: { return m_pWeldWidget; } + + sal_Int64 SAL_CALL getSomething(css::uno::Sequence const& aIdentifier) override + { + return comphelper::getSomethingImpl( + aIdentifier, this, comphelper::FallbackToGetSomethingOf{}); + } }; GdkPixbuf* load_icon_by_name(const OUString& rIconName); diff --git a/vcl/unx/gtk3/fpicker/SalGtkFilePicker.cxx b/vcl/unx/gtk3/fpicker/SalGtkFilePicker.cxx index 4068d57f2fa1..762f1338fe62 100644 --- a/vcl/unx/gtk3/fpicker/SalGtkFilePicker.cxx +++ b/vcl/unx/gtk3/fpicker/SalGtkFilePicker.cxx @@ -34,6 +34,7 @@ #include #include #include +#include #include #include #include @@ -1631,7 +1632,7 @@ GtkWidget* SalGtkPicker::GetParentWidget(const uno::Sequence& rArgumen if (xParentWindow.is()) { - if (SalGtkXWindow* pGtkXWindow = dynamic_cast(xParentWindow.get())) + if (SalGtkXWindow* pGtkXWindow = comphelper::getFromUnoTunnel(xParentWindow)) pParentWidget = pGtkXWindow->getGtkWidget(); else { diff --git a/vcl/unx/gtk3/gtkinst.cxx b/vcl/unx/gtk3/gtkinst.cxx index 0525f8118531..960aabe11a0b 100644 --- a/vcl/unx/gtk3/gtkinst.cxx +++ b/vcl/unx/gtk3/gtkinst.cxx @@ -65,6 +65,7 @@ #include #include #include +#include #include #include #include @@ -24483,7 +24484,7 @@ weld::MessageDialog* GtkInstance::CreateMessageDialog(weld::Widget* pParent, Vcl weld::Window* GtkInstance::GetFrameWeld(const css::uno::Reference& rWindow) { - if (SalGtkXWindow* pGtkXWindow = dynamic_cast(rWindow.get())) + if (SalGtkXWindow* pGtkXWindow = comphelper::getFromUnoTunnel(rWindow)) return pGtkXWindow->getFrameWeld(); return SalInstance::GetFrameWeld(rWindow); }