I think you could change this line to:

```coffeescript
@subscribe atom.workspaceView, 'pane:attached pane:removed', => 
  @centerImage()
```

That will trigger `centerImage` whenever a pane is added or removed.