I have tried all kind of plugins to solve this issue. Currently I am using Content Aware Sidebars plugin, which work great. Having widgets depending on content is far more complex. I think there is room for a new approach to deal with that issue.