Some OSes don't support handling battery ACPI events, maybe because they're not aimed for running on a portable device. In a virtual machine we should be able to simulate a battery-less device so that the VM is not aware and thus unaffected about battery state changes.