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


Thank you for visiting the BlackBerry Support Community Forums.

BlackBerry will be closing the BlackBerry Support Community Forums Device Forums on April 1st (Developers, see below)

BlackBerry remains committed to providing excellent customer support to our customers. We are delighted to direct you to the CrackBerry Forums, a well-established and thorough support channel, for continued BlackBerry support. Please visit http://forums.crackberry.com or http://crackberry.com/ask. You can also continue to visit BlackBerry Support or the BlackBerry Knowledge Base for official support options available for your BlackBerry Smartphone.

"When we launched CrackBerry.com 10 years ago, we set out to make it a fun and useful destination where BlackBerry Smartphone owners could share their excitement and learn to unleash the full potential of their BlackBerry. A decade later, the CrackBerry community is as active and passionate as ever and I know our knowledgeable members and volunteers will be excited to welcome and assist more BlackBerry owners with their questions."

- Kevin Michaluk, Founder, CrackBerry.com

Developers, for more information about the BlackBerry Developer Community please review Join the Conversation on the BlackBerry Developer Community Forums found on Inside BlackBerry.


Reply
Developer
Posts: 197
Registered: ‎11-25-2012
My Device: BlackBerry Dev Alpha B
Accepted Solution

Gallery app on Dev Alpha?

Hi, 

 

  I'm porting an app that should use a build-in picture gallery app to allow the user select a picture. As I can see there is no such app currently on Dev Alpha device. So my question would be, how can I implement this feature, is there any Cascades class exists for this or should I do it completely by hands as I did on PlayBook for one of my Qt apps? (Invoker method doesn't work since there is no gallery app present on the device). Thank you in advance

Developer
Posts: 6,473
Registered: ‎12-08-2010
My Device: PlayBook, Z10
My Carrier: none

Re: Gallery app on Dev Alpha?

I'm not sure why you say the "Invoker method doesn't work" unless it's simply an assumption you're making just because you don't actually *see* any standalone picture viewer app.

If you use BBM or the camera, however, you'll see that they both invoke a Card which does allow displaying pictures, so you ought to be able to do the same.

Peter Hansen -- (BB10 and dev-related blog posts at http://peterhansen.ca.)
Author of White Noise and Battery Guru for BB10 and for PlayBook | Get more from your battery!
Developer
Posts: 197
Registered: ‎11-25-2012
My Device: BlackBerry Dev Alpha B

Re: Gallery app on Dev Alpha?

peter9477, thank you for reply. I should've written "Invoker method didn't work" as I tried it. That's why I was surprised because the camera app indeed have image viewer. Probably I should try few more times, but first I will update my SDK today Smiley Happy Will report about results so others can benefit from them.

Developer
Posts: 6,473
Registered: ‎12-08-2010
My Device: PlayBook, Z10
My Carrier: none

Re: Gallery app on Dev Alpha?

meego_man, okay, that's different then. :-)

Do you have any code snippet or sample to post? I haven't even gotten to Cards yet, but especially if it's QML I could try testing something quickly and see how I fare.

Peter Hansen -- (BB10 and dev-related blog posts at http://peterhansen.ca.)
Author of White Noise and Battery Guru for BB10 and for PlayBook | Get more from your battery!
Developer
Posts: 197
Registered: ‎11-25-2012
My Device: BlackBerry Dev Alpha B

Re: Gallery app on Dev Alpha?

peter9477, my bad, I used the wrong code Smiley Happy I tried the example from photobomber and it was opening a single image instead of a list. Only yesterday I realised that I was expecting something that is not there Smiley Very Happy

 

  I'll try to use a file picker today, looks like it's a way to go. Once I have a working code I'll post it here

Highlighted
Developer
Posts: 154
Registered: ‎02-01-2009
My Device: Torch, PlayBook and Dev Alpha
My Carrier: SFR

Re: Gallery app on Dev Alpha?

[ Edited ]

Hi,

 

You have to use FilePicker

 

      attachedObjects: [
          FilePicker {
              id: imgPicker
  
              title: qsTr ("Image")
              mode: FilePickerMode.Picker
              type: FileType.Picture
              viewMode: ViewMode.GridView
              sortBy: FilePickerSortFlag.Default
              sortOrder: FilePickerSortOrder.Default
  
              onFileSelected: {
                  imgFile = selectedFiles[0]
              }
          }
      ]

 

Also, you can call PlayCloud Smiley Happy

 

http://www.progweb.com/bb10/playcloud/IMG_00000022.png

 

Or : http://www.progweb.com/bb10/playcloud/

 

Regards,

 

Nicolas

 

Developer
Posts: 197
Registered: ‎11-25-2012
My Device: BlackBerry Dev Alpha B

Re: Gallery app on Dev Alpha?

nicklasThank you very much, just what I needed. I almost got there myself, hanging the phone few times because didn't use FilePicker as attachedObject Smiley Very Happy 

 

Developer
Posts: 656
Registered: ‎02-03-2010
My Device: Z10 LE
My Carrier: Rogers

Re: Gallery app on Dev Alpha?

I see how to use the Filepicker to select one photo but that isn't the same as the gallery app that the camera has which allows the user to go from picture to picture including videos and then share them.  Purpose isn't to pick something but to just let the user acces their photos to view and share them from within our app.  Does anyone know how to invoke that type of app?


Steven Kader at JaredCo
   Follow me on Twitter    |     Mipixi.com :  Web App for Photo Sharing