View Issue Details

IDProjectCategoryView StatusLast Update
0032813LazarusLCLpublic2018-03-15 09:18
ReporterAlexey Assigned ToJuha Manninen  
Status resolvedResolutionfixed 
Product Version1.8 
Summary0032813: TControlBar is faulty
DescriptionDrop TControlBar at Form. It is not moveabe/resizeable. Try to delete it (use Object Inspector for it). Got Access Violation trap.
Steps To ReproduceSee description.
TagsNo tags attached.
Fixed in Revisionr56709, r56716
Attached Files


related to 0033430 closedJuha Manninen Tcontrolbar still faulty, AV with IDE. 


Vojtech Cihak

2017-12-12 18:59

reporter   ~0104664

Last edited: 2017-12-12 19:00

View 2 revisions

I found the reason, it is csDesignInteractive in ControlStyle. But it's there for years so something probably changed in Lazarus. Also, I don't know what this option should exactly do, there's only a short comment "// wants mouse events in design mode ".
Delphi docs says: "The control maps right mouse button clicks at design time into left mouse button clicks to manipulate the control." but it doesn't work in Lazarus.
The fix is to remove csDesignInteractive in TCustomControlBar.Create().

EDIT: I can confirm crashes but after removing csDesignInteractive I didn't notice AccessViolation anymore.

Juha Manninen

2017-12-13 00:12

developer   ~0104668

Last edited: 2017-12-13 00:13

View 2 revisions

Please test with r56709. I think I prevented the AV.
Otherwise the problem remains.
csDesignInteractive is processed in Designer's MouseDownOnControl, MouseUpOnControl and MouseMoveOnControl. Clearly it has a meaning and purpose.
What kind of control should set csDesignInteractive? Apparently TControlBar should not.

Vojtech Cihak

2017-12-13 00:43

reporter   ~0104669

@ Please test with r56709. I think I prevented the AV.

I can't see AV anymore.

@ What kind of control should set csDesignInteractive?
I don't know. It's my mistake, years ago I gave it to constructor even if I didn't know what it really should do.


2017-12-13 15:18

reporter   ~0104676

Last edited: 2017-12-13 15:47

View 3 revisions

I removed "csDesignInteractive" from and rebuilded Lazarus. No changes, AV is here. And I can't understand why component not moveabe/resizeable. Is it "by design"?

Upd: OK, dled designer.pp r5609 and recompiled. All healed. Thnx!

Vojtech Cihak

2017-12-13 16:09

reporter   ~0104678

@ Alexey: If you do some change in include file only (here it is not enough and Lazarus doesn't notice it and will not rebuild that file. You have to change something in owner pas file (here extctrls.pas).


2017-12-13 20:54

reporter   ~0104681

Last edited: 2017-12-13 20:55

View 2 revisions

Anyhow, can mark it as Resolved.

Juha Manninen

2017-12-14 07:02

developer   ~0104688

I removed csDesignInteractive from TControlBar.
A control that sets it must handle MouseDown, MouseUp and MouseMove by itself.

jamie philbrook

2018-03-15 01:59

reporter   ~0107118

1.8.2 still has AV with that control..

Can't move it

if you delete it the old crash comes back...

Issue History

Date Modified Username Field Change
2017-12-12 16:32 Alexey New Issue
2017-12-12 18:59 Vojtech Cihak Note Added: 0104664
2017-12-12 19:00 Vojtech Cihak Note Edited: 0104664 View Revisions
2017-12-13 00:12 Juha Manninen Note Added: 0104668
2017-12-13 00:13 Juha Manninen Note Edited: 0104668 View Revisions
2017-12-13 00:43 Vojtech Cihak Note Added: 0104669
2017-12-13 15:18 Alexey Note Added: 0104676
2017-12-13 15:19 Alexey Note Edited: 0104676 View Revisions
2017-12-13 15:47 Alexey Note Edited: 0104676 View Revisions
2017-12-13 16:09 Vojtech Cihak Note Added: 0104678
2017-12-13 20:54 Alexey Note Added: 0104681
2017-12-13 20:55 Alexey Note Edited: 0104681 View Revisions
2017-12-14 06:54 Juha Manninen Assigned To => Juha Manninen
2017-12-14 06:54 Juha Manninen Status new => assigned
2017-12-14 07:02 Juha Manninen Fixed in Revision => r56709, r56716
2017-12-14 07:02 Juha Manninen LazTarget => -
2017-12-14 07:02 Juha Manninen Note Added: 0104688
2017-12-14 07:02 Juha Manninen Status assigned => resolved
2017-12-14 07:02 Juha Manninen Resolution open => fixed
2018-03-15 01:59 jamie philbrook Note Added: 0107118
2018-03-15 09:18 Juha Manninen Relationship added related to 0033430