Closed mchav closed 8 years ago
@ChavXO This doesn't even compile. You need to add a | ClearColor (Float, Float, Float, Float)
case to FunctionCall
, around line 310. Doing so is a major version bump, which conflicts with #6.
Additionally, your implementation sets the clearColor as a global mutable variable, which will cause all kinds of "action at a distance".
We cannot accept this PR at this time.
@mgold I figured the global variable was a problem. How would you suggest I proceed?
It was suggested by John :) https://groups.google.com/forum/?nomobile=true#!topic/elm-discuss/DZZ41fGxalo
I saw that after I closed, sorry! If John approves the change then that would allow us to make a version bump. As for the global, you'll need to attach it to...I'm not sure if it would be a Renderable, a Drawable, or something else, but the thing that's getting its clear color set. And you'd need to update that value in an immutable way.
@mgold. Thanks. I'm relatively new to the Elm community so I wasn't caught up with the the issues surrounding native libraries and Evan's message about approving version bumps. Caught up now.
Turns out I didn't even need a global. It suffices to return the function. Should I open another pull request?
Sure, take another stab :) (You could force-push to this branch or something, but let's start fresh.)
Not the best implementation but I needed a way to set a clear color and I think that sort of functionality is generally useful.