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
ac5cec21
Kaydet (Commit)
ac5cec21
authored
Ara 26, 2014
tarafından
Tomaž Vajngerl
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
Cleanup zoomsliderctrl & viewlayoutctrl
Change-Id: Ie5f135e8457ed75146328a388f3b70273bf54ed2
üst
b99aeb24
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
16 additions
and
15 deletions
+16
-15
zoomsliderctrl.cxx
svx/source/stbctrls/zoomsliderctrl.cxx
+7
-6
viewlayoutctrl.cxx
sw/source/uibase/utlui/viewlayoutctrl.cxx
+9
-9
No files found.
svx/source/stbctrls/zoomsliderctrl.cxx
Dosyayı görüntüle @
ac5cec21
...
...
@@ -152,8 +152,8 @@ long SvxZoomSliderControl::Zoom2Offset( sal_uInt16 nCurrentZoom ) const
return
nRet
;
}
SvxZoomSliderControl
::
SvxZoomSliderControl
(
sal_uInt16
_nSlotId
,
sal_uInt16
_nId
,
StatusBar
&
_rStb
)
:
SfxStatusBarControl
(
_nSlotId
,
_nId
,
_rStb
),
SvxZoomSliderControl
::
SvxZoomSliderControl
(
sal_uInt16
_nSlotId
,
sal_uInt16
_nId
,
StatusBar
&
rStatusBar
)
:
SfxStatusBarControl
(
_nSlotId
,
_nId
,
rStatusBar
),
mpImpl
(
new
SvxZoomSliderControl_Impl
)
{
mpImpl
->
maSliderButton
=
Image
(
SVX_RES
(
RID_SVXBMP_SLIDERBUTTON
)
);
...
...
@@ -161,16 +161,17 @@ SvxZoomSliderControl::SvxZoomSliderControl( sal_uInt16 _nSlotId, sal_uInt16 _nI
mpImpl
->
maDecreaseButton
=
Image
(
SVX_RES
(
RID_SVXBMP_SLIDERDECREASE
)
);
//#ifndef MACOSX
if
(
_rStb
.
GetDPIScaleFactor
()
>
1
)
sal_Int32
nScaleFactor
=
rStatusBar
.
GetDPIScaleFactor
();
if
(
nScaleFactor
!=
1
)
{
Image
arr
[
3
]
=
{
mpImpl
->
maSliderButton
,
mpImpl
->
maIncreaseButton
,
mpImpl
->
maDecreaseButton
};
for
(
int
i
=
0
;
i
<
3
;
i
++
)
{
BitmapEx
b
=
arr
[
i
].
GetBitmapEx
();
BitmapEx
aBitmap
=
arr
[
i
].
GetBitmapEx
();
//Use Lanczos scaling for the slider button because it does a better job with circles
b
.
Scale
(
_rStb
.
GetDPIScaleFactor
(),
_rStb
.
GetDPIScaleFactor
()
,
i
==
0
?
BMP_SCALE_LANCZOS
:
BMP_SCALE_FAST
);
arr
[
i
]
=
Image
(
b
);
aBitmap
.
Scale
(
nScaleFactor
,
nScaleFactor
,
i
==
0
?
BMP_SCALE_LANCZOS
:
BMP_SCALE_FAST
);
arr
[
i
]
=
Image
(
aBitmap
);
}
mpImpl
->
maSliderButton
=
arr
[
0
];
mpImpl
->
maIncreaseButton
=
arr
[
1
];
...
...
sw/source/uibase/utlui/viewlayoutctrl.cxx
Dosyayı görüntüle @
ac5cec21
...
...
@@ -39,8 +39,8 @@ struct SwViewLayoutControl::SwViewLayoutControl_Impl
Image
maImageBookMode_Active
;
};
SwViewLayoutControl
::
SwViewLayoutControl
(
sal_uInt16
_nSlotId
,
sal_uInt16
_nId
,
StatusBar
&
rSt
b
)
:
SfxStatusBarControl
(
_nSlotId
,
_nId
,
rSt
b
),
SwViewLayoutControl
::
SwViewLayoutControl
(
sal_uInt16
_nSlotId
,
sal_uInt16
_nId
,
StatusBar
&
rSt
atusBar
)
:
SfxStatusBarControl
(
_nSlotId
,
_nId
,
rSt
atusBar
),
mpImpl
(
new
SwViewLayoutControl_Impl
)
{
mpImpl
->
mnState
=
0
;
...
...
@@ -52,7 +52,8 @@ SwViewLayoutControl::SwViewLayoutControl( sal_uInt16 _nSlotId, sal_uInt16 _nId,
mpImpl
->
maImageBookMode
=
Image
(
SW_RES
(
IMG_VIEWLAYOUT_BOOKMODE
)
);
mpImpl
->
maImageBookMode_Active
=
Image
(
SW_RES
(
IMG_VIEWLAYOUT_BOOKMODE_ACTIVE
)
);
if
(
rStb
.
GetDPIScaleFactor
()
>
1
)
sal_Int32
nScaleFactor
=
rStatusBar
.
GetDPIScaleFactor
();
if
(
nScaleFactor
!=
1
)
{
Image
arr
[
6
]
=
{
mpImpl
->
maImageSingleColumn
,
mpImpl
->
maImageSingleColumn_Active
,
mpImpl
->
maImageAutomatic
,
mpImpl
->
maImageAutomatic_Active
,
...
...
@@ -60,9 +61,9 @@ SwViewLayoutControl::SwViewLayoutControl( sal_uInt16 _nSlotId, sal_uInt16 _nId,
for
(
int
i
=
0
;
i
<
6
;
i
++
)
{
BitmapEx
b
=
arr
[
i
].
GetBitmapEx
();
b
.
Scale
(
rStb
.
GetDPIScaleFactor
(),
rStb
.
GetDPIScaleFactor
()
,
BMP_SCALE_FAST
);
arr
[
i
]
=
Image
(
b
);
BitmapEx
aBitmap
=
arr
[
i
].
GetBitmapEx
();
aBitmap
.
Scale
(
nScaleFactor
,
nScaleFactor
,
BMP_SCALE_FAST
);
arr
[
i
]
=
Image
(
aBitmap
);
}
mpImpl
->
maImageSingleColumn
=
arr
[
0
];
...
...
@@ -74,7 +75,6 @@ SwViewLayoutControl::SwViewLayoutControl( sal_uInt16 _nSlotId, sal_uInt16 _nId,
mpImpl
->
maImageBookMode
=
arr
[
4
];
mpImpl
->
maImageBookMode_Active
=
arr
[
5
];
}
}
SwViewLayoutControl
::~
SwViewLayoutControl
()
...
...
@@ -124,8 +124,8 @@ void SwViewLayoutControl::Paint( const UserDrawEvent& rUsrEvt )
mpImpl
->
maImageAutomatic
.
GetSizePixel
().
Width
()
+
mpImpl
->
maImageBookMode
.
GetSizePixel
().
Width
();
const
long
nXOffset
=
(
aRect
.
GetWidth
()
-
nImageWidthSum
)
/
2
;
const
long
nYOffset
=
(
aControlRect
.
GetHeight
()
-
mpImpl
->
maImageSingleColumn
.
GetSizePixel
().
Height
())
/
2
;
const
long
nXOffset
=
(
aRect
.
GetWidth
()
-
nImageWidthSum
)
/
2
;
const
long
nYOffset
=
(
aControlRect
.
GetHeight
()
-
mpImpl
->
maImageSingleColumn
.
GetSizePixel
().
Height
())
/
2
;
aRect
.
Left
()
=
aRect
.
Left
()
+
nXOffset
;
aRect
.
Top
()
=
aRect
.
Top
()
+
nYOffset
;
...
...
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