NodeMonitor: Revert enums back to #defines

While enums are presented much more clearly in the docs and the values didn't
change this apparently caused some issues so we're going back to using #defines.

Also update the docs changing the \var tags to \def tag and putting the description
in a \brief tag.
This commit is contained in:
John Scipione
2014-06-18 20:57:49 -04:00
parent b885e90eb9
commit 5efee6dfb0
2 changed files with 51 additions and 51 deletions
+41 -37
View File
@@ -9,8 +9,8 @@
* Clemens Zeidler, [email protected] * Clemens Zeidler, [email protected]
* *
* Corresponds to: * Corresponds to:
* headers/os/storage/NodeMonitor.h hrev47402 * headers/os/storage/NodeMonitor.h hrev47403
* src/kits/storage/NodeMonitor.cpp hrev47402 * src/kits/storage/NodeMonitor.cpp hrev47403
*/ */
@@ -122,99 +122,103 @@
*/ */
//// The "opcode" field of the B_NODE_MONITOR notification message you get. // The "opcode" field of the B_NODE_MONITOR notification message you get.
/*! /*!
\var B_ENTRY_CREATED \def B_ENTRY_CREATED
\brief \c B_NODE_MONITOR notification message "opcode" is set when entry is
\c B_NODE_MONITOR notification message "opcode" is set when entry is created.
created.
\since BeOS R3 \since BeOS R3
*/ */
/*! /*!
\var B_ENTRY_REMOVED \def B_ENTRY_REMOVED
\brief \c B_NODE_MONITOR notification message "opcode" is set when entry is
\c B_NODE_MONITOR notification message "opcode" is set when entry is removed.
removed.
\since BeOS R3 \since BeOS R3
*/ */
/*! /*!
\var B_ENTRY_MOVED \def B_ENTRY_MOVED
\brief \c B_NODE_MONITOR notification message "opcode" is set when entry is
\c B_NODE_MONITOR notification message "opcode" is set when entry is moved.
moved.
\since BeOS R3 \since BeOS R3
*/ */
/*! /*!
\var B_STAT_CHANGED \def B_STAT_CHANGED
\brief \c B_NODE_MONITOR notification message "opcode" set when stat info
changes.
\c B_NODE_MONITOR notification message "opcode" set when stat info More information can be found in the "fields" field.
changes. More information can be found in the "fields" field.
\since BeOS R3 \since BeOS R3
*/ */
/*! /*!
\var B_ATTR_CHANGED \def B_ATTR_CHANGED
\brief \c B_NODE_MONITOR notification message "opcode" set when attribute
changes.
\c B_NODE_MONITOR notification message "opcode" set when attribute More information can be found in the "cause" field.
changes. More information can be found in the "cause" field.
\since BeOS R3 \since BeOS R3
*/ */
/*! /*!
\var B_DEVICE_MOUNTED \def B_DEVICE_MOUNTED
\brief \c B_NODE_MONITOR notification message "opcode" set when device is
\c B_NODE_MONITOR notification message "opcode" set when device is mounted.
mounted.
\since BeOS R3 \since BeOS R3
*/ */
/*! /*!
\var B_DEVICE_UNMOUNTED \def B_DEVICE_UNMOUNTED
\brief \c B_NODE_MONITOR notification message "opcode" set when device is
\c B_NODE_MONITOR notification message "opcode" set when device is unmounted.
unmounted.
\since BeOS R3 \since BeOS R3
*/ */
/*! // More specific info in the "cause" field of B_ATTR_CHANGED notification
\var B_ATTR_CREATED // messages.
\c B_ATTR_CHANGED notification message "cause" set when attribute is
created. /*!
\def B_ATTR_CREATED
\brief \c B_ATTR_CHANGED notification message "cause" set when attribute is
created.
\since Haiku R1 \since Haiku R1
*/ */
/*! /*!
\var B_ATTR_REMOVED \def B_ATTR_REMOVED
\brief \c B_ATTR_CHANGED notification message "cause" set when attribute is
\c B_ATTR_CHANGED notification message "cause" set when attribute is removed.
removed.
\since Haiku R1 \since Haiku R1
*/ */
// More specific info in the "fields" field of B_STAT_CHANGED notification
// messages, specifying what parts of the stat data have actually been
// changed.
/*! /*!
\var B_STAT_MODE \var B_STAT_MODE
\brief Set when stat mode changes. \brief Set when stat mode changes.
+10 -14
View File
@@ -32,25 +32,21 @@ enum {
// The presence and meaning of the other fields in that message specifying what // The presence and meaning of the other fields in that message specifying what
// exactly caused the notification depend on this value. // exactly caused the notification depend on this value.
enum { #define B_ENTRY_CREATED 1
B_ENTRY_CREATED = 1, #define B_ENTRY_REMOVED 2
B_ENTRY_REMOVED, #define B_ENTRY_MOVED 3
B_ENTRY_MOVED, #define B_STAT_CHANGED 4
B_STAT_CHANGED, #define B_ATTR_CHANGED 5
B_ATTR_CHANGED, #define B_DEVICE_MOUNTED 6
B_DEVICE_MOUNTED, #define B_DEVICE_UNMOUNTED 7
B_DEVICE_UNMOUNTED
};
// More specific info in the "cause" field of B_ATTR_CHANGED notification // More specific info in the "cause" field of B_ATTR_CHANGED notification
// messages. (Haiku only) // messages. (Haiku only)
enum { #define B_ATTR_CREATED 1
B_ATTR_CREATED = 1, #define B_ATTR_REMOVED 2
B_ATTR_REMOVED, // B_ATTR_CHANGED is reused
// B_ATTR_CHANGED
};
// More specific info in the "fields" field of B_STAT_CHANGED notification // More specific info in the "fields" field of B_STAT_CHANGED notification