Hi,
I tried without success to use the sample code (example coming from the
GeoExt documentation at
http://dev.geoext.org/docs/lib/GeoExt/plugins/TreeNodeActions.html) to
create a layer node UI with an actions plugin. I use the GeoExt trunk.
I received the following error message from firebug:
GeoExt.examples is undefined
anonymous()
anonymous()
new GeoExt.tree.TreeNodeUIEventMixin()\r\n
Had anybody similar problems?
Thanks,
Arnaud
The sample code:
var uiClass = GeoExt.examples.LayerNodeUI = Ext.extend(
GeoExt.tree.LayerNodeUI,
new GeoExt.tree.TreeNodeUIEventMixin()
);
// this function takes action based on the "action"
// parameter, it is used as a listener to layer
// nodes' "action" events
function onAction(node, action, evt) {
var layer = node.layer;
switch(action) {
case "delete":
layer.destroy();
break;
}
};
var tree = new Ext.tree.TreePanel({
region: "west",
width: 250,
title: "Layer Tree",
loader: {
applyLoader: false,
uiProviders: {
"ui": GeoExt.examples.LayerNodeUI
}
},
// apply the tree node actions plugin to layer nodes
plugins: [{
ptype: "gx_treenodeactions",
listeners: {
action: onAction
}
}],
root: {
nodeType: "gx_layercontainer",
loader: {
baseAttrs: {
radioGroup: "radiogroup",
uiProvider: "ui",
actions: [{
action: "delete",
qtip: "delete"
}]
}
}
},
rootVisible: false
});
- -----------------------------------------------------------------------------
E-MAIL DISCLAIMER
The present message may contain confidential and/or legally privileged
information. If you are not the intended addressee and in case of a
transmission error, please notify the sender immediately and destroy this
E-mail. Disclosure, reproduction or distribution of this document and its
possible attachments is strictly forbidden.
SPACEBEL denies all liability for incomplete, improper, inaccurate,
intercepted, (partly) destroyed, lost and/or belated transmission of the
current information given that unencrypted electronic transmission cannot
currently be guaranteed to be secure or error free.
Upon request or in conformity with formal, contractual agreements, an
originally signed hard copy will be sent to you to confirm the information
contained in this E-mail.
SPACEBEL denies all liability where E-mail is used for private use.
SPACEBEL cannot be held responsible for possible viruses that might corrupt
this message and/or your computer system.
e ------------------------------------------------------------------------------_______________________________________________
Users mailing list
[email protected]
http://www.geoext.org/cgi-bin/mailman/listinfo/users