def __init__(self, fv):
        """
        This method is called when the plugin is loaded for the  first
        time.  ``fv`` is a reference to the Ginga (reference viewer) shell.

        You need to call the superclass initializer and then do any local
        initialization.
        """
        super(MyGlobalPlugin, self).__init__(fv)

        # Your initialization here

        # Create some variables to keep track of what is happening
        # with which channel
        self.active = None
        self.gui_up = False
        self.tw = None

        # Subscribe to some interesting callbacks that will inform us
        # of channel events.  You may not need these depending on what
        # your plugin does
        fv.set_callback('add-channel', self.add_channel)
        fv.set_callback('delete-channel', self.delete_channel)
        fv.set_callback('channel-change', self.focus_cb)
def __init__ ( self , fv ) : super ( MyGlobalPlugin , self ) . __init__ ( fv ) self . active = None self . gui_up = False self . tw = None fv . set_callback ( 'add-channel' , self . add_channel ) fv . set_callback ( 'delete-channel' , self . delete_channel ) fv . set_callback ( 'channel-change' , self . focus_cb )
This method is called when the plugin is loaded for the  first
        time.  ``fv`` is a reference to the Ginga (reference viewer) shell.

        You need to call the superclass initializer and then do any local
        initialization.