

class View(object):
    def __init__(self):
        self.offset_x = 0
        self.offset_y = 0
        self._enabled = False

    def move(self, *args):
        if len(args) == 1:
            # It's probably a tuple.
            self.offset_x += args[0][0]
            self.offset_y += args[0][1]
        elif len(args) == 2:
            # It's 2 values passed.
            self.offset_x += args[0]
            self.offset_y += args[1]

    def init(self):
        pass

    def update(self, delta_time):
        pass

    def process_rect(self, rect, copy_rect=True, add=False):
        if copy_rect:
            rect = rect.copy()
        if not add:
            rect.x -= self.offset_x
            rect.y -= self.offset_y
        else:
            rect.x += self.offset_x
            rect.y += self.offset_y
        return rect
