Changeset 1301


Ignore:
Timestamp:
08/21/11 01:24:17 (21 months ago)
Author:
reyalp
Message:

fix ptp enums, don't want anonymous enum variables

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/core/ptp.h

    r1155 r1301  
    2222 
    2323// N.B.: unused parameters should be set to 0 
    24 enum { 
     24enum ptp_chdk_command { 
    2525  PTP_CHDK_Version = 0,     // return param1 is major version number 
    2626                            // return param2 is minor version number 
     
    6464                            // input messages do not have type or subtype, they are always a string destined for the script (similar to USER/string) 
    6565                            // output param1 is ptp_chdk_script_msg_status 
    66 } ptp_chdk_command; 
     66}; 
    6767 
    6868// data types as used by ReadScriptMessage 
    69 enum { 
     69enum ptp_chdk_script_data_type { 
    7070  PTP_CHDK_TYPE_UNSUPPORTED = 0, // type name will be returned in data 
    7171  PTP_CHDK_TYPE_NIL, 
     
    7676                        // this function can be overridden in lua to change the format 
    7777                        // the string may be empty for an empty table 
    78 } ptp_chdk_script_data_type; 
     78}; 
    7979 
    8080// TempData flags 
     
    9696 
    9797// message types 
    98 enum { 
     98enum ptp_chdk_script_msg_type { 
    9999    PTP_CHDK_S_MSGTYPE_NONE = 0, // no messages waiting 
    100100    PTP_CHDK_S_MSGTYPE_ERR,      // error message 
     
    102102    PTP_CHDK_S_MSGTYPE_USER,     // message queued by script 
    103103// TODO chdk console data ? 
    104 } ptp_chdk_script_msg_type; 
     104}; 
    105105 
    106106// error subtypes for PTP_CHDK_S_MSGTYPE_ERR and script startup status 
    107 enum { 
     107enum ptp_chdk_script_error_type { 
    108108    PTP_CHDK_S_ERRTYPE_NONE = 0, 
    109109    PTP_CHDK_S_ERRTYPE_COMPILE, 
    110110    PTP_CHDK_S_ERRTYPE_RUN, 
    111 } ptp_chdk_script_error_type; 
     111}; 
    112112 
    113113// message status 
    114 enum { 
     114enum ptp_chdk_script_msg_status { 
    115115    PTP_CHDK_S_MSGSTATUS_OK = 0, // queued ok 
    116116    PTP_CHDK_S_MSGSTATUS_NOTRUN, // no script is running 
    117117    PTP_CHDK_S_MSGSTATUS_QFULL,  // queue is full 
    118118    PTP_CHDK_S_MSGSTATUS_BADID,  // specified ID is not running 
    119 } ptp_chdk_script_msg_status; 
     119}; 
    120120#endif // __CHDK_PTP_H 
Note: See TracChangeset for help on using the changeset viewer.