Search code examples
iosdelphifiremonkeydelphi-10-seattle

Is there a way to enable/disable the disclosure indicator in a TListView on iOS (FireMonkey)?


I have a TListView in a FireMonkey App.

On the Android and Windows versions, it shows each of the list view items as with a disclosure indicator (a '>' on the right hand side of the list that indicates that there is details that can be accessed for the list item).

On iOS the disclosure indicator is not showing up. I'd like to make the app consistent across all three OS's.

Is there a different name for a property in FireMonkey that turns it on and off?

Is there another solution to this?


Solution

  • If you examine the ItemAppearance property of the TListView, you'll find an ItemObjects member. This will have and Accessory member, which has several properties: AccessoryType, Alignment, Opacity, etc.

    You can changing the Opacity to 0 or Visibility to false to hide the Accessory (in this case the more/disclosure indicator).

    In my particular case, the disclosure indicator was showing up on iOS. However, it was almost the exact same colour as the background (a light grey), so blended in. On Android and Windows, they come out as black and hence stand out. There appears to be no convenient way to control the colour of the Accessory member.