def submitButtonHandler(self, value): self.__currentSlot, _ = self.__makeInitialSlotData(value) self.fireEvent( CSRosterSlotSettingsWindow( CSRosterSlotSettingsWindow.APPLY_SLOT_SETTINGS, self.__getSlotsSettings())) self.onWindowClose()
def submitButtonHandler(self, value): self.currentSlot = self.__makeCurrentSlotData(value) self.fireEvent( CSRosterSlotSettingsWindow( CSRosterSlotSettingsWindow.APPLY_SLOT_SETTINGS, self.currentSlot)) self.onWindowClose()
def submitButtonHandler(self, value): self.__currentSlot, _ = self.__makeInitialSlotData(value) slotSettins = self.__getSlotsSettings() self.fireEvent( CSRosterSlotSettingsWindow( CSRosterSlotSettingsWindow.APPLY_SLOT_SETTINGS, slotSettins)) if self.__currentSlot is not None and 'intCD' in self.__currentSlot: self.__addAditionalSlot(slotSettins) self.onWindowClose() return
def __addAditionalSlot(self, slotSettins): row = slotSettins[0] column = slotSettins[1] vehicleCD = self.__currentSlot['intCD'] vehicle = self.itemsCache.items.getItemByCD(int(vehicleCD)) if vehicle.hasNationGroup and vehicle.activeInNationGroup: addVehCD = iterVehTypeCDsInNationGroup(vehicleCD).next() vehicle = self.itemsCache.items.getItemByCD(addVehCD) addSlot = makeVehicleVO( vehicle, self.__convertLevelsRange(self._levelsRange), self.__vehicleTypes) slotSettings = [row, 1 - column, addSlot] self.fireEvent( CSRosterSlotSettingsWindow( CSRosterSlotSettingsWindow.APPLY_SLOT_SETTINGS, slotSettings))