PtToggleButton

Does anyone know of a way to set up a toggle buttons so that when you click
it it will pull up a dialog but NOT invert the SET bit?
I have a module with a list of feature capabilities. I’d like to set the
Pt_SET flag progamatically if the feature exists or not, then if it IS set,
allow the user to click the particular feature capability which would bring
up some additional information on that feature.

If I allow Pt_SELECTABLE then I can bring up the dialog box but the Pt_SET
flag is toggled.
And if I remove the Pt_SELECTABLE flag then the user is not allowed to
toggle the Pt_SET flag but I cannot pull up the Dialog

Help?!?!


Jeffrey B. Holtz
Software Engineering
Electro Scientific Industries, Inc.
Ph: 734-332-7054
Fax: 734-332-7077
email: holtzj@esi.com

“Jeff Holtz” <holtzj@mediaone.net> wrote in message
news:aiukkl$bll$1@inn.qnx.com

Does anyone know of a way to set up a toggle buttons so that when you
click
it it will pull up a dialog but NOT invert the SET bit?
I have a module with a list of feature capabilities. I’d like to set the
Pt_SET flag progamatically if the feature exists or not, then if it IS
set,
allow the user to click the particular feature capability which would
bring
up some additional information on that feature.

If I allow Pt_SELECTABLE then I can bring up the dialog box but the Pt_SET
flag is toggled.
And if I remove the Pt_SELECTABLE flag then the user is not allowed to
toggle the Pt_SET flag but I cannot pull up the Dialog

Help?!?!


Jeffrey B. Holtz
Software Engineering
Electro Scientific Industries, Inc.
Ph: 734-332-7054
Fax: 734-332-7077
email: > holtzj@esi.com

Hey Jeff,

I’ve run into similar issues often times having to validate an action when a
button is pressed and only set the button if the validition is true. The
best way to do it is to simply ‘undo’ the default behaviour. Just use the
‘activate callback’ for the button, and then in there, PtSetResource(button,
Pt_ARG_FLAGS, Pt_FALSE, Pt_SET ), then call up your dialog depending if ur
doing it in code or through Phab.

Yamin

How about Pt_BLOCKED | Pt_GHOST // to enable / disable UI
Pt_SELECTABLE always on and Pt_TOGGLE cleared always?
(makes this a normal button)
Pt_ARG_SET_COLOR and Pt_ARG_INDICATOR_COLOR should be set the same
and shows feature available or not.
just an idea :slight_smile:
cheers, Peter
“Yamin Bismilla” <y2bismil@hotmail.com> schrieb im Newsbeitrag
news:aj0cms$khd$1@inn.qnx.com

“Jeff Holtz” <> holtzj@mediaone.net> > wrote in message
news:aiukkl$bll$> 1@inn.qnx.com> …

Does anyone know of a way to set up a toggle buttons so that when you
click
it it will pull up a dialog but NOT invert the SET bit?
I have a module with a list of feature capabilities. I’d like to set
the
Pt_SET flag progamatically if the feature exists or not, then if it IS
set,
allow the user to click the particular feature capability which would
bring
up some additional information on that feature.

If I allow Pt_SELECTABLE then I can bring up the dialog box but the
Pt_SET
flag is toggled.
And if I remove the Pt_SELECTABLE flag then the user is not allowed to
toggle the Pt_SET flag but I cannot pull up the Dialog

Help?!?!


Jeffrey B. Holtz
Software Engineering
Electro Scientific Industries, Inc.
Ph: 734-332-7054
Fax: 734-332-7077
email: > holtzj@esi.com



Hey Jeff,

I’ve run into similar issues often times having to validate an action when
a
button is pressed and only set the button if the validition is true. The
best way to do it is to simply ‘undo’ the default behaviour. Just use the
‘activate callback’ for the button, and then in there,
PtSetResource(button,
Pt_ARG_FLAGS, Pt_FALSE, Pt_SET ), then call up your dialog depending if ur
doing it in code or through Phab.

Yamin