-
3 Nov 2012 1:46 AM #1
Unanswered: Zoom images inside tab panel
Unanswered: Zoom images inside tab panel
Hi,
I need to implement zoom in/out image which is placed in the panel inside a tab panel. am using sencha touch 1.1 framework. I have tried the following code which is not working for the images which are placed inside a tabpanelPls help me with the sample code which can be used for zoom in/out in pinch event.Code:graph.add({ title: 'Graph', html: '<img alt="loading graph" width="100%" style="padding:10px 10px 10px 10px;" src="chart.png"></img><br />' }); graph.doLayout(); graph.body.select('img').on({ pinchstart: function(e, t){ this.startScale = this.scale; }, pinch: function(e, t){ this.scale = e.scale * this.startScale; t.style.webkitTransform = 'scale(' + this.scale + ')'; }, scope: { scale: 1 }
Thanks
-
4 Nov 2012 5:25 PM #2Sencha - Senior Forum Manager
- Join Date
- Mar 2007
- Location
- St. Louis, MO
- Posts
- 33,582
- Vote Rating
- 434
- Answers
- 3102
What are some of the values this.scale is like?
Mitchell Simoens @SenchaMitch
Sencha Inc, Senior Forum Manager
________________
http://www.JSONPLint.com - Source to lint your JSONP!
Check out my GitHub, lots of nice things for Ext JS 4 and Sencha Touch 2
https://github.com/mitchellsimoens
Think my support is good? Get more personalized support via a support subscription. https://www.sencha.com/store/
Need more help with your app? Hire Sencha Services services@sencha.com
Want to learn Sencha Touch 2? Check out Sencha Touch in Action that is almost in print!
When posting code, please use BBCode's CODE tags.
-
7 Nov 2012 9:33 AM #3
Hi mitchellsimoens,
am not very sure abt the scale parameter. The piece of code wht i have attached worked for the image which is in the panel. After i put the panel inside the tabpanel only its not working.
Pls help
thanks


Reply With Quote