-
Notifications
You must be signed in to change notification settings - Fork 28
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
Error CS0012: The type 'QuantizedColor' is defined in an assembly that is not referenced. You must add a reference to assembly 'ColorThief.Forms, Version=1.1.0.1, Culture=neutral, PublicKeyToken=null'. #9
Comments
Hello @afbase, thanks for your detailed description. |
@KSemenenko |
@afbase, why do you need DI? await CrossColorThief.Current.GetPalette(sourceImage); or you want to use new method like FromUrl? |
If I write this line of code in my PCL project, I get a
I'd rather try to write all of this in a PCL project but I'm beginning to think this is not possible. |
I think where this issue is coming up is ColorThief reference/object confusion between PCL and platform projects. I think what we want in the PCL project is
instead of what I originally had here:
If I try |
@afbase I think I found a problem, it's still in the structure of the project. |
I may follow up on this later in my development near the end of March as I have reprioritized my development as this became a bit of a blocker. I am working on other features but what I am now thinking is to refactor the Shared library's implementation to a dependency service onto interfaces implemented in the various platform libraries. |
Hi @KSemenenko
I'm trying to follow your suggestion in the prior issue:
In my PCL Xamarin project I have an interface and added reference to
ksesmenenko.ColorThief.Forms
v1.0.0.4:and then also in my PCL Xamarin project call it using dependency service:
Finally in my iOS project I have added reference to
ksesmenenko.ColorThief.Forms
v1.0.0.4 again and then made the dependency service implementation like so:And here I get the error on the
ColorThiefHelper
class :The bug is strange as there is no
Version=1.1.0.1
of ColorThief.Forms in nuget.Do you know what might be the problem?
The text was updated successfully, but these errors were encountered: