@@ -169,8 +169,7 @@ public Point Size
169
169
CursorPos = CursorPos ;
170
170
}
171
171
172
- if ( SizeChanged != null )
173
- SizeChanged ( this , new SizeChangedEventArgs ( oldCursorPos ) ) ;
172
+ SizeChanged ? . Invoke ( this , new SizeChangedEventArgs ( oldCursorPos ) ) ;
174
173
}
175
174
}
176
175
@@ -232,8 +231,7 @@ public void ChangeToScreen(bool alternate)
232
231
else
233
232
currentBuffer = screenBuffer ;
234
233
235
- if ( ScreenChanged != null )
236
- ScreenChanged ( this , EventArgs . Empty ) ;
234
+ ScreenChanged ? . Invoke ( this , EventArgs . Empty ) ;
237
235
}
238
236
239
237
void advanceCursorRow ( )
@@ -248,8 +246,7 @@ void advanceCursorRow()
248
246
Array . Copy ( lines , 1 , lines , 0 , lines . Length - 1 ) ;
249
247
lines [ lines . Length - 1 ] = newLine ;
250
248
251
- if ( LinesMoved != null )
252
- LinesMoved ( this , new LinesMovedEventArgs ( 1 , 0 , Size . Row - 1 ) ) ;
249
+ LinesMoved ? . Invoke ( this , new LinesMovedEventArgs ( 1 , 0 , Size . Row - 1 ) ) ;
253
250
}
254
251
}
255
252
@@ -266,8 +263,7 @@ public void MoveLines(int index, int newIndex, int count)
266
263
for ( int i = 0 ; i < addedCount ; ++ i )
267
264
lines [ addIndex + i ] = new TerminalLine ( ) ;
268
265
269
- if ( LinesMoved != null )
270
- LinesMoved ( this , new LinesMovedEventArgs ( index , newIndex , count ) ) ;
266
+ LinesMoved ? . Invoke ( this , new LinesMovedEventArgs ( index , newIndex , count ) ) ;
271
267
}
272
268
273
269
public void InsertCharacters ( string text , TerminalFont font )
0 commit comments