Welcome!

Welcome to the official BlackBerry Support Community Forums.

This is your resource to discuss support topics with your peers, and learn from each other.

inside custom component

Native Development

Reply
Trusted Contributor
Posts: 160
Registered: ‎09-01-2013
My Device: z10 and q10
My Carrier: videocon
Accepted Solution

moving images

can anyone help me that how should I attach a moving image in my app.plz send me the code
Developer
Posts: 6,152
Registered: ‎07-05-2012
My Device: Playbook, Dev Alpha C, Z10 LE, Z30
My Carrier: Orange

Re: moving images

Animated GIFs won't work apparently but you can use MediaPlayer to run movei formats...

 

http://developer.blackberry.com/native/reference/cascades/bb__multimedia__mediaplayer.html

 

Alternatively you can switch images yourself using a timer such as QTimer.


If you've been helped click on Like Button, if you've been saved buy the app. Smiley Happy

Developer of stokLocker, Sympatico and Super Sentences.
Trusted Contributor
Posts: 160
Registered: ‎09-01-2013
My Device: z10 and q10
My Carrier: videocon

Re: moving images

okk thanks.
Developer
Posts: 828
Registered: ‎10-16-2012
My Device: Red Z10
My Carrier: Rogers

Re: moving images

Gif's may work if displayed through a webview, I've seen them in action on bb10 in tubmlr apps so I know it is possible some way

Trusted Contributor
Posts: 160
Registered: ‎09-01-2013
My Device: z10 and q10
My Carrier: videocon

Re: moving images

can you plz send me the code with an example so I undrstand it better.
Developer
Posts: 6,152
Registered: ‎07-05-2012
My Device: Playbook, Dev Alpha C, Z10 LE, Z30
My Carrier: Orange

Re: moving images

		WebView {
		    verticalAlignment: VerticalAlignment.Center
		    horizontalAlignment: HorizontalAlignment.Center
		    preferredHeight: 900
		    preferredWidth: 700
		    

            html: "<html><head><title>hi</title></head>" + 
            	"<body>" +
                "<img src='http://www.stok.biz/animImg.png' alt='web pic'>" +
            	"</body>" +
            	"</html>"
		}

 


If you've been helped click on Like Button, if you've been saved buy the app. Smiley Happy

Developer of stokLocker, Sympatico and Super Sentences.
Highlighted
Trusted Contributor
Posts: 160
Registered: ‎09-01-2013
My Device: z10 and q10
My Carrier: videocon

Re: moving images

okk thanks for providing the code.i will.use it now!!