/* -*- 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 SW_USRFLD_HXX #define SW_USRFLD_HXX #include "swdllapi.h" #include "fldbas.hxx" class SfxPoolItem; class SwCalc; class SwDoc; class SW_DLLPUBLIC SwUserFieldType : public SwValueFieldType { bool bValidValue : 1; bool bDeleted : 1; double nValue; rtl::OUString aName; String aContent; sal_uInt16 nType; public: SwUserFieldType( SwDoc* pDocPtr, const String& ); virtual const rtl::OUString& GetName() const; virtual SwFieldType* Copy() const; String Expand(sal_uInt32 nFmt, sal_uInt16 nSubType, sal_uInt16 nLng); String GetContent( sal_uInt32 nFmt = 0 ); void SetContent( const String& rStr, sal_uInt32 nFmt = 0 ); inline bool IsValid() const; inline void ChgValid( bool bNew ); double GetValue(SwCalc& rCalc); // Recalculate member nValue. inline double GetValue() const; inline void SetValue(const double nVal); inline sal_uInt16 GetType() const; inline void SetType(sal_uInt16); bool IsDeleted() const { return bDeleted; } void SetDeleted( bool b ) { bDeleted = b; } virtual bool QueryValue( com::sun::star::uno::Any& rVal, sal_uInt16 nMId ) const; virtual bool PutValue( const com::sun::star::uno::Any& rVal, sal_uInt16 nMId ); protected: virtual void Modify( const SfxPoolItem* pOld, const SfxPoolItem* pNew ); }; inline bool SwUserFieldType::IsValid() const { return bValidValue; } inline void SwUserFieldType::ChgValid( bool bNew ) { bValidValue = bNew; } inline double SwUserFieldType::GetValue() const { return nValue; } inline void SwUserFieldType::SetValue(const double nVal) { nValue = nVal; } inline sal_uInt16 SwUserFieldType::GetType() const { return nType; } inline void SwUserFieldType::SetType(sal_uInt16 nSub) { nType = nSub; EnableFormat(!(nSub & nsSwGetSetExpType::GSE_STRING)); } class SW_DLLPUBLIC SwUserField : public SwValueField { sal_uInt16 nSubType; virtual String Expand() const; virtual SwField* Copy() const; public: SwUserField(SwUserFieldType*, sal_uInt16 nSub = 0, sal_uInt32 nFmt = 0); virtual sal_uInt16 GetSubType() const; virtual void SetSubType(sal_uInt16 nSub); virtual double GetValue() const; virtual void SetValue( const double& rVal ); virtual String GetFieldName() const; // Name cannot be changed. virtual const rtl::OUString& GetPar1() const; // Content. virtual rtl::OUString GetPar2() const; virtual void SetPar2(const rtl::OUString& rStr); virtual bool QueryValue( com::sun::star::uno::Any& rVal, sal_uInt16 nWhichId ) const; virtual bool PutValue( const com::sun::star::uno::Any& rVal, sal_uInt16 nWhichId ); }; #endif // SW_USRFLD_HXX /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ 4'>distro/collabora/cp-4.4 LibreOffice 核心代码仓库文档基金会
summaryrefslogtreecommitdiff
path: root/sfx2/source/sidebar/ContextChangeBroadcaster.cxx
AgeCommit message (Collapse)Author
2020-11-08lok: sidebar: disable context deactivationHenry Castro
In the Collabora Online, for every SfxViewFrame instance, it has a relationship with a user name, and it is not allowed to deactivate the sidebar of the other user. However, in the Desktop case, a user name has a relationship to many SfxViewFrame instances and it can deactivate the sidebar when a SfxViewFrame instance receives the input focus. Change-Id: If1936f1dc3779664970bd584e2b9d6f595c4b072 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/104115 Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com> Reviewed-by: Andras Timar <andras.timar@collabora.com> (cherry picked from commit 663de10f95bb72630658a5a06501e37d1810e0c7) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/105451
2020-09-22lok:sidebar: deactivate the shell with no default contextHenry Castro
When a different view deactivates to current shell, then it is set to default context that cause a side effect into another view with different panels in the sidebar. Change-Id: Ie99cde89bdfdb08e1ac93aed947cf13048800c0a Reviewed-on: https://gerrit.libreoffice.org/c/core/+/102887 Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com> Reviewed-by: Henry Castro <hcastro@collabora.com> (cherry picked from commit e7c3678e309b59479be24be2b7c57f8b20dce4dd) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/102942 Reviewed-by: Andras Timar <andras.timar@collabora.com>
2018-11-06lok: Notify about the current editing context.Jan Holesovsky
Change-Id: I47e67b680a6abdb66020b295f55ee6a73b7b5608 Reviewed-on: https://gerrit.libreoffice.org/62956 Tested-by: Jenkins Reviewed-by: Jan Holesovsky <kendy@collabora.com>
2018-10-24remove more rtl::OUString and OString prefixesNoel Grandin
which seem to have snuck back in since the great rounds of removals. Change-Id: I85f7f5f4801c0b48dae8b50f51f83595b286d6a1 Reviewed-on: https://gerrit.libreoffice.org/62229 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2016-12-21convert EnumContext::Context to scoped enumNoel Grandin
Change-Id: I16ec63beb801073e5d604d852892c2fd6e8d8fc3 Reviewed-on: https://gerrit.libreoffice.org/32272 Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk> Tested-by: Noel Grandin <noel.grandin@collabora.co.uk>
2016-06-27GSoC notebookbar: switching tabs depending on contextSzymon Kłos
+ sfx2::sidebar::EnumContext moved to the vcl module + TabPage contains vector with context values + vcl builder reads control's contexts from the "class" mark + ContextTabControl shows tabs depending on context Change-Id: I661b0d3f35d46ace2a2e8eb1d374148f0c60017d Reviewed-on: https://gerrit.libreoffice.org/26447 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>