Пример #1
0
qwDecoratedCanvas::qwDecoratedCanvas(int defSelBvr, panelID myID, QWidget *parent): QWidget(parent), defaultSelectionBehavior(defSelBvr)
{

   this->myID = myID;

   myGridCanvasPtr  = new qwGridCanvas(this);
   myBottomPanelPtr = new qwBottomPanel(this);
   myThumbnailListPtr = new qwPickUpList(this);

   setMinimumWidth(UI_MIN_PANEL_WIDTH);
   setMinimumHeight(UI_MIN_PANEL_HEIGHT);

   myLayout.setSpacing(0);
   myLayout.setContentsMargins(0, 0, 0, 0);

   myGridCanvasPtr->setSizePolicy(QSizePolicy::Expanding, QSizePolicy::Expanding);
   myBottomPanelPtr->setSizePolicy(QSizePolicy::Expanding, QSizePolicy::Fixed);
   myThumbnailListPtr->setSizePolicy(QSizePolicy::Expanding, QSizePolicy::Fixed);
   myThumbnailListPtr->clear();
   myThumbnailListPtr->setContentsMargins(0, 0, 0, 0);

   myBottomPanelPtr->thumbnailsBarButtonPtr->setChecked(true);

   myLayout.addWidget(myGridCanvasPtr);
   myLayout.addWidget(myBottomPanelPtr);
   myLayout.addWidget(myThumbnailListPtr, 0, Qt::AlignBottom);
   setLayout(&myLayout);

   setFocusPolicy(Qt::ClickFocus);

   if(myID == panelLeftTop)
       focusInEvent(0);
}
Пример #2
0
void QDateEdit_QtDShell::__override_focusInEvent(QFocusEvent*  event0, bool static_call)
{
    if (static_call) {
        QDateTimeEdit::focusInEvent((QFocusEvent* )event0);
    } else {
        focusInEvent((QFocusEvent* )event0);
    }
}
Пример #3
0
void QStatusBar_QtDShell::__override_focusInEvent(QFocusEvent*  arg__1, bool static_call)
{
    if (static_call) {
        QWidget::focusInEvent((QFocusEvent* )arg__1);
    } else {
        focusInEvent((QFocusEvent* )arg__1);
    }
}
void QGraphicsEllipseItem_QtDShell::__override_focusInEvent(QFocusEvent*  event0, bool static_call)
{
    if (static_call) {
        QGraphicsItem::focusInEvent((QFocusEvent* )event0);
    } else {
        focusInEvent((QFocusEvent* )event0);
    }
}
Пример #5
0
void QFontComboBox_QtDShell::__override_focusInEvent(QFocusEvent*  e0, bool static_call)
{
    if (static_call) {
        QComboBox::focusInEvent((QFocusEvent* )e0);
    } else {
        focusInEvent((QFocusEvent* )e0);
    }
}
void QAbstractPageSetupDialog_QtDShell::__override_focusInEvent(QFocusEvent*  arg__1, bool static_call)
{
    if (static_call) {
        QWidget::focusInEvent((QFocusEvent* )arg__1);
    } else {
        focusInEvent((QFocusEvent* )arg__1);
    }
}
Пример #7
0
Qt5RegistersView::Qt5RegistersView(Qt5MainWindow* mainWindow, Qt5DockWidget* dock, Qt5DynamicView* parent)
    : Qt5BaseView(mainWindow, dock, parent)
{
    m_type = Qt5ViewType_Registers;

    focusInEvent(nullptr);

    m_locals = new Qt5Registers(this);
    m_locals->setFocusProxy(this);

    createFrameEmbedWidget(m_locals, "Registers");
}
Пример #8
0
Qt5CallStackView::Qt5CallStackView(Qt5MainWindow* mainWindow, Qt5DockWidget* dock, Qt5DynamicView* parent)
    : Qt5BaseView(mainWindow, dock, parent)
{
    m_type = Qt5ViewType_CallStack;

    focusInEvent(nullptr);

    m_callStack = new Qt5CallStack(this);
    m_callStack->setFocusProxy(this);

    createFrameEmbedWidget(m_callStack, "Call Stack");

    connect(m_callStack, SIGNAL(customContextMenuRequested(const QPoint &)), this, SLOT(contextMenuProxy(const QPoint &)));
}
		void bc_editor_app::changeEvent(QEvent* p_event)
		{
			if (p_event->type() == QEvent::WindowStateChange)
			{
				QWindowStateChangeEvent* l_window_state_event = static_cast<QWindowStateChangeEvent*>(p_event);
				m_d3d_widget->window_state_change_event(l_window_state_event, windowState());
			}

			if (p_event->type() == QEvent::ActivationChange)
			{
				if (isActiveWindow())
				{
					QFocusEvent l_focus_event(QEvent::FocusIn);
					focusInEvent(&l_focus_event);
				}
				else
				{
					QFocusEvent l_focus_event(QEvent::FocusOut);
					focusOutEvent(&l_focus_event);
				}
			}

			QWidget::changeEvent(p_event);
		}
