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
Contributor
IamSergio
Posts: 18
Registered: ‎07-05-2012
My Device: PlayBook
My Carrier: None

Image in dialog

Hi all.

How to show my picture (for example, from png file) in standard dialog?

Is this possible?

Please use plain text.
BlackBerry Development Advisor (Retired)
amarcon
Posts: 155
Registered: ‎07-16-2012
My Device: Dev Alpha
My Carrier: Bell

Re: Image in dialog

Yes,

 

you can try something like this:

 

    attachedObjects: [
        CustomDialog {
           id: myCustomDialog
           content: Container {
               ImageView {
                   imageSource: "asset:///images/bubble"
                   layoutProperties: DockLayoutProperties {
                       horizontalAlignment: HorizontalAlignment.Fill
				       verticalAlignment: VerticalAlignment.Fill
				   }
			   }
               Button {
                   text: "Hide CustomDialog"
                   onClicked: myCustomDialog.visible = false
               }
           }
       }
   ]

 

Hope this helps.

Please use plain text.
Contributor
IamSergio
Posts: 18
Registered: ‎07-05-2012
My Device: PlayBook
My Carrier: None

Re: Image in dialog

Sorry,

the program is written in ANSI C, Native SDK

Please use plain text.
BlackBerry Development Advisor (Retired)
amarcon
Posts: 155
Registered: ‎07-16-2012
My Device: Dev Alpha
My Carrier: Bell

Re: Image in dialog

Oh ok, not sure if I can help more... I'm mostly focused on Cascades.

 

Question: you were able to get a dialog working?

Please use plain text.
BlackBerry Development Advisor (Retired)
amarcon
Posts: 155
Registered: ‎07-16-2012
My Device: Dev Alpha
My Carrier: Bell

Re: Image in dialog

Anyway, running through the documentation, found the reference bellow, hope this helps.

 

https://developer.blackberry.com/native/reference/com.qnx.doc.bps.lib_ref/com.qnx.doc.bps.lib_ref/to...

Please use plain text.
Developer
borceg
Posts: 671
Registered: ‎03-21-2012
My Device: BlackBerry PlayBook 16GB
My Carrier: Vip

Re: Image in dialog

Current dialog.h implementation doesn't provide functions to set/add image to any dialog.

Fill feature request at jira tracker
https://www.blackberry.com/jira/secure/Dashboard.jspa
Please use plain text.
Developer
jtegen
Posts: 6,541
Registered: ‎10-27-2010
My Device: HTC One, PlayBook, LE Z10, DE Q10
My Carrier: Verizon

Re: Image in dialog

You can create your own if needed.
Please use plain text.