Action when we need to remove dropped item.

        :param *args: Position arguments.
        :type *args: list

        :param kwargs: Keywords arguments.
        :type kwargs: dict
553578
def drop_remove(*args, **kwargs):
        
        dropped_item = args[0]
        field_list = kwargs['field_list']
        num_duplicate = 0
        for i in range(field_list.count()):
            if dropped_item.text() == field_list.item(i).text():
                num_duplicate += 1
        if num_duplicate > 1:
            # Notes(IS): For some reason, removeItemWidget is not working.
            field_list.takeItem(field_list.row(dropped_item))
766135
async def remove_items(self, *items):
    '''
    '''
    items = [i.id for i in (await self.process(items)) if i in self.items]
    if not items:
      return

    await self.connector.delete(
      'Playlists/{Id}/Items'.format(Id=self.id),
      EntryIds=','.join(items),
      remote=False
    )
317712
def dropEvent(self, ev):
        """"""
        # use function above to accept event if it contains a file URL
        files = self._checkDragDropEvent(ev)
        if files:
            pos = ev.pos()
            dropitem = self.itemAt(pos)
            dprint(1, "dropped on", pos.x(), pos.y(), dropitem and str(dropitem.text(1)))
            # if event originated with ourselves, reorder items
            if ev.source() is self:
                self.reorderItems(dropitem, *files)
            # else event is from someone else, accept the dropped files
            else:
                self._dropped_on = dropitem
                self.emit(SIGNAL("droppedFiles"), *files)
                # if event originated with another DPTreeWidget, emit a draggedAwayFiles() signal on its behalf
                if isinstance(ev.source(), DPTreeWidget):
                    ev.source().emit(SIGNAL("draggedAwayFiles"), *files)
493030
def drop(self, items):
        
        self._manager.leaser.remove(items)
        self._manager.maybe_resume_consumer()
548907
def _api_handler(self, *args, **kwargs):
        
        keyword_arguments = {}
        keyword_arguments.update(self.keywords)
        keyword_arguments.update(kwargs)
        return api_handler(*args, **keyword_arguments)
409340
def pop(self, key, default=NONE):
        
        if key in self:
            self._list_remove(key)
            return self._pop(key)
        else:
            if default is NONE:
                raise KeyError(key)
            else:
                return default
767005
def delete(self, id, id_name='id', **kwargs):
        
        response = self._new_response()
        if self._check_supported_op('delete', response):
            params = {'Key': {id_name: id}}
            self._call_ddb_method(self.table.delete_item, params, response)
            response.data = 'true'
        response.prepare()
        return response
493340
@SuppressWarnings("squid:S3346")
    public void postRemoveItem(int item, int bin) {
        assert candidate.get(bin).get(item);
        candidate.get(bin).clear(item);
    }
190473
def remove(self, item):
        
        if item not in self:
            raise ValueError('objectlist.remove(item) failed, item not in list')
        item_id = int(self._view_path_for(item))
        giter = self._iter_for(item)
        del self[giter]
        self.emit('item-removed', item, item_id)
377069
def on_remove(self, widget, data=None):
        
        treeiter, path = self.get_selected_object()
        if not treeiter:
            return

        # check if an element is selected
        dict_path_as_list = self.tree_store[path][self.ID_STORAGE_ID]
        logger.debug("Deleting semantic data entry with name {}!".format(dict_path_as_list[-1]))
        self.model.state.remove_semantic_data(dict_path_as_list)
        self.reload_tree_store_data()

        # hold cursor position where the last element was removed
        try:
            self.select_entry(self.tree_store[path][self.ID_STORAGE_ID])
        except IndexError:
            if len(self.tree_store):
                if len(path) > 1:
                    possible_before_path = tuple(list(path[:-1]) + [path[-1] - 1])
                    if possible_before_path[-1] > -1:
                        self.select_entry(self.tree_store[possible_before_path][self.ID_STORAGE_ID])
                    else:
                        self.select_entry(self.tree_store[path[:-1]][self.ID_STORAGE_ID])
                else:
                    self.select_entry(self.tree_store[path[0] - 1][self.ID_STORAGE_ID])
        return True
918617
def dropped(self, item, event):
        
        location = self.rowAt(event.pos().y())

        if isinstance(item, StimFactory):
            factory = item
            # create new stimulus then!
            stim = factory.create()
            if stim is not None:
                self.model().insertTest(stim, location)
        elif event.source() == self:
            self.model().insertTest(item, location)
1210910
def _remove(self, client_kwargs):
        
        with _handle_client_exception():
            # Object
            if 'obj' in client_kwargs:
                return self.client.delete_object(
                    client_kwargs['container'], client_kwargs['obj'])

            # Container
            return self.client.delete_container(client_kwargs['container'])
1236881
def _on_items_changed(self, change):
        
        if change['type'] != 'container':
            return
        op = change['operation']
        if op == 'append':
            i = len(change['value'])-1
            self.adapter.notifyItemInserted(i)
        elif op == 'insert':
            self.adapter.notifyItemInserted(change['index'])
        elif op in ('pop', '__delitem__'):
            self.adapter.notifyItemRemoved(change['index'])
        elif op == '__setitem__':
            self.adapter.notifyItemChanged(change['index'])
        elif op == 'extend':
            n = len(change['items'])
            i = len(change['value'])-n
            self.adapter.notifyItemRangeInserted(i, n)
        elif op in ('remove', 'reverse', 'sort'):
            # Reset everything for these
            self.adapter.notifyDataSetChanged()
32632
def remove(self, item):
        
        if item not in self:
            raise ValueError('objectlist.remove(item) failed, item not in list')
        item_path = self._view_path_for(item)
        giter = self._iter_for(item)
        del self[giter]
        self.emit('item-removed', item, item_path)
809450
def delete(self, *items):
        
        self._visual_drag.delete(*items)
        ttk.Treeview.delete(self, *items)
1358613
def dpop(self, **kwds):
        
        item = self.dget(**kwds)
        self.remove(item)
        return item
382627
def remove(self, pk):
        
        pk = str(pk)
        try:
            del self.items[pk]
        except KeyError:
            raise ItemNotInCart(pk=pk)
        self.update()