Freeman35 Posted July 4, 2019 Share Posted July 4, 2019 Hello, How to use percentage value in statuspanel's widh? Thank you. Quote Link to comment Share on other sites More sharing options...
Sherzod Posted July 4, 2019 Share Posted July 4, 2019 1 hour ago, Freeman35 said: How to use percentage value in statuspanel's widh? Hello, I think that only fixed values. But you can use resize function and calculate... Quote Link to comment Share on other sites More sharing options...
Freeman35 Posted July 4, 2019 Author Share Posted July 4, 2019 Thank you Quote Link to comment Share on other sites More sharing options...
Sherzod Posted July 4, 2019 Share Posted July 4, 2019 2 hours ago, Sherzod said: But you can use resize function and calculate... If you need I can give you an approximate solution. Quote Link to comment Share on other sites More sharing options...
Sherzod Posted July 5, 2019 Share Posted July 5, 2019 19 hours ago, Freeman35 said: How to use percentage value in statuspanel's widh? One of the possible solutions I think. function resize(sender, width, height, oldWidth, oldHeight, eOpts) { Ext.defer(function() { var me=sender.items, dV=0; //first panel 50% dV+=50*width/100; me.getAt(0).el.setStyle("width", dV+"px"); //second panel 30% me.getAt(1).el.setStyle("left", dV+2+"px"); dV+=30*width/100; me.getAt(1).el.setStyle("width", dV+"px"); //last 20% me.getAt(2).el.setStyle("left", dV+2+"px"); dV+=20*width/100; me.getAt(2).el.setStyle("width", dV+"px"); }, 20); } 1 Quote Link to comment Share on other sites More sharing options...
Freeman35 Posted July 5, 2019 Author Share Posted July 5, 2019 Thank you so much, it was not importand, but you gived one more perfect solution, thnak you so much. You will get a double esspresso from me ( guatemala been ) Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.