H. Verbeet : wined3d: Also update reference counts when we're recording a stateblock.