Closed Bug 1581202 Opened 1 year ago Closed 5 months ago

Convert interface comments to jsdoc

Categories

(Chat Core :: General, task)

task
Not set

Tracking

(Not tracked)

RESOLVED FIXED
Instantbird 71

People

(Reporter: clokep, Assigned: clokep)

Details

Attachments

(1 file, 1 obsolete file)

(In reply to Magnus Melin [:mkmelin] from bug 1557506, comment #2)

::: chat/components/public/imIConversationsService.idl
@@ +93,5 @@

[scriptable, uuid(3f88cc5c-6940-4eb5-a576-c65770f49ce9)]
interface imIMessage: prplIMessage {

  • attribute boolean cancelled;
  • // Holds the sender color for Chats.
  • // Empty string by default, it is set by the conversation binding.

For these, please update to jsdoc style documentation comments. /** */

We talked about this on IRC and I'm filing this as a follow-up.

Magnus also gave this as an example:

https://searchfox.org/comm-central/source/mailnews/base/public/nsIMsgKeyArray.idl#28-31

Docs available at https://jsdoc.app/

Attached patch Patch v1 (obsolete) — Splinter Review

This is a pretty mechanical conversation with a few extra bits added.

Assignee: nobody → clokep
Status: NEW → ASSIGNED
Attachment #9093138 - Flags: review?(mkmelin+mozilla)
Comment on attachment 9093138 [details] [diff] [review]
Patch v1

Review of attachment 9093138 [details] [diff] [review]:
-----------------------------------------------------------------

::: chat/components/public/imITagsService.idl
@@ +60,1 @@
>    Array<imITag> getTags();

Would add an empty line before each new   /**
Could also switch to @returns

::: chat/components/public/prplIConversation.idl
@@ +49,5 @@
>    void sendMsg(in AUTF8String aMsg);
>  
> +  /**
> +   * Preprocess messages before they are sent (eg. split long messages).
> +   * Can return null if no changes are to be made.

would be preferable to use @returns to document it

@returns the messages, or null if no changes are to be made

::: chat/components/public/prplIMessage.idl
@@ +71,5 @@
> +   * The first action will be the 'default' and may be performed
> +   * automatically when the message is double clicked.
> +   * For example, 'Reply' is usually a good default action.
> +   *
> +   * @returns an array of prplIMessageAction

@returns prplIMessageAction[]
Attachment #9093138 - Flags: review?(mkmelin+mozilla) → review+
Attached patch Patch v2Splinter Review

Updates the patch with the comments from Magnus.

Attachment #9093138 - Attachment is obsolete: true
Attachment #9093260 - Flags: review+

Pushed by clokep@gmail.com:
https://hg.mozilla.org/comm-central/rev/6f78a5f43bcd
Convert interface comments to jsdoc for chat. r=mkmelin

Status: ASSIGNED → RESOLVED
Closed: 5 months ago
Resolution: --- → FIXED
Target Milestone: --- → Instantbird 71
You need to log in before you can comment on or make changes to this bug.