def showEvent(self, event):
        """ initialize dialog

	    :param event: NOT USED
        """
        self.LayerCombo.clear()  # remove previous entries
        self.ColumnCombo.clear()
        self.BaseEdit.clear()    # clear textbox
        # fill layer name combo
        names = util.getLayerNames([QGis.Polygon, QGis.Line, QGis.Point])
        self.LayerCombo.addItems(names)
        # set active layer as default
        if iface.activeLayer():
            i = self.LayerCombo.findText(iface.activeLayer().name())
            if i > -1:
                self.LayerCombo.setCurrentIndex(i)
 def showEvent(self, event):
     # remove previous entries from layer list
     self.ui.layerBox.clear()
     # remove previous shape path
     self.ui.pointEdit.clear()
     # add polygon layers to list
     names = util.getLayerNames([QGis.Polygon])
     self.ui.layerBox.addItems(names)
     if iface.activeLayer():
         # set active item in list to the active layer
         i = 0
         for name in names:
             l = util.getMapLayerByName(name)
             if l == iface.activeLayer():
                 self.ui.layerBox.setCurrentIndex(i)
                 break
             i += 1