Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cache checkbox locally #6840

Merged
merged 1 commit into from
May 5, 2022
Merged

Cache checkbox locally #6840

merged 1 commit into from
May 5, 2022

Conversation

PureWeen
Copy link
Member

@PureWeen PureWeen commented May 5, 2022

Description of Change

When we initially did checkbox, we didn't cache the images used for disabled because it would always tint them grey. Well, now it seems to always tint them gray no matter how many different StackOverflow posts I found. So, I modified the code to not recreate the images every time and cause a layout loop. I logged the issue here about the tinting.

The code for testing this issue is

MainPage = new ContentPage
{
	Content = new StackLayout()
	{
		Children =
		{
			new CheckBox() { Color = Colors.Purple },
			new CheckBox() {  Color = Colors.Purple, IsEnabled = false },
		}
	}
};

Which is another disappointment with this PR :-) When placed in our test runners this code runs fine and doesn't cause a layout loop.

  • I removed a bunch of internal methods that weren't used anywhere
  • I made the exception for a missing handler more clear. This came up as I was attempting to write a unit test

Issues Fixed

Fixes #6687

Copy link
Contributor

@SotoiGhost SotoiGhost left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM! 👍🏼

@Redth Redth added this to the 6.0.300 milestone May 5, 2022
@PureWeen PureWeen merged commit 228f932 into main May 5, 2022
@PureWeen PureWeen deleted the ios_checkbox_fix branch May 5, 2022 15:15
@github-actions github-actions bot locked and limited conversation to collaborators Dec 22, 2023
@samhouts samhouts added the fixed-in-6.0.312 Look for this fix in 6.0.312! label Aug 2, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
area-controls-checkbox CheckBox fixed-in-6.0.312 Look for this fix in 6.0.312!
Projects
None yet
Development

Successfully merging this pull request may close these issues.

iOS Checkbox is causing an infinite loop
6 participants