Use Apple Wireless Keyboard for PC and Mac
As per Bluetooth functionality, one would have to pair/unpair with the chosen device to switch to another system. It's worth noting that Apple by no means supports PC's to work with their accessories, and a quick search will show you plenty of people having a less-than-stellar experience trying to make it work. A more appropriate long-term solution is a wired keyboard and a KVM to switch between systems.