fixed bug on first with infobar appearing:

on first try to send message to infobar's port,
it could be not present at that time(and in most cases it is),
because adding listener function is wrapped by chrome.tabs.getCurrent
so we are adding listener firstly, and in callback getting current tab
id and saving it in window object