[Libreoffice-commits] .: sc/source

Libreoffice Gerrit user logerrit at kemper.freedesktop.org
Wed Oct 17 02:17:23 PDT 2012


 sc/source/ui/dbgui/tpsort.cxx |   12 ++++++++----
 sc/source/ui/inc/tpsort.hxx   |    8 ++------
 2 files changed, 10 insertions(+), 10 deletions(-)

New commits:
commit 76737b0fe2e8afa3248ceee5025415c807d8687b
Author: Noel Power <noel.power at suse.com>
Date:   Wed Oct 17 11:01:15 2012 +0200

    exchange sort settings between the two tab pages, fdo#53482
    
    Change-Id: I540481585bec2479db541025755c2a5a670da9ed

diff --git a/sc/source/ui/dbgui/tpsort.cxx b/sc/source/ui/dbgui/tpsort.cxx
index 84084d7..5de7f74 100644
--- a/sc/source/ui/dbgui/tpsort.cxx
+++ b/sc/source/ui/dbgui/tpsort.cxx
@@ -285,9 +285,11 @@ sal_Bool ScTabPageSortFields::FillItemSet( SfxItemSet& rArgSet )
 
 // -----------------------------------------------------------------------
 
-// for data exchange without dialogue detour: (still TODO!)
-void ScTabPageSortFields::ActivatePage()
+// for data exchange without dialogue detour:
+void ScTabPageSortFields::ActivatePage( const SfxItemSet& rSet )
 {
+    // Refresh local copy with shared data
+    aSortData = static_cast<const ScSortItem&>(rSet.Get( SCITEM_SORTDATA )).GetSortData();
     if ( pDlg )
     {
         if ( bHasHeader  != pDlg->GetHeaders()
@@ -765,9 +767,11 @@ sal_Bool ScTabPageSortOptions::FillItemSet( SfxItemSet& rArgSet )
 
 // -----------------------------------------------------------------------
 
-// for data exchange without dialogue detour: (still TODO!)
-void ScTabPageSortOptions::ActivatePage()
+// for data exchange without dialogue detour:
+void ScTabPageSortOptions::ActivatePage( const SfxItemSet& rSet )
 {
+    // Refresh local copy with shared data
+    aSortData = static_cast<const ScSortItem&>(rSet.Get( SCITEM_SORTDATA )).GetSortData();
     if ( pDlg )
     {
         if ( aBtnHeader.IsChecked() != pDlg->GetHeaders() )
diff --git a/sc/source/ui/inc/tpsort.hxx b/sc/source/ui/inc/tpsort.hxx
index e8c208a..b6fb493 100644
--- a/sc/source/ui/inc/tpsort.hxx
+++ b/sc/source/ui/inc/tpsort.hxx
@@ -69,11 +69,9 @@ public:
     virtual void        Reset       ( const SfxItemSet& rArgSet );
 
 protected:
-// for data exchange (TODO: should be changed!)
-//  virtual void        ActivatePage    ( const SfxItemSet& rSet );
+    virtual void        ActivatePage    ( const SfxItemSet& rSet );
     using SfxTabPage::ActivatePage;
     using SfxTabPage::DeactivatePage;
-    virtual void        ActivatePage    ();
     virtual int         DeactivatePage  ( SfxItemSet* pSet = 0);
 
 private:
@@ -130,11 +128,9 @@ public:
     virtual void        Reset       ( const SfxItemSet& rArgSet );
 
 protected:
-// for data exchange (TODO: should be changed!)
-//  virtual void        ActivatePage    ( const SfxItemSet& rSet );
+    virtual void        ActivatePage    ( const SfxItemSet& rSet );
     using SfxTabPage::ActivatePage;
     using SfxTabPage::DeactivatePage;
-    virtual void        ActivatePage    ();
     virtual int         DeactivatePage  ( SfxItemSet* pSet = 0);
 
 private:


More information about the Libreoffice-commits mailing list