I'm not sure that this is "fixing" but the idea is simple:
- take a docked panel and float it
- then take that floating panel and dock it
- desired behavior: the panel docks it the same tile that it originally was floated from
This seems to match what the "average" user would expect so that although it could be seen as inconsistent behavior, this is worthy of your consideration.