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
f229b9b0
Kaydet (Commit)
f229b9b0
authored
Kas 20, 2015
tarafından
Matúš Kukan
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
tdf#74608 dbaccess: Constructor feature for ODatabaseDocument
Change-Id: Id524a1a717c350cb0558ef5ff11da3e6c941c203
üst
970f5189
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
22 additions
and
55 deletions
+22
-55
databasedocument.cxx
dbaccess/source/core/dataaccess/databasedocument.cxx
+20
-46
databasedocument.hxx
dbaccess/source/core/dataaccess/databasedocument.hxx
+0
-6
services.hxx
dbaccess/source/core/inc/services.hxx
+0
-1
services.cxx
dbaccess/source/core/misc/services.cxx
+0
-1
dba.component
dbaccess/util/dba.component
+2
-1
No files found.
dbaccess/source/core/dataaccess/databasedocument.cxx
Dosyayı görüntüle @
f229b9b0
...
...
@@ -22,8 +22,6 @@
#include "datasource.hxx"
#include "databasedocument.hxx"
#include "dbastrings.hrc"
#include "module_dba.hxx"
#include "services.hxx"
#include "documenteventexecutor.hxx"
#include "databasecontext.hxx"
#include "documentcontainer.hxx"
...
...
@@ -52,7 +50,6 @@
#include <com/sun/star/task/XStatusIndicator.hpp>
#include <com/sun/star/task/XStatusIndicatorFactory.hpp>
#include <com/sun/star/ucb/SimpleFileAccess.hpp>
#include <com/sun/star/ucb/XContent.hpp>
#include <com/sun/star/ui/UIConfigurationManager.hpp>
#include <com/sun/star/ui/XUIConfigurationStorage.hpp>
#include <com/sun/star/view/XSelectionSupplier.hpp>
...
...
@@ -111,11 +108,6 @@ using namespace ::com::sun::star::script;
using
namespace
::
com
::
sun
::
star
::
script
::
provider
;
using
namespace
::
com
::
sun
::
star
::
ui
;
using
namespace
::
cppu
;
using
namespace
::
osl
;
using
::
com
::
sun
::
star
::
awt
::
XWindow
;
using
::
com
::
sun
::
star
::
ucb
::
XContent
;
using
::
com
::
sun
::
star
::
sdb
::
application
::
XDatabaseDocumentUI
;
namespace
dbaccess
{
...
...
@@ -147,17 +139,6 @@ bool ViewMonitor::onSetCurrentController( const Reference< XController >& _rxCon
return
bLoadFinished
;
}
}
// namespace dbaccess
// ODatabaseDocument
extern
"C"
void
SAL_CALL
createRegistryInfo_ODatabaseDocument
()
{
static
::
dba
::
OAutoRegistration
<
::
dbaccess
::
ODatabaseDocument
>
aAutoRegistration
;
}
namespace
dbaccess
{
ODatabaseDocument
::
ODatabaseDocument
(
const
::
rtl
::
Reference
<
ODatabaseModelImpl
>&
_pImpl
)
:
ModelDependentComponent
(
_pImpl
)
...
...
@@ -611,7 +592,7 @@ namespace
{
bool
lcl_hasAnyModifiedSubComponent_throw
(
const
Reference
<
XController
>&
i_rController
)
{
Reference
<
XDatabaseDocumentUI
>
xDatabaseUI
(
i_rController
,
UNO_QUERY_THROW
);
Reference
<
css
::
sdb
::
application
::
XDatabaseDocumentUI
>
xDatabaseUI
(
i_rController
,
UNO_QUERY_THROW
);
Sequence
<
Reference
<
XComponent
>
>
aComponents
(
xDatabaseUI
->
getSubComponents
()
);
const
Reference
<
XComponent
>*
component
=
aComponents
.
getConstArray
();
...
...
@@ -1900,37 +1881,14 @@ void SAL_CALL ODatabaseDocument::removeEventListener( const Reference< lang::XEv
}
// XServiceInfo
OUString
ODatabaseDocument
::
getImplementationName
(
)
throw
(
RuntimeException
,
std
::
exception
)
{
return
getImplementationName_static
();
}
OUString
ODatabaseDocument
::
getImplementationName_static
(
)
throw
(
RuntimeException
)
OUString
ODatabaseDocument
::
getImplementationName
()
throw
(
RuntimeException
,
std
::
exception
)
{
return
OUString
(
"com.sun.star.comp.dba.ODatabaseDocument"
);
}
Sequence
<
OUString
>
ODatabaseDocument
::
getSupportedServiceNames
(
)
throw
(
RuntimeException
,
std
::
exception
)
Sequence
<
OUString
>
ODatabaseDocument
::
getSupportedServiceNames
()
throw
(
RuntimeException
,
std
::
exception
)
{
return
getSupportedServiceNames_static
();
}
Reference
<
XInterface
>
ODatabaseDocument
::
Create
(
const
Reference
<
XComponentContext
>&
_rxContext
)
{
Reference
<
XUnoTunnel
>
xDBContextTunnel
(
DatabaseContext
::
create
(
_rxContext
),
UNO_QUERY_THROW
);
ODatabaseContext
*
pContext
=
reinterpret_cast
<
ODatabaseContext
*
>
(
xDBContextTunnel
->
getSomething
(
ODatabaseContext
::
getUnoTunnelImplementationId
()
)
);
::
rtl
::
Reference
<
ODatabaseModelImpl
>
pImpl
(
new
ODatabaseModelImpl
(
_rxContext
,
*
pContext
)
);
Reference
<
XModel
>
xModel
(
pImpl
->
createNewModel_deliverOwnership
(
false
)
);
return
xModel
.
get
();
}
Sequence
<
OUString
>
ODatabaseDocument
::
getSupportedServiceNames_static
(
)
throw
(
RuntimeException
)
{
Sequence
<
OUString
>
aSNS
(
2
);
aSNS
[
0
]
=
"com.sun.star.sdb.OfficeDatabaseDocument"
;
aSNS
[
1
]
=
"com.sun.star.document.OfficeDocument"
;
return
aSNS
;
return
{
"com.sun.star.sdb.OfficeDatabaseDocument"
,
"com.sun.star.document.OfficeDocument"
};
}
sal_Bool
ODatabaseDocument
::
supportsService
(
const
OUString
&
_rServiceName
)
throw
(
RuntimeException
,
std
::
exception
)
...
...
@@ -2252,4 +2210,20 @@ OUString SAL_CALL ODatabaseDocument::getUntitledPrefix() throw (uno::RuntimeE
}
// namespace dbaccess
extern
"C"
SAL_DLLPUBLIC_EXPORT
css
::
uno
::
XInterface
*
SAL_CALL
com_sun_star_comp_dba_ODatabaseDocument
(
css
::
uno
::
XComponentContext
*
context
,
css
::
uno
::
Sequence
<
css
::
uno
::
Any
>
const
&
)
{
Reference
<
XUnoTunnel
>
xDBContextTunnel
(
DatabaseContext
::
create
(
context
),
UNO_QUERY_THROW
);
dbaccess
::
ODatabaseContext
*
pContext
=
reinterpret_cast
<
dbaccess
::
ODatabaseContext
*>
(
xDBContextTunnel
->
getSomething
(
dbaccess
::
ODatabaseContext
::
getUnoTunnelImplementationId
()));
rtl
::
Reference
<
dbaccess
::
ODatabaseModelImpl
>
pImpl
(
new
dbaccess
::
ODatabaseModelImpl
(
context
,
*
pContext
));
css
::
uno
::
Reference
<
XInterface
>
inst
(
pImpl
->
createNewModel_deliverOwnership
(
false
));
inst
->
acquire
();
return
inst
.
get
();
}
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
dbaccess/source/core/dataaccess/databasedocument.hxx
Dosyayı görüntüle @
f229b9b0
...
...
@@ -294,12 +294,6 @@ public:
virtual
sal_Bool
SAL_CALL
supportsService
(
const
OUString
&
ServiceName
)
throw
(
css
::
uno
::
RuntimeException
,
std
::
exception
)
override
;
virtual
css
::
uno
::
Sequence
<
OUString
>
SAL_CALL
getSupportedServiceNames
(
)
throw
(
css
::
uno
::
RuntimeException
,
std
::
exception
)
override
;
// css::lang::XServiceInfo - static methods
static
css
::
uno
::
Sequence
<
OUString
>
getSupportedServiceNames_static
()
throw
(
css
::
uno
::
RuntimeException
);
static
OUString
getImplementationName_static
()
throw
(
css
::
uno
::
RuntimeException
);
static
css
::
uno
::
Reference
<
css
::
uno
::
XInterface
>
SAL_CALL
Create
(
const
css
::
uno
::
Reference
<
css
::
uno
::
XComponentContext
>&
);
// XInterface
virtual
css
::
uno
::
Any
SAL_CALL
queryInterface
(
const
css
::
uno
::
Type
&
_rType
)
throw
(
css
::
uno
::
RuntimeException
,
std
::
exception
)
override
;
virtual
void
SAL_CALL
acquire
(
)
throw
()
override
;
...
...
dbaccess/source/core/inc/services.hxx
Dosyayı görüntüle @
f229b9b0
...
...
@@ -25,7 +25,6 @@
#include <sal/types.h>
extern
"C"
void
SAL_CALL
createRegistryInfo_DataAccessDescriptorFactory
();
extern
"C"
void
SAL_CALL
createRegistryInfo_ODatabaseDocument
();
#endif
...
...
dbaccess/source/core/misc/services.cxx
Dosyayı görüntüle @
f229b9b0
...
...
@@ -58,7 +58,6 @@ extern "C" void SAL_CALL createRegistryInfo_DBA()
static
bool
bInit
=
false
;
if
(
!
bInit
)
{
createRegistryInfo_ODatabaseDocument
();
createRegistryInfo_DataAccessDescriptorFactory
();
bInit
=
true
;
}
...
...
dbaccess/util/dba.component
Dosyayı görüntüle @
f229b9b0
...
...
@@ -37,7 +37,8 @@
<implementation
name=
"com.sun.star.comp.dba.ODatabaseContext"
>
<service
name=
"com.sun.star.sdb.DatabaseContext"
/>
</implementation>
<implementation
name=
"com.sun.star.comp.dba.ODatabaseDocument"
>
<implementation
name=
"com.sun.star.comp.dba.ODatabaseDocument"
constructor=
"com_sun_star_comp_dba_ODatabaseDocument"
>
<service
name=
"com.sun.star.document.OfficeDocument"
/>
<service
name=
"com.sun.star.sdb.OfficeDatabaseDocument"
/>
</implementation>
...
...
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