Пример #10
0
void DhQGraphicsScene::DvhfocusInEvent(QFocusEvent* x1) {
  return focusInEvent(x1);
}
Пример #11
0
void DhQPushButton::DvhfocusInEvent(QFocusEvent* x1) {
  return focusInEvent(x1);
}
Пример #12
0
void DhQGroupBox::DvhfocusInEvent(QFocusEvent* x1) {
  return focusInEvent(x1);
}
Пример #13
0
void DhQScrollArea::DvhfocusInEvent(QFocusEvent* x1) {
  return focusInEvent(x1);
}
Пример #14
0
void DhQStackedWidget::DvhfocusInEvent(QFocusEvent* x1) {
    return focusInEvent(x1);
}
Пример #15
0
bool CLockedEdit::eventFilter(QObject *object, QEvent *event)
{
   if ( event->type() == QEvent::Show )
   {
      showEvent(dynamic_cast<QShowEvent*>(event));
      return true;
   }
   if ( event->type() == QEvent::ShowToParent )
   {
      showEvent(dynamic_cast<QShowEvent*>(event));
      return true;
   }
   if ( event->type() == QEvent::Hide )
   {
      hideEvent(dynamic_cast<QHideEvent*>(event));
      return true;
   }
   if ( event->type() == QEvent::Move )
   {
      moveEvent(dynamic_cast<QMoveEvent*>(event));
      return true;
   }
   if ( event->type() == QEvent::Paint )
   {
      paintEvent(dynamic_cast<QPaintEvent*>(event));
      return true;
   }
   if ( event->type() == QEvent::FocusIn )
   {
      focusInEvent(dynamic_cast<QFocusEvent*>(event));
      return true;
   }
   if ( event->type() == QEvent::FocusOut )
   {
      focusOutEvent(dynamic_cast<QFocusEvent*>(event));
      return true;
   }
   if ( event->type() == QEvent::MouseButtonPress )
   {
      mousePressEvent(dynamic_cast<QMouseEvent*>(event));
      return true;
   }
   if ( event->type() == QEvent::MouseButtonRelease )
   {
      mouseReleaseEvent(dynamic_cast<QMouseEvent*>(event));
      return true;
   }
   if ( event->type() == QEvent::MouseButtonDblClick )
   {
      mouseDoubleClickEvent(dynamic_cast<QMouseEvent*>(event));
      return true;
   }
   if ( event->type() == QEvent::MouseMove )
   {
      mouseMoveEvent(dynamic_cast<QMouseEvent*>(event));
      return true;
   }
   if ( event->type() == QEvent::Wheel )
   {
      wheelEvent(dynamic_cast<QWheelEvent*>(event));
      return true;
   }
   if ( event->type() == QEvent::Resize )
   {
      resizeEvent(dynamic_cast<QResizeEvent*>(event));
      return true;
   }
   if ( event->type() == QEvent::KeyPress )
   {
      keyPressEvent(dynamic_cast<QKeyEvent*>(event));
      return true;
   }
   if ( event->type() == QEvent::KeyRelease )
   {
      keyReleaseEvent(dynamic_cast<QKeyEvent*>(event));
      return true;
   }
//   qDebug("eventFilter: unhandled %d object %s", event->type(), object->objectName().toAscii().constData());
   return false;
}
Пример #16
0
void DhQGraphicsItemGroup::DvhfocusInEvent(QFocusEvent* x1) {
  return focusInEvent(x1);
}
Пример #17
0
void DhQSlider::DvhfocusInEvent(QFocusEvent* x1) {
  return focusInEvent(x1);
}
Пример #18
0
void DhQAbstractSpinBox::DvhfocusInEvent(QFocusEvent* x1) {
  return focusInEvent(x1);
}
Пример #19
0
void DhQGraphicsEllipseItem::DvhfocusInEvent(QFocusEvent* x1) {
  return focusInEvent(x1);
}
Пример #20
0
void DhQGLWidget::DvhfocusInEvent(QFocusEvent* x1) {
  return focusInEvent(x1);
}
Пример #21
0
Qt5HexEditView::Qt5HexEditView(Qt5MainWindow* mainWindow, Qt5DockWidget* dock, Qt5DynamicView* parent)
    : Qt5BaseView(mainWindow, dock, parent)
{
    m_type = Qt5ViewType_HexEdit;

    focusInEvent(nullptr);

    m_hexEdit = new Qt5HexEditWidget(this);
    m_hexEdit->setFocusProxy(this);

    createFrameEmbedWidget(m_hexEdit, "Memory");

    connect(m_hexEdit, SIGNAL(customContextMenuRequested(const QPoint &)), this, SLOT(contextMenuProxy(const QPoint &)));

    // \todo: this code is awful

    m_statusBar = new QStatusBar(m_hexEdit);

    // Address Label
    m_addressNameLabel = new QLabel();
    m_addressNameLabel->setText(tr("Address:"));
    m_statusBar->addPermanentWidget(m_addressNameLabel);

    m_addressLabel = new QLabel();
    m_addressLabel->setFrameShape(QFrame::Panel);
    m_addressLabel->setFrameShadow(QFrame::Sunken);
    m_addressLabel->setMinimumWidth(70);
    m_statusBar->addPermanentWidget(m_addressLabel);

    connect(m_hexEdit, SIGNAL(currentAddressChanged(int)), this, SLOT(setAddress(int)));

    // Size Label
    m_sizeNameLabel = new QLabel();
    m_sizeNameLabel->setText(tr("Size:"));
    m_statusBar->addPermanentWidget(m_sizeNameLabel);

    m_sizeLabel = new QLabel();
    m_sizeLabel->setFrameShape(QFrame::Panel);
    m_sizeLabel->setFrameShadow(QFrame::Sunken);
    m_sizeLabel->setMinimumWidth(70);
    m_statusBar->addPermanentWidget(m_sizeLabel);

    connect(m_hexEdit, SIGNAL(currentSizeChanged(int)), this, SLOT(setSize(int)));

    // Overwrite Mode Label
    m_overwriteModeNameLabel = new QLabel();
    m_overwriteModeNameLabel->setText(tr("Mode:"));
    m_statusBar->addPermanentWidget(m_overwriteModeNameLabel);

    m_overwriteModeLabel = new QLabel();
    m_overwriteModeLabel->setFrameShape(QFrame::Panel);
    m_overwriteModeLabel->setFrameShadow(QFrame::Sunken);
    m_overwriteModeLabel->setMinimumWidth(70);
    m_statusBar->addPermanentWidget(m_overwriteModeLabel);

    //setOverwriteMode(m_hexEdit->getOverwriteMode());

    m_statusBar->showMessage(tr("Ready"));

    testEditor();
}