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
94b38840
Kaydet (Commit)
94b38840
authored
Tem 03, 2015
tarafından
Jan Holesovsky
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
tdf#92528: Saving of usage info can happen very late in the tear down.
Change-Id: Id545f3447472a8e6ee137a6630ee14b45a45d673
üst
b010e407
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
11 additions
and
3 deletions
+11
-3
unoctitm.cxx
sfx2/source/control/unoctitm.cxx
+11
-3
No files found.
sfx2/source/control/unoctitm.cxx
Dosyayı görüntüle @
94b38840
...
...
@@ -598,11 +598,14 @@ class UsageInfo {
typedef
std
::
map
<
OUString
,
int
>
UsageMap
;
/// Are we collecting the info? We cache the value because the call to save can happen very late.
bool
mbIsCollecting
;
/// Command vs. how many times it was used
UsageMap
maUsage
;
public
:
UsageInfo
()
UsageInfo
()
:
mbIsCollecting
(
false
)
{
}
...
...
@@ -616,6 +619,9 @@ public:
/// Save the usage data for the next session.
void
save
();
/// Modify the flag whether we are collecting.
void
setCollecting
(
bool
bIsCollecting
)
{
mbIsCollecting
=
bIsCollecting
;
}
};
void
UsageInfo
::
increment
(
const
OUString
&
rCommand
)
...
...
@@ -630,7 +636,7 @@ void UsageInfo::increment(const OUString &rCommand)
void
UsageInfo
::
save
()
{
if
(
!
officecfg
::
Office
::
Common
::
Misc
::
CollectUsageInformation
::
get
()
)
if
(
!
mbIsCollecting
)
return
;
// TODO - do a real saving here, not only dump to the screen
...
...
@@ -647,7 +653,9 @@ class theUsageInfo : public rtl::Static<UsageInfo, theUsageInfo> {};
/// Extracts information about the command + args, and stores that.
void
collectUsageInformation
(
const
util
::
URL
&
rURL
,
const
uno
::
Sequence
<
beans
::
PropertyValue
>&
rArgs
)
{
if
(
!
officecfg
::
Office
::
Common
::
Misc
::
CollectUsageInformation
::
get
())
bool
bCollecting
=
officecfg
::
Office
::
Common
::
Misc
::
CollectUsageInformation
::
get
();
theUsageInfo
::
get
().
setCollecting
(
bCollecting
);
if
(
!
bCollecting
)
return
;
OUStringBuffer
aBuffer
;
...
...
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