Go to the documentation of this file.00001 class Adapter(object):
00002 """ Interface definations provided by the Adapter for use by the View.
00003
00004 NOTE: There should be no Qt specific code here!
00005 """
00006
00007 def __init__(self, model, view):
00008 self._topology = model
00009 self._view = view
00010 self._view.register_adapter(self)
00011
00012 def reorder_blocks(self, srcIdx, lowerIdx, upperIdx):
00013 """ Move block with index srcIdx between blocks with lowerIdx and upperIdx.
00014 Associated BlockItems are also be updated as necessary to reflect the change.
00015
00016 srcIdx, lowerIdx, and upperIdx should all be ints, except for when
00017 lowerIdx or upperIdx does not exists (at the far left and right) in which
00018 case they should be None.
00019 """
00020 raise NotImplementedError()
00021
00022 def reorder_bands(self, srcAlt, lowerAlt, upperAlt):
00023 """ Move band with altitude srcAlt between bands with lowerAlt and upperAlt.
00024 Bands cannot be dragged to the opposite side of the BlockContainer, that
00025 is, positive bands can only be dragged with positive bands.
00026 """
00027 raise NotImplementedError()
00028
00029 def reorder_snaps(self, blockIdx, container, srcIdx, lowerIdx, upperIdx):
00030 """ Move a snap with order srcIdx between snaps in the same container of
00031 the same block with index blockIdx with orders lowerIdx and upperIdx.
00032
00033 blockIdx - the index of the block the snaps are in
00034 container - either "emitter" or "collector"
00035 """
00036 raise NotImplementedError()
00037
00038 def bring_band_to_front(self, altitude):
00039 """ change a bands rank to bring it to the front. This should not affect
00040 the relative order of the other band's ranks, but may change their
00041 actual rank value.
00042 """
00043 raise NotImplementedError()
00044
00045
00046
00047
00048
00049