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
db9602cb
Kaydet (Commit)
db9602cb
authored
May 08, 2013
tarafından
Andre Fischer
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
122254: Process mouse wheel events over sidebar scroll bar.
üst
0fabc9a7
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
52 additions
and
1 deletion
+52
-1
Deck.cxx
sfx2/source/sidebar/Deck.cxx
+51
-1
Deck.hxx
sfx2/source/sidebar/Deck.hxx
+1
-0
No files found.
sfx2/source/sidebar/Deck.cxx
Dosyayı görüntüle @
db9602cb
...
@@ -220,6 +220,56 @@ void Deck::DataChanged (const DataChangedEvent& rEvent)
...
@@ -220,6 +220,56 @@ void Deck::DataChanged (const DataChangedEvent& rEvent)
long
Deck
::
Notify
(
NotifyEvent
&
rEvent
)
{
if
(
rEvent
.
GetType
()
!=
EVENT_COMMAND
)
return
sal_False
;
CommandEvent
*
pCommandEvent
=
reinterpret_cast
<
CommandEvent
*>
(
rEvent
.
GetData
());
if
(
pCommandEvent
==
NULL
)
return
sal_False
;
switch
(
pCommandEvent
->
GetCommand
())
{
case
COMMAND_WHEEL
:
{
if
(
!
mpVerticalScrollBar
||
!
mpVerticalScrollBar
->
IsVisible
())
return
sal_False
;
// Ignore all wheel commands from outside the vertical
// scroll bar. Otherwise after a scroll we might land on
// a spin field and subsequent wheel events would change
// the value of that control.
if
(
rEvent
.
GetWindow
()
!=
mpVerticalScrollBar
.
get
())
return
sal_True
;
// Get the wheel data and check that it describes a valid
// vertical scroll.
const
CommandWheelData
*
pData
=
pCommandEvent
->
GetWheelData
();
if
(
pData
==
NULL
||
pData
->
GetModifier
()
||
pData
->
GetMode
()
!=
COMMAND_WHEEL_SCROLL
||
pData
->
IsHorz
())
return
sal_False
;
// Execute the actual scroll action.
long
nDelta
=
pData
->
GetDelta
();
mpVerticalScrollBar
->
DoScroll
(
mpVerticalScrollBar
->
GetThumbPos
()
-
nDelta
);
return
sal_True
;
}
default
:
break
;
}
return
sal_False
;
}
void
Deck
::
SetPanels
(
const
SharedPanelContainer
&
rPanels
)
void
Deck
::
SetPanels
(
const
SharedPanelContainer
&
rPanels
)
{
{
maPanels
=
rPanels
;
maPanels
=
rPanels
;
...
@@ -276,7 +326,6 @@ void Deck::ShowPanel (const Panel& rPanel)
...
@@ -276,7 +326,6 @@ void Deck::ShowPanel (const Panel& rPanel)
if
(
rPanel
.
GetTitleBar
()
!=
NULL
&&
rPanel
.
GetTitleBar
()
->
IsVisible
())
if
(
rPanel
.
GetTitleBar
()
!=
NULL
&&
rPanel
.
GetTitleBar
()
->
IsVisible
())
nPanelTop
=
rPanel
.
GetTitleBar
()
->
GetPosPixel
().
Y
();
nPanelTop
=
rPanel
.
GetTitleBar
()
->
GetPosPixel
().
Y
();
// Determine what the new thumb position should be like.
// Determine what the new thumb position should be like.
// When the whole panel does not fit then make its top visible
// When the whole panel does not fit then make its top visible
// and it off at the bottom.
// and it off at the bottom.
...
@@ -419,4 +468,5 @@ void Deck::ScrollContainerWindow::SetSeparators (const ::std::vector<sal_Int32>&
...
@@ -419,4 +468,5 @@ void Deck::ScrollContainerWindow::SetSeparators (const ::std::vector<sal_Int32>&
maSeparators
=
rSeparators
;
maSeparators
=
rSeparators
;
}
}
}
}
// end of namespace sfx2::sidebar
}
}
// end of namespace sfx2::sidebar
sfx2/source/sidebar/Deck.hxx
Dosyayı görüntüle @
db9602cb
...
@@ -73,6 +73,7 @@ public:
...
@@ -73,6 +73,7 @@ public:
virtual
void
Paint
(
const
Rectangle
&
rUpdateArea
);
virtual
void
Paint
(
const
Rectangle
&
rUpdateArea
);
virtual
void
DataChanged
(
const
DataChangedEvent
&
rEvent
);
virtual
void
DataChanged
(
const
DataChangedEvent
&
rEvent
);
virtual
long
Notify
(
NotifyEvent
&
rEvent
);
void
PrintWindowTree
(
void
);
void
PrintWindowTree
(
void
);
void
PrintWindowTree
(
const
::
std
::
vector
<
Panel
*>&
rPanels
);
void
PrintWindowTree
(
const
::
std
::
vector
<
Panel
*>&
rPanels
);
...
...
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