windows: use multiple assignment to condense code