当前位置: 首页>>代码示例>>C++>>正文


C++ showPopup函数代码示例

本文整理汇总了C++中showPopup函数的典型用法代码示例。如果您正苦于以下问题:C++ showPopup函数的具体用法?C++ showPopup怎么用?C++ showPopup使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。


在下文中一共展示了showPopup函数的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。

示例1: showPopup

bool DocumentWindow::loadDocument(const QString& path)
{
    if (!closeDocument())
    {
        return false;
    }

    const QFile::FileError loading = m_document.loadFromFile(path);
    if (loading != QFile::NoError)
    {
        showPopup(tr("Error"), tr("Failed to load file: %1").arg(path));
        return false;
    }

    m_path = path;
    m_synchronized = true;

    setWindowTitle(separateName(path));

    setDocumentModel();

    emit documentLoaded(path);

    return true;
}
开发者ID:vladpyslaru,项目名称:cross-class,代码行数:25,代码来源:DocumentWindow.cpp

示例2: beginDragAutoRepeat

void ComboBox::mouseDrag (const MouseEvent& e)
{
    beginDragAutoRepeat (50);

    if (isButtonDown && ! e.mouseWasClicked())
        showPopup();
}
开发者ID:sonic59,项目名称:JuceEditor,代码行数:7,代码来源:juce_ComboBox.cpp

示例3: getSelectedItemIndex

//==============================================================================
bool ComboBox::keyPressed (const KeyPress& key)
{
    if (key.isKeyCode (KeyPress::upKey) || key.isKeyCode (KeyPress::leftKey))
    {
        int index = getSelectedItemIndex() - 1;

        while (index >= 0 && ! selectIfEnabled (index))
            --index;

        return true;
    }
    else if (key.isKeyCode (KeyPress::downKey) || key.isKeyCode (KeyPress::rightKey))
    {
        int index = getSelectedItemIndex() + 1;

        while (index < getNumItems() && ! selectIfEnabled (index))
            ++index;

        return true;
    }
    else if (key.isKeyCode (KeyPress::returnKey))
    {
        showPopup();
        return true;
    }

    return false;
}
开发者ID:sonic59,项目名称:JuceEditor,代码行数:29,代码来源:juce_ComboBox.cpp

示例4: QMainWindow

menix::menix(QWidget *parent) :
        QMainWindow(parent),
        m_ui(new Ui::menix) {
    m_ui->setupUi(this);


    QToolBar *toolbarIconos = addToolBar(tr("Iconos"));
    toolbarIconos->addAction(QIcon(":/preferences-system.png"),"Opciones",this,SLOT( abrirOpciones() ) );
    toolbarIconos->addAction(QIcon(":/terminal.png"),"Debug",this,SLOT(abrirDebug()));

    opciones = new opcionesGlobales();
    numero = opciones->NumeroDestino();
    puerto = opciones->Puerto();
    pin = opciones->Pin();
    centro = opciones->CentroMensajes();
    fixok = opciones->Fixok();
    
    ips = new QStringList( opciones->Ips() );

    file = new QFile( opciones->fileLog() );
    file->open( QIODevice::WriteOnly | QIODevice::Text );
    flog = new QTextStream( file );
    
    mensaje = new smsat(centro,puerto,flog,pin,fixok);
    crearAcciones();
    crearBandeja();
//    testPuerto( mensaje );
    Server *tcp = new Server(ips,this);
    connect(tcp,SIGNAL(sendMessage(QString)),this,SLOT(sendMessage(QString)));
    connect(mensaje,SIGNAL(sendAt(QString)),this,SLOT(sendedMessage(QString)));
    connect(mensaje,SIGNAL(displayMsg(QString)),this,SLOT(showPopup(QString)));
}
开发者ID:josacar,项目名称:menix,代码行数:32,代码来源:menix.cpp

示例5: setFrameRect

void PopupContainer::showInRect(const FloatQuad& controlPosition, const IntSize& controlSize, FrameView* v, int index)
{
    // The controlSize is the size of the select box. It's usually larger than
    // we need. Subtract border size so that usually the container will be
    // displayed exactly the same width as the select box.
    m_listBox->setBaseWidth(max(controlSize.width() - borderSize * 2, 0));

    m_listBox->updateFromElement();

    // We set the selected item in updateFromElement(), and disregard the
    // index passed into this function (same as Webkit's PopupMenuWin.cpp)
    // FIXME: make sure this is correct, and add an assertion.
    // ASSERT(popupWindow(popup)->listBox()->selectedIndex() == index);

    // Save and convert the controlPosition to main window coords. Each point is converted separately
    // to window coordinates because the control could be in a transformed webview and then each point
    // would be transformed by a different delta.
    m_controlPosition.setP1(v->contentsToWindow(IntPoint(controlPosition.p1().x(), controlPosition.p1().y())));
    m_controlPosition.setP2(v->contentsToWindow(IntPoint(controlPosition.p2().x(), controlPosition.p2().y())));
    m_controlPosition.setP3(v->contentsToWindow(IntPoint(controlPosition.p3().x(), controlPosition.p3().y())));
    m_controlPosition.setP4(v->contentsToWindow(IntPoint(controlPosition.p4().x(), controlPosition.p4().y())));

    m_controlSize = controlSize;

    // Position at (0, 0) since the frameRect().location() is relative to the
    // parent WebWidget.
    setFrameRect(IntRect(IntPoint(), controlSize));
    showPopup(v);
}
开发者ID:335969568,项目名称:Blink-1,代码行数:29,代码来源:PopupContainer.cpp

