History

GSF.EMAX: Modified ControlFile to cache the FrameLength array.

StephenCWills committed 10 years ago

Commit ba39ede1 parent dc0a3491 file · +3 −4Browse files

Showing the changes to Source/Libraries/GSF.EMAX/ControlFile.cs (1 of 1 file). Show all

Unified · Split

Source/Libraries/GSF.EMAX/ControlFile.cs+3−4
@@ -161,7 +161,6 @@ namespace GSF.EMAX · 160 unmodified lines
161 161
162 int cardCount;162 int cardCount;
163 int remainder;163 int remainder;
164 int[] frameLength;
165 164
166 if ((object)m_frameLength != null)165 if ((object)m_frameLength != null)
167 return m_frameLength;166 return m_frameLength;
@@ -172,12 +171,12 @@ namespace GSF.EMAX · 4 unmodified lines
172 if (remainder > 0)171 if (remainder > 0)
173 cardCount++;172 cardCount++;
174 173
175 frameLength = Enumerable.Repeat(largeFrame, cardCount).ToArray();174 m_frameLength = Enumerable.Repeat(largeFrame, cardCount).ToArray();
176 175
177 if (0 < remainder && remainder <= 32)176 if (0 < remainder && remainder <= 32)
178 frameLength[cardCount - 1] = smallFrame;177 m_frameLength[cardCount - 1] = smallFrame;
179 178
180 return frameLength;179 return m_frameLength;
181 }180 }
182 }181 }
183 182

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t