summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNoel Grandin <noel.grandin@collabora.co.uk>2023-07-21 14:39:42 +0200
committerNoel Grandin <noel.grandin@collabora.co.uk>2023-07-22 08:51:18 +0200
commit6d9e304d1748668cc25905945129095bd14fd1af (patch)
treeb0ea02d427718d504da97f46d033cfabb2594937
parent818f8f13128ba78769b4f542ed1efef658de38d9 (diff)
SfxItemSetHint is dead
since commit 519876dffdc8c93710af543cc11332dab9a50c14 Author: Mike Kaganski <mike.kaganski@collabora.com> Date: Tue Jul 18 23:45:47 2023 +0300 Cleanup SfxApplication::Get/SetOptions, and drop unused SIDs Change-Id: I8d306bf6792630cfdaa0a0ac8b77730e1e1f0070 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/154724 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
-rw-r--r--cui/source/options/treeopt.cxx4
-rw-r--r--include/sfx2/app.hxx2
-rw-r--r--include/svl/isethint.hxx40
-rw-r--r--sfx2/source/appl/appcfg.cxx5
-rw-r--r--solenv/clang-format/excludelist1
-rw-r--r--svl/Library_svl.mk1
-rw-r--r--svl/source/notify/isethint.cxx33
-rw-r--r--sw/source/uibase/app/apphdl.cxx1
-rw-r--r--sw/source/uibase/app/appopt.cxx4
9 files changed, 5 insertions, 86 deletions
diff --git a/cui/source/options/treeopt.cxx b/cui/source/options/treeopt.cxx
index d3c65eb0c847..3a637145e13d 100644
--- a/cui/source/options/treeopt.cxx
+++ b/cui/source/options/treeopt.cxx
@@ -1143,7 +1143,7 @@ void OfaTreeOptionsDialog::ApplyItemSet( sal_uInt16 nId, const SfxItemSet& rSet
SfxItemSetFixed<SID_ATTR_QUICKLAUNCHER, SID_ATTR_QUICKLAUNCHER> aOptSet(SfxGetpApp()->GetPool());
aOptSet.Put(rSet);
if(aOptSet.Count())
- SfxGetpApp()->SetOptions( aOptSet );
+ SfxApplication::SetOptions( aOptSet );
// get dispatcher anew, because SetOptions() might have destroyed the dispatcher
SfxViewFrame *pViewFrame = SfxViewFrame::Current();
@@ -1193,7 +1193,7 @@ void OfaTreeOptionsDialog::ApplyItemSet( sal_uInt16 nId, const SfxItemSet& rSet
break;
case SID_INET_DLG :
case SID_FILTER_DLG:
- SfxGetpApp()->SetOptions( rSet );
+ SfxApplication::SetOptions( rSet );
break;
case SID_SB_STARBASEOPTIONS:
diff --git a/include/sfx2/app.hxx b/include/sfx2/app.hxx
index 09ddd082db31..4a6e8428972d 100644
--- a/include/sfx2/app.hxx
+++ b/include/sfx2/app.hxx
@@ -155,7 +155,7 @@ public:
// misc.
static void GetOptions(SfxItemSet &);
- void SetOptions(const SfxItemSet &);
+ static void SetOptions(const SfxItemSet &);
virtual void Invalidate(sal_uInt16 nId = 0) override;
void NotifyEvent(const SfxEventHint& rEvent, bool bSynchron = true );
bool IsDowning() const;
diff --git a/include/svl/isethint.hxx b/include/svl/isethint.hxx
deleted file mode 100644
index 89dbc3b71829..000000000000
--- a/include/svl/isethint.hxx
+++ /dev/null
@@ -1,40 +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_SVL_ISETHINT_HXX
-#define INCLUDED_SVL_ISETHINT_HXX
-
-#include <svl/svldllapi.h>
-#include <svl/hint.hxx>
-#include <svl/itemset.hxx>
-
-
-class SVL_DLLPUBLIC SfxItemSetHint final : public SfxHint
-{
- SfxItemSet maItemSet;
-
-public:
- SfxItemSetHint( const SfxItemSet &rItemSet );
- virtual ~SfxItemSetHint() override;
-
- const SfxItemSet& GetItemSet() const { return maItemSet; }
-};
-
-#endif
-
-/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sfx2/source/appl/appcfg.cxx b/sfx2/source/appl/appcfg.cxx
index b0816397c88b..1f030223c2f3 100644
--- a/sfx2/source/appl/appcfg.cxx
+++ b/sfx2/source/appl/appcfg.cxx
@@ -32,8 +32,6 @@
#include <sfx2/sfxsids.hrc>
-#include <svl/isethint.hxx>
-
#include <officecfg/Inet.hxx>
#include <officecfg/Office/Common.hxx>
#include <officecfg/Office/Recovery.hxx>
@@ -340,9 +338,6 @@ void SfxApplication::SetOptions_Nbc(const SfxItemSet& rSet)
void SfxApplication::SetOptions(const SfxItemSet &rSet)
{
SetOptions_Nbc( rSet );
-
- // Undo-Count
- Broadcast( SfxItemSetHint( rSet ) );
}
diff --git a/solenv/clang-format/excludelist b/solenv/clang-format/excludelist
index ffe9eb7b3e78..c49000bc3350 100644
--- a/solenv/clang-format/excludelist
+++ b/solenv/clang-format/excludelist
@@ -5640,7 +5640,6 @@ include/svl/inethist.hxx
include/svl/instrm.hxx
include/svl/int64item.hxx
include/svl/intitem.hxx
-include/svl/isethint.hxx
include/svl/itempool.hxx
include/svl/itemprop.hxx
include/svl/itemset.hxx
diff --git a/svl/Library_svl.mk b/svl/Library_svl.mk
index ac6fe2d8130a..87024bbf499e 100644
--- a/svl/Library_svl.mk
+++ b/svl/Library_svl.mk
@@ -165,7 +165,6 @@ $(eval $(call gb_Library_add_exception_objects,svl,\
svl/source/misc/urihelper \
svl/source/notify/SfxBroadcaster \
svl/source/notify/broadcast \
- svl/source/notify/isethint \
svl/source/notify/listener \
svl/source/notify/lstner \
svl/source/numbers/currencytable \
diff --git a/svl/source/notify/isethint.cxx b/svl/source/notify/isethint.cxx
deleted file mode 100644
index c0012377eccb..000000000000
--- a/svl/source/notify/isethint.cxx
+++ /dev/null
@@ -1,33 +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 .
- */
-
-#include <svl/isethint.hxx>
-#include <svl/itemset.hxx>
-
-/**
- * Copies the SfxItemSet passed as a parameter.
- */
-SfxItemSetHint::SfxItemSetHint(const SfxItemSet& rItemSet)
- : maItemSet(rItemSet.CloneAsValue())
-{
-}
-
-SfxItemSetHint::~SfxItemSetHint() {}
-
-/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sw/source/uibase/app/apphdl.cxx b/sw/source/uibase/app/apphdl.cxx
index 087caeffbed2..5e38ee835078 100644
--- a/sw/source/uibase/app/apphdl.cxx
+++ b/sw/source/uibase/app/apphdl.cxx
@@ -29,7 +29,6 @@
#include <svtools/restartdialog.hxx>
#include <svl/eitem.hxx>
#include <svl/whiter.hxx>
-#include <svl/isethint.hxx>
#include <svl/stritem.hxx>
#include <sfx2/request.hxx>
#include <sfx2/fcontnr.hxx>
diff --git a/sw/source/uibase/app/appopt.cxx b/sw/source/uibase/app/appopt.cxx
index e6923fe9aee1..7be59a1dab9a 100644
--- a/sw/source/uibase/app/appopt.cxx
+++ b/sw/source/uibase/app/appopt.cxx
@@ -290,14 +290,14 @@ void SwModule::ApplyItemSet( sal_uInt16 nId, const SfxItemSet& rSet )
if( const SfxUInt16Item* pMetricItem = rSet.GetItemIfSet(SID_ATTR_METRIC, false ) )
{
- SfxGetpApp()->SetOptions(rSet);
+ SfxApplication::SetOptions(rSet);
PutItem(*pMetricItem);
::SetDfltMetric(static_cast<FieldUnit>(pMetricItem->GetValue()), !bTextDialog);
}
if( const SfxBoolItem* pCharItem = rSet.GetItemIfSet(SID_ATTR_APPLYCHARUNIT,
false ) )
{
- SfxGetpApp()->SetOptions(rSet);
+ SfxApplication::SetOptions(rSet);
::SetApplyCharUnit(pCharItem->GetValue(), !bTextDialog);
}