hi
I would appriciate some help of the more experienced users on this forum.
I have a collection object, and an gallery widget In dojo 0.9 I would call my gallery widget and pass the collection object as parameter in the new () statement.
In the constructor() I could then access via this.method the methods from the collection object, however in 1.0 it doesn't do that anymore.
From what I understand, the gallery needs to inherit the collection in the "dojo.declare("dojox.widget.gallery",[dojox.collection],", however the content of my collection object passed during creation is gone.
I hope this makes any sence, basically I try to convert a collection object into a gallery widget. Where collection object has pointers to where in the collection the gallery is, and the gallery has methods to browse through and display the required details from the collection.
Cheers
Peter

Can you post some code?
...at first glance your post doesn't make a lot of sense. To begin with, the Gallery is in dojox.image, and I can't tell exactly *what* "collection" you're talking about; there's a dojox.collections project, but the Gallery doesn't make use of any of them (they consume a dojo data store in order to display items).
If you could post a code example, that'd probably be best. Just wrap your code with either an <html> tag, or a <javascript> tag, and the forums should display it properly.
This is the creation of the
This is the creation of the display widget:
---
child = new dojox.custom.widget.cImagePane(GalleryCollection);
---
Below is the constructor of dojox.custom.widget.cImagePane
--
constructor: function(/* Gallery Collection Object */){
this.setPreviousThumb(this.previousImage());
this.pointer--;
this.setImage(this.nextImage());
this.pointer++;
this.setNextThumb(this.nextImage());
},
--
the next methods/property are frm the gallery collection the rest is local to the cImagePane:
- pointer
- previousImage()
- nextImage()
What I do is get the image, provide it to the display method setPreviousThumb() which will set the details in my HTML template file.
Before (0.9) it worked like this, but now it fails on the Gallery methods/properties. When I run console.dir(this) as my 1st line in the constructor method I can see that the object is already defined, and that 'declaredClass = dojox.custom.widget.cImagePane'.
Any tips, I'm not the experienced in the the inheritance (yet)
Sounds like you're just missing a ref to your gallery.
...as opposed to using "this.previousImage", perhaps you need to do something like "this.gallery.previousImage"?
Also, you might want to use your own namespace for this (and not dojox); dojox isn't a community namespace, and it's pretty easy to register your own module (search on the top left for "registerModulePath").
how to?
I will try my own namespace, I thought dojox was meant for personal modules. The part I'm failing to understand is that in 0.9 'console.dir(this)' in the 'constructor' method of 'cImagePane' would print the gallery object, but in 1.02 it prints the cImagePane object. Basically what I would like is to convert my gallery object to a cImagePane object (keeping my gallery methods, but enabling my cImagePane methods also. (I believe this is called casting? Correct?).
I agree I can make gallery a property of the cImagePane object, and store the gallery collection in this property, but :-) I was trying to make it work as if cImagePane was initial loaded with the collection.
Cheers
Peter