Qt: do not send mousewheel event to lcl when combobox is dropped down. issue #27675

git-svn-id: trunk@48394 -
This commit is contained in:
zeljko 2015-03-16 13:51:00 +00:00
parent 77e59cf3b8
commit 6e3dd69f06

View File

@ -8508,10 +8508,14 @@ begin
if not getVisible then if not getVisible then
Result := FOwner.SlotMouseWheel(FOwner.Widget, Event) Result := FOwner.SlotMouseWheel(FOwner.Widget, Event)
else else
Result := inherited EventFilter(Sender, Event); begin
// issue #27675.Do not send wheel event from cbox when dropped down.
// DebugLn('TQtScrollBar.EventFilter: QEventWheel ',dbgsName(LCLObject),' Result=',dbgs(Result)); // LCL thinks that combobox sent that event so we have undesirable effects.
if (FOwner.ChildOfComplexWidget = ccwComboBox) and getEnabled then
Result := False
else
Result := inherited EventFilter(Sender, Event);
end;
// do not scroll when disabled or issue #25992 // do not scroll when disabled or issue #25992
if not getEnabled then if not getEnabled then
Result := True Result := True