QLCFixtureEditor::QLCFixtureEditor(QWidget* parent, QLCFixtureDef* fixtureDef, const QString& fileName) : QWidget(parent) , m_fixtureDef(fixtureDef) , m_fileName(fileName) , m_modified(false) { setupUi(this); init(); setCaption(); setModified(false); /* Connect to be able to enable/disable clipboard actions */ connect(_app, SIGNAL(clipboardChanged()), this, SLOT(slotClipboardChanged())); /* Initial update to clipboard actions */ slotClipboardChanged(); QSettings settings; QVariant var = settings.value(SETTINGS_GEOMETRY); if (var.isValid() == true) parentWidget()->restoreGeometry(var.toByteArray()); }
int QLCFixtureEditor::qt_metacall(QMetaObject::Call _c, int _id, void **_a) { _id = QWidget::qt_metacall(_c, _id, _a); if (_id < 0) return _id; if (_c == QMetaObject::InvokeMetaMethod) { switch (_id) { case 0: slotManufacturerTextEdited((*reinterpret_cast< const QString(*)>(_a[1]))); break; case 1: slotModelTextEdited((*reinterpret_cast< const QString(*)>(_a[1]))); break; case 2: slotTypeActivated((*reinterpret_cast< const QString(*)>(_a[1]))); break; case 3: slotChannelListSelectionChanged((*reinterpret_cast< QTreeWidgetItem*(*)>(_a[1]))); break; case 4: slotAddChannel(); break; case 5: slotRemoveChannel(); break; case 6: slotEditChannel(); break; case 7: slotCopyChannel(); break; case 8: slotPasteChannel(); break; case 9: slotExpandChannels(); break; case 10: slotChannelListContextMenuRequested(); break; case 11: slotModeListSelectionChanged((*reinterpret_cast< QTreeWidgetItem*(*)>(_a[1]))); break; case 12: slotAddMode(); break; case 13: slotRemoveMode(); break; case 14: slotEditMode(); break; case 15: slotCloneMode(); break; case 16: slotExpandModes(); break; case 17: slotModeListContextMenuRequested(); break; case 18: slotClipboardChanged(); break; default: ; } _id -= 19; } return _id; }
void KClipboardSynchronizer::setupSignals() { QClipboard *clip = QApplication::clipboard(); disconnect(clip, NULL, this, NULL); if(s_sync) connect(clip, SIGNAL(selectionChanged()), SLOT(slotSelectionChanged())); if(s_reverse_sync) connect(clip, SIGNAL(dataChanged()), SLOT(slotClipboardChanged())); }