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
859c0066
Kaydet (Commit)
859c0066
authored
Nis 28, 2016
tarafından
David Tardon
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
add member prefix
Change-Id: Ic53e0c564176649b6cba84ea898c3c2f69fcad8c
üst
10b818d4
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
25 additions
and
25 deletions
+25
-25
unchss.cxx
sd/source/ui/dlg/unchss.cxx
+21
-21
unchss.hxx
sd/source/ui/inc/unchss.hxx
+4
-4
No files found.
sd/source/ui/dlg/unchss.cxx
Dosyayı görüntüle @
859c0066
...
@@ -41,18 +41,18 @@ StyleSheetUndoAction::StyleSheetUndoAction(SdDrawDocument* pTheDoc,
...
@@ -41,18 +41,18 @@ StyleSheetUndoAction::StyleSheetUndoAction(SdDrawDocument* pTheDoc,
SdUndoAction
(
pTheDoc
)
SdUndoAction
(
pTheDoc
)
{
{
DBG_ASSERT
(
pTheStyleSheet
,
"Undo without StyleSheet ???"
);
DBG_ASSERT
(
pTheStyleSheet
,
"Undo without StyleSheet ???"
);
pStyleSheet
=
pTheStyleSheet
;
m
pStyleSheet
=
pTheStyleSheet
;
// Create ItemSets; Attention, it is possible that the new one is from a,
// Create ItemSets; Attention, it is possible that the new one is from a,
// different pool. Therefore we clone it with its items.
// different pool. Therefore we clone it with its items.
pNewSet
=
o3tl
::
make_unique
<
SfxItemSet
>
(
static_cast
<
SfxItemPool
&>
(
SdrObject
::
GetGlobalDrawObjectItemPool
()),
pTheNewItemSet
->
GetRanges
());
m
pNewSet
=
o3tl
::
make_unique
<
SfxItemSet
>
(
static_cast
<
SfxItemPool
&>
(
SdrObject
::
GetGlobalDrawObjectItemPool
()),
pTheNewItemSet
->
GetRanges
());
SdrModel
::
MigrateItemSet
(
pTheNewItemSet
,
pNewSet
.
get
(),
pTheDoc
);
SdrModel
::
MigrateItemSet
(
pTheNewItemSet
,
m
pNewSet
.
get
(),
pTheDoc
);
pOldSet
=
o3tl
::
make_unique
<
SfxItemSet
>
(
static_cast
<
SfxItemPool
&>
(
SdrObject
::
GetGlobalDrawObjectItemPool
()),
pStyleSheet
->
GetItemSet
().
GetRanges
());
mpOldSet
=
o3tl
::
make_unique
<
SfxItemSet
>
(
static_cast
<
SfxItemPool
&>
(
SdrObject
::
GetGlobalDrawObjectItemPool
()),
m
pStyleSheet
->
GetItemSet
().
GetRanges
());
SdrModel
::
MigrateItemSet
(
&
pStyleSheet
->
GetItemSet
(),
pOldSet
.
get
(),
pTheDoc
);
SdrModel
::
MigrateItemSet
(
&
mpStyleSheet
->
GetItemSet
(),
m
pOldSet
.
get
(),
pTheDoc
);
aComment
=
SD_RESSTR
(
STR_UNDO_CHANGE_PRES_OBJECT
);
m
aComment
=
SD_RESSTR
(
STR_UNDO_CHANGE_PRES_OBJECT
);
OUString
aName
(
pStyleSheet
->
GetName
());
OUString
aName
(
m
pStyleSheet
->
GetName
());
// delete layout name and separator
// delete layout name and separator
sal_Int32
nPos
=
aName
.
indexOf
(
SD_LT_SEPARATOR
);
sal_Int32
nPos
=
aName
.
indexOf
(
SD_LT_SEPARATOR
);
...
@@ -91,36 +91,36 @@ StyleSheetUndoAction::StyleSheetUndoAction(SdDrawDocument* pTheDoc,
...
@@ -91,36 +91,36 @@ StyleSheetUndoAction::StyleSheetUndoAction(SdDrawDocument* pTheDoc,
}
}
// replace placeholder with template name
// replace placeholder with template name
aComment
=
aComment
.
replaceFirst
(
"$"
,
aName
);
maComment
=
m
aComment
.
replaceFirst
(
"$"
,
aName
);
}
}
void
StyleSheetUndoAction
::
Undo
()
void
StyleSheetUndoAction
::
Undo
()
{
{
SfxItemSet
aNewSet
(
mpDoc
->
GetItemPool
(),
pOldSet
->
GetRanges
()
);
SfxItemSet
aNewSet
(
mpDoc
->
GetItemPool
(),
m
pOldSet
->
GetRanges
()
);
SdrModel
::
MigrateItemSet
(
pOldSet
.
get
(),
&
aNewSet
,
mpDoc
);
SdrModel
::
MigrateItemSet
(
m
pOldSet
.
get
(),
&
aNewSet
,
mpDoc
);
pStyleSheet
->
GetItemSet
().
Set
(
aNewSet
);
m
pStyleSheet
->
GetItemSet
().
Set
(
aNewSet
);
if
(
pStyleSheet
->
GetFamily
()
==
SD_STYLE_FAMILY_PSEUDO
)
if
(
m
pStyleSheet
->
GetFamily
()
==
SD_STYLE_FAMILY_PSEUDO
)
static_cast
<
SdStyleSheet
*>
(
pStyleSheet
)
->
GetRealStyleSheet
()
->
Broadcast
(
SfxSimpleHint
(
SFX_HINT_DATACHANGED
));
static_cast
<
SdStyleSheet
*>
(
m
pStyleSheet
)
->
GetRealStyleSheet
()
->
Broadcast
(
SfxSimpleHint
(
SFX_HINT_DATACHANGED
));
else
else
pStyleSheet
->
Broadcast
(
SfxSimpleHint
(
SFX_HINT_DATACHANGED
));
m
pStyleSheet
->
Broadcast
(
SfxSimpleHint
(
SFX_HINT_DATACHANGED
));
}
}
void
StyleSheetUndoAction
::
Redo
()
void
StyleSheetUndoAction
::
Redo
()
{
{
SfxItemSet
aNewSet
(
mpDoc
->
GetItemPool
(),
pOldSet
->
GetRanges
()
);
SfxItemSet
aNewSet
(
mpDoc
->
GetItemPool
(),
m
pOldSet
->
GetRanges
()
);
SdrModel
::
MigrateItemSet
(
pNewSet
.
get
(),
&
aNewSet
,
mpDoc
);
SdrModel
::
MigrateItemSet
(
m
pNewSet
.
get
(),
&
aNewSet
,
mpDoc
);
pStyleSheet
->
GetItemSet
().
Set
(
aNewSet
);
m
pStyleSheet
->
GetItemSet
().
Set
(
aNewSet
);
if
(
pStyleSheet
->
GetFamily
()
==
SD_STYLE_FAMILY_PSEUDO
)
if
(
m
pStyleSheet
->
GetFamily
()
==
SD_STYLE_FAMILY_PSEUDO
)
static_cast
<
SdStyleSheet
*>
(
pStyleSheet
)
->
GetRealStyleSheet
()
->
Broadcast
(
SfxSimpleHint
(
SFX_HINT_DATACHANGED
));
static_cast
<
SdStyleSheet
*>
(
m
pStyleSheet
)
->
GetRealStyleSheet
()
->
Broadcast
(
SfxSimpleHint
(
SFX_HINT_DATACHANGED
));
else
else
pStyleSheet
->
Broadcast
(
SfxSimpleHint
(
SFX_HINT_DATACHANGED
));
m
pStyleSheet
->
Broadcast
(
SfxSimpleHint
(
SFX_HINT_DATACHANGED
));
}
}
OUString
StyleSheetUndoAction
::
GetComment
()
const
OUString
StyleSheetUndoAction
::
GetComment
()
const
{
{
return
aComment
;
return
m
aComment
;
}
}
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
sd/source/ui/inc/unchss.hxx
Dosyayı görüntüle @
859c0066
...
@@ -30,11 +30,11 @@ class SdDrawDocument;
...
@@ -30,11 +30,11 @@ class SdDrawDocument;
class
StyleSheetUndoAction
:
public
SdUndoAction
class
StyleSheetUndoAction
:
public
SdUndoAction
{
{
SfxStyleSheet
*
pStyleSheet
;
SfxStyleSheet
*
m
pStyleSheet
;
std
::
unique_ptr
<
SfxItemSet
>
pNewSet
;
std
::
unique_ptr
<
SfxItemSet
>
m
pNewSet
;
std
::
unique_ptr
<
SfxItemSet
>
pOldSet
;
std
::
unique_ptr
<
SfxItemSet
>
m
pOldSet
;
OUString
aComment
;
OUString
m
aComment
;
public
:
public
:
StyleSheetUndoAction
(
SdDrawDocument
*
pTheDoc
,
StyleSheetUndoAction
(
SdDrawDocument
*
pTheDoc
,
...
...
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