Datatypes library autodoc for SetDTAttrsA()
Datatypes library autodoc for SetDTAttrsA()
The SetDTAttrs() function in the datatype.library autodoc does not document the "struct Requester *" argument in the INPUTS paragraph. A short explanation for that arg should be added. In addition, I can't find any explanation for that argument in the "Datatypes Library" documentation WIKI.
AmigaOne X1000 with 2GB memory - OS4.1 FE
- broadblues
- AmigaOS Core Developer
- Posts: 600
- Joined: Sat Jun 18, 2011 2:40 am
- Location: Portsmouth, UK
- Contact:
Re: Datatypes library autodoc for SetDTAttrsA()
It's exactly the same usage as the equivalent
IIntuition->SetGadgetAttrs() function.
999 out a 1000 you will set that to NULL.
made BZ about the missing description in the autodoc
IIntuition->SetGadgetAttrs() function.
999 out a 1000 you will set that to NULL.
made BZ about the missing description in the autodoc
Re: Datatypes library autodoc for SetDTAttrsA()
I also notice that the return value for SetDTAttrsA() is not documented. I would assume 0 or -1 for failure but I don't want my program waiting for a signal that sound play has completed if SetDTAttrsA() failed. Could you add that to the BZ?broadblues wrote:It's exactly the same usage as the equivalent
IIntuition->SetGadgetAttrs() function.
999 out a 1000 you will set that to NULL.
made BZ about the missing description in the autodoc
AmigaOne X1000 with 2GB memory - OS4.1 FE
- broadblues
- AmigaOS Core Developer
- Posts: 600
- Joined: Sat Jun 18, 2011 2:40 am
- Location: Portsmouth, UK
- Contact:
Re: Datatypes library autodoc for SetDTAttrsA()
Don't assume that. SetAttrs type functions don't give simplistic fail or success return codes. The return does not indicate success or failure, but may , depending n the object indicate that some kind of refresh is required (mainly for gadgets).I also notice that the return value for SetDTAttrsA() is not documented. I would assume 0 or -1 for failure but I don't want my program waiting for a signal that sound play has completed if SetDTAttrsA() failed. Could you add that to the BZ?
Consult the individual documentation for the datatype you are using.
Re: Datatypes library autodoc for SetDTAttrsA()
The sound datatype docs don't mention any return value for setting attributes or specifically SDTA_SignalBitMask & SDTA_SignalTask. Since all the examples I have blindly assume a signal will be sent, I guess I'll do the same. A lack of meaningfull return values seems to be common with object oriented stuff, which is why I don't like it.broadblues wrote:Don't assume that. SetAttrs type functions don't give simplistic fail or success return codes. The return does not indicate success or failure, but may , depending n the object indicate that some kind of refresh is required (mainly for gadgets).I also notice that the return value for SetDTAttrsA() is not documented. I would assume 0 or -1 for failure but I don't want my program waiting for a signal that sound play has completed if SetDTAttrsA() failed. Could you add that to the BZ?
Consult the individual documentation for the datatype you are using.
AmigaOne X1000 with 2GB memory - OS4.1 FE
- broadblues
- AmigaOS Core Developer
- Posts: 600
- Joined: Sat Jun 18, 2011 2:40 am
- Location: Portsmouth, UK
- Contact:
Re: Datatypes library autodoc for SetDTAttrsA()
Well passing a signal mask and process address can hardly fail so there *is* no meaning error code.
There are other methods for retrieving errors, checking the result of the NewObject() lsistening to DTA_ErrorLevel in your IDCMP_UPDATE handler etc.
There are other methods for retrieving errors, checking the result of the NewObject() lsistening to DTA_ErrorLevel in your IDCMP_UPDATE handler etc.