xbmc/xbmc — pull request #1206 by pieh (2012-07-23 13:00:59+00:00)
Title: Add Skin.AspectRatio infolabel

This is RFC PR, so before commenting code, please comment on approach.

I had some thoughts about what info is relevant:
- Skin.AspectRatio (always returning info from closest resolutution match from resolutions defined in addon.xml, no matter if proper .xml file exist for this resolution)
- Window.AspectRatio (return info from resolution that is actually used for current window)

Few cases we have to consider about resolutions in addon.xml
1. They point to same folder then both Skin.AspectRatio and Window.AspectRatio would return same info
2. They point to different folders:
- Window.AspectRatio wouldn't actually be needed, because we might just "hard code" stuff differently in each folder
- Skin.AspectRatio might return "16:9" even if we are in "4:3" folder and this just *might* actually have some value

---

I'm aware that this is little ugly (Skin.AspectRatio vs Window.AspectRatio). Perhaps we could allow to set closest resolution on window even if we are loading file from default resolution (f.e. forceresolution="true" attribute on non-default resolutions)? Then Window.AspectRatio would be indeed valuable info and we could seperate different aspect xml snippets in seperate folders without entire xml duplication and avoid stretching like it was described in Jezz_X comment in https://github.com/pieh/xbmc/commit/f019f8c2241625e788756cda2e623ed44b073361#commitcomment-1614658.