diff options
author | Tor Lillqvist <tml@collabora.com> | 2014-05-06 15:00:41 +0300 |
---|---|---|
committer | Tor Lillqvist <tml@collabora.com> | 2014-05-06 15:01:31 +0300 |
commit | 5e80dd672fe64d44e05a2025e9569afdd62bb0d7 (patch) | |
tree | 6b54ec79069ed0dcd7e7425663a1912d6fe50282 /sfx2/inc | |
parent | aa8abbe736b0c8ad54f208916b0eca2d04ebd396 (diff) |
Move a few more headers that are included only in sfx2 to sfx2
Change-Id: I8bd81a45f5ef1b76fce1563b06e05a4eefcff0ec
Diffstat (limited to 'sfx2/inc')
-rw-r--r-- | sfx2/inc/sidebar/ContextChangeBroadcaster.hxx | 68 | ||||
-rw-r--r-- | sfx2/inc/sidebar/PopupContainer.hxx | 40 |
2 files changed, 108 insertions, 0 deletions
diff --git a/sfx2/inc/sidebar/ContextChangeBroadcaster.hxx b/sfx2/inc/sidebar/ContextChangeBroadcaster.hxx new file mode 100644 index 000000000000..de381929c05d --- /dev/null +++ b/sfx2/inc/sidebar/ContextChangeBroadcaster.hxx @@ -0,0 +1,68 @@ +/* -*- 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_SFX2_SIDEBAR_CONTEXTCHANGEBROADCASTER_HXX +#define INCLUDED_SFX2_SIDEBAR_CONTEXTCHANGEBROADCASTER_HXX + +#include <com/sun/star/frame/XFrame.hpp> + +namespace cssu = ::com::sun::star::uno; + +namespace sfx2 { namespace sidebar { + + +/** This class is a helper for broadcasting context changes that are + tied to shells being activated or deactivated. +*/ +class ContextChangeBroadcaster +{ +public: + ContextChangeBroadcaster (void); + ~ContextChangeBroadcaster (void); + + void Initialize (const ::rtl::OUString& rsContextName); + + void Activate (const cssu::Reference<css::frame::XFrame>& rxFrame); + void Deactivate (const cssu::Reference<css::frame::XFrame>& rxFrame); + + /** Enable or disable the broadcaster. + @param bIsEnabled + The new value of the "enabled" state. + @return + The old value of the "enabled" state is returned. + */ + bool SetBroadcasterEnabled (const bool bIsEnabled); + +private: + rtl::OUString msContextName; + bool mbIsBroadcasterEnabled; + + void BroadcastContextChange ( + const cssu::Reference<css::frame::XFrame>& rxFrame, + const ::rtl::OUString& rsModuleName, + const ::rtl::OUString& rsContextName); + ::rtl::OUString GetModuleName ( + const cssu::Reference<css::frame::XFrame>& rxFrame); +}; + + +} } // end of namespace ::sd::sidebar + +#endif + +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/sfx2/inc/sidebar/PopupContainer.hxx b/sfx2/inc/sidebar/PopupContainer.hxx new file mode 100644 index 000000000000..435b43b00969 --- /dev/null +++ b/sfx2/inc/sidebar/PopupContainer.hxx @@ -0,0 +1,40 @@ +/* -*- 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_SFX2_SIDEBAR_POPUPCONTAINER_HXX +#define INCLUDED_SFX2_SIDEBAR_POPUPCONTAINER_HXX + +#include <sfx2/dllapi.h> +#include <vcl/floatwin.hxx> + +namespace sfx2 { namespace sidebar { + +class SFX2_DLLPUBLIC PopupContainer : public FloatingWindow +{ +public: + PopupContainer (Window* pParent); + virtual ~PopupContainer (void); + + virtual long Notify (NotifyEvent& rNEvt); +}; + +} } // end of namespace sfx2::sidebar + +#endif + +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ |