-
Notifications
You must be signed in to change notification settings - Fork 49
We need Generic converter! We need X:Bind and X:Phase! #210
Comments
@Mike-EEE @birbilis |
https://docs.microsoft.com/en-us/uwp/api/windows.ui.xaml.data.ivalueconverter |
from that same article:
means instead of
|
also from that article:
|
So, I have to say, forget cpp. |
@birbilis it seems that x:bind solves that problem and we neglected it..... |
I don't get your reflection argument. I've never written any reflection in any value converters. |
I get the value of generics in code behind. I don't really see the value in xaml. |
@dotMorten , it is true that we don't ususally use reflection, but i guess that it does make effect, and the object boxing and unboxing is really a performance pit |
@birbilis i just wondering if the entire dependency things could be redone to get rid of relection? |
@juepiezhongren not sure if you had in mind something like the BindProperties method I had here: Do you mean you want to bind by early-bound (resolved at compile time) property name and not late-bound (resolved at run-time via reflection, or lookup tables or whatever) one for example? note that I was only interested in binding properties to properties there (like when you do wiring), not to expressions (which can do only 1-way binding obviously). Btw, speaking of two-way binding of properties, I had done loop breaking of such wirings in Java ~20 years ago (when working on E-Slate and its Plugs mechanism - http://e-slate.cti.gr) with TLS (Thread-Local Storage). Don't remember if C#/.NET support thread-local fields though in classes like Java had. |
@birbilis these days, i only think early-bound be necessary. Sure, runtime-bound could benefit from things like xaml-parser etc, but considering ios forbidding jsPatch and future mono-wasm, its significance seems limited, just my opinion. |
@juepiezhongren actually, I'm interested in End User Programming/Development and constructivism, esp. in educational software, so there one definitely needs late-binding since the end-user can choose to be the author, remixer etc. Especially when you want to have multiple development modalities like we were doing back then with E-Slate, e.g. when you have both structural "programming" via wiring (we had data flow - say wire Integer to Integer, and interface - say wire Plane to Map - matching via visual plugs) and verbal expression via scripting (e.g. we had Logo and Javascript) but to not deroute a lot from your suggestion, isn't it missing some functionality judging from the Microsoft documentation excerpts I posted above? |
@birbilis i got ur idea, "UI Dev 4 Dev". That's absolutely where late-bind must implement. |
Everyone loves binding, but every one hates the perf pit out of reflection.
Please provide us a generic IValueConverter!
Besides, X:Bind makes us with better binding perf, and X:Phase is also good for things like listView.
It's a shame for uwp that x:bind is not together with generic converters.
The text was updated successfully, but these errors were encountered: