From 83111eda2e441f288201aac5cc21cf179744947f Mon Sep 17 00:00:00 2001 From: Caolán McNamara Date: Wed, 15 Nov 2017 15:32:20 +0000 Subject: remove now unused ToolPanelModule MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Change-Id: I30c91acf28fc8c9d1815796b0a0d7924b42a06f8 Reviewed-on: https://gerrit.libreoffice.org/44767 Tested-by: Jenkins Reviewed-by: Caolán McNamara Tested-by: Caolán McNamara --- sd/Library_sd.mk | 1 - sd/source/ui/framework/module/ImpressModule.cxx | 1 - sd/source/ui/framework/module/ToolPanelModule.cxx | 88 ----------------------- sd/source/ui/framework/module/ToolPanelModule.hxx | 52 -------------- 4 files changed, 142 deletions(-) delete mode 100644 sd/source/ui/framework/module/ToolPanelModule.cxx delete mode 100644 sd/source/ui/framework/module/ToolPanelModule.hxx diff --git a/sd/Library_sd.mk b/sd/Library_sd.mk index ecaf83587f26..ae4592e340f3 100644 --- a/sd/Library_sd.mk +++ b/sd/Library_sd.mk @@ -250,7 +250,6 @@ $(eval $(call gb_Library_add_exception_objects,sd,\ sd/source/ui/framework/module/ShellStackGuard \ sd/source/ui/framework/module/SlideSorterModule \ sd/source/ui/framework/module/ToolBarModule \ - sd/source/ui/framework/module/ToolPanelModule \ sd/source/ui/framework/module/ViewTabBarModule \ sd/source/ui/framework/tools/FrameworkHelper \ sd/source/ui/func/bulmaper \ diff --git a/sd/source/ui/framework/module/ImpressModule.cxx b/sd/source/ui/framework/module/ImpressModule.cxx index bf2ee2472c93..3b62e17ae380 100644 --- a/sd/source/ui/framework/module/ImpressModule.cxx +++ b/sd/source/ui/framework/module/ImpressModule.cxx @@ -23,7 +23,6 @@ #include "ViewTabBarModule.hxx" #include "CenterViewFocusModule.hxx" #include "SlideSorterModule.hxx" -#include "ToolPanelModule.hxx" #include "ToolBarModule.hxx" #include "ShellStackGuard.hxx" diff --git a/sd/source/ui/framework/module/ToolPanelModule.cxx b/sd/source/ui/framework/module/ToolPanelModule.cxx deleted file mode 100644 index ab8d6fc25430..000000000000 --- a/sd/source/ui/framework/module/ToolPanelModule.cxx +++ /dev/null @@ -1,88 +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 "ToolPanelModule.hxx" - -#include -#include -#include - -#include -#include -#include - -using namespace ::com::sun::star; -using namespace ::com::sun::star::uno; -using namespace ::com::sun::star::drawing::framework; - -using ::sd::framework::FrameworkHelper; - -namespace sd { namespace framework { - -//===== ToolPanelModule ================================================== - -ToolPanelModule::ToolPanelModule ( - const Reference& rxController, - const OUString& rsSidebarPaneURL) - : ResourceManager(rxController, - FrameworkHelper::CreateResourceId(FrameworkHelper::msSidebarViewURL, rsSidebarPaneURL)) -{ - if (mxConfigurationController.is()) - { - if (SvtToolPanelOptions().GetVisibleImpressView()) - AddActiveMainView(FrameworkHelper::msImpressViewURL); - if (SvtToolPanelOptions().GetVisibleOutlineView()) - AddActiveMainView(FrameworkHelper::msOutlineViewURL); - if (SvtToolPanelOptions().GetVisibleNotesView()) - AddActiveMainView(FrameworkHelper::msNotesViewURL); - if (SvtToolPanelOptions().GetVisibleHandoutView()) - AddActiveMainView(FrameworkHelper::msHandoutViewURL); - if (SvtToolPanelOptions().GetVisibleSlideSorterView()) - AddActiveMainView(FrameworkHelper::msSlideSorterURL); - - mxConfigurationController->addConfigurationChangeListener( - this, - FrameworkHelper::msResourceActivationEvent, - Any()); - } -} - -ToolPanelModule::~ToolPanelModule() -{ -} - -void ToolPanelModule::SaveResourceState() -{ - SvtToolPanelOptions().SetVisibleImpressView(IsResourceActive(FrameworkHelper::msImpressViewURL)); - SvtToolPanelOptions().SetVisibleOutlineView(IsResourceActive(FrameworkHelper::msOutlineViewURL)); - SvtToolPanelOptions().SetVisibleNotesView(IsResourceActive(FrameworkHelper::msNotesViewURL)); - SvtToolPanelOptions().SetVisibleHandoutView(IsResourceActive(FrameworkHelper::msHandoutViewURL)); - SvtToolPanelOptions().SetVisibleSlideSorterView(IsResourceActive(FrameworkHelper::msSlideSorterURL)); -} - -void SAL_CALL ToolPanelModule::notifyConfigurationChange ( - const ConfigurationChangeEvent& rEvent) -{ - if (rEvent.Type != FrameworkHelper::msResourceActivationEvent) - ResourceManager::notifyConfigurationChange(rEvent); -} - -} } // end of namespace sd::framework - -/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/sd/source/ui/framework/module/ToolPanelModule.hxx b/sd/source/ui/framework/module/ToolPanelModule.hxx deleted file mode 100644 index 4e4aeee58fb0..000000000000 --- a/sd/source/ui/framework/module/ToolPanelModule.hxx +++ /dev/null @@ -1,52 +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_SD_SOURCE_UI_FRAMEWORK_MODULE_TOOLPANELMODULE_HXX -#define INCLUDED_SD_SOURCE_UI_FRAMEWORK_MODULE_TOOLPANELMODULE_HXX - -#include "ResourceManager.hxx" - -#include -#include - -namespace sd { namespace framework { - -/** This module is responsible for showing the toolpanel bar. -*/ -class ToolPanelModule - : public ResourceManager -{ -public: - ToolPanelModule ( - const css::uno::Reference& rxController, - const OUString& rsRightPaneURL); - virtual ~ToolPanelModule() override; - - virtual void SaveResourceState() override; - // XConfigurationChangeListener - - virtual void SAL_CALL notifyConfigurationChange ( - const css::drawing::framework::ConfigurationChangeEvent& rEvent) override; -}; - -} } // end of namespace sd::framework - -#endif - -/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ -- cgit