Preference-Cell-Examples icon indicating copy to clipboard operation
Preference-Cell-Examples copied to clipboard

Add multiple cells

Open RedenticDev opened this issue 4 years ago • 9 comments

Let me know what you think, probably gonna upload some more cells later as this repo is very useful.

RedenticDev avatar Oct 09 '21 17:10 RedenticDev

I really like the addition of the icon to the AnimatedTitleView, but it should be a part of the same class not in a separate file. I've attached source files that combines the classes.

LacertosusRepo avatar Oct 10 '21 19:10 LacertosusRepo

Working on it. Side note: why do you use categories instead of declaring properties or ivars?

RedenticDev avatar Oct 10 '21 20:10 RedenticDev

This should work, I let you checking out. I didn't test that. Just remove the "second part" of the .h file to fix the merge conflict.

RedenticDev avatar Oct 10 '21 21:10 RedenticDev

Side note: why do you use categories instead of declaring properties or ivars?

What do you mean?

LacertosusRepo avatar Oct 10 '21 22:10 LacertosusRepo

Side note: why do you use categories instead of declaring properties or ivars?

What do you mean?

You're using curly braces in @implementation and I thought it was a class extension, my bad. But what are the upsides of doing so on some codes I've seen? People were using @interface in their .h, extension with their variables in the .m, and @implementation in .m too

RedenticDev avatar Oct 10 '21 22:10 RedenticDev

Declaring ivars in the implementation just defaults them to @private vs the interface being @public. It's just preference to me, I try to only use properties if something need access to a value/object.

LacertosusRepo avatar Oct 12 '21 16:10 LacertosusRepo

What's the point of using ivars then?

RedenticDev avatar Oct 12 '21 17:10 RedenticDev

What's the point of using ivars then?

Because nothing needs access to the variables. They are just for this class so there's no point in making properties.

LacertosusRepo avatar Oct 12 '21 22:10 LacertosusRepo

Okay I see thanks. I let you check the PR.

RedenticDev avatar Oct 12 '21 22:10 RedenticDev