Replies: 1 comment
-
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
I migrated to MAUI from Forms recently, and I decided to shim my huge and complex custom renderer that interfaces with the platform camera rather than migrate to a handler. This worked great for the most part, because all the required callbacks and wiring to connect the platform code to the cross-platform control appears to get invoked as needed. This is on Android by the way, and my custom renderer inherits from
ViewRenderer<CameraModule, View>
, whereCameraModule
inherits fromContentView
.However, now I find that the
TextureView
that I have relied on for years no longer becomes available. My understanding is that that means it never gets attached to the Window. I inflate my axml layout that contains the TextureView, I attach the callback handlers, and then I add it with AddView, but it doesn't work anymore. I also tried doing the same using the SetNativeControl method, even though I haven't had to do that before, but that doesn't seem to change anything. Why would this be?My project is at https://github.com/KRA2008/crosscam and the branch that shows my current frustrated state is mauiMigrationGOODer.
Edit: I went ahead and grabbed the WindowManager and added my view to the Window myself, and that resulted in my callback code being invoked - the TextureView became available - but the layout is all messed up, probably because I'm giving it bogus LayoutParams. So why is the TextureView not being attached to the Window for me?
Beta Was this translation helpful? Give feedback.
All reactions