Skip to content

Consider using LinkedHashSet instead of HashSet to preserve the ordering of CyaneaViewProcessor to make it possible to override default processors #82

@K1rakishou

Description

@K1rakishou

Right now all processors are being added to a HashSet which reorders them randomly, due to how hashsets work, and it becomes impossible to override a default CyaneaViewProcessor because a custom processor may end up processed earlier than the default one.

Let's say I want to override TextViewProcessor to use a completely different color. Right now it's impossible because the order of processors is unpredictable so it may work for one processor but won't work for another. Using LinkedHashSet for CyaneaViewFactory.processors should fix this little issue since all custom processors are already added to the end of the list in CyaneaDelegateImplBase.getViewProcessors().

Maybe there is already a mechanism for that but I couldn't find it.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions