Select2 isn't working fine on a chrome extension popup

I'm experiencing a bad behavior of Select2 on a chrome extension using AngularJS and Angular-UI.

The scenario

Select2's content is loaded asynchronously via AngularJs $resouces module.


What should happen?

The content should be display when i click on the Select2.


What is actually happening?

When i first click on any select2 dropdown, it just winks and then hides.


Obs.:
The same code works just fine out of chrome's extension popup.
You can see it working here: http://moneynow2.apphb.com.
And can browse the code here at my github repository.

Mine working fine in Chrome extension, but I'm getting "Refused to execute inline event handler because it violates the following Content Security Policy directive: "default-src 'self' chrome-extension-resource:". Note that 'script-src' was not explicitly set, so 'default-src' is used as a fallback." In chrome console.

This is really hard to test.

It looks like in a popup, when I open the dropmenu, the route gets reloaded (the whole controller and contents of ng-view reloads). This doesn't occur on the webpage. I thought that the popup was appearing in the bottom-right corner, stretching out the window (it happened as I stepped through it). When this occurred, I thought it might have triggered a window-scroll event which actually causes select2 to disappear (it's a feature of select2 to prevent the dropmenu from staying in some random place since it's pos:fixed).

I also don't know enough about chrome popups to figure out what events may cause the 'url' to change or a scroll event to trigger, etc.

At first I would have suggested doing selectOptions = { data: $myResource.query() } or something, but I'm starting to think it won't help.

Suggestion:

Try removing the router and see what happens. I don't really know that you should bother with it in a chrome extension. In such a small space, less code is probably better anyway.