[Libreoffice-commits] core.git: cui/source
Stephan Bergmann
sbergman at redhat.com
Fri Apr 11 09:00:44 PDT 2014
cui/source/dialogs/SpellDialog.cxx | 6 ---
cui/source/dialogs/colorpicker.cxx | 1
cui/source/dialogs/insdlg.cxx | 2 -
cui/source/dialogs/plfilter.cxx | 2 +
cui/source/dialogs/plfilter.hxx | 34 ++++++++++++++++++++++
cui/source/inc/colorpicker.hxx | 51 +++++++++++++++++++++++++++++++++
cui/source/options/connpooloptions.cxx | 15 ---------
cui/source/options/optcolor.cxx | 3 -
cui/source/options/optlingu.cxx | 28 ------------------
cui/source/uno/services.cxx | 8 +----
10 files changed, 91 insertions(+), 59 deletions(-)
New commits:
commit 6bb60dab6f901797dd062bd9e61a17ee0ca5ae92
Author: Stephan Bergmann <sbergman at redhat.com>
Date: Fri Apr 11 18:00:18 2014 +0200
Clean up function declarations and some unused functions
Change-Id: I45ea22c86ea66c49fd86af2b5d0df060138f7e9a
diff --git a/cui/source/dialogs/SpellDialog.cxx b/cui/source/dialogs/SpellDialog.cxx
index 94e5f20..659cb10 100644
--- a/cui/source/dialogs/SpellDialog.cxx
+++ b/cui/source/dialogs/SpellDialog.cxx
@@ -138,8 +138,6 @@ public:
m_nOldErrorStart = nOldStart;
m_nOldErrorEnd = nOldEnd;
}
- long GetNewErrorStart() { return m_nNewErrorStart;}
- long GetNewErrorEnd() { return m_nNewErrorEnd;}
long GetOldErrorStart() { return m_nOldErrorStart;}
long GetOldErrorEnd() { return m_nOldErrorEnd;}
@@ -153,10 +151,6 @@ public:
void SetOffset(long nSet) {m_nOffset = nSet;}
long GetOffset() const {return m_nOffset;}
-
- void SetErrorType( const OUString& rId ) { m_sRuleId = rId; }
- const OUString& GetErrorType() const { return m_sRuleId; }
-
};
}//namespace svx
using namespace ::svx;
diff --git a/cui/source/dialogs/colorpicker.cxx b/cui/source/dialogs/colorpicker.cxx
index a86c92b..a44c4c0 100644
--- a/cui/source/dialogs/colorpicker.cxx
+++ b/cui/source/dialogs/colorpicker.cxx
@@ -43,6 +43,7 @@
#include <basegfx/color/bcolortools.hxx>
#include "dialmgr.hxx"
#include "colorpicker.hrc"
+#include "colorpicker.hxx"
#include <cmath>
#include <limits>
diff --git a/cui/source/dialogs/insdlg.cxx b/cui/source/dialogs/insdlg.cxx
index b188210..ac0645e 100644
--- a/cui/source/dialogs/insdlg.cxx
+++ b/cui/source/dialogs/insdlg.cxx
@@ -33,6 +33,7 @@
#include <comphelper/processfactory.hxx>
#include "insdlg.hxx"
+#include <plfilter.hxx>
#include <dialmgr.hxx>
#include <svtools/sores.hxx>
@@ -353,7 +354,6 @@ uno::Reference< io::XInputStream > SvInsertOleDlg::GetIconIfIconified( OUString*
IMPL_LINK_NOARG(SvInsertPlugInDialog, BrowseHdl)
{
Sequence< OUString > aFilterNames, aFilterTypes;
- void fillNetscapePluginFilters( Sequence< OUString >& rNames, Sequence< OUString >& rTypes );
fillNetscapePluginFilters( aFilterNames, aFilterTypes );
Reference< XComponentContext > xContext( ::comphelper::getProcessComponentContext() );
diff --git a/cui/source/dialogs/plfilter.cxx b/cui/source/dialogs/plfilter.cxx
index 4c0b7c3..386ff69 100644
--- a/cui/source/dialogs/plfilter.cxx
+++ b/cui/source/dialogs/plfilter.cxx
@@ -29,6 +29,8 @@
#include <com/sun/star/plugin/PluginManager.hpp>
#include <com/sun/star/plugin/XPluginManager.hpp>
+#include <plfilter.hxx>
+
using namespace std;
using namespace com::sun::star::uno;
using namespace com::sun::star::lang;
diff --git a/cui/source/dialogs/plfilter.hxx b/cui/source/dialogs/plfilter.hxx
new file mode 100644
index 0000000..f982fe0
--- /dev/null
+++ b/cui/source/dialogs/plfilter.hxx
@@ -0,0 +1,34 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
+/*
+ * This file is part of the LibreOffice project.
+ *
+ * This Source Code Form is subject to the terms of the Mozilla Public
+ * License, v. 2.0. If a copy of the MPL was not distributed with this
+ * file, You can obtain one at http://mozilla.org/MPL/2.0/.
+ *
+ * This file incorporates work covered by the following license notice:
+ *
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed
+ * with this work for additional information regarding copyright
+ * ownership. The ASF licenses this file to you under the Apache
+ * License, Version 2.0 (the "License"); you may not use this file
+ * except in compliance with the License. You may obtain a copy of
+ * the License at http://www.apache.org/licenses/LICENSE-2.0 .
+ */
+
+#ifndef INCLUDED_CUI_SOURCE_DIALOGS_PLFILTER_HXX
+#define INCLUDED_CUI_SOURCE_DIALOGS_PLFILTER_HXX
+
+#include <sal/config.h>
+
+#include <com/sun/star/uno/Sequence.hxx>
+#include <rtl/ustring.hxx>
+
+void fillNetscapePluginFilters(
+ css::uno::Sequence<OUString> & rNames,
+ css::uno::Sequence<OUString> & rTypes);
+
+#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/cui/source/inc/colorpicker.hxx b/cui/source/inc/colorpicker.hxx
new file mode 100644
index 0000000..c5fe678
--- /dev/null
+++ b/cui/source/inc/colorpicker.hxx
@@ -0,0 +1,51 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
+/*
+ * This file is part of the LibreOffice project.
+ *
+ * This Source Code Form is subject to the terms of the Mozilla Public
+ * License, v. 2.0. If a copy of the MPL was not distributed with this
+ * file, You can obtain one at http://mozilla.org/MPL/2.0/.
+ *
+ * This file incorporates work covered by the following license notice:
+ *
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed
+ * with this work for additional information regarding copyright
+ * ownership. The ASF licenses this file to you under the Apache
+ * License, Version 2.0 (the "License"); you may not use this file
+ * except in compliance with the License. You may obtain a copy of
+ * the License at http://www.apache.org/licenses/LICENSE-2.0 .
+ */
+
+#ifndef INCLUDED_CUI_SOURCE_INC_COLORPICKER_HXX
+#define INCLUDED_CUI_SOURCE_INC_COLORPICKER_HXX
+
+#include <sal/config.h>
+
+#include <com/sun/star/uno/Exception.hpp>
+#include <com/sun/star/uno/Reference.hxx>
+#include <com/sun/star/uno/RuntimeException.hpp>
+#include <com/sun/star/uno/Sequence.hxx>
+#include <rtl/ustring.hxx>
+#include <sal/types.h>
+
+namespace com { namespace sun { namespace star { namespace uno {
+ class XComponentContext;
+ class XInterface;
+} } } }
+
+namespace cui {
+
+OUString SAL_CALL ColorPicker_getImplementationName();
+
+css::uno::Reference<css::uno::XInterface> SAL_CALL ColorPicker_createInstance(
+ css::uno::Reference<css::uno::XComponentContext> const &)
+ SAL_THROW((css::uno::Exception));
+
+css::uno::Sequence<OUString> SAL_CALL ColorPicker_getSupportedServiceNames()
+ throw (css::uno::RuntimeException);
+}
+
+#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/cui/source/options/connpooloptions.cxx b/cui/source/options/connpooloptions.cxx
index 3f5b162..6dff2f0 100644
--- a/cui/source/options/connpooloptions.cxx
+++ b/cui/source/options/connpooloptions.cxx
@@ -54,9 +54,7 @@ namespace offapp
// the handler will be called with a DriverPoolingSettings::const_iterator as parameter,
// or NULL if no valid current row exists
void SetRowChangeHandler(const Link& _rHdl) { m_aRowChangeHandler = _rHdl; }
- Link GetRowChangeHandler() const { return m_aRowChangeHandler; }
- const DriverPooling* getCurrentRow() const;
DriverPooling* getCurrentRow();
void updateCurrentRow();
@@ -159,19 +157,6 @@ namespace offapp
}
}
-
- const DriverPooling* DriverListControl::getCurrentRow() const
- {
- OSL_ENSURE( ( GetCurRow() < m_aSettings.size() ) && ( GetCurRow() >= 0 ),
- "DriverListControl::getCurrentRow: invalid current row!");
-
- if ( ( GetCurRow() >= 0 ) && ( GetCurRow() < m_aSettings.size() ) )
- return &(*(m_aSettings.begin() + GetCurRow()));
-
- return NULL;
- }
-
-
DriverPooling* DriverListControl::getCurrentRow()
{
OSL_ENSURE( ( GetCurRow() < m_aSettings.size() ) && ( GetCurRow() >= 0 ),
diff --git a/cui/source/options/optcolor.cxx b/cui/source/options/optcolor.cxx
index 1fe8c0f..051d7c2 100644
--- a/cui/source/options/optcolor.cxx
+++ b/cui/source/options/optcolor.cxx
@@ -199,8 +199,6 @@ private:
~Chapter();
public:
void SetBackground(const Wallpaper& W) { m_pText->SetBackground(W); }
- long GetHeight() const { return m_pText->GetSizePixel().Height(); }
- long GetLeft() const { return m_pText->GetPosPixel().X(); }
void Show(const Wallpaper& rBackWall);
void Hide();
};
@@ -227,7 +225,6 @@ private:
void ColorChanged (ExtendedColorConfigValue&);
public:
long GetTop () const { return m_pPreview->GetPosPixel().Y(); }
- long GetBottom () const { return GetTop() + m_pPreview->GetSizePixel().Height(); }
unsigned GetHeight () const { return m_pColorList->GetSizePixel().Height(); }
public:
bool Is (CheckBox* pBox) const { return m_pText == pBox; }
diff --git a/cui/source/options/optlingu.cxx b/cui/source/options/optlingu.cxx
index 0eaf290..c2c4b11 100644
--- a/cui/source/options/optlingu.cxx
+++ b/cui/source/options/optlingu.cxx
@@ -213,7 +213,6 @@ public:
sal_uInt8 GetType() const {return nType;}
sal_Bool IsChecked() const {return bIsChecked;}
sal_uInt8 GetIndex() const {return nIndex;}
- void SetIndex(sal_uInt8 nSet) {nIndex = nSet;}
const OUString& GetImplName() const {return sImplName;}
};
@@ -233,10 +232,7 @@ public:
sal_uLong GetUserData() const { return nVal; }
sal_uInt16 GetEntryId() const { return (sal_uInt16)(nVal >> 16); }
sal_Bool IsChecked() const { return (sal_Bool)(nVal >> 8) & 0x01; }
- sal_Bool IsEditable() const { return (sal_Bool)(nVal >> 9) & 0x01; }
sal_Bool IsDeletable() const { return (sal_Bool)(nVal >> 10) & 0x01; }
-
- void SetChecked( sal_Bool bVal );
};
@@ -252,13 +248,6 @@ DicUserData::DicUserData(
}
-void DicUserData::SetChecked( sal_Bool bVal )
-{
- nVal &= ~(1UL << 8);
- nVal |= (sal_uLong)(bVal ? 1 : 0) << 8;
-}
-
-
// class BrwString_Impl -------------------------------------------------
static void lcl_SetCheckButton( SvTreeListEntry* pEntry, sal_Bool bCheck )
@@ -408,11 +397,9 @@ public:
sal_uInt16 GetEntryId() const { return (sal_uInt16)(nVal >> 16); }
sal_Bool HasNumericValue() const { return (sal_Bool)(nVal >> 10) & 0x01; }
sal_uInt16 GetNumericValue() const { return (sal_uInt16)(nVal & 0xFF); }
- sal_Bool IsChecked() const { return (sal_Bool)(nVal >> 8) & 0x01; }
sal_Bool IsCheckable() const { return (sal_Bool)(nVal >> 9) & 0x01; }
sal_Bool IsModified() const { return (sal_Bool)(nVal >> 11) & 0x01; }
- void SetChecked( sal_Bool bVal );
void SetNumericValue( sal_uInt8 nNumVal );
};
@@ -429,16 +416,6 @@ OptionsUserData::OptionsUserData( sal_uInt16 nEID,
((sal_uLong)(0xFF & nNumVal));
}
-void OptionsUserData::SetChecked( sal_Bool bVal )
-{
- if (IsCheckable() && (IsChecked() != bVal))
- {
- nVal &= ~(1UL << 8);
- nVal |= (sal_uLong)(bVal ? 1 : 0) << 8;
- SetModified();
- }
-}
-
void OptionsUserData::SetNumericValue( sal_uInt8 nNumVal )
{
if (HasNumericValue() && (GetNumericValue() != nNumVal))
@@ -551,16 +528,11 @@ public:
const Sequence<Locale> & GetAllSupportedLocales() const { return aAllServiceLocales; }
- const LangImplNameTable & GetSpellTable() const { return aCfgSpellTable; }
LangImplNameTable & GetSpellTable() { return aCfgSpellTable; }
- const LangImplNameTable & GetHyphTable() const { return aCfgHyphTable; }
LangImplNameTable & GetHyphTable() { return aCfgHyphTable; }
- const LangImplNameTable & GetThesTable() const { return aCfgThesTable; }
LangImplNameTable & GetThesTable() { return aCfgThesTable; }
- const LangImplNameTable & GetGrammarTable() const { return aCfgGrammarTable; }
LangImplNameTable & GetGrammarTable() { return aCfgGrammarTable; }
- const ServiceInfoArr & GetDisplayServiceArray() const { return aDisplayServiceArr; }
ServiceInfoArr & GetDisplayServiceArray() { return aDisplayServiceArr; }
const sal_uLong & GetDisplayServiceCount() const { return nDisplayServices; }
diff --git a/cui/source/uno/services.cxx b/cui/source/uno/services.cxx
index e9e798a..893388e 100644
--- a/cui/source/uno/services.cxx
+++ b/cui/source/uno/services.cxx
@@ -22,13 +22,9 @@
#include "cppuhelper/factory.hxx"
#include <cppuhelper/implementationentry.hxx>
-using namespace com::sun::star;
+#include <colorpicker.hxx>
-namespace cui {
-extern OUString SAL_CALL ColorPicker_getImplementationName();
-extern uno::Reference< uno::XInterface > SAL_CALL ColorPicker_createInstance( uno::Reference< uno::XComponentContext > const & ) SAL_THROW( (uno::Exception) );
-extern uno::Sequence< OUString > SAL_CALL ColorPicker_getSupportedServiceNames() throw( uno::RuntimeException );
-}
+using namespace com::sun::star;
namespace
{
More information about the Libreoffice-commits
mailing list