Gtk2: fixed mouse capturing for native scrolling win controls (listbox,listview etc).issue #21713

git-svn-id: trunk@36734 -
This commit is contained in:
zeljko 2012-04-12 08:33:53 +00:00
parent 610d3f9251
commit 7d77b04315

View File

@ -4717,7 +4717,18 @@ begin
Result := WidgetInfo^.ClientWidget
else
Result := WidgetInfo^.CoreWidget;
{$IFDEF GTK2_USE_OLD_CAPTURE}
end;
{$ELSE}
end else
if GTK_IS_SCROLLED_WINDOW(Widget) and (GTK_IS_BIN(Widget)) then
begin
{$IFDEF VerboseMouseCapture}
writeln('GetDefaultMouseCaptureWidget: **',TWinControl(LCLObject).ClassName,' grabbing viewport ...');
{$ENDIF}
Result := gtk_bin_get_child(PGtkBin(Widget));
end;
{$ENDIF}
end;
end;
end;