summaryrefslogtreecommitdiffstats
path: root/sd/source/ui/remotecontrol/Listener.hxx
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-07 09:06:44 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-07 09:06:44 +0000
commited5640d8b587fbcfed7dd7967f3de04b37a76f26 (patch)
tree7a5f7c6c9d02226d7471cb3cc8fbbf631b415303 /sd/source/ui/remotecontrol/Listener.hxx
parentInitial commit. (diff)
downloadlibreoffice-upstream.tar.xz
libreoffice-upstream.zip
Adding upstream version 4:7.4.7.upstream/4%7.4.7upstream
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'sd/source/ui/remotecontrol/Listener.hxx')
-rw-r--r--sd/source/ui/remotecontrol/Listener.hxx62
1 files changed, 62 insertions, 0 deletions
diff --git a/sd/source/ui/remotecontrol/Listener.hxx b/sd/source/ui/remotecontrol/Listener.hxx
new file mode 100644
index 000000000..58d7483f6
--- /dev/null
+++ b/sd/source/ui/remotecontrol/Listener.hxx
@@ -0,0 +1,62 @@
+/* -*- 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/.
+ */
+#pragma once
+
+#include <sal/config.h>
+#include <com/sun/star/presentation/XSlideShowListener.hpp>
+
+#include <rtl/ref.hxx>
+#include <comphelper/compbase.hxx>
+#include <com/sun/star/uno/Reference.hxx>
+
+namespace com::sun::star::presentation { class XSlideShowController; }
+namespace sd { class Communicator; }
+namespace sd { class Transmitter; }
+
+namespace sd {
+/**
+ * Slide show listener. This class can also be used for anything else that is
+ * specific to the lifetime of one slideshow while a client is connected.
+ */
+class Listener
+ : public comphelper::WeakComponentImplHelper< css::presentation::XSlideShowListener >
+{
+public:
+ Listener( const ::rtl::Reference<Communicator>& rServer, sd::Transmitter *aTransmitter );
+ virtual ~Listener() override;
+ void init( const css::uno::Reference< css::presentation::XSlideShowController >& aController );
+
+ // XAnimationListener
+ virtual void SAL_CALL beginEvent(const css::uno::Reference<
+ css::animations::XAnimationNode >& rNode ) override;
+ virtual void SAL_CALL endEvent( const css::uno::Reference<
+ css::animations::XAnimationNode >& rNode ) override;
+ virtual void SAL_CALL repeat( const css::uno::Reference<
+ css::animations::XAnimationNode >& rNode, ::sal_Int32 Repeat ) override;
+
+ // XSlideShowListener
+ virtual void SAL_CALL paused( ) override;
+ virtual void SAL_CALL resumed( ) override;
+ virtual void SAL_CALL slideTransitionStarted( ) override;
+ virtual void SAL_CALL slideTransitionEnded( ) override;
+ virtual void SAL_CALL slideAnimationsEnded( ) override;
+ virtual void SAL_CALL slideEnded(sal_Bool bReverse) override;
+ virtual void SAL_CALL hyperLinkClicked( const OUString& hyperLink ) override;
+
+ // XEventListener
+ virtual void disposing(std::unique_lock<std::mutex>&) override;
+ virtual void SAL_CALL disposing (const css::lang::EventObject& rEvent) override;
+
+private:
+ rtl::Reference<Communicator> mCommunicator;
+ sd::Transmitter *pTransmitter;
+ css::uno::Reference< css::presentation::XSlideShowController > mController;
+};
+}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */