void UIToolsView::resizeEvent(QResizeEvent *pEvent) { /* Call to base-class: */ QIWithRetranslateUI<QIGraphicsView>::resizeEvent(pEvent); /* Notify listeners: */ emit sigResized(); }
void UIGChooserView::resizeEvent(QResizeEvent*) { /* Update scene-rect: */ updateSceneRect(); /* Notify listeners: */ emit sigResized(); }
void UIGDetailsView::resizeEvent(QResizeEvent *pEvent) { /* Call to base-class: */ QGraphicsView::resizeEvent(pEvent); /* Notify listeners: */ emit sigResized(); }
void UIMiniToolBar::resizeEvent(QResizeEvent*) { /* Rebuild shape: */ rebuildShape(); /* Notify listeners: */ emit sigResized(); }
void UIGRuntimeInformation::prepareConnections() { /* Setup details-model connections: */ connect(m_pDetailsModel, SIGNAL(sigRootItemMinimumWidthHintChanged(int)), m_pDetailsView, SLOT(sltMinimumWidthHintChanged(int))); connect(m_pDetailsModel, SIGNAL(sigRootItemMinimumHeightHintChanged(int)), m_pDetailsView, SLOT(sltMinimumHeightHintChanged(int))); /* Setup details-view connections: */ connect(m_pDetailsView, SIGNAL(sigResized()), m_pDetailsModel, SLOT(sltHandleViewResize())); }
void UIGChooser::prepareConnections() { /* Setup chooser-model connections: */ connect(m_pChooserModel, SIGNAL(sigRootItemMinimumWidthHintChanged(int)), m_pChooserView, SLOT(sltMinimumWidthHintChanged(int))); connect(m_pChooserModel, SIGNAL(sigRootItemMinimumHeightHintChanged(int)), m_pChooserView, SLOT(sltMinimumHeightHintChanged(int))); connect(m_pChooserModel, SIGNAL(sigFocusChanged(UIGChooserItem*)), m_pChooserView, SLOT(sltFocusChanged(UIGChooserItem*))); /* Setup chooser-view connections: */ connect(m_pChooserView, SIGNAL(sigResized()), m_pChooserModel, SLOT(sltHandleViewResized())); }
void UIGChooser::prepareConnections() { /* Chooser-model connections: */ connect(m_pChooserModel, SIGNAL(sigRootItemResized(const QSizeF&, int)), m_pChooserView, SLOT(sltHandleRootItemResized(const QSizeF&, int))); connect(m_pChooserModel, SIGNAL(sigSelectionChanged()), this, SIGNAL(sigSelectionChanged())); connect(m_pChooserModel, SIGNAL(sigSlidingStarted()), this, SIGNAL(sigSlidingStarted())); /* Chooser-view connections: */ connect(m_pChooserView, SIGNAL(sigResized()), m_pChooserModel, SLOT(sltHandleViewResized())); /* Global connections: */ connect(gVBoxEvents, SIGNAL(sigMachineStateChange(QString, KMachineState)), m_pChooserModel, SLOT(sltMachineStateChanged(QString, KMachineState))); connect(gVBoxEvents, SIGNAL(sigMachineDataChange(QString)), m_pChooserModel, SLOT(sltMachineDataChanged(QString))); connect(gVBoxEvents, SIGNAL(sigMachineRegistered(QString, bool)), m_pChooserModel, SLOT(sltMachineRegistered(QString, bool))); connect(gVBoxEvents, SIGNAL(sigSessionStateChange(QString, KSessionState)), m_pChooserModel, SLOT(sltSessionStateChanged(QString, KSessionState))); connect(gVBoxEvents, SIGNAL(sigSnapshotChange(QString, QString)), m_pChooserModel, SLOT(sltSnapshotChanged(QString, QString))); }
void TextEdit::resizeEvent( QResizeEvent * e ) { QTextEdit::resizeEvent(e); emit sigResized( e ); }
void UIRuntimeMiniToolBar::prepare() { /* Allow any size: */ setMinimumSize(1, 1); /* Make sure we have no focus: */ setFocusPolicy(Qt::NoFocus); /* Prepare mdi-area: */ m_pMdiArea = new QMdiArea; { /* Configure own background: */ QPalette pal = m_pMdiArea->palette(); pal.setColor(QPalette::Window, QColor(Qt::transparent)); m_pMdiArea->setPalette(pal); /* Configure viewport background: */ m_pMdiArea->setBackground(QColor(Qt::transparent)); /* Layout mdi-area according parent-widget: */ QVBoxLayout *pMainLayout = new QVBoxLayout(this); pMainLayout->setContentsMargins(0, 0, 0, 0); pMainLayout->addWidget(m_pMdiArea); /* Make sure we have no focus: */ m_pMdiArea->setFocusPolicy(Qt::NoFocus); m_pMdiArea->viewport()->setFocusPolicy(Qt::NoFocus); } /* Prepare mini-toolbar: */ m_pToolbar = new UIMiniToolBar; { /* Propagate known options to child: */ m_pToolbar->setAutoHide(m_fAutoHide); m_pToolbar->setAlignment(m_alignment); m_pToolbar->setIntegrationMode(m_integrationMode); /* Configure own background: */ QPalette pal = m_pToolbar->palette(); pal.setColor(QPalette::Window, palette().color(QPalette::Window)); m_pToolbar->setPalette(pal); /* Configure child connections: */ connect(m_pToolbar, SIGNAL(sigResized()), this, SLOT(sltHandleToolbarResize())); connect(m_pToolbar, SIGNAL(sigAutoHideToggled()), this, SLOT(sltAutoHideToggled())); connect(m_pToolbar, SIGNAL(sigMinimizeAction()), this, SIGNAL(sigMinimizeAction())); connect(m_pToolbar, SIGNAL(sigExitAction()), this, SIGNAL(sigExitAction())); connect(m_pToolbar, SIGNAL(sigCloseAction()), this, SIGNAL(sigCloseAction())); /* Add child to mdi-area: */ m_pEmbeddedToolbar = m_pMdiArea->addSubWindow(m_pToolbar, Qt::Window | Qt::FramelessWindowHint); /* Make sure we have no focus: */ m_pToolbar->setFocusPolicy(Qt::NoFocus); m_pEmbeddedToolbar->setFocusPolicy(Qt::NoFocus); } /* Prepare hover-enter/leave timers: */ m_pHoverEnterTimer = new QTimer(this); { m_pHoverEnterTimer->setSingleShot(true); m_pHoverEnterTimer->setInterval(50); connect(m_pHoverEnterTimer, SIGNAL(timeout()), this, SLOT(sltHoverEnter())); } m_pHoverLeaveTimer = new QTimer(this); { m_pHoverLeaveTimer->setSingleShot(true); m_pHoverLeaveTimer->setInterval(500); connect(m_pHoverLeaveTimer, SIGNAL(timeout()), this, SLOT(sltHoverLeave())); } /* Install 'auto-hide' animation to 'toolbarPosition' property: */ m_pAnimation = UIAnimation::installPropertyAnimation(this, "toolbarPosition", "hiddenToolbarPosition", "shownToolbarPosition", SIGNAL(sigHoverEnter()), SIGNAL(sigHoverLeave()), true); /* Integrate if necessary: */ integrate(); /* Adjust geometry finally: */ adjustGeometry(); }