-
-
Notifications
You must be signed in to change notification settings - Fork 746
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
WinRT support #59
WinRT support #59
Conversation
I made a whole bunch of shims to try and get the existing RequestBuilderImplementation to build with as few modifications as possible, but I have NFI if t will work for real on WinRT.
For unit testing, check out xUnit for WinRT :) http://blog.novotny.org/2014/08/11/now-shipping-xunit-support-for-windows-8-and-windows-phone-app-8-1/ |
static class Uri | ||
{ | ||
static readonly Dictionary<char, int> hexDigits | ||
= "0123456789abcdef".Select((c, i) => new {c, i}) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Uppercase A, B, C, D, E, F are also hex digits
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yeah good call. That'll teach me to push and go to sleep.
Ugh, I hate how I'm getting nerd-sniped to support this garbage platform :) Thanks for the PR @bennor |
Hey, at least WinRT/Universal apps have a longer/better path forward than WP8 SL, esp with Threshold. |
✨ |
Feel free to send any hassles supporting it my way. I opened this can of worms. 😸 |
@bennor It looks like it works, though I hit the deadlock issue too. Oh wells |
What's the deadlock issue; how can I repro it to dig in? |
@onovotny Try to make any web request from |
I think the same for anything on the UI thread. Seems to be a limitation of async on the platform. Once I jumped through some hoops to make a proper async request it worked okay. |
Hey mate,
This is probably still WIP at the moment, but I've managed to get something to build, and was able to get a simple request working from a dummy WinRT app. 🤘
This is the first time I've even touched WinRT, so I had a few headaches and even managed to convince myself it didn't work for a while because deadlocks. 😠
Anyway, I think it's close, but I'm not really sure how to put it through more thorough testing. I'm not even sure where to begin with unit testing WinRT, so if you have any ideas I'd love some help.
The approach I took was just to polyfill all the reflection stuff and some static
Uri
methods that are absent (or moved) in WinRT. If that's the wrong approach, or you just have a better one, I'm open to suggestions.Cheers