I have a class that inherits from UIView
However when trying to use the follow (UIView *)viewWithTag:(NSInteger)tag
I get the warning: *incompatible Objective-C types initializing 'struct UIView *', expected 'struct CustomView '
Right now I have made a custom method that returns my custom view, the method uses a for loop with view.subviews since the views I am looking for come from the same superview. I do a conditional check if the tag matches the one I am searching for then I return the view.
I suppose I am just wondering if there is a better practice to this?
Thanks