[Libreoffice-commits] core.git: sc/source sc/uiconfig

Tor Lillqvist tml at collabora.com
Thu Nov 27 01:39:35 PST 2014


 sc/source/ui/optdlg/calcoptionsdlg.cxx            |    7 +++----
 sc/source/ui/optdlg/calcoptionsdlg.hxx            |    2 ++
 sc/uiconfig/scalc/ui/formulacalculationoptions.ui |   14 ++++++++++++++
 3 files changed, 19 insertions(+), 4 deletions(-)

New commits:
commit 28c7d76587fe3fce1d7544654f58a3028dc1d2fe
Author: Tor Lillqvist <tml at collabora.com>
Date:   Thu Nov 27 11:16:31 2014 +0200

    Add the "Test" button back
    
    This functionality is Calc-specific and will stay in the Calc part of
    the options. Let's not give the false impression that it would be
    going away. (How it looks and works now is not final.)
    
    Change-Id: Ic2f783a6fd07de89eec7d7e685364dad71243b4b

diff --git a/sc/source/ui/optdlg/calcoptionsdlg.cxx b/sc/source/ui/optdlg/calcoptionsdlg.cxx
index 4dc5c4f..e056980 100644
--- a/sc/source/ui/optdlg/calcoptionsdlg.cxx
+++ b/sc/source/ui/optdlg/calcoptionsdlg.cxx
@@ -153,6 +153,7 @@ ScCalcOptionsDialog::ScCalcOptionsDialog(vcl::Window* pParent, const ScCalcConfi
     get(mpBtnFalse, "false");
     get(mpSpinButton, "spinbutton");
     get(mpEditField, "entry");
+    get(mpTestButton, "test");
     get(mpOpenclInfoList, "opencl_list");
     get(mpBtnAutomaticSelectionTrue, "automatic_select_true");
     get(mpBtnAutomaticSelectionFalse, "automatic_select_false");
@@ -204,6 +205,8 @@ ScCalcOptionsDialog::ScCalcOptionsDialog(vcl::Window* pParent, const ScCalcConfi
     mpLbSettings->SetSelectHdl(aLink);
     mpLbOptionEdit->SetSelectHdl(aLink);
 
+    mpTestButton->SetClickHdl(LINK(this, ScCalcOptionsDialog, TestClickHdl));
+
     aLink = LINK(this, ScCalcOptionsDialog, BtnToggleHdl);
     mpBtnTrue->SetToggleHdl(aLink); // Set handler only to the 'True' button.
 
@@ -729,8 +732,6 @@ IMPL_LINK(ScCalcOptionsDialog, EditModifiedHdl, Control*, pCtrl)
     return 0;
 }
 
-#if 0
-
 namespace {
 
 struct Area
@@ -1163,6 +1164,4 @@ IMPL_LINK( ScCalcOptionsDialog, TestClickHdl, PushButton*, )
     return 0;
 }
 
-#endif
-
 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sc/source/ui/optdlg/calcoptionsdlg.hxx b/sc/source/ui/optdlg/calcoptionsdlg.hxx
index 789c01d..c7bfe4d 100644
--- a/sc/source/ui/optdlg/calcoptionsdlg.hxx
+++ b/sc/source/ui/optdlg/calcoptionsdlg.hxx
@@ -41,6 +41,7 @@ public:
     DECL_LINK( DeviceSelHdl, void* );
     DECL_LINK( NumModifiedHdl, void * );
     DECL_LINK( EditModifiedHdl, Control * );
+    DECL_LINK( TestClickHdl, PushButton* );
 
     const ScCalcConfig& GetConfig() const { return maConfig;}
 
@@ -74,6 +75,7 @@ private:
     RadioButton* mpBtnFalse;
     NumericField* mpSpinButton;
     Edit* mpEditField;
+    PushButton* mpTestButton;
 
     FixedText* mpFtAnnotation;
     FixedText* mpFtFrequency;
diff --git a/sc/uiconfig/scalc/ui/formulacalculationoptions.ui b/sc/uiconfig/scalc/ui/formulacalculationoptions.ui
index 37a10c6..6fee1af 100644
--- a/sc/uiconfig/scalc/ui/formulacalculationoptions.ui
+++ b/sc/uiconfig/scalc/ui/formulacalculationoptions.ui
@@ -646,6 +646,20 @@
                 <property name="height">1</property>
               </packing>
             </child>
+            <child>
+              <object class="GtkButton" id="test">
+                <property name="label" translatable="yes">_Test</property>
+                <property name="visible">True</property>
+                <property name="can_focus">True</property>
+                <property name="receives_default">True</property>
+              </object>
+              <packing>
+                <property name="left_attach">0</property>
+                <property name="top_attach">28</property>
+                <property name="expand">False</property>
+                <property name="fill">True</property>
+              </packing>
+            </child>
           </object>
           <packing>
             <property name="expand">False</property>


More information about the Libreoffice-commits mailing list