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
7f5ca4c9
Kaydet (Commit)
7f5ca4c9
authored
Eyl 05, 2012
tarafından
Noel Power
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
fix scroll top & scroll left
Change-Id: If333932a0f3cfde6e8459ca3506a609207982f96
üst
be045f69
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
15 additions
and
4 deletions
+15
-4
scrollabledialog.cxx
toolkit/source/awt/scrollabledialog.cxx
+5
-4
dialogcontrol.cxx
toolkit/source/controls/dialogcontrol.cxx
+10
-0
No files found.
toolkit/source/awt/scrollabledialog.cxx
Dosyayı görüntüle @
7f5ca4c9
...
...
@@ -56,12 +56,11 @@ void ScrollableDialog::lcl_Scroll( long nX, long nY )
{
long
nXScroll
=
mnScrollPos
.
X
()
-
nX
;
long
nYScroll
=
mnScrollPos
.
Y
()
-
nY
;
printf
(
"ScrollableDialog::lcl_Scroll %d, %d
nXScroll %d, nYScroll %d
\n
"
,
nX
,
nY
,
nXScroll
,
nYScroll
);
printf
(
"ScrollableDialog::lcl_Scroll %d, %d
resulting in delta nXScroll %d, nYScroll %d for ( %d ) children
\n
"
,
nX
,
nY
,
nXScroll
,
nYScroll
,
GetChildCount
()
-
2
);
mnScrollPos
=
Point
(
nX
,
nY
);
Rectangle
aScrollableArea
(
0
,
0
,
maScrollArea
.
Width
(),
maScrollArea
.
Height
()
);
Window
::
Scroll
(
nXScroll
,
nYScroll
,
aScrollableArea
);
// Manually scroll all children ( except the scrollbars )
for
(
int
index
=
0
;
index
<
GetChildCount
();
++
index
)
{
...
...
@@ -89,18 +88,20 @@ void ScrollableDialog::SetScrollTop( long nTop )
{
printf
(
"ScrollableDialog::SetScrollTop(%d)
\n
"
,
nTop
);
Point
aOld
=
mnScrollPos
;
lcl_Scroll
(
mnScrollPos
.
X
()
,
nTop
);
lcl_Scroll
(
mnScrollPos
.
X
()
,
mnScrollPos
.
Y
()
-
nTop
);
printf
(
"about to set thumb
\n
"
);
maHScrollBar
.
SetThumbPos
(
0
);
// new pos is 0,0
mnScrollPos
=
aOld
;
}
void
ScrollableDialog
::
SetScrollLeft
(
long
nLeft
)
{
printf
(
"ScrollableDialog::SetScrollLeft(%d)
\n
"
,
nLeft
);
Point
aOld
=
mnScrollPos
;
lcl_Scroll
(
nLeft
,
mnScrollPos
.
Y
()
);
lcl_Scroll
(
mnScrollPos
.
X
()
-
nLeft
,
mnScrollPos
.
Y
()
);
printf
(
"about to set thumb
\n
"
);
maVScrollBar
.
SetThumbPos
(
0
);
// new pos is 0,0
mnScrollPos
=
aOld
;
}
void
ScrollableDialog
::
SetScrollWidth
(
long
nWidth
)
...
...
toolkit/source/controls/dialogcontrol.cxx
Dosyayı görüntüle @
7f5ca4c9
...
...
@@ -358,6 +358,15 @@ void UnoDialogControl::createPeer( const Reference< XToolkit > & rxToolkit, cons
if
(
maTopWindowListeners
.
getLength
()
)
xTW
->
addTopWindowListener
(
&
maTopWindowListeners
);
// there must be a better way than doing this, we can't
// process the scrolltop & scrollleft in XDialog because
// the children haven't been added when those props are applied
Reference
<
XPropertySet
>
xDlgProps
(
getModel
(),
UNO_QUERY
);
Reference
<
XPropertySet
>
xPeerProps
(
getPeer
(),
uno
::
UNO_QUERY
);
ImplSetPeerProperty
(
GetPropertyName
(
BASEPROPERTY_SCROLLTOP
),
ImplGetPropertyValue
(
GetPropertyName
(
BASEPROPERTY_SCROLLTOP
)
)
);
ImplSetPeerProperty
(
GetPropertyName
(
BASEPROPERTY_SCROLLLEFT
),
ImplGetPropertyValue
(
GetPropertyName
(
BASEPROPERTY_SCROLLLEFT
)
)
);
}
}
...
...
@@ -1089,6 +1098,7 @@ void UnoFrameControl::ImplSetPosSize( Reference< XControl >& rxCtrl )
SimpleFontMetric
aFM
;
FontDescriptor
aFD
;
Any
aVal
=
ImplGetPropertyValue
(
GetPropertyName
(
BASEPROPERTY_FONTDESCRIPTOR
)
);
aVal
>>=
aFD
;
if
(
!
aFD
.
StyleName
.
isEmpty
()
)
{
...
...
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