Hi All. I am using the Stock component.
The stock is created with an item height, like this
In some cases, I may need to stack items in this Stock. So I need to conditionally change its height in setup()
This works fine. But at some point in the game setup, the 'completesetup()' method is called, and it will resize the stock based on 'itemHeight' that the Stock is created with, and the resizing overwrites the later update of 'newHeight'.
I am wondering how I should deal with this.
Is there a callback I can use after completesetup so I can update the height?
Is there a way to disable resizing stock in completesetup?
The stock is created with an item height, like this
Code: Select all
this.myStock.create( this, $('my_stock'), ..., itemHeight );
Code: Select all
dojo.style('my_stock', 'height', newHeight+'px');
I am wondering how I should deal with this.
Is there a callback I can use after completesetup so I can update the height?
Is there a way to disable resizing stock in completesetup?