summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--include/toolkit/awt/vclxfont.hxx7
-rw-r--r--toolkit/source/awt/vclxfont.cxx3
-rw-r--r--toolkit/source/helper/vclunohelper.cxx2
3 files changed, 2 insertions, 10 deletions
diff --git a/include/toolkit/awt/vclxfont.hxx b/include/toolkit/awt/vclxfont.hxx
index efad4b590da7..c4f768954c6e 100644
--- a/include/toolkit/awt/vclxfont.hxx
+++ b/include/toolkit/awt/vclxfont.hxx
@@ -23,7 +23,6 @@
#include <memory>
#include <toolkit/dllapi.h>
#include <com/sun/star/awt/XFont2.hpp>
-#include <com/sun/star/lang/XUnoTunnel.hpp>
#include <comphelper/servicehelper.hxx>
#include <cppuhelper/implbase.hxx>
#include <mutex>
@@ -38,8 +37,7 @@ class FontMetric;
class TOOLKIT_DLLPUBLIC VCLXFont final :
public cppu::WeakImplHelper<
- css::awt::XFont2,
- css::lang::XUnoTunnel>
+ css::awt::XFont2>
{
std::mutex maMutex;
css::uno::Reference< css::awt::XDevice> mxDevice;
@@ -56,9 +54,6 @@ public:
void Init( css::awt::XDevice& rxDev, const vcl::Font& rFont );
const vcl::Font& GetFont() const { return maFont; }
- // css::lang::XUnoTunnel
- UNO3_GETIMPLEMENTATION_DECL(VCLXFont)
-
// css::lang::XFont
css::awt::FontDescriptor SAL_CALL getFontDescriptor( ) override;
css::awt::SimpleFontMetric SAL_CALL getFontMetric( ) override;
diff --git a/toolkit/source/awt/vclxfont.cxx b/toolkit/source/awt/vclxfont.cxx
index 866a362e710f..01e7aaae7944 100644
--- a/toolkit/source/awt/vclxfont.cxx
+++ b/toolkit/source/awt/vclxfont.cxx
@@ -64,9 +64,6 @@ bool VCLXFont::ImplAssertValidFontMetric()
return mpFontMetric != nullptr;
}
-// css::lang::XUnoTunnel
-UNO3_GETIMPLEMENTATION_IMPL( VCLXFont );
-
css::awt::FontDescriptor VCLXFont::getFontDescriptor( )
{
std::unique_lock aGuard( maMutex );
diff --git a/toolkit/source/helper/vclunohelper.cxx b/toolkit/source/helper/vclunohelper.cxx
index bac88c66268a..42b55c6db04f 100644
--- a/toolkit/source/helper/vclunohelper.cxx
+++ b/toolkit/source/helper/vclunohelper.cxx
@@ -250,7 +250,7 @@ vcl::Font VCLUnoHelper::CreateFont( const css::awt::FontDescriptor& rDescr, cons
vcl::Font VCLUnoHelper::CreateFont( const css::uno::Reference< css::awt::XFont >& rxFont )
{
vcl::Font aFont;
- VCLXFont* pVCLXFont = comphelper::getFromUnoTunnel<VCLXFont>( rxFont );
+ VCLXFont* pVCLXFont = dynamic_cast<VCLXFont*>( rxFont.get() );
if ( pVCLXFont )
aFont = pVCLXFont->GetFont();
return aFont;