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
eb08ea4f
Kaydet (Commit)
eb08ea4f
authored
Mar 25, 2013
tarafından
Fridrich Štrba
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
A little tiny insignificant cleanup
Change-Id: I285da1f12711e9e96b666a3ce1560c203870cac3
üst
fd652cf5
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
8 additions
and
19 deletions
+8
-19
t602filter.cxx
filter/source/t602/t602filter.cxx
+8
-19
No files found.
filter/source/t602/t602filter.cxx
Dosyayı görüntüle @
eb08ea4f
...
@@ -136,42 +136,31 @@ T602ImportFilter::~T602ImportFilter()
...
@@ -136,42 +136,31 @@ T602ImportFilter::~T602ImportFilter()
}
}
// XExtendedTypeDetection
// XExtendedTypeDetection
::
rtl
::
OUString
T602ImportFilter
::
detect
(
Sequence
<
PropertyValue
>&
Descriptor
)
OUString
T602ImportFilter
::
detect
(
Sequence
<
PropertyValue
>&
Descriptor
)
throw
(
RuntimeException
)
throw
(
RuntimeException
)
{
{
// checks for filter or type name would be necessary in case we want to use the filter also for "602" files
// without the magic bytes at the beginning; I leave the code as comment in case of
// ::rtl::OUString aFilterName, aTypeName;
sal_Int32
nLength
=
Descriptor
.
getLength
();
sal_Int32
nLength
=
Descriptor
.
getLength
();
const
PropertyValue
*
pValue
=
Descriptor
.
getConstArray
();
const
PropertyValue
*
pValue
=
Descriptor
.
getConstArray
();
for
(
sal_Int32
i
=
0
;
i
<
nLength
;
i
++
)
for
(
sal_Int32
i
=
0
;
i
<
nLength
;
i
++
)
{
{
if
(
pValue
[
i
].
Name
==
"InputStream"
)
if
(
pValue
[
i
].
Name
==
"InputStream"
)
pValue
[
i
].
Value
>>=
mxInputStream
;
pValue
[
i
].
Value
>>=
mxInputStream
;
/* else if ( pValue[i].Name == "FilterName" )
pValue[i].Value >>= aFilterName;
else if ( pValue[i].Name == "TypeName" )
pValue[i].Value >>= aTypeName; */
}
}
if
(
!
mxInputStream
.
is
())
if
(
!
mxInputStream
.
is
())
return
::
rtl
::
OUString
();
return
OUString
();
/* if ( aFilterName == "T602Document" || aTypeName == "writer_T602_Document" )
// preselection by type (extension) or filter name: no reason to check type
return rtl::OUString( "writer_T602_Document" ); */
::
com
::
sun
::
star
::
uno
::
Sequence
<
sal_Int8
>
aData
;
::
com
::
sun
::
star
::
uno
::
Sequence
<
sal_Int8
>
aData
;
size_t
numBytes
=
4
;
const
size_t
numBytes
=
4
;
size_t
numBytesRead
=
0
;
size_t
numBytesRead
=
0
;
numBytesRead
=
mxInputStream
->
readSomeBytes
(
aData
,
numBytes
);
numBytesRead
=
mxInputStream
->
readSomeBytes
(
aData
,
numBytes
);
if
((
numBytesRead
!=
numBytes
)
||
(
aData
[
0
]
!=
'@'
)
||
if
((
numBytesRead
!=
numBytes
)
||
(
aData
[
0
]
!=
'@'
)
||
(
aData
[
1
]
!=
'C'
)
||
(
aData
[
2
]
!=
'T'
)
||
(
aData
[
3
]
!=
' '
))
(
aData
[
1
]
!=
'C'
)
||
(
aData
[
2
]
!=
'T'
)
||
(
aData
[
3
]
!=
' '
))
return
::
rtl
::
OUString
();
return
OUString
();
return
rtl
::
OUString
(
"writer_T602_Document"
);
return
OUString
(
"writer_T602_Document"
);
}
}
// XFilter
// XFilter
...
@@ -1144,7 +1133,7 @@ ResMgr* T602ImportFilterDialog::getResMgr()
...
@@ -1144,7 +1133,7 @@ ResMgr* T602ImportFilterDialog::getResMgr()
return
mpResMgr
;
return
mpResMgr
;
}
}
void
SAL_CALL
T602ImportFilterDialog
::
setTitle
(
const
::
rtl
::
OUString
&
)
void
SAL_CALL
T602ImportFilterDialog
::
setTitle
(
const
OUString
&
)
throw
(
::
com
::
sun
::
star
::
uno
::
RuntimeException
)
throw
(
::
com
::
sun
::
star
::
uno
::
RuntimeException
)
{
{
}
}
...
@@ -1158,9 +1147,9 @@ sal_Int16 SAL_CALL T602ImportFilterDialog::execute()
...
@@ -1158,9 +1147,9 @@ sal_Int16 SAL_CALL T602ImportFilterDialog::execute()
return
com
::
sun
::
star
::
ui
::
dialogs
::
ExecutableDialogResults
::
CANCEL
;
return
com
::
sun
::
star
::
ui
::
dialogs
::
ExecutableDialogResults
::
CANCEL
;
}
}
rtl
::
OUString
T602ImportFilterDialog
::
getResStr
(
sal_Int16
resid
)
OUString
T602ImportFilterDialog
::
getResStr
(
sal_Int16
resid
)
{
{
rtl
::
OUString
sStr
=
String
(
ResId
(
resid
,
*
getResMgr
()
)
);
OUString
sStr
(
ResId
(
resid
,
*
getResMgr
()
)
);
return
sStr
;
return
sStr
;
}
}
...
...
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