[Libreoffice-commits] core.git: sd/source

Caolán McNamara (via logerrit) logerrit at kemper.freedesktop.org
Fri Mar 5 16:53:53 UTC 2021


 sd/source/ui/sidebar/LayoutMenu.cxx |   20 --------------------
 sd/source/ui/sidebar/LayoutMenu.hxx |    1 -
 2 files changed, 21 deletions(-)

New commits:
commit a0a0f8786f1deab4283cee45dfd8888ddbd2811e
Author:     Caolán McNamara <caolanm at redhat.com>
AuthorDate: Fri Mar 5 11:35:17 2021 +0000
Commit:     Caolán McNamara <caolanm at redhat.com>
CommitDate: Fri Mar 5 17:53:09 2021 +0100

    with widget layout we don't need to explicitly track the parent resize
    
    Change-Id: I17e153ecc8b1b79bbbfbbccfe88a46f5905611fd
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/112010
    Tested-by: Caolán McNamara <caolanm at redhat.com>
    Reviewed-by: Caolán McNamara <caolanm at redhat.com>

diff --git a/sd/source/ui/sidebar/LayoutMenu.cxx b/sd/source/ui/sidebar/LayoutMenu.cxx
index ec0feafe5d71..e435bdcdcde0 100644
--- a/sd/source/ui/sidebar/LayoutMenu.cxx
+++ b/sd/source/ui/sidebar/LayoutMenu.cxx
@@ -201,10 +201,6 @@ void LayoutMenu::implConstruct( DrawDocShell& rDocumentShell )
         aStateChangeLink,
         Reference<frame::XDispatchProvider>(mrBase.GetController()->getFrame(), UNO_QUERY),
         ".uno:VerticalTextState");
-
-    SetSizePixel(GetParent()->GetSizePixel());
-    Link<VclWindowEvent&,void> aWindowEventHandlerLink (LINK(this,LayoutMenu,WindowEventHandler));
-    GetParent()->AddEventListener(aWindowEventHandlerLink);
 }
 
 LayoutMenu::~LayoutMenu()
@@ -237,9 +233,6 @@ void LayoutMenu::Dispose()
     Clear();
     Link<tools::EventMultiplexerEvent&,void> aLink (LINK(this,LayoutMenu,EventMultiplexerListener));
     mrBase.GetEventMultiplexer()->RemoveEventListener (aLink);
-
-    Link<VclWindowEvent&,void> aWindowEventHandlerLink (LINK(this,LayoutMenu,WindowEventHandler));
-    GetParent()->RemoveEventListener(aWindowEventHandlerLink);
 }
 
 AutoLayout LayoutMenu::GetSelectedAutoLayout() const
@@ -726,19 +719,6 @@ IMPL_LINK(LayoutMenu, EventMultiplexerListener, ::sd::tools::EventMultiplexerEve
     }
 }
 
-IMPL_LINK(LayoutMenu, WindowEventHandler, VclWindowEvent&, rEvent, void)
-{
-    switch (rEvent.GetId())
-    {
-        case VclEventId::WindowShow:
-        case VclEventId::WindowResize:
-            SetSizePixel(GetParent()->GetSizePixel());
-            break;
-
-        default: break;
-    }
-}
-
 void LayoutMenu::DataChanged (const DataChangedEvent& /*rEvent*/)
 {
     Fill();
diff --git a/sd/source/ui/sidebar/LayoutMenu.hxx b/sd/source/ui/sidebar/LayoutMenu.hxx
index b6f6388483ac..b9eb1d167177 100644
--- a/sd/source/ui/sidebar/LayoutMenu.hxx
+++ b/sd/source/ui/sidebar/LayoutMenu.hxx
@@ -168,7 +168,6 @@ private:
     DECL_LINK(ClickHandler, ValueSet*, void);
     DECL_LINK(StateChangeHandler, const OUString&, void);
     DECL_LINK(EventMultiplexerListener, ::sd::tools::EventMultiplexerEvent&, void);
-    DECL_LINK(WindowEventHandler, VclWindowEvent&, void);
     void OnMenuItemSelected(std::string_view ident);
 };
 


More information about the Libreoffice-commits mailing list