Recent

Author Topic: TPanel children remain enabled when disabling the TPanel  (Read 3940 times)

Hansaplast

  • Hero Member
  • *****
  • Posts: 538
  • Tweaking4All.com
    • Tweaking4All
TPanel children remain enabled when disabling the TPanel
« on: September 13, 2015, 09:09:58 pm »
If appropriate, I wouldn't mind reporting a bug, but I'm not sure what the exact status is of Cocoa widget development considering it's alpha stage. I for sure wouldn't mind doing some testing.

When I place components on a TPanel, and at runtime toggle between TPanel.enabled:=true and enabled:=false, then none of the children components change their enabled state, except TLabel. In code I was unable to see anything where the TPanel passes it disabled state to it's children, even though TLabel did disable. (I apologize for the lack of experience  :-[ [size=78%])[/size]

I tried a few components, and these for sure do not change their enabled state, even though the parent panel enabled state changes.

So components on a disabled TPanel remain enabled and functional,...

TEDit,
TMemo,
TButton,
TRadioButton,
TGroupCheckBox,
TCheckBox,
TComboBox



Note:
This is with Lazarus 1.5 SVN 49818, FPC 2.6.4 according to the Lazarus About, FPC 3.3.1 according to the compiler that I have entered as the compiler executable under Tools -> Options -> Compiler Executable. The IDE is Carbon, but under Project Options I've set the target to Cocoa. I was not able to compile the IDE with Cocoa, so there is the possibility that this is a problem on my setup (unable to find "fpcres" even though it clearly exists in the paths).


Any insights/tips/comments are much appreciated.

felipemdc

  • Administrator
  • Hero Member
  • *
  • Posts: 3541
Re: TPanel children remain enabled when disabling the TPanel
« Reply #1 on: September 13, 2016, 10:00:54 am »
Hello, please report bugs in the BTS system, never in the forum and always attach a minimal test case showing the problem.

Thaddy

  • Hero Member
  • *****
  • Posts: 8973
Re: TPanel children remain enabled when disabling the TPanel
« Reply #2 on: September 13, 2016, 11:16:48 am »
FPC 3.3.1 according to the compiler that I have entered as the compiler executable under Tools
Well, FPC's trunk compiler is at 3.1.1 and Lazarus trunk is at 1.7.
The stable versions are 3.0.0 and 1.6.
FPC 2.6.4 is not supported and I even wonder if Lazarus 1.5 is still supported.
FPC 3.3.1 is looking into the future... It does not exist.

So my insight is you have both versions that are very old and one version that has arrived from 2040 or somthing ;)
Upgrade and ask again. Much has changed since Magna Carta.
Most people that want to use threading should learn to patch their jeans first: use a needle.