summaryrefslogtreecommitdiff
path: root/vcl/inc
diff options
context:
space:
mode:
authorNoel Grandin <noel.grandin@collabora.co.uk>2021-07-13 13:00:23 +0200
committerNoel Grandin <noel.grandin@collabora.co.uk>2021-07-13 15:04:29 +0200
commitb862ec6ac16f3e02be7845bb0db7a77250cb587d (patch)
tree3b860a05f2f79a7889822ea6cdaabe3aa4ada1fc /vcl/inc
parent14653f89a83982ef36346ebc15f14099fd5cf8f1 (diff)
merge UnoGraphicTransformer into UnoGraphic
it is never instantiated by itself. And this also means it now only has one OWeakObject base class Change-Id: I3074130539ab023fec5537e0e7794e1c2db7e6ee Reviewed-on: https://gerrit.libreoffice.org/c/core/+/118835 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'vcl/inc')
-rw-r--r--vcl/inc/graphic/UnoGraphic.hxx19
-rw-r--r--vcl/inc/graphic/UnoGraphicTransformer.hxx58
2 files changed, 16 insertions, 61 deletions
diff --git a/vcl/inc/graphic/UnoGraphic.hxx b/vcl/inc/graphic/UnoGraphic.hxx
index ef4300cb5175..7ab50a0b903d 100644
--- a/vcl/inc/graphic/UnoGraphic.hxx
+++ b/vcl/inc/graphic/UnoGraphic.hxx
@@ -23,9 +23,9 @@
#include <com/sun/star/graphic/XGraphic.hpp>
#include <com/sun/star/lang/XUnoTunnel.hpp>
#include <com/sun/star/awt/XBitmap.hpp>
+#include <com/sun/star/graphic/XGraphicTransformer.hpp>
#include <graphic/UnoGraphicDescriptor.hxx>
-#include <graphic/UnoGraphicTransformer.hxx>
#include <vcl/graph.hxx>
@@ -34,8 +34,8 @@ namespace unographic {
class Graphic final : public css::graphic::XGraphic,
public css::awt::XBitmap,
public css::lang::XUnoTunnel,
- public ::unographic::GraphicDescriptor,
- public ::unographic::GraphicTransformer
+ public css::graphic::XGraphicTransformer,
+ public ::unographic::GraphicDescriptor
{
public:
Graphic();
@@ -70,6 +70,19 @@ private:
// XUnoTunnel
virtual sal_Int64 SAL_CALL getSomething( const css::uno::Sequence< sal_Int8 >& rId ) override;
+ // XGraphicTransformer
+ virtual css::uno::Reference< css::graphic::XGraphic > SAL_CALL colorChange(
+ const css::uno::Reference< css::graphic::XGraphic >& rGraphic,
+ sal_Int32 nColorFrom, sal_Int8 nTolerance, sal_Int32 nColorTo, sal_Int8 nAlphaTo ) override;
+
+ virtual css::uno::Reference< css::graphic::XGraphic > SAL_CALL applyDuotone(
+ const css::uno::Reference< css::graphic::XGraphic >& rGraphic,
+ sal_Int32 nColorOne, sal_Int32 nColorTwo ) override;
+
+ virtual css::uno::Reference< css::graphic::XGraphic > SAL_CALL applyBrightnessContrast(
+ const css::uno::Reference< css::graphic::XGraphic >& rxGraphic,
+ sal_Int32 nBrightness, sal_Int32 nContrast, sal_Bool mso ) override;
+
::Graphic maGraphic;
};
diff --git a/vcl/inc/graphic/UnoGraphicTransformer.hxx b/vcl/inc/graphic/UnoGraphicTransformer.hxx
deleted file mode 100644
index 785efdcd11b9..000000000000
--- a/vcl/inc/graphic/UnoGraphicTransformer.hxx
+++ /dev/null
@@ -1,58 +0,0 @@
-/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
-/*
- * This file is part of the LibreOffice project.
- *
- * This Source Code Form is subject to the terms of the Mozilla Public
- * License, v. 2.0. If a copy of the MPL was not distributed with this
- * file, You can obtain one at http://mozilla.org/MPL/2.0/.
- *
- * This file incorporates work covered by the following license notice:
- *
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements. See the NOTICE file distributed
- * with this work for additional information regarding copyright
- * ownership. The ASF licenses this file to you under the Apache
- * License, Version 2.0 (the "License"); you may not use this file
- * except in compliance with the License. You may obtain a copy of
- * the License at http://www.apache.org/licenses/LICENSE-2.0 .
- */
-
-#ifndef INCLUDED_VCL_SOURCE_GRAPHIC_TRANSFORMER_HXX
-#define INCLUDED_VCL_SOURCE_GRAPHIC_TRANSFORMER_HXX
-
-#include <cppuhelper/implbase1.hxx>
-#include <com/sun/star/graphic/XGraphicTransformer.hpp>
-
-namespace unographic {
-
-
-typedef ::cppu::WeakAggImplHelper1<
- css::graphic::XGraphicTransformer
- > GraphicTransformer_UnoImplHelper1;
-class GraphicTransformer : public GraphicTransformer_UnoImplHelper1
-{
- public:
-
- GraphicTransformer();
- virtual ~GraphicTransformer() override;
-
- // XGraphicTransformer
- virtual css::uno::Reference< css::graphic::XGraphic > SAL_CALL colorChange(
- const css::uno::Reference< css::graphic::XGraphic >& rGraphic,
- sal_Int32 nColorFrom, sal_Int8 nTolerance, sal_Int32 nColorTo, sal_Int8 nAlphaTo ) override;
-
- virtual css::uno::Reference< css::graphic::XGraphic > SAL_CALL applyDuotone(
- const css::uno::Reference< css::graphic::XGraphic >& rGraphic,
- sal_Int32 nColorOne, sal_Int32 nColorTwo ) override;
-
- virtual css::uno::Reference< css::graphic::XGraphic > SAL_CALL applyBrightnessContrast(
- const css::uno::Reference< css::graphic::XGraphic >& rxGraphic,
- sal_Int32 nBrightness, sal_Int32 nContrast, sal_Bool mso ) override;
-
-};
-
-}
-
-#endif
-
-/* vim:set shiftwidth=4 softtabstop=4 expandtab: */