<div dir="ltr">in my attempt to slay all macros in phonon's source I have come to a halt with a very elemental question that I think we should agree on as a community.<div><br></div><div style>right now (in theory) you can build phonon-vlc 0.1 against phonon 4.6 because former retains old interface defintions and constantly everywhere tries to use old interfaces whenever casting to the present interface is not working.</div>
<div style><br></div><div style>to illustrate this quickly:</div><div style><br></div><div style>class iInterface1 {</div><div style>void play() = 0;</div><div style>}</div><div style><br></div><div style>class iInterface2 : public iInterface1 {</div>
<div style>void pause() = 0;</div><div style>}</div><div style><br></div><div style>if a backend does not implement 2 a qobject_cast will fail, so phonon4 then tries to cast to 1.</div><div style><br></div><div style>this allows backends to not implement new functions immediately but remain buildable against a new phonon.</div>
<div style><br></div><div style>I personally believe this to be a bad idea as it makes it more confusing what you can expect from a version of phonon and in its current implementation even causes runtime overhead due to many casts. at the same time running against an old backend will render phonon not working (though I suppose we can detect that and display a warning), so this is also not making my heart smile.</div>
<div style><br></div><div style>also in practice this did not work out as intended as numerous internal cmake changes made old backends not build with a new phonon so it's effectively useless right now</div><div style>
<br></div><div style>thoughts?</div><div style>should we keep trying to retain this compatibility feature for backends or drop it?</div><div style><br></div><div style>HS</div></div>