Revert "loplugin:finalclasses"

This reverts commit 9ce9011230a97f3fe4fcd2f8d761781c4300772b.

Reason for revert: see comments in https://gerrit.libreoffice.org/c/core/+/124632

Change-Id: Ibc8b7a8c190e7a8afec793c1202dba97ac6909bd
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/124483
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
This commit is contained in:
Noel Grandin 2021-11-03 13:49:58 +01:00
parent 0464b86787
commit b64efd7b29
15 changed files with 47 additions and 32 deletions

View File

@ -33,7 +33,7 @@ namespace basctl
*
* @see LibBox Class
*/
class LibBoxControl final : public SfxToolBoxControl
class LibBoxControl : public SfxToolBoxControl
{
public:
/*!
@ -121,7 +121,7 @@ public:
*
* @see LibBoxControl Class
*/
class LibBox final : public DocListenerBox
class LibBox : public DocListenerBox
{
public:
/// @param pParent
@ -136,10 +136,11 @@ public:
*/
void Update(const SfxStringItem* pItem);
private:
protected:
/// Called for setting language when user selects a language in ComboBox
virtual void Select() override;
private:
static void ReleaseFocus();
/*!
@ -177,7 +178,7 @@ private:
*
* @see LanguageBox Class
*/
class LanguageBoxControl final : public SfxToolBoxControl
class LanguageBoxControl : public SfxToolBoxControl
{
public:
/*! Macro for registering two methods
@ -220,7 +221,7 @@ public:
*
* @see LanguageBoxControl Class
*/
class LanguageBox final : public DocListenerBox
class LanguageBox : public DocListenerBox
{
public:
/*!
@ -237,7 +238,7 @@ public:
*/
void Update(const SfxStringItem* pItem);
private:
protected:
/// Called for setting language when user selects a language in ComboBox
virtual void Select() override;
@ -249,6 +250,7 @@ private:
*/
virtual bool HandleKeyInput(const KeyEvent& rKEvt) override;
private:
/// Delete all languages from ComboBox
void ClearBox();
/// Switch interface of dialog to selected language

View File

@ -33,7 +33,7 @@ namespace basctl
* in a tree structure which allows user to quickly select the necessary
* macro in BasicIDE.
*/
class ObjectCatalog final : public DockingWindow
class ObjectCatalog : public DockingWindow
{
public:
explicit ObjectCatalog(vcl::Window* pParent);

View File

@ -45,13 +45,15 @@ class ObjectCatalog;
bool implImportDialog(weld::Window* pWin, const ScriptDocument& rDocument, const OUString& rLibName);
class DialogWindow final : public BaseWindow
class DialogWindow: public BaseWindow
{
private:
DialogWindowLayout& m_rLayout;
std::unique_ptr<DlgEditor> m_pEditor;
std::unique_ptr<SfxUndoManager> m_pUndoMgr; // never nullptr
sal_uInt16 m_nControlSlotId;
protected:
virtual void Paint(vcl::RenderContext& rRenderContext, const tools::Rectangle& rRect) override;
virtual void Resize() override;
virtual void dispose() override;
@ -112,32 +114,37 @@ public:
// DialogWindowLayout
class DialogWindowLayout final : public Layout
class DialogWindowLayout : public Layout
{
public:
DialogWindowLayout (vcl::Window* pParent, ObjectCatalog&);
virtual ~DialogWindowLayout() override;
virtual void dispose() override;
public:
void ShowPropertyBrowser ();
void UpdatePropertyBrowser ();
void DisablePropertyBrowser ();
public:
// Layout:
virtual void Activating (BaseWindow&) override;
virtual void Deactivating () override;
virtual void ExecuteGlobal (SfxRequest&) override;
virtual void GetState (SfxItemSet&, unsigned nWhich) override;
virtual void UpdateDebug (bool) override {};
private:
protected:
// Layout:
virtual void OnFirstSize (tools::Long nWidth, tools::Long nHeight) override;
private:
// dockable windows:
// object catalog (owned by Shell)
ObjectCatalog& rObjectCatalog;
// property browser (created by this, deleted by toolkit)
VclPtr<PropBrw> pPropertyBrowser;
void AddPropertyBrowser ();
private:
void AddPropertyBrowser ();
private:
friend class DialogWindow;
};

View File

@ -29,7 +29,7 @@ namespace basctl
class Shell;
class Controller final :
class Controller :
public comphelper::OMutexAndBroadcastHelper,
public comphelper::OPropertyContainer,
public comphelper::OPropertyArrayUsageHelper<Controller>,
@ -58,7 +58,7 @@ public:
// OPropertySetHelper
virtual ::cppu::IPropertyArrayHelper& SAL_CALL getInfoHelper() override;
private:
protected:
// OPropertyArrayUsageHelper
virtual ::cppu::IPropertyArrayHelper* createArrayHelper( ) const override;
};

View File

@ -49,7 +49,7 @@ class TabBar;
class BaseWindow;
class LocalizationMgr;
class Shell final :
class Shell :
public SfxViewShell,
public DocumentEventListener
{

View File

@ -100,7 +100,7 @@ public:
LibraryLocation GetLocation() const { return m_eLocation; }
};
class LibEntry final : public DocumentEntry
class LibEntry : public DocumentEntry
{
private:
OUString m_aLibName;
@ -171,7 +171,7 @@ public:
*/
class SbTreeListBox final : public DocumentEventListener
class SbTreeListBox : public DocumentEventListener
{
private:
std::unique_ptr<weld::TreeView> m_xControl;
@ -180,8 +180,9 @@ private:
bool m_bFreezeOnFirstAddRemove;
BrowseMode nMode;
DocumentEventNotifier m_aNotifier;
void SetEntryBitmaps(const weld::TreeIter& rIter, const OUString& rImage);
protected:
DECL_LINK(RequestingChildrenHdl, const weld::TreeIter&, bool);
DECL_LINK(OpenCurrentHdl, weld::TreeView&, bool);
void ImpCreateLibEntries(const weld::TreeIter& rShellRootEntry, const ScriptDocument& rDocument, LibraryLocation eLocation);

View File

@ -124,8 +124,9 @@ private:
// basctl::TabBar
// Not to be confused with ::TabBar from svtools.
class TabBar final : public ::TabBar
class TabBar : public ::TabBar
{
protected:
virtual void MouseButtonDown( const MouseEvent& rMEvt ) override;
virtual void Command( const CommandEvent& rCEvt ) override;

View File

@ -57,7 +57,7 @@ class DialogWindowLayout;
class DlgEdObj;
class DlgEdHint final : public SfxHint
class DlgEdHint: public SfxHint
{
public:
enum Kind {
@ -92,7 +92,7 @@ class DlgEdForm;
class DlgEdFactory;
class DlgEdFunc;
class DlgEditor final : public SfxBroadcaster
class DlgEditor: public SfxBroadcaster
{
public:
enum Mode {

View File

@ -51,7 +51,7 @@ public:
// DlgEdFuncInsert
class DlgEdFuncInsert final : public DlgEdFunc
class DlgEdFuncInsert : public DlgEdFunc
{
public:
explicit DlgEdFuncInsert(DlgEditor& rParent);
@ -64,7 +64,7 @@ public:
// DlgEdFuncSelect
class DlgEdFuncSelect final : public DlgEdFunc
class DlgEdFuncSelect : public DlgEdFunc
{
public:
explicit DlgEdFuncSelect(DlgEditor& rParent);

View File

@ -31,7 +31,7 @@ class DlgEdObj;
typedef ::cppu::WeakImplHelper<css::beans::XPropertyChangeListener> PropertyChangeListenerHelper;
class DlgEdPropListenerImpl final : public PropertyChangeListenerHelper
class DlgEdPropListenerImpl : public PropertyChangeListenerHelper
{
private:
DlgEdObj& rDlgEdObj;
@ -51,7 +51,7 @@ public:
typedef ::cppu::WeakImplHelper<css::container::XContainerListener> ContainerListenerHelper;
class DlgEdEvtContListenerImpl final : public ContainerListenerHelper
class DlgEdEvtContListenerImpl : public ContainerListenerHelper
{
private:
DlgEdObj& rDlgEdObj;

View File

@ -25,7 +25,7 @@ namespace basctl
{
// DlgEdModel
class DlgEdModel final : public SdrModel
class DlgEdModel : public SdrModel
{
friend class DlgEdPage;

View File

@ -144,19 +144,23 @@ public:
// DlgEdForm
class DlgEdForm final : public DlgEdObj
class DlgEdForm: public DlgEdObj
{
friend class DlgEditor;
friend class DlgEdFactory;
private:
DlgEditor& rDlgEditor;
std::vector<DlgEdObj*> pChildren;
mutable ::std::optional< css::awt::DeviceInfo > mpDeviceInfo;
private:
explicit DlgEdForm(
SdrModel& rSdrModel,
DlgEditor&);
protected:
virtual void NbcMove( const Size& rSize ) override;
virtual void NbcResize(const Point& rRef, const Fraction& xFact, const Fraction& yFact) override;
virtual bool EndCreate(SdrDragStat& rStat, SdrCreateCmd eCmd) override;

View File

@ -31,7 +31,7 @@ class DlgEditor;
// DlgEdView
class DlgEdView final : public SdrView
class DlgEdView : public SdrView
{
private:
DlgEditor& rDlgEditor;
@ -48,7 +48,7 @@ public:
virtual void MarkListHasChanged() override;
virtual void MakeVisible( const tools::Rectangle& rRect, vcl::Window& rWin ) override;
private:
protected:
/// override to handle HitTest for some objects specially
using SdrView::CheckSingleSdrObjectHit;
virtual SdrObject* CheckSingleSdrObjectHit(const Point& rPnt, sal_uInt16 nTol, SdrObject* pObj, SdrPageView* pPV, SdrSearchOptions nOptions, const SdrLayerIDSet* pMVisLay) const override;

View File

@ -42,7 +42,7 @@ struct LanguageEntry
extern bool localesAreEqual( const css::lang::Locale& rLocaleLeft,
const css::lang::Locale& rLocaleRight );
class ManageLanguageDialog final : public weld::GenericDialogController
class ManageLanguageDialog : public weld::GenericDialogController
{
private:
std::shared_ptr<LocalizationMgr> m_xLocalizationMgr;
@ -69,7 +69,7 @@ public:
virtual ~ManageLanguageDialog() override;
};
class SetDefaultLanguageDialog final : public weld::GenericDialogController
class SetDefaultLanguageDialog : public weld::GenericDialogController
{
private:
std::shared_ptr<LocalizationMgr> m_xLocalizationMgr;

View File

@ -34,7 +34,7 @@ enum ItemType
TYPE_METHOD
};
class SbxItem final : public SfxPoolItem
class SbxItem : public SfxPoolItem
{
const ScriptDocument m_aDocument;
const OUString m_aLibName;