I have the following code that successfully shows a widget panel. When using the Launchpad theme, the colour from the widget's button icon in the AnchorBarController doesn't get applied to the panel header. It should look like this:

but instead looks like this:

Also, when minimised the panel looks like this:

when it should take on the colour of the button icon in the AnchorBarController like this:

The code:
var myWidget = null;
arrayUtils.some(this.wManager.appConfig.widgetPool.widgets, function (aWidget) {
if (aWidget.name === widgetName) {
myWidget = aWidget;
}
});
if (myWidget) {
// check for presence of the AnchorBarController
var controller = this.wManager.getWidgetsByName("AnchorBarController");
if (controller.length > 0) {
this.pManager.showPanel(myWidget).then(lang.hitch(this, function (panel) {
panel.setPosition({ top: 120, left: 10, width: 350, height: 480, margin: 10, index: 0 });
}));
}
else {
this.pManager.showPanel(myWidget);
}
}Does anyone know of a way to get the icon colours to apply to the panel?