Callback for comboboxes: notifies us that a combobox for the given item and column has changed
178659
def _updateItemComboBoxIndex(self, item, column, num):
        """"""
        item._combobox_current_index[column] = num
        item._combobox_current_value[column] = item._combobox_option_list[column][num][0]
1288176
public static <Item extends IItem & IExpandable> void notifyItemsChanged(final FastAdapter adapter, ExpandableExtension expandableExtension, Set<Long> identifiers, boolean restoreExpandedState) {
        int i;
        IItem item;
        for (i = 0; i < adapter.getItemCount(); i++) {
            item = adapter.getItem(i);
            if (item instanceof IExpandable) {
                notifyItemsChanged(adapter, expandableExtension, (Item) item, identifiers, true, restoreExpandedState);
            } else if (identifiers.contains(item.getIdentifier())) {
                adapter.notifyAdapterItemChanged(i);
            }
        }
    }
857548
protected void onSelectedItemChanged() {
        if (selectedItem == null) {
            anchorLabel();
            getInputWidget().setText("");
        } else {
            getInputWidget().setText(getItemPrinter().print(selectedItem));
            floatLabel();
        }

        if (itemChooserListener != null) itemChooserListener.onSelectionChanged(this, selectedItem);
    }
552231
function(name){
        this.comboDatas.forEach(function(item, index){
            if(item.name === name){
                this.selectItem(index);
                return;
            }
        }.bind(this));
    }
897326
def _on_change(self):
        """"""
        if callable(self.__callback):
            self.__callback((self._family, self._size, self._bold, self._italic, self._underline, self._overstrike))
1336537
function (items, options) {


            options = options || {};
            _.defaults(options, {silent: false, index: this.$items.length});

            var index = options.index;

            if (!_.isArray(items)) {
                items = [items];
            }
            var item, itemIndex;
            for (var i = 0; i < items.length; i++) {
                item = items[i];
                if (item instanceof Bindable) {
                    item.bind('change', this._onItemChange, this);
                    item.bind('*', this._onItemEvent, this);
                }
                itemIndex = index + i;
                if (_.isUndefined(this.$items[itemIndex]) || itemIndex >= this.$items.length) {
                    this.$items[itemIndex] = item;
                } else {
                    this.$items.splice(itemIndex, 0, item);
                }
                if (options.silent !== true) {
                    this.trigger('add', {item: item, index: itemIndex});
                }
            }
        }
832658
public void itemStateChanged(ItemEvent ie) {
		Object source = ie.getSource();
		// System.out.println("ItemEvent:"+source);
		if (source == socks5radio || source == socks4radio)
			onSocksChange();
		else if (source == up_check)
			onUPChange();

	}
413981
def _itemComboBox(self, item, column):
        """"""
        if item.treeWidget() is not self:
            return None
        combobox = self.itemWidget(item, column)
        if not combobox:
            combobox = QComboBox(self)
            # combobox.setSizeAdjustPolicy(QComboBox.AdjustToContents)
            self.setItemWidget(item, column, combobox)
            width = 0
            for num, (name, icon) in enumerate(item._combobox_option_list[column]):
                if icon:
                    combobox.addItem(icon, name)
                else:
                    combobox.addItem(name)
                width = max(width, self._fontmetrics.width(name) + (icon and 16 or 0))
            combobox.setCurrentIndex(item._combobox_current_index[column])
            item._combobox_changed[column] = Kittens.utils.curry(self._updateItemComboBoxIndex, item, column)
            QObject.connect(combobox, SIGNAL("currentIndexChanged(int)"), item._combobox_changed[column])
            QObject.connect(combobox, SIGNAL("currentIndexChanged(int)"), self._emitUpdatedSignal)
            # resize section if needed
            width += 32
            if width > self.header().sectionSize(column):
                self.header().resizeSection(column, width)
        return combobox
412977
void switchTwoColumns(int columnIndex, int columnToIndex) {
        for (int i = 0; i < getRowCount() - 1; i++) {
            Object cellData = getItems()[i][columnToIndex];
            getItems()[i][columnToIndex] = getItems()[i][columnIndex];
            getItems()[i][columnIndex] = cellData;
        }
    }
896014
void onColumnSelect(final int index, final boolean selected) {
        final DataColumnDef columnDef = acceptableColumns.get(index);
        if (selected) {
            listEditor.getList().add(columnDef.clone());
        } else {
            listEditor.getList().remove(columnDef);
        }
        columnsChangedEvent.fire(new ColumnsChangedEvent(this, listEditor.getList()));
    }
89527
def item_selection_changed(self):
        """"""
        is_selection = len(self.selectedItems()) > 0
        self.expand_selection_action.setEnabled(is_selection)
        self.collapse_selection_action.setEnabled(is_selection)
829941
function (itemIndex) {
            // Don't do anything if the widget is disabled
            if (!this._data.disabled) {
                var newVal = !this._data.items[itemIndex].selected;
                this.setSelection(itemIndex, newVal);
                return newVal;
            } else {
                return this._data.items[itemIndex].selected;
            }
        }
735011
def _on_wid_changed(self, wid):
        """"""
        if self._itsme: return
        self.update_model(self._get_idx_from_widget(wid))
        return
476376
def OnUpdate(self, event):
        """"""

        if wx.ID_UNDO in self.id2menuitem:
            undo_item = self.id2menuitem[wx.ID_UNDO]
            undo_item.Enable(undo.stack().canundo())

        if wx.ID_REDO in self.id2menuitem:
            redo_item = self.id2menuitem[wx.ID_REDO]
            redo_item.Enable(undo.stack().canredo())

        event.Skip()
811562
def related_items_changed(self, instance, related_manager):
        
        assigned = related_manager.select_related("keyword")
        keywords = " ".join([str(a.keyword) for a in assigned])
        string_field_name = list(self.fields.keys())[0] % \
                            self.related_field_name
        if getattr(instance, string_field_name) != keywords:
            setattr(instance, string_field_name, keywords)
            instance.save()
423346
function ( e, item ) {
            var res = { 
                id:    this._conf().fieldID,
                meta:  this._meta(),
                value: {}
            };
            var oldValue = getOrDefault( this, 'props.config.value', [] );
            res.value[ res.id ] = _.contains(oldValue, item.id ) 
                ? _.without( oldValue, item.id ) : oldValue.concat([ item.id ]);

            this.handleEvent( 'change')( e );
            this._conf().onChange( res );
        }
820928
function changedActiveItems(item) {
  if (!defined(item._dataflowUrl)) {
    // All the data is already here, just update the total columns.
    var shownDimensionCombinations = calculateShownDimensionCombinations(
      item,
      item._fullDimensions
    );
    var columns = item._tableStructure.columns.slice(
      0,
      shownDimensionCombinations.ids.length + item._numberOfInitialColumns
    );
    if (columns.length > 0) {
      columns = columns.concat(
        buildTotalSelectedColumn(item, shownDimensionCombinations)
      );
      updateColumns(item, columns);
    }
    return when();
  } else {
    // Get the URL for the data request, and load & build the appropriate table.
    var activeConceptIds = calculateActiveConceptIds(item);
    var dimensionRequestString = calculateDimensionRequestString(
      item,
      activeConceptIds,
      item._fullDimensions
    );
    if (!defined(dimensionRequestString)) {
      return; // No value for a dimension, so ignore.
    }
    return loadAndBuildTable(item, dimensionRequestString);
  }
}