PDA

View Full Version : [OPEN-177] xds-1.0.2.2 - jsClass Bug with Namespaces



hschaefer123
12 Jul 2010, 5:46 AM
Trying to use a Viewport Component as root Component via jsClass using namespaces like "Uops.Viewport" generates
Ext.onReady(function() {
var uops.Viewport = new Uops.Viewport({
renderTo: Ext.getBody()
});
uops.Viewport.show();
});

and does not work for the local var!

The same without namespace

Ext.onReady(function() {
var uopsViewport = new UopsViewport({
renderTo: Ext.getBody()
});
uopsViewport.show();
});

works as expected!

so for root comps the namespace is buggy for generated local var!

I also have problems using class linked components where all linked comps are
moved to the root level and the outer "xds_index".js is generating
multiple components for the viewport!

Also changing the userXType works only on intial creating components.
After first export the outer container component will still exists an only update
the inner UI comp. "Export All" should be named "Export UI" and a additional
button "Export All" would be helpful. As a workaround i need to delete the
target export dir to get the changes working.

Best wishes,
Holger

jarrednicholls
12 Jul 2010, 7:19 AM
Hi Holger,

Thanks for reporting these issues, I'll open a couple of tickets now and get them resolved for the next release. Thanks again!

jarrednicholls
12 Jul 2010, 12:50 PM
Hi Holger,

I have fixed the namespace/variable issue for the next release.

As for the first linked component issue, I don't quite understand what the issue is. You stated you have "problems using class linked components where all linked components are moved to the root level and the outer xds_index.js is generating multiple components". What does that mean exactly? Did you move your linked components to the root level? If that's the case, you cannot do that, the linked components must always be a child of something, while the main/root-level component is what should reside at the root. Maybe you can send me your project file so I can fully understand what you're referring to. jarred [at] sencha.com.

The userXType issue is one that will require some thought in order to resolve properly. You see, .js file (not .ui.js) is the implementation file which is meant to contain your project's behavior code. Because of this, we do not overwrite it on subsequent exports if the file already exists. So we will have to think about the best way to solve this problem, because we cannot make this file overwritable, and if it's not overwritable, then we have to do some extra work in order to update the Ext.reg() call for the updated userXType. But, we may call this a "by design" side effect and force you to update the xtype manually or delete the file manually...because in the end, we do not want to "mess up" or "mess with" your implementation file if it already exists. Hope you understand.

Thanks!