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
c767178b
Kaydet (Commit)
c767178b
authored
Agu 20, 2012
tarafından
Tor Lillqvist
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
Fix compilation in the (experimental) DISABLE_DBCONNECTIVITY case
Change-Id: I392b0203e0850a57eb3e1dfdaf21eafed838129b
üst
aa6808ba
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
33 additions
and
0 deletions
+33
-0
docsh8.cxx
sc/source/ui/docshell/docsh8.cxx
+33
-0
No files found.
sc/source/ui/docshell/docsh8.cxx
Dosyayı görüntüle @
c767178b
...
@@ -34,7 +34,10 @@
...
@@ -34,7 +34,10 @@
#include <comphelper/types.hxx>
#include <comphelper/types.hxx>
#include <ucbhelper/content.hxx>
#include <ucbhelper/content.hxx>
#include <svx/txenctab.hxx>
#include <svx/txenctab.hxx>
#ifndef DISABLE_DBCONNECTIVITY
#include <svx/dbcharsethelper.hxx>
#include <svx/dbcharsethelper.hxx>
#endif
#include <com/sun/star/sdb/CommandType.hpp>
#include <com/sun/star/sdb/CommandType.hpp>
#include <com/sun/star/sdbc/DataType.hpp>
#include <com/sun/star/sdbc/DataType.hpp>
...
@@ -104,6 +107,8 @@ using ::std::vector;
...
@@ -104,6 +107,8 @@ using ::std::vector;
#define SC_DBPROP_EXTENSION "Extension"
#define SC_DBPROP_EXTENSION "Extension"
#define SC_DBPROP_CHARSET "CharSet"
#define SC_DBPROP_CHARSET "CharSet"
#ifndef DISABLE_DBCONNECTIVITY
namespace
namespace
{
{
sal_uLong
lcl_getDBaseConnection
(
uno
::
Reference
<
sdbc
::
XDriverManager
>&
_rDrvMgr
,
uno
::
Reference
<
sdbc
::
XConnection
>&
_rConnection
,
String
&
_rTabName
,
const
String
&
rFullFileName
,
rtl_TextEncoding
eCharSet
)
sal_uLong
lcl_getDBaseConnection
(
uno
::
Reference
<
sdbc
::
XDriverManager
>&
_rDrvMgr
,
uno
::
Reference
<
sdbc
::
XConnection
>&
_rConnection
,
String
&
_rTabName
,
const
String
&
rFullFileName
,
rtl_TextEncoding
eCharSet
)
...
@@ -159,6 +164,9 @@ namespace
...
@@ -159,6 +164,9 @@ namespace
return
0L
;
return
0L
;
}
}
}
}
#endif // !DISABLE_DBCONNECTIVITY
// -----------------------------------------------------------------------
// -----------------------------------------------------------------------
// MoveFile/KillFile/IsDocument: similar to SfxContentHelper
// MoveFile/KillFile/IsDocument: similar to SfxContentHelper
...
@@ -245,6 +253,8 @@ bool ScDocShell::IsDocument( const INetURLObject& rURL )
...
@@ -245,6 +253,8 @@ bool ScDocShell::IsDocument( const INetURLObject& rURL )
// -----------------------------------------------------------------------
// -----------------------------------------------------------------------
#ifndef DISABLE_DBCONNECTIVITY
static
void
lcl_setScalesToColumns
(
ScDocument
&
rDoc
,
const
vector
<
long
>&
rScales
)
static
void
lcl_setScalesToColumns
(
ScDocument
&
rDoc
,
const
vector
<
long
>&
rScales
)
{
{
SvNumberFormatter
*
pFormatter
=
rDoc
.
GetFormatTable
();
SvNumberFormatter
*
pFormatter
=
rDoc
.
GetFormatTable
();
...
@@ -292,9 +302,19 @@ static void lcl_setScalesToColumns(ScDocument& rDoc, const vector<long>& rScales
...
@@ -292,9 +302,19 @@ static void lcl_setScalesToColumns(ScDocument& rDoc, const vector<long>& rScales
}
}
}
}
#endif // !DISABLE_DBCONNECTIVITY
sal_uLong
ScDocShell
::
DBaseImport
(
const
String
&
rFullFileName
,
CharSet
eCharSet
,
sal_uLong
ScDocShell
::
DBaseImport
(
const
String
&
rFullFileName
,
CharSet
eCharSet
,
ScColWidthParam
aColWidthParam
[
MAXCOLCOUNT
],
ScFlatBoolRowSegments
&
rRowHeightsRecalc
)
ScColWidthParam
aColWidthParam
[
MAXCOLCOUNT
],
ScFlatBoolRowSegments
&
rRowHeightsRecalc
)
{
{
#ifdef DISABLE_DBCONNECTIVITY
(
void
)
rFullFileName
;
(
void
)
eCharSet
;
(
void
)
aColWidthParam
;
(
void
)
rRowHeightsRecalc
;
return
ERRCODE_IO_GENERAL
;
#else
ScColumn
::
DoubleAllocSwitch
aAllocSwitch
(
true
);
ScColumn
::
DoubleAllocSwitch
aAllocSwitch
(
true
);
sal_uLong
nErr
=
eERR_OK
;
sal_uLong
nErr
=
eERR_OK
;
...
@@ -470,8 +490,11 @@ sal_uLong ScDocShell::DBaseImport( const String& rFullFileName, CharSet eCharSet
...
@@ -470,8 +490,11 @@ sal_uLong ScDocShell::DBaseImport( const String& rFullFileName, CharSet eCharSet
aDocument
.
DoColResize
(
0
,
0
,
static_cast
<
SCCOL
>
(
nColCount
)
-
1
,
0
);
aDocument
.
DoColResize
(
0
,
0
,
static_cast
<
SCCOL
>
(
nColCount
)
-
1
,
0
);
return
nErr
;
return
nErr
;
#endif // !DISABLE_DBCONNECTIVITY
}
}
#ifndef DISABLE_DBCONNECTIVITY
namespace
{
namespace
{
inline
bool
IsAsciiDigit
(
sal_Unicode
c
)
inline
bool
IsAsciiDigit
(
sal_Unicode
c
)
...
@@ -777,8 +800,17 @@ inline void lcl_getLongVarCharString( rtl::OUString& rString, ScBaseCell* pCell,
...
@@ -777,8 +800,17 @@ inline void lcl_getLongVarCharString( rtl::OUString& rString, ScBaseCell* pCell,
}
}
#endif // !DISABLE_DBCONNECTIVITY
sal_uLong
ScDocShell
::
DBaseExport
(
const
rtl
::
OUString
&
rFullFileName
,
CharSet
eCharSet
,
bool
&
bHasMemo
)
sal_uLong
ScDocShell
::
DBaseExport
(
const
rtl
::
OUString
&
rFullFileName
,
CharSet
eCharSet
,
bool
&
bHasMemo
)
{
{
#ifdef DISABLE_DBCONNECTIVITY
(
void
)
rFullFileName
;
(
void
)
eCharSet
;
(
void
)
bHasMemo
;
return
ERRCODE_IO_GENERAL
;
#else
// remove the file so the dBase driver doesn't find an invalid file
// remove the file so the dBase driver doesn't find an invalid file
INetURLObject
aDeleteObj
(
rFullFileName
,
INET_PROT_FILE
);
INetURLObject
aDeleteObj
(
rFullFileName
,
INET_PROT_FILE
);
KillFile
(
aDeleteObj
);
KillFile
(
aDeleteObj
);
...
@@ -1156,6 +1188,7 @@ sal_uLong ScDocShell::DBaseExport( const rtl::OUString& rFullFileName, CharSet e
...
@@ -1156,6 +1188,7 @@ sal_uLong ScDocShell::DBaseExport( const rtl::OUString& rFullFileName, CharSet e
}
}
return
nErr
;
return
nErr
;
#endif // !DISABLE_DBCONNECTIVITY
}
}
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
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