示例6: QKeySequence

void QxtLookupLineEdit::keyPressEvent ( QKeyEvent * event )
{
    QKeySequence currSeq = QKeySequence(event->key() | event->modifiers());
    if(currSeq.matches(qxt_d().m_trigger))
        showPopup ();
    else
        QLineEdit::keyPressEvent(event);
}
开发者ID:develnk,项目名称:qxtweb-qt5,代码行数:8,代码来源:qxtlookuplineedit.cpp

示例7: showPopup

//==============================================================================
void ComboBox::showPopupIfNotActive()
{
    if (! menuActive)
    {
        menuActive = true;
        showPopup();
    }
}
开发者ID:AndyJBuchanan,项目名称:dexed,代码行数:9,代码来源:juce_ComboBox.cpp

示例8: qDebug

/**
 * @brief Slot connected to MarblePopupItem::editAlbumSignal
 * @param p_marker_id
 * @param p_album_id
 */
void MarbleMap::editAlbumSlot(int p_marker_id, int p_album_id)
{
#ifdef DBG_MARBLE_MAP
  qDebug() << "MarbleMap::editAlbumSlot(" << p_marker_id << "," << p_album_id << ")";
#endif
  destroyPopup();
  showPopup(m_current_marker, EDIT_ALBUM, p_album_id);
}
开发者ID:GiancarloF,项目名称:POM,代码行数:13,代码来源:marblemap.cpp

示例9: showPopup

void StackFolder::timerEvent(QTimerEvent *event)
{
    if (event->timerId() == m_delayedShowTimer.timerId()) {
        m_delayedShowTimer.stop();
        showPopup();
    }
    Plasma::PopupApplet::timerEvent(event);
}
开发者ID:KDE,项目名称:stackfolder,代码行数:8,代码来源:stackfolder.cpp

示例10: hidePopup

void pTreeComboBox::mousePressEvent( QMouseEvent* event )
{
    if ( mView ) {
        mFrame->isVisible() ? hidePopup() : showPopup();
    }
    
    QWidget::mousePressEvent( event );
}
开发者ID:pasnox,项目名称:fresh,代码行数:8,代码来源:pTreeComboBox.cpp

示例11: showPopup

void GameScene::buyTimer(CCObject* pSender ,cocos2d::ui::TouchEventType type) {
    if (type == cocos2d::ui::TOUCH_EVENT_ENDED) {
        if(GameManager::getXu() >= 3) {
            //buy xu
            GameManager::addXu(-3);
            GameManager::addTimer(2);
            showPopup(popupBuyItem,false);
            validateTimer();
            lb_xu->setText(Utils::convertIntToChar(GameManager::getXu()));
        } else {
            //native jni call function
//		Utils::sendSms5k("callbackSMS");
            showPopup(popupBuyItem,false);

        }
    }
}
开发者ID:meocondilonton,项目名称:game,代码行数:17,代码来源:GameScene.cpp

示例12: findById

void QuickOpenManager::showById(const QString &id)
{
    IQuickOpen *i = findById(id);
    if (i) {
        setCurrentFilter(i);
        showPopup();
    }
}
开发者ID:vovkasm,项目名称:liteide,代码行数:8,代码来源:quickopenmanager.cpp

示例13: showPopup

void QFontComboBox_QtDShell::__override_showPopup(bool static_call)
{
    if (static_call) {
        QComboBox::showPopup();
    } else {
        showPopup();
    }
}
开发者ID:dreamsxin,项目名称:nawia,代码行数:8,代码来源:QFontComboBox_shell.cpp

示例14: showPopup

bool PHIAComboBox::event( QEvent *e )
{
    if ( e->type()==QEvent::MouseButtonPress || e->type()==QEvent::MouseButtonDblClick ) {
        showPopup();
        e->ignore();
        return true;
    }
    return QComboBox::event( e );
}
开发者ID:Phisketeer,项目名称:phisketeer,代码行数:9,代码来源:phiacomboboxhack.cpp

示例15: beginDragAutoRepeat

//==============================================================================
void ComboBox::mouseDown (const MouseEvent& e)
{
    beginDragAutoRepeat (300);

    isButtonDown = isEnabled() && ! e.mods.isPopupMenu();

    if (isButtonDown && (e.eventComponent == this || ! label->isEditable()))
        showPopup();
}
开发者ID:sonic59,项目名称:JuceS1Text,代码行数:10,代码来源:juce_ComboBox.cpp


注:本文中的showPopup函数示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。