docs: def on_canvas_slave__electrode_selected(self, slave, data):
          '''
          .. versionchanged:: 0.11
              Clear any temporary routes (drawn while mouse is down) from routes
              list.
  
          .. versionchanged:: 0.11.3
              Clear temporary routes by setting ``df_routes`` property of
              :attr:`canvas_slave`.
          '''
          if self.plugin is None:
              return
          # XXX Negative `route_i` corresponds to temporary route being
          # drawn.  Since electrode selection terminates route drawing, clear any
          # rows corresponding to negative `route_i` values from the routes
          # table.
          slave.df_routes = slave.df_routes.loc[slave.df_routes.route_i >=
                                                0].copy()
          state = self.canvas_slave.electrode_states.get(data['electrode_id'], 0)
          self.plugin.execute_async('microdrop.electrode_controller_plugin',
                                    'set_electrode_states',
                                    electrode_states=pd
                                    .Series([not state],
                                            index=[data['electrode_id']]))