extensions/source/propctrlr/browserview.cxx    |    4 ++--
 extensions/source/propctrlr/browserview.hxx    |    2 +-
 extensions/source/propctrlr/propertyeditor.cxx |    4 ++--
 extensions/source/propctrlr/propertyeditor.hxx |    4 ++--
 4 files changed, 7 insertions(+), 7 deletions(-)

New commits:
commit a8ae24a8bd7bfffa75af9d0dc50765d51df9c720
Author:     Justin Luth <jl...@mail.com>
AuthorDate: Mon Aug 8 14:43:10 2022 -0400
Commit:     Caolán McNamara <caol...@redhat.com>
CommitDate: Tue Aug 9 11:38:00 2022 +0200

    tdf#150278: avoid gen/gtk3 difference in m_xPropBox->GetCurPage()
    
    When switching between tabs, at this call SAL_USE_VCLPLUGIN=gen
    was returning the switched-to-tab id, while gtk3 was still
    returning the leaving-tab's id.
    
    So just ignore all that an use the OnActivatePage value.
    
    Change-Id: I166626eac033af65e95f8a280076a6bcc070bee3
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/138003
    Tested-by: Jenkins
    Tested-by: Caolán McNamara <caol...@redhat.com>
    Reviewed-by: Caolán McNamara <caol...@redhat.com>

diff --git a/extensions/source/propctrlr/browserview.cxx 
b/extensions/source/propctrlr/browserview.cxx
index df0c6693b9bd..e7b7cb690d20 100644
--- a/extensions/source/propctrlr/browserview.cxx
+++ b/extensions/source/propctrlr/browserview.cxx
@@ -35,9 +35,9 @@ namespace pcr
         m_xPropBox->setPageActivationHandler(LINK(this, OPropertyBrowserView, 
OnPageActivation));
     }
 
-    IMPL_LINK_NOARG(OPropertyBrowserView, OnPageActivation, LinkParamNone*, 
void)
+    IMPL_LINK(OPropertyBrowserView, OnPageActivation, const OString&, 
rNewPage, void)
     {
-        m_nActivePage = m_xPropBox->GetCurPage();
+        m_nActivePage = rNewPage.toUInt32();
         m_aPageActivationHandler.Call(nullptr);
     }
 
diff --git a/extensions/source/propctrlr/browserview.hxx 
b/extensions/source/propctrlr/browserview.hxx
index 35195d20e199..7a0711fb145c 100644
--- a/extensions/source/propctrlr/browserview.hxx
+++ b/extensions/source/propctrlr/browserview.hxx
@@ -48,7 +48,7 @@ namespace pcr
         css::awt::Size getMinimumSize() const;
 
     private:
-        DECL_LINK(OnPageActivation, LinkParamNone*, void);
+        DECL_LINK(OnPageActivation, const OString&, void);
     };
 
 } // namespace pcr
diff --git a/extensions/source/propctrlr/propertyeditor.cxx 
b/extensions/source/propctrlr/propertyeditor.cxx
index e412508f3aa7..45d2fb2bc7ce 100644
--- a/extensions/source/propctrlr/propertyeditor.cxx
+++ b/extensions/source/propctrlr/propertyeditor.cxx
@@ -347,9 +347,9 @@ namespace pcr
         return xControl;
     }
 
-    IMPL_LINK_NOARG(OPropertyEditor, OnPageActivate, const OString&, void)
+    IMPL_LINK(OPropertyEditor, OnPageActivate, const OString&, rNewPage, void)
     {
-        m_aPageActivationHandler.Call(nullptr);
+        m_aPageActivationHandler.Call(rNewPage);
     }
 
     IMPL_LINK(OPropertyEditor, OnPageDeactivate, const OString&, rIdent, bool)
diff --git a/extensions/source/propctrlr/propertyeditor.hxx 
b/extensions/source/propctrlr/propertyeditor.hxx
index 606da6561705..fa0e3a0cd3ab 100644
--- a/extensions/source/propctrlr/propertyeditor.hxx
+++ b/extensions/source/propctrlr/propertyeditor.hxx
@@ -57,7 +57,7 @@ namespace pcr
         IPropertyLineListener*      m_pListener;
         IPropertyControlObserver*   m_pObserver;
         sal_uInt16                  m_nNextId;
-        Link<LinkParamNone*,void>   m_aPageActivationHandler;
+        Link<const OString&,void>   m_aPageActivationHandler;
         bool                        m_bHasHelpSection;
 
         MapStringToPageId           m_aPropertyPageIds;
@@ -95,7 +95,7 @@ namespace pcr
         void                        RemoveEntry( const OUString& _rName );
         void                        ChangeEntry( const OLineDescriptor& );
 
-        void                        setPageActivationHandler(const 
Link<LinkParamNone*,void>& _rHdl) { m_aPageActivationHandler = _rHdl; }
+        void                        setPageActivationHandler(const Link<const 
OString&,void>& _rHdl) { m_aPageActivationHandler = _rHdl; }
 
         Size                        get_preferred_size() const;
 

Reply via email to