bug fix: when have multiple main view, pop up callback now will invoke the correct one