Changes between Version 33 and Version 34 of CodeBestPractices
- Timestamp:
- 2012-12-01 13:48:08 (11 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
CodeBestPractices
v33 v34 10 10 * [#Logging_events Logging events] 11 11 * [#Assertions Checking for proper usage (Assertions)] 12 * Creation and disposal of objects and data13 12 * [#Compatibility Cross-platform compatibility] 14 13 * [#Mono Mono] 15 * Target processor14 * [#Target_processor] Target processor 16 15 * [#User_Interface_design_guidelines User-interface design guidelines] 17 16 * Re-use what's already there … … 85 84 End Function 86 85 }}} 86 87 Note that we deliberately did not adopt the use of {http://msdn.microsoft.com/en-us/devlabs/dd491992.aspx CodeContracts] which make code a lot harder to read. 87 88 ---- 88 89 == Compatibility == … … 107 108 || vbTab, etc || Convert.!ToChar(Keys.Tab), etc || 108 109 || vbNewline || Environment.!NewLine || 109 || !InStr, Left, Mid || .NET [http://msdn.microsoft.com/en-US/library/system.string_methods%28v=vs.80%29.aspx String class] || 110 || MsgBox || See below, [#Notifications User Interface guidelines] || 110 || !InStr, Left, Mid || [http://msdn.microsoft.com/en-US/library/system.string_methods%28v=vs.80%29.aspx .NET String class] || 111 || !UBound, etc || [http://msdn.microsoft.com/en-us/library/system.array.getupperbound.aspx .NET Array class] || 112 || !MsgBox || See below, [#Notifications User Interface guidelines] || 111 113 112 114 === Target processor === … … 131 133 == Notifications == 132 134 135 Instead of showing message boxes, in EwE we channel all user feedback through messages: 136 * [http://webservice.ecopath.org/Ecopath/Help/?topic=html/b372577d-dc80-8e05-e20a-63c033888fe7.htm Feedback messages] ask for user feedback, and 137 * [http://webservice.ecopath.org/Ecopath/Help/?topic=html/0002ea1e-d9d1-370c-0126-ff3cce98b16a.htm Regular messages] may pop up based on the message importance and alert preferences set by the user. 133 138 139 Centralized messages have a few advantages: 140 * They will be written to the [#Logging_events EwE log]; 141 * Are shown in the EwE status panel; 142 * Have the ability to be [http://webservice.ecopath.org/Ecopath/Help/?topic=html/7673c56d-88f7-1d4c-94ba-405a9092f252.htm suppressed]. 134 143 135 144 ----