Skip to content
Projeler
Gruplar
Parçacıklar
Yardım
Yükleniyor...
Oturum aç / Kaydol
Gezinmeyi değiştir
C
core
Proje
Proje
Ayrıntılar
Etkinlik
Cycle Analytics
Depo (repository)
Depo (repository)
Dosyalar
Kayıtlar (commit)
Dallar (branch)
Etiketler
Katkıda bulunanlar
Grafik
Karşılaştır
Grafikler
Konular (issue)
0
Konular (issue)
0
Liste
Pano
Etiketler
Kilometre Taşları
Birleştirme (merge) Talepleri
0
Birleştirme (merge) Talepleri
0
CI / CD
CI / CD
İş akışları (pipeline)
İşler
Zamanlamalar
Grafikler
Paketler
Paketler
Wiki
Wiki
Parçacıklar
Parçacıklar
Üyeler
Üyeler
Collapse sidebar
Close sidebar
Etkinlik
Grafik
Grafikler
Yeni bir konu (issue) oluştur
İşler
Kayıtlar (commit)
Konu (issue) Panoları
Kenar çubuğunu aç
LibreOffice
core
Commits
f4776bf4
Kaydet (Commit)
f4776bf4
authored
12 years ago
tarafından
Noel Grandin
Kaydeden (comit)
Stephan Bergmann
12 years ago
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
fdo#46808, fix up some NumberFormatter createInstance calls I missed
Change-Id: Ieb3ce841243797a119f1d1d40379ff2a4614168f
üst
d40dceb7
Hide whitespace changes
Inline
Side-by-side
Showing
11 changed files
with
40 additions
and
41 deletions
+40
-41
services.hxx
forms/source/inc/services.hxx
+0
-1
Library_analysis.mk
scaddins/Library_analysis.mk
+1
-0
analysis.cxx
scaddins/source/analysis/analysis.cxx
+4
-3
analysis.hxx
scaddins/source/analysis/analysis.hxx
+1
-1
analysishelper.cxx
scaddins/source/analysis/analysishelper.cxx
+3
-7
analysishelper.hxx
scaddins/source/analysis/analysishelper.hxx
+4
-3
cellvalueconversion.cxx
svtools/source/table/cellvalueconversion.cxx
+4
-3
gridctrl.cxx
svx/source/fmcomp/gridctrl.cxx
+13
-15
filtnav.cxx
svx/source/form/filtnav.cxx
+5
-2
fmsrcimp.cxx
svx/source/form/fmsrcimp.cxx
+5
-5
fmservs.hxx
svx/source/inc/fmservs.hxx
+0
-1
No files found.
forms/source/inc/services.hxx
Dosyayı görüntüle @
f4776bf4
...
...
@@ -210,7 +210,6 @@ namespace frm
// -----------------------
FORMS_CONSTASCII_STRING
(
SRV_AWT_POINTER
,
"com.sun.star.awt.Pointer"
);
FORMS_CONSTASCII_STRING
(
SRV_AWT_IMAGEPRODUCER
,
"com.sun.star.awt.ImageProducer"
);
FORMS_CONSTASCII_STRING
(
FRM_NUMBER_FORMATTER
,
"com.sun.star.util.NumberFormatter"
);
FORMS_CONSTASCII_STRING
(
FRM_NUMBER_FORMATS_SUPPLIER
,
"com.sun.star.util.NumberFormatsSupplier"
);
FORMS_CONSTASCII_STRING
(
SRV_SDB_ROWSET
,
"com.sun.star.sdb.RowSet"
);
...
...
This diff is collapsed.
Click to expand it.
scaddins/Library_analysis.mk
Dosyayı görüntüle @
f4776bf4
...
...
@@ -37,6 +37,7 @@ $(eval $(call gb_Library_use_internal_comprehensive_api,analysis,\
))
$(eval $(call gb_Library_use_libraries,analysis,\
comphelper \
cppu \
cppuhelper \
sal \
...
...
This diff is collapsed.
Click to expand it.
scaddins/source/analysis/analysis.cxx
Dosyayı görüntüle @
f4776bf4
...
...
@@ -19,6 +19,7 @@
#include "analysis.hxx"
#include <comphelper/processfactory.hxx>
#include <cppuhelper/factory.hxx>
#include <osl/diagnose.h>
#include <rtl/ustrbuf.hxx>
...
...
@@ -155,13 +156,13 @@ void AnalysisAddIn::InitData( void )
}
AnalysisAddIn
::
AnalysisAddIn
(
const
uno
::
Reference
<
lang
::
XMultiServiceFactory
>&
xServiceFac
t
)
:
AnalysisAddIn
::
AnalysisAddIn
(
const
uno
::
Reference
<
uno
::
XComponentContext
>&
xContex
t
)
:
pDefLocales
(
NULL
),
pFD
(
NULL
),
pFactDoubles
(
NULL
),
pCDL
(
NULL
),
pResMgr
(
NULL
),
aAnyConv
(
x
ServiceFac
t
)
aAnyConv
(
x
Contex
t
)
{
}
...
...
@@ -259,7 +260,7 @@ SEQ( STRING ) AnalysisAddIn::getSupportedServiceNames_Static()
REF
(
uno
::
XInterface
)
SAL_CALL
AnalysisAddIn_CreateInstance
(
const
uno
::
Reference
<
lang
::
XMultiServiceFactory
>&
xServiceFact
)
{
static
uno
::
Reference
<
uno
::
XInterface
>
xInst
=
(
cppu
::
OWeakObject
*
)
new
AnalysisAddIn
(
xServiceFact
);
static
uno
::
Reference
<
uno
::
XInterface
>
xInst
=
(
cppu
::
OWeakObject
*
)
new
AnalysisAddIn
(
comphelper
::
getComponentContext
(
xServiceFact
)
);
return
xInst
;
}
...
...
This diff is collapsed.
Click to expand it.
scaddins/source/analysis/analysis.hxx
Dosyayı görüntüle @
f4776bf4
...
...
@@ -76,7 +76,7 @@ private:
public
:
AnalysisAddIn
(
const
::
com
::
sun
::
star
::
uno
::
Reference
<
::
com
::
sun
::
star
::
lang
::
XMultiServiceFactory
>&
xServiceFac
t
);
const
::
com
::
sun
::
star
::
uno
::
Reference
<
::
com
::
sun
::
star
::
uno
::
XComponentContext
>&
xContex
t
);
virtual
~
AnalysisAddIn
();
double
FactDouble
(
sal_Int32
nNum
)
THROWDEF_RTE_IAE
;
...
...
This diff is collapsed.
Click to expand it.
scaddins/source/analysis/analysishelper.cxx
Dosyayı görüntüle @
f4776bf4
...
...
@@ -18,6 +18,7 @@
*/
#include <com/sun/star/util/XNumberFormatTypes.hpp>
#include <com/sun/star/util/NumberFormatter.hpp>
#include <string.h>
#include <stdio.h>
...
...
@@ -2845,15 +2846,10 @@ sal_Bool ScaDate::operator<( const ScaDate& rCmp ) const
//-----------------------------------------------------------------------------
ScaAnyConverter
::
ScaAnyConverter
(
const
uno
::
Reference
<
lang
::
XMultiServiceFactory
>&
xServiceFac
t
)
:
ScaAnyConverter
::
ScaAnyConverter
(
const
uno
::
Reference
<
uno
::
XComponentContext
>&
xContex
t
)
:
bHasValidFormat
(
sal_False
)
{
if
(
xServiceFact
.
is
()
)
{
uno
::
Reference
<
uno
::
XInterface
>
xInstance
=
xServiceFact
->
createInstance
(
OUString
(
RTL_CONSTASCII_USTRINGPARAM
(
"com.sun.star.util.NumberFormatter"
))
);
xFormatter
=
uno
::
Reference
<
util
::
XNumberFormatter
>
(
xInstance
,
uno
::
UNO_QUERY
);
}
xFormatter
=
util
::
NumberFormatter
::
create
(
xContext
);
}
ScaAnyConverter
::~
ScaAnyConverter
()
...
...
This diff is collapsed.
Click to expand it.
scaddins/source/analysis/analysishelper.hxx
Dosyayı görüntüle @
f4776bf4
...
...
@@ -23,8 +23,9 @@
#include <com/sun/star/lang/XServiceName.hpp>
#include <com/sun/star/lang/XServiceInfo.hpp>
#include <com/sun/star/lang/XMultiServiceFactory.hpp>
#include <com/sun/star/uno/XComponentContext.hpp>
#include <com/sun/star/util/Date.hpp>
#include <com/sun/star/util/XNumberFormatter.hpp>
#include <com/sun/star/util/XNumberFormatter
2
.hpp>
#include <com/sun/star/util/XNumberFormatsSupplier.hpp>
#include <com/sun/star/sheet/XAddIn.hpp>
#include <com/sun/star/sheet/addin/XAnalysis.hpp>
...
...
@@ -1030,7 +1031,7 @@ inline void ScaDate::addYears( sal_Int32 nYearCount ) throw( ::com::sun::star::l
class
ScaAnyConverter
{
private
:
::
com
::
sun
::
star
::
uno
::
Reference
<
::
com
::
sun
::
star
::
util
::
XNumberFormatter
>
xFormatter
;
::
com
::
sun
::
star
::
uno
::
Reference
<
::
com
::
sun
::
star
::
util
::
XNumberFormatter
2
>
xFormatter
;
sal_Int32
nDefaultFormat
;
sal_Bool
bHasValidFormat
;
...
...
@@ -1045,7 +1046,7 @@ private:
public
:
ScaAnyConverter
(
const
::
com
::
sun
::
star
::
uno
::
Reference
<
::
com
::
sun
::
star
::
lang
::
XMultiServiceFactory
>&
xServiceFac
t
);
const
::
com
::
sun
::
star
::
uno
::
Reference
<
::
com
::
sun
::
star
::
uno
::
XComponentContext
>&
xContex
t
);
~
ScaAnyConverter
();
/// Initializing with current language settings
...
...
This diff is collapsed.
Click to expand it.
svtools/source/table/cellvalueconversion.cxx
Dosyayı görüntüle @
f4776bf4
...
...
@@ -27,7 +27,7 @@
#include "cellvalueconversion.hxx"
#include <com/sun/star/util/
X
NumberFormatter.hpp>
#include <com/sun/star/util/NumberFormatter.hpp>
#include <com/sun/star/util/XNumberFormatsSupplier.hpp>
#include <com/sun/star/beans/XPropertySet.hpp>
#include <com/sun/star/util/Date.hpp>
...
...
@@ -54,6 +54,8 @@ namespace svt
/** === begin UNO using === **/
using
::
com
::
sun
::
star
::
uno
::
Any
;
using
::
com
::
sun
::
star
::
util
::
XNumberFormatter
;
using
::
com
::
sun
::
star
::
util
::
XNumberFormatter2
;
using
::
com
::
sun
::
star
::
util
::
NumberFormatter
;
using
::
com
::
sun
::
star
::
uno
::
UNO_QUERY_THROW
;
using
::
com
::
sun
::
star
::
util
::
XNumberFormatsSupplier
;
using
::
com
::
sun
::
star
::
beans
::
XPropertySet
;
...
...
@@ -343,8 +345,7 @@ namespace svt
try
{
// a number formatter
Reference
<
XNumberFormatter
>
const
xFormatter
(
io_data
.
aContext
.
createComponent
(
"com.sun.star.util.NumberFormatter"
),
UNO_QUERY_THROW
);
Reference
<
XNumberFormatter
>
const
xFormatter
(
NumberFormatter
::
create
(
io_data
.
aContext
.
getUNOContext
()
),
UNO_QUERY_THROW
);
// a supplier of number formats
Sequence
<
Any
>
aInitArgs
(
1
);
...
...
This diff is collapsed.
Click to expand it.
svx/source/fmcomp/gridctrl.cxx
Dosyayı görüntüle @
f4776bf4
...
...
@@ -44,12 +44,13 @@
#include <com/sun/star/sdbc/XResultSetUpdate.hpp>
#include <com/sun/star/sdbcx/Privilege.hpp>
#include <com/sun/star/container/XChild.hpp>
#include <com/sun/star/util/
X
NumberFormatter.hpp>
#include <com/sun/star/util/NumberFormatter.hpp>
#include <com/sun/star/util/XNumberFormatsSupplier.hpp>
#include <com/sun/star/util/XCloneable.hpp>
#include <com/sun/star/beans/XPropertySet.hpp>
#include <com/sun/star/beans/PropertyChangeEvent.hpp>
#include <comphelper/extract.hxx>
#include <comphelper/processfactory.hxx>
#include <tools/resid.hxx>
#include <tools/diagnose_ex.h>
#include <vcl/menu.hxx>
...
...
@@ -1451,23 +1452,20 @@ void DbGridControl::setDataSource(const Reference< XRowSet >& _xCursor, sal_uInt
m_xFormatter
=
NULL
;
OStaticDataAccessTools
aStaticTools
;
Reference
<
::
com
::
sun
::
star
::
util
::
XNumberFormatsSupplier
>
xSupplier
=
aStaticTools
.
getNumberFormats
(
aStaticTools
.
getRowSetConnection
(
_xCursor
),
sal_True
);
if
(
xSupplier
.
is
()
&&
m_xServiceFactory
.
is
()
)
if
(
xSupplier
.
is
())
{
m_xFormatter
=
Reference
<
::
com
::
sun
::
star
::
util
::
XNumberFormatter
>
(
m_xServiceFactory
->
createInstance
(
FM_NUMBER_FORMATTER
),
m_xFormatter
=
Reference
<
::
com
::
sun
::
star
::
util
::
XNumberFormatter
>
(
::
com
::
sun
::
star
::
util
::
NumberFormatter
::
create
(
comphelper
::
getComponentContext
(
m_xServiceFactory
)
),
UNO_QUERY
);
if
(
m_xFormatter
.
is
())
{
m_xFormatter
->
attachNumberFormatsSupplier
(
xSupplier
);
m_xFormatter
->
attachNumberFormatsSupplier
(
xSupplier
);
// retrieve the datebase of the Numberformatter
try
{
xSupplier
->
getNumberFormatSettings
()
->
getPropertyValue
(
rtl
::
OUString
(
"NullDate"
))
>>=
m_aNullDate
;
}
catch
(
Exception
&
)
{
}
// retrieve the datebase of the Numberformatter
try
{
xSupplier
->
getNumberFormatSettings
()
->
getPropertyValue
(
rtl
::
OUString
(
"NullDate"
))
>>=
m_aNullDate
;
}
catch
(
Exception
&
)
{
}
}
...
...
This diff is collapsed.
Click to expand it.
svx/source/form/filtnav.cxx
Dosyayı görüntüle @
f4776bf4
...
...
@@ -38,9 +38,10 @@
#include <com/sun/star/awt/XTextComponent.hpp>
#include <com/sun/star/form/runtime/XFormController.hpp>
#include <com/sun/star/lang/XUnoTunnel.hpp>
#include <com/sun/star/util/
X
NumberFormatter.hpp>
#include <com/sun/star/util/NumberFormatter.hpp>
#include <com/sun/star/beans/XFastPropertySet.hpp>
#include <comphelper/componentcontext.hxx>
#include <comphelper/processfactory.hxx>
#include <comphelper/property.hxx>
#include <comphelper/sequence.hxx>
...
...
@@ -103,6 +104,8 @@ namespace svxform
using
::
com
::
sun
::
star
::
util
::
XNumberFormatsSupplier
;
using
::
com
::
sun
::
star
::
beans
::
XPropertySet
;
using
::
com
::
sun
::
star
::
util
::
XNumberFormatter
;
using
::
com
::
sun
::
star
::
util
::
XNumberFormatter2
;
using
::
com
::
sun
::
star
::
util
::
NumberFormatter
;
using
::
com
::
sun
::
star
::
sdbc
::
XRowSet
;
using
::
com
::
sun
::
star
::
lang
::
Locale
;
using
::
com
::
sun
::
star
::
sdb
::
SQLContext
;
...
...
@@ -895,7 +898,7 @@ sal_Bool FmFilterModel::ValidateText(FmFilterItem* pItem, UniString& rText, UniS
// obtain a number formatter for this connection
// TODO: shouldn't this be cached?
Reference
<
XNumberFormatsSupplier
>
xFormatSupplier
=
aStaticTools
.
getNumberFormats
(
xConnection
,
sal_True
);
Reference
<
XNumberFormatter
>
xFormatter
(
m_xORB
->
createInstance
(
FM_NUMBER_FORMATTER
),
UNO_QUERY
);
Reference
<
XNumberFormatter
>
xFormatter
(
NumberFormatter
::
create
(
comphelper
::
getComponentContext
(
m_xORB
)
),
UNO_QUERY_THROW
);
xFormatter
->
attachNumberFormatsSupplier
(
xFormatSupplier
);
// get the field (database column) which the item is responsible for
...
...
This diff is collapsed.
Click to expand it.
svx/source/form/fmsrcimp.cxx
Dosyayı görüntüle @
f4776bf4
...
...
@@ -49,7 +49,7 @@
#include <com/sun/star/i18n/CollatorOptions.hpp>
#include <com/sun/star/sdbcx/XColumnsSupplier.hpp>
#include <com/sun/star/util/
X
NumberFormatter.hpp>
#include <com/sun/star/util/NumberFormatter.hpp>
#include <com/sun/star/util/NumberFormat.hpp>
#include <com/sun/star/util/XNumberFormatsSupplier.hpp>
#include <com/sun/star/util/XNumberFormats.hpp>
...
...
@@ -710,10 +710,10 @@ FmSearchEngine::FmSearchEngine(const Reference< XMultiServiceFactory >& _rxORB,
{
DBG_CTOR
(
FmSearchEngine
,
NULL
);
m_xFormatter
=
Reference
<
::
com
::
sun
::
star
::
util
::
XNumberFormatter
>
(
::
comphelper
::
getProcessServiceFactory
()
->
createInstance
(
FM_NUMBER_FORMATTER
),
UNO_QUERY
);
if
(
m_xFormatter
.
is
())
m_xFormatter
->
attachNumberFormatsSupplier
(
m_xFormatSupplier
);
m_xFormatter
=
Reference
<
::
com
::
sun
::
star
::
util
::
XNumberFormatter
>
(
::
com
::
sun
::
star
::
util
::
NumberFormatter
::
create
(
::
comphelper
::
getProcessComponentContext
()
),
UNO_QUERY_THROW
);
m_xFormatter
->
attachNumberFormatsSupplier
(
m_xFormatSupplier
);
Init
(
sVisibleFields
);
}
...
...
This diff is collapsed.
Click to expand it.
svx/source/inc/fmservs.hxx
Dosyayı görüntüle @
f4776bf4
...
...
@@ -21,7 +21,6 @@
#include <svx/svxdllapi.h>
#define FM_NUMBER_FORMATTER rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "com.sun.star.util.NumberFormatter" ) )
#define FM_COMPONENT_EDIT rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "stardiv.one.form.component.Edit" ) )
#define FM_COMPONENT_TEXTFIELD rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "stardiv.one.form.component.TextField" ) )
#define FM_COMPONENT_LISTBOX rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "stardiv.one.form.component.ListBox" ) )
...
...
This diff is collapsed.
Click to expand it.
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment