View Issue Details

IDProjectCategoryView StatusLast Update
0037371LazarusLCLpublic2020-07-17 02:59
ReporterJoeny Ang Assigned ToJuha Manninen  
PrioritynormalSeverityminorReproducibilityalways
Status resolvedResolutionfixed 
Product Version2.1 (SVN) 
Summary0037371: [Patch] GTK2: Dragging TLabel/TPanel with TDockImageWindow does not work
DescriptionWhen DragKind=dkDock and DragMode=dmAutomatic, TLabel and TPanel (others?) cannot be dragged if TDockImageWindow (widgetsets that supports hints and alphablend) is used.

Problem: TGtk2WidgetSet.SetVisible() is calling ReleaseMouseCapture() for forms.

Patch: Don't call ReleaseMouseCapture() if form is a TDockImageWindow.
Steps To ReproduceUsing the test project, try dragging the different controls around.
TagsNo tags attached.
Fixed in Revisionr63572
LazTarget-
WidgetsetGTK 2
Attached Files

Activities

Joeny Ang

2020-07-16 10:57

reporter  

gtk2-tlabel-tpanel-tdockimagewindow.patch (453 bytes)   
--- lcl/interfaces/gtk2/gtk2widgetset.inc
+++ lcl/interfaces/gtk2/gtk2widgetset.inc
@@ -5140,7 +5140,8 @@
       // capturing is always gtkwindow dependent. On showing a new window
       // the gtk will put a new widget on the grab stack.
       // -> release our capture
-      ReleaseMouseCapture;
+      if not ACustomForm.ClassNameIs('TDockImageWindow') then
+        ReleaseMouseCapture;
     end;
 
     if gtk_widget_visible(SenderWidget) then

Juha Manninen

2020-07-16 12:30

developer   ~0124085

Last edited: 2020-07-16 12:30

View 2 revisions

Thanks for the patch and test application. Seems to work well. Applied.

Joeny Ang

2020-07-17 02:59

reporter   ~0124112

Thanks :)

Issue History

Date Modified Username Field Change
2020-07-16 10:57 Joeny Ang New Issue
2020-07-16 10:57 Joeny Ang File Added: gtk2-tlabel-tpanel-tdockimagewindow.patch
2020-07-16 10:57 Joeny Ang File Added: tlabel-tpanel-tdockimagewindow-test.zip
2020-07-16 12:29 Juha Manninen Assigned To => Juha Manninen
2020-07-16 12:29 Juha Manninen Status new => assigned
2020-07-16 12:30 Juha Manninen Status assigned => resolved
2020-07-16 12:30 Juha Manninen Resolution open => fixed
2020-07-16 12:30 Juha Manninen Fixed in Revision => r63572
2020-07-16 12:30 Juha Manninen LazTarget => -
2020-07-16 12:30 Juha Manninen Widgetset GTK 2 => GTK 2
2020-07-16 12:30 Juha Manninen Note Added: 0124085
2020-07-16 12:30 Juha Manninen Note Edited: 0124085 View Revisions
2020-07-17 02:59 Joeny Ang Note Added: 0124112