rds1983 / Myra

UI Library for MonoGame, FNA and Stride
MIT License
704 stars 94 forks source link

UI inside of TabItems doesn't change when clicking tabs in TabControl #362

Closed Machaira closed 1 year ago

Machaira commented 1 year ago

I have the following MML:

rds1983 commented 1 year ago

Hi, The MML you've provided is incomplete. Though it looks fine. There's stock tab sample MML: https://github.com/rds1983/Myra/blob/master/samples/UI/tabs.xmmp I've pasted it into MyraPad and the TabControl worked as expected(you could switch tabs through clicking).

btw, I recommend moving call of desktop.Render() beyond spriteBatch.Begin()/spriteBatch.End().

Machaira commented 1 year ago

Can you let me know what's incomplete about it? I must be missing something. :(

rds1983 commented 1 year ago

Oh, it was complete actually. Though for some reason, the browser showed me only part of it. Anyway, both tabs of your TabControl have same content. Hence there's no change when switching between tabs.

Machaira commented 1 year ago

You are correct. My error. :( TabControl works correctly.