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
5a699487
Kaydet (Commit)
5a699487
authored
Ock 01, 2017
tarafından
Caolán McNamara
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
fold ResourceIndexAccessBase into ResourceStringIndexAccess
Change-Id: Icef518dc65d5edf4e7893df460aaae179eecfb45
üst
705b4351
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
16 deletions
+6
-16
ResourceIndexAccess.cxx
extensions/source/resource/ResourceIndexAccess.cxx
+6
-16
No files found.
extensions/source/resource/ResourceIndexAccess.cxx
Dosyayı görüntüle @
5a699487
...
...
@@ -37,10 +37,10 @@ namespace
return
std
::
shared_ptr
<
ResMgr
>
(
ResMgr
::
CreateResMgr
(
sEncName
.
getStr
()));
}
class
Resource
IndexAccessBase
:
public
cppu
::
WeakImplHelper
<
css
::
container
::
XIndexAccess
>
class
Resource
StringIndexAccess
:
public
cppu
::
WeakImplHelper
<
css
::
container
::
XIndexAccess
>
{
public
:
explicit
Resource
IndexAccessBase
(
const
std
::
shared_ptr
<
ResMgr
>&
pResMgr
)
explicit
Resource
StringIndexAccess
(
const
std
::
shared_ptr
<
ResMgr
>&
pResMgr
)
:
m_pResMgr
(
pResMgr
)
{
OSL_ENSURE
(
m_pResMgr
,
"no resource manager given"
);
...
...
@@ -49,25 +49,15 @@ namespace
// XIndexAccess
virtual
::
sal_Int32
SAL_CALL
getCount
(
)
throw
(
css
::
uno
::
RuntimeException
,
std
::
exception
)
override
{
return
m_pResMgr
.
get
()
?
SAL_MAX_UINT16
:
0
;
};
virtual
css
::
uno
::
Any
SAL_CALL
getByIndex
(
::
sal_Int32
Index
)
throw
(
css
::
lang
::
IndexOutOfBoundsException
,
css
::
lang
::
WrappedTargetException
,
css
::
uno
::
RuntimeException
,
std
::
exception
)
override
;
// XElementAccess
virtual
sal_Bool
SAL_CALL
hasElements
(
)
throw
(
css
::
uno
::
RuntimeException
,
std
::
exception
)
override
{
return
static_cast
<
bool
>
(
m_pResMgr
.
get
());
};
protected
:
// m_pResMgr should never be NULL
const
std
::
shared_ptr
<
ResMgr
>
m_pResMgr
;
};
class
ResourceStringIndexAccess
:
public
ResourceIndexAccessBase
{
public
:
explicit
ResourceStringIndexAccess
(
const
std
::
shared_ptr
<
ResMgr
>&
pResMgr
)
:
ResourceIndexAccessBase
(
pResMgr
)
{}
// XIndexAccess
virtual
css
::
uno
::
Any
SAL_CALL
getByIndex
(
::
sal_Int32
Index
)
throw
(
css
::
lang
::
IndexOutOfBoundsException
,
css
::
lang
::
WrappedTargetException
,
css
::
uno
::
RuntimeException
,
std
::
exception
)
override
;
// XElementAccessBase
virtual
css
::
uno
::
Type
SAL_CALL
getElementType
(
)
throw
(
css
::
uno
::
RuntimeException
,
std
::
exception
)
override
{
return
::
cppu
::
UnoType
<
OUString
>::
get
();
};
private
:
// m_pResMgr should never be NULL
const
std
::
shared_ptr
<
ResMgr
>
m_pResMgr
;
};
}
...
...
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