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
29ea595d
Kaydet (Commit)
29ea595d
authored
May 18, 2015
tarafından
Tomaž Vajngerl
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
cleanup LineWidthControl
Change-Id: I875af6213660ba0fa9831b76c4d72e2092cd0a3a
üst
9b6057dc
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
14 additions
and
27 deletions
+14
-27
LineWidthControl.cxx
svx/source/sidebar/line/LineWidthControl.cxx
+14
-27
No files found.
svx/source/sidebar/line/LineWidthControl.cxx
Dosyayı görüntüle @
29ea595d
...
...
@@ -32,7 +32,6 @@
#include <sfx2/dispatch.hxx>
#include "svx/sidebar/PopupContainer.hxx"
namespace
svx
{
namespace
sidebar
{
LineWidthControl
::
LineWidthControl
(
...
...
@@ -76,9 +75,6 @@ void LineWidthControl::dispose()
svx
::
sidebar
::
PopupControl
::
dispose
();
}
void
LineWidthControl
::
Paint
(
vcl
::
RenderContext
&
rRenderContext
,
const
Rectangle
&
rect
)
{
svx
::
sidebar
::
PopupControl
::
Paint
(
rRenderContext
,
rect
);
...
...
@@ -104,9 +100,6 @@ void LineWidthControl::Paint(vcl::RenderContext& rRenderContext, const Rectangle
rRenderContext
.
Pop
();
}
void
LineWidthControl
::
Initialize
()
{
maVSWidth
->
SetStyle
(
maVSWidth
->
GetStyle
()
|
WB_3DLOOK
|
WB_NO_DIRECTSELECT
);
// WB_NAMEFIELD | WB_ITEMBORDER |WB_DOUBLEBORDER | WB_NONEFIELD |
...
...
@@ -197,9 +190,6 @@ void LineWidthControl::GetFocus()
maVSWidth
->
GrabFocus
();
}
void
LineWidthControl
::
SetWidthSelect
(
long
lValue
,
bool
bValuable
,
SfxMapUnit
eMapUnit
)
{
mbVSFocus
=
true
;
...
...
@@ -207,10 +197,10 @@ void LineWidthControl::SetWidthSelect( long lValue, bool bValuable, SfxMapUnit e
mbCloseByEdit
=
false
;
meMapUnit
=
eMapUnit
;
SvtViewOptions
aWinOpt
(
E_WINDOW
,
SIDEBAR_LINE_WIDTH_GLOBAL_VALUE
);
if
(
aWinOpt
.
Exists
()
)
if
(
aWinOpt
.
Exists
()
)
{
::
com
::
sun
::
star
::
uno
::
Sequence
<
::
com
::
sun
::
star
::
beans
::
NamedValue
>
aSeq
=
aWinOpt
.
GetUserData
();
::
rtl
::
OUString
aTmp
;
css
::
uno
::
Sequence
<
css
::
beans
::
NamedValue
>
aSeq
=
aWinOpt
.
GetUserData
();
OUString
aTmp
;
if
(
aSeq
.
getLength
())
aSeq
[
0
].
Value
>>=
aTmp
;
...
...
@@ -235,10 +225,10 @@ void LineWidthControl::SetWidthSelect( long lValue, bool bValuable, SfxMapUnit e
maVSWidth
->
SetItemText
(
9
,
rStr
[
8
]);
}
if
(
bValuable
)
if
(
bValuable
)
{
sal_Int64
nVal
=
OutputDevice
::
LogicToLogic
(
lValue
,
(
MapUnit
)
eMapUnit
,
MAP_100TH_MM
);
nVal
=
maMFWidth
->
Normalize
(
nVal
);
sal_Int64
nVal
=
OutputDevice
::
LogicToLogic
(
lValue
,
(
MapUnit
)
eMapUnit
,
MAP_100TH_MM
);
nVal
=
maMFWidth
->
Normalize
(
nVal
);
maMFWidth
->
SetValue
(
nVal
,
FUNIT_100TH_MM
);
}
else
...
...
@@ -253,11 +243,14 @@ void LineWidthControl::SetWidthSelect( long lValue, bool bValuable, SfxMapUnit e
OUString
strCurrValue
=
maMFWidth
->
GetText
();
sal_uInt16
i
=
0
;
for
(;
i
<
8
;
i
++
)
{
if
(
strCurrValue
==
rStr
[
i
])
{
maVSWidth
->
SetSelItem
(
i
+
1
);
break
;
}
}
if
(
i
>=
8
)
{
mbVSFocus
=
false
;
...
...
@@ -268,15 +261,12 @@ void LineWidthControl::SetWidthSelect( long lValue, bool bValuable, SfxMapUnit e
maVSWidth
->
StartSelection
();
}
IMPL_LINK
(
LineWidthControl
,
VSSelectHdl
,
void
*
,
pControl
)
{
if
(
pControl
==
&
maVSWidth
)
if
(
pControl
==
&
maVSWidth
)
{
sal_uInt16
iPos
=
maVSWidth
->
GetSelectItemId
();
if
(
iPos
>=
1
&&
iPos
<=
8
)
if
(
iPos
>=
1
&&
iPos
<=
8
)
{
sal_IntPtr
nVal
=
LogicToLogic
(
reinterpret_cast
<
sal_IntPtr
>
(
maVSWidth
->
GetItemData
(
iPos
)),
MAP_POINT
,
(
MapUnit
)
meMapUnit
);
nVal
=
maMFWidth
->
Denormalize
(
nVal
);
...
...
@@ -287,10 +277,10 @@ IMPL_LINK(LineWidthControl, VSSelectHdl, void *, pControl)
mbCloseByEdit
=
false
;
mnTmpCustomWidth
=
0
;
}
else
if
(
iPos
==
9
)
else
if
(
iPos
==
9
)
{
//last custom
//modified
if
(
mbCustom
)
if
(
mbCustom
)
{
long
nVal
=
LogicToLogic
(
mnCustomWidth
,
MAP_POINT
,
(
MapUnit
)
meMapUnit
);
nVal
=
maMFWidth
->
Denormalize
(
nVal
);
...
...
@@ -310,15 +300,12 @@ IMPL_LINK(LineWidthControl, VSSelectHdl, void *, pControl)
}
//modify end
}
if
((
iPos
>=
1
&&
iPos
<=
8
)
||
(
iPos
==
9
&&
mbCustom
))
//add
if
((
iPos
>=
1
&&
iPos
<=
8
)
||
(
iPos
==
9
&&
mbCustom
))
//add
mrLinePropertyPanel
.
EndLineWidthPopupMode
();
}
return
0L
;
}
IMPL_LINK
(
LineWidthControl
,
MFModifyHdl
,
void
*
,
pControl
)
{
if
(
pControl
==
&
maMFWidth
)
...
...
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