resource/dock: fix trayicon position when screen size changed

1. the wrong position was caused by the latency of updating
$("#system").offsetTop.

2. Add helper function run_callback_after_prop_changed to
common/js/utils.coffee. It's helping us to invoke functions after prop
updated.

Change-Id: Id30aaf037a6ff692acfb7fa313149c0afbd0424e