Hybrid View
-
30 Dec 2008 5:33 AM #1
Scrollbar to the ExtJS panel ?
Scrollbar to the ExtJS panel ?
Hi,
I am having some requirement to make my ext panel a custom panel with the scrollbars that match the current theme of the application, i have used this http://www.hesido.com/web.php?page=customscrollbar
link but didn't get my requirement fulfilled. My Panel has title but i need to scrollbars to the contents inside the panel not the title.
I don't have enough knowledge abt ExtJS, still then i am trying to do some home work.
I would request you to help me in this regard if possible for you, or provide me some helping url's that will guide me in this approach.
regards,
sanjayLast edited by mystix; 30 Dec 2008 at 6:51 AM. Reason: moved to 2.x Help from Examples
-
30 Dec 2008 7:20 AM #2Sencha - Community Support Team
- Join Date
- Mar 2007
- Location
- The Netherlands
- Posts
- 24,251
- Vote Rating
- 41
This should probably work:
Code:var panel = new Ext.Panel({ ... autoScroll:true, listeners: { render: function(c){ CSBfleXcroll(c.body.dom.id); } } });
-
5 Jan 2009 12:59 AM #3
Re: Scrollbar to the ExtJS panel?
Re: Scrollbar to the ExtJS panel?
thanks for the quick response, but i doubt that it works, attached is the code of the panel that i am using, please have a look and let me know if i am doing things right. Could you please rectify my mistake and make this example working.
Error:- undefined CSBfleXcroll
thanks in advance.
Sanjay
-
5 Jan 2009 1:25 AM #4Sencha - Community Support Team
- Join Date
- Mar 2007
- Location
- The Netherlands
- Posts
- 24,251
- Vote Rating
- 41
I don't get an undefined error in your code. The code actually works, but it doesn't display very well, because you didn't include a stylesheet for the custom scroller.
-
5 Jan 2009 5:18 AM #5
RE: Scrollbar to the ExtJS panel ?
RE: Scrollbar to the ExtJS panel ?
Sorry if i forgot to mention it earlier, my requirement is
consider a div in an html page, render an extjs panel into it, the scrollbars need to be themed properly as then can match the site themes but the title of the extjs panel should not scroll.
thanks
Sanjay
-
5 Jan 2009 6:32 AM #6Sencha - Community Support Team
- Join Date
- Mar 2007
- Location
- The Netherlands
- Posts
- 24,251
- Vote Rating
- 41
OK, the problem is that the 'html' config option gets applied AFTER the render method.
Try using:
(I removed the cls, because it was causing the panel to scroll instead of the body!)Code:var myExtJSPanel_1 = new Ext.Panel({ title:'Title of the panel', id:'myExtJSPanel_2', width:400, height:400, listeners: { render: function(c){ CSBfleXcroll.defer(1, window, [c.body.dom]); } }, renderTo:'myExtJSPanel_1', html:'...' });
-
6 Apr 2010 8:54 AM #7
Yo uso este codigo y me esta funcionando.....si alguien quiere opinar?????
<script type="text/javascript">
Ext.BLANK_IMAGE_URL = 'Libs/resources/images/default/s.gif';
Ext.override(Ext.Component, {
afterRender: function() {
if (Ext.isDefined(this.body)) {
CSBfleXcroll.defer(1, window, [this.body.dom]);
}
}
});


Reply With Quote