Ejemplo n.º 1
0
    def __init__(self, parent, embed=False):
        QtGui.QWidget.__init__(self, parent)

        if embed:
            self.setupUi(parent)
        else:
            self.setupUi(self)

        self.configureCardButton.setIcon(kdeui.KIcon("configure"))

        # Backend
        self.iface = Interface()
        self.iface.listenSignals(self.signalHandler)

        # Disable module if no packages provide backend or
        # no valid configuration is found
        if not self.checkBackend():
            parent.setDisabled(True)

        self.cardDialog = VideoCardDialog(self, self.iface)
        self.configureCardButton.clicked.connect(self.cardDialog.show)

        self.outputDialogs = {}
        self.firstLoad = True

        self.configChanged.connect(self.slotConfigChanged)
Ejemplo n.º 2
0
    def __init__(self, parent, embed=False):
        QtGui.QWidget.__init__(self, parent)

        if embed:
            self.setupUi(parent)
        else:
            self.setupUi(self)

        self.scene = DisplayScene(self.graphicsView)
        self.scene.outputsChanged.connect(self.slotChangeDisplays)
        self.scene.outputSelected.connect(self.slotUpdateOutputProperties)

        # Backend
        self.iface = Interface()
        self.iface.listenSignals(self.signalHandler)

        # Disable module if no packages provide backend or
        # no valid configuration is found
        if not self.checkBackend():
            parent.setDisabled(True)

        self.extendDisplays.toggled.connect(self.emitConfigChanged)
        self.detectButton.clicked.connect(self.slotDetectClicked)
        self.modeList.currentIndexChanged.connect(self.slotModeSelected)
        self.rateList.currentIndexChanged[int].connect(self.slotRateSelected)
        self.rotationList.currentIndexChanged[int].connect(self.slotRotationSelected)