A few months back I posted a note about some enhancements I'd made to the existing iTunes plugin (which also included a small change to the Rainmeter.cpp file as well in order to add some functionality needed for my changes). I was waiting to hear how to submit these changes (and I've been busy on other things so I haven't had any time to do any further work on it). Since I haven't heard how to do this, I'm posting my code to this forum for review and possible inclusion (if it's good enough!).
The attachment contains the following:
the modified iTunesPlugin.cpp
the modified Rainmeter.cpp
a skin that implements the new features of the iTunesPlugin
The skin's not perfect yet (and hopefully I managed to straighten out exactly which files in my skin folder were actually used), but it should give a fairly good idea of what these changes allow (a short list: better "live" integration with iTunes including updating control states based on changes such as changing tracks and pausing in iTunes itself, the ability to directly set a volume level instead only increasing or decreasing by a set amount, the ability to set a track's rating).
I made my original changes a few months ago so before putting this post together I grabbed the latest version of the source code and merged my changes into it. The files in this post should now be up-to-date with the current source code. If there's anything else I should do to submit this, please let me know.
Thanks. BTW, I added a new bang, RainmeterPluginBangWithArg, in order to support the new methods in the iTunesPlugin that set the volume and rating. Basically, it accepts a single argument that it treats as a string and which the plugin is then responsible for interpreting however it wants. In my case I'm just setting a single numeric value, but if a plugin method needed more than one argument they could be combined into a single delimited string (for example, "1;two;3.14") that the method could parse out.
Would anyone need a further write-up of this for inclusion in the documentation?
technologist wrote:Thanks. BTW, I added a new bang, RainmeterPluginBangWithArg, in order to support the new methods in the iTunesPlugin that set the volume and rating. Basically, it accepts a single argument that it treats as a string and which the plugin is then responsible for interpreting however it wants. In my case I'm just setting a single numeric value, but if a plugin method needed more than one argument they could be combined into a single delimited string (for example, "1;two;3.14") that the method could parse out.
Would anyone need a further write-up of this for inclusion in the documentation?
Thank you for the great work. It works perfectly.
However I found that there are some glitches under weird circumstances (behind a proxy and iTunes will popup a modal dialog at start/random time). The modified cpp is attached.