Esempio n. 1
0
    def __init__(self):
        """
        The constructor and initiator.
        :return:
        """
        # initial setup
        super(mainWindow, self).__init__()
        self.setupUi(self)

        # create an instance of the table data and give yourself as UI Interface
        self.ame_data = AMEData(self)

        # take care about ring combo
        self.ring_dict = Ring.get_ring_dict()
        keys = list(self.ring_dict.keys())
        keys.sort()
        self.comboBox_ring.addItems(keys)
        self.current_ring_name = ''

        self.comboBox_ring.setCurrentIndex(4)
        self.on_comboBox_ring_changed(4)

        # fill combo box with names
        self.comboBox_name.addItems(self.ame_data.names_list)

        # UI related stuff
        self.setup_table_view()
        self.connect_signals()

        # A particle to begin with
        self.particle = None
        self.comboBox_name.setCurrentIndex(6)
        self.reinit_particle()
Esempio n. 2
0
    def __init__(self):
        """
        The constructor and initiator.
        :return:
        """
        # initial setup
        super(mainWindow, self).__init__()
        self.setupUi(self)

        # create an instance of the table data and give yourself as UI Interface
        self.ame_data = AMEData(self)

        # take care about ring combo
        self.ring_dict = Ring.get_ring_dict()
        keys = list(self.ring_dict.keys())
        keys.sort()
        self.comboBox_ring.addItems(keys)
        self.current_ring_name = ''

        self.comboBox_ring.setCurrentIndex(4)
        self.on_comboBox_ring_changed(4)

        # fill combo box with names
        self.comboBox_name.addItems(self.ame_data.names_list)

        # UI related stuff
        self.setup_table_view()
        self.connect_signals()

        # A particle to begin with
        self.particle = None
        self.comboBox_name.setCurrentIndex(6)
        self.reinit_particle()