本文整理汇总了C++中closed函数的典型用法代码示例。如果您正苦于以下问题:C++ closed函数的具体用法?C++ closed怎么用?C++ closed使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了closed函数的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的C++代码示例。
示例1: closed
void ConnectionBox::onCancel() {
emit closed();
}
开发者ID:2k13yr,项目名称:tdesktop,代码行数:3,代码来源:connectionbox.cpp
示例2: closed
void DialogSecuritySubscriptions::on_pushButtonCancel_clicked()
{
emit closed();
close();
}
开发者ID:aboduo,项目名称:quazaa,代码行数:5,代码来源:dialogsecuritysubscriptions.cpp
示例3: allocateRegs
void BackEnd::genCodeImpl(IRUnit& unit, AsmInfo* asmInfo) {
ctr++;
auto regs = allocateRegs(unit);
assert(checkRegisters(unit, regs)); // calls checkCfg internally.
Timer _t(Timer::codeGen);
LiveRegs live_regs = computeLiveRegs(unit, regs);
CodegenState state(unit, regs, live_regs, asmInfo);
CodeBlock& mainCodeIn = mcg->code.main();
CodeBlock& coldCodeIn = mcg->code.cold();
CodeBlock* frozenCode = &mcg->code.frozen();
CodeBlock mainCode;
CodeBlock coldCode;
bool relocate = false;
if (RuntimeOption::EvalJitRelocationSize &&
supportsRelocation() &&
coldCodeIn.canEmit(RuntimeOption::EvalJitRelocationSize * 3)) {
/*
* This is mainly to exercise the relocator, and ensure that its
* not broken by new non-relocatable code. Later, it will be
* used to do some peephole optimizations, such as reducing branch
* sizes.
* Allocate enough space that the relocated cold code doesn't
* overlap the emitted cold code.
*/
static unsigned seed = 42;
auto off = rand_r(&seed) & (cacheLineSize() - 1);
coldCode.init(coldCodeIn.frontier() +
RuntimeOption::EvalJitRelocationSize + off,
RuntimeOption::EvalJitRelocationSize - off, "cgRelocCold");
mainCode.init(coldCode.frontier() +
RuntimeOption::EvalJitRelocationSize + off,
RuntimeOption::EvalJitRelocationSize - off, "cgRelocMain");
relocate = true;
} else {
/*
* Use separate code blocks, so that attempts to use the mcg's
* code blocks directly will fail (eg by overwriting the same
* memory being written through these locals).
*/
coldCode.init(coldCodeIn.frontier(), coldCodeIn.available(),
coldCodeIn.name().c_str());
mainCode.init(mainCodeIn.frontier(), mainCodeIn.available(),
mainCodeIn.name().c_str());
}
if (frozenCode == &coldCodeIn) {
frozenCode = &coldCode;
}
auto frozenStart = frozenCode->frontier();
auto coldStart DEBUG_ONLY = coldCodeIn.frontier();
auto mainStart DEBUG_ONLY = mainCodeIn.frontier();
size_t hhir_count{0};
{
mcg->code.lock();
mcg->cgFixups().setBlocks(&mainCode, &coldCode, frozenCode);
SCOPE_EXIT {
mcg->cgFixups().setBlocks(nullptr, nullptr, nullptr);
mcg->code.unlock();
};
if (RuntimeOption::EvalHHIRGenerateAsserts) {
emitTraceCall(mainCode, unit.bcOff());
}
auto const linfo = layoutBlocks(unit);
auto main_start = mainCode.frontier();
auto cold_start = coldCode.frontier();
auto frozen_start = frozenCode->frontier();
Vasm vasm(&state.meta);
auto& vunit = vasm.unit();
// create the initial set of vasm numbered the same as hhir blocks.
for (uint32_t i = 0, n = unit.numBlocks(); i < n; ++i) {
state.labels[i] = vunit.makeBlock(AreaIndex::Main);
}
vunit.roots.push_back(state.labels[unit.entry()]);
vasm.main(mainCode);
vasm.cold(coldCode);
vasm.frozen(*frozenCode);
for (auto it = linfo.blocks.begin(); it != linfo.blocks.end(); ++it) {
auto block = *it;
auto v = block->hint() == Block::Hint::Unlikely ? vasm.cold() :
block->hint() == Block::Hint::Unused ? vasm.frozen() :
vasm.main();
FTRACE(6, "genBlock {} on {}\n", block->id(),
area_names[(unsigned)v.area()]);
auto b = state.labels[block];
vunit.blocks[b].area = v.area();
v.use(b);
hhir_count += genBlock(unit, v, vasm, state, block);
assert(v.closed());
assert(vasm.main().empty() || vasm.main().closed());
assert(vasm.cold().empty() || vasm.cold().closed());
assert(vasm.frozen().empty() || vasm.frozen().closed());
}
//.........这里部分代码省略.........
开发者ID:Ruwan-Ranganath,项目名称:hhvm,代码行数:101,代码来源:back-end-x64.cpp
示例4: closed
void DeviceCollectionWND::closeEvent(QCloseEvent *e)
{
QWidget::closeEvent( e );
emit closed();
}
开发者ID:firef0xff,项目名称:SSHGS01,代码行数:5,代码来源:device_collection_wnd.cpp
示例5: closed
void TypeTypeForm::applyClicked()
{
m_type->setNote(m_textNote->toPlainText());
emit closed(m_op, QVarPtr<TypeType>::asQVariant(m_type));
}
开发者ID:Nazardo,项目名称:QEbu,代码行数:5,代码来源:typetypeform.cpp
示例6: closed
void FixtureConsole::closeEvent(QCloseEvent* e)
{
emit closed();
}
开发者ID:speakman,项目名称:qlc,代码行数:4,代码来源:fixtureconsole.cpp
示例7: closed
void SynthControl::closeEvent(QCloseEvent* ev)
{
emit closed(false);
QWidget::closeEvent(ev);
}
开发者ID:FryderykChopin,项目名称:MuseScore,代码行数:5,代码来源:synthcontrol.cpp
示例8: showMainWindow
void MainWindowPlugin::onOptionsChanged(const OptionsNode &ANode)
{
QWidget * widget = FMainWindowBorder ? (QWidget*)FMainWindowBorder : (QWidget*)FMainWindow;
if (ANode.path() == OPV_MAINWINDOW_STAYONTOP)
{
bool show = widget->isVisible();
if (ANode.value().toBool())
widget->setWindowFlags(widget->windowFlags() | Qt::WindowStaysOnTopHint);
else
widget->setWindowFlags(widget->windowFlags() & ~Qt::WindowStaysOnTopHint);
if (show)
showMainWindow();
}
#ifdef Q_OS_WIN
else if (ANode.path() == OPV_MAINWINDOW_MINIMIZETOTRAY_W7)
{
if (QSysInfo::windowsVersion() == QSysInfo::WV_WINDOWS7)
{
bool minimize = ANode.value().toBool();
FMainWindowBorder->setMinimizeOnClose(!minimize);
FMainWindowBorder->setShowInTaskBar(!minimize);
if (minimize)
disconnect(FMainWindowBorder ? (QObject*)FMainWindowBorder : (QObject*)FMainWindow, SIGNAL(closed()), this, SLOT(onMainWindowClosed()));
else
connect(FMainWindowBorder ? (QObject*)FMainWindowBorder : (QObject*)FMainWindow, SIGNAL(closed()), SLOT(onMainWindowClosed()));
}
else
FMainWindowBorder->setShowInTaskBar(false);
}
#endif
}
开发者ID:Rambler-ru,项目名称:Contacts,代码行数:31,代码来源:mainwindowplugin.cpp
示例9: closePressed
void AbstractBox::onClose() {
closePressed();
emit closed();
}
开发者ID:neuroidss,项目名称:tdesktop,代码行数:4,代码来源:abstractbox.cpp
示例10: closed
void PlayPanel::closeEvent(QCloseEvent* ev)
{
emit closed(false);
QWidget::closeEvent(ev);
}
开发者ID:Fyrult,项目名称:MuseScore,代码行数:5,代码来源:playpanel.cpp
示例11: closed
void Tuning::prepareRemove()
{
glView_->destroy();
emit closed(index_);
}
开发者ID:flair2005,项目名称:omnidome,代码行数:5,代码来源:Tuning.cpp
示例12: closed
void CDialogCreateTorrent::on_pushButtonSave_clicked()
{
emit closed();
close();
}
开发者ID:c3c,项目名称:quazaa,代码行数:5,代码来源:dialogcreatetorrent.cpp
示例13: MainWindow
void ClientApplication::showMainWindow() {
mainWindow = new MainWindow();
connect(mainWindow, SIGNAL(closed()), SLOT(quit()));
mainWindow->show();
}
开发者ID:odelande,项目名称:QGameTrainer,代码行数:5,代码来源:ClientApplication.cpp
示例14: QMainWindow
MainWindow::MainWindow()
: QMainWindow(0)
, ui(new Ui::MainWindow)
, m_isKKeyPressed(false)
{
// Create the UI.
ui->setupUi(this);
#ifndef Q_WS_X11
ui->mainToolBar->setToolButtonStyle(Qt::ToolButtonTextUnderIcon);
#endif
setCorner(Qt::TopLeftCorner, Qt::LeftDockWidgetArea);
setCorner(Qt::TopRightCorner, Qt::RightDockWidgetArea);
setDockNestingEnabled(true);
// These use the icon theme on Linux, with fallbacks to the icons specified in QtDesigner for other platforms.
ui->actionOpen->setIcon(QIcon::fromTheme("document-open", ui->actionOpen->icon()));
ui->actionSave->setIcon(QIcon::fromTheme("document-save", ui->actionSave->icon()));
ui->actionEncode->setIcon(QIcon::fromTheme("media-record", ui->actionEncode->icon()));
// Connect UI signals.
connect(ui->actionOpen, SIGNAL(triggered()), this, SLOT(openVideo()));
connect(ui->actionAbout_Qt, SIGNAL(triggered()), qApp, SLOT(aboutQt()));
// Accept drag-n-drop of files.
this->setAcceptDrops(true);
// Add the player widget.
QLayout* layout = new QVBoxLayout(ui->playerPage);
layout->setObjectName("centralWidgetLayout");
layout->setMargin(0);
m_player = new Player(this);
layout->addWidget(m_player);
connect(this, SIGNAL(producerOpened()), m_player, SLOT(onProducerOpened()));
connect(m_player, SIGNAL(showStatusMessage(QString)), this, SLOT(showStatusMessage(QString)));
connect(m_player, SIGNAL(inChanged(int)), this, SLOT(onCutModified()));
connect(m_player, SIGNAL(outChanged(int)), this, SLOT(onCutModified()));
// Add the docks.
m_propertiesDock = new QDockWidget(tr("Properties"));
m_propertiesDock->hide();
m_propertiesDock->setObjectName("propertiesDock");
m_propertiesDock->setWindowIcon(QIcon((":/icons/icons/view-form.png")));
m_propertiesDock->toggleViewAction()->setIcon(QIcon::fromTheme("view-form", m_propertiesDock->windowIcon()));
addDockWidget(Qt::LeftDockWidgetArea, m_propertiesDock);
ui->menuView->addAction(m_propertiesDock->toggleViewAction());
ui->mainToolBar->addAction(m_propertiesDock->toggleViewAction());
connect(m_propertiesDock->toggleViewAction(), SIGNAL(triggered(bool)), this, SLOT(onPropertiesDockTriggered(bool)));
m_recentDock = new RecentDock(this);
m_recentDock->hide();
addDockWidget(Qt::LeftDockWidgetArea, m_recentDock);
ui->menuView->addAction(m_recentDock->toggleViewAction());
ui->mainToolBar->addAction(m_recentDock->toggleViewAction());
connect(m_recentDock, SIGNAL(itemActivated(QString)), this, SLOT(open(QString)));
connect(m_recentDock->toggleViewAction(), SIGNAL(triggered(bool)), this, SLOT(onRecentDockTriggered(bool)));
m_playlistDock = new PlaylistDock(this);
m_playlistDock->hide();
addDockWidget(Qt::LeftDockWidgetArea, m_playlistDock);
ui->menuView->addAction(m_playlistDock->toggleViewAction());
ui->mainToolBar->addAction(m_playlistDock->toggleViewAction());
connect(m_playlistDock->toggleViewAction(), SIGNAL(triggered(bool)), this, SLOT(onPlaylistDockTriggered(bool)));
connect(m_playlistDock, SIGNAL(clipOpened(void*,int,int)), this, SLOT(openCut(void*, int, int)));
connect(m_playlistDock, SIGNAL(itemActivated(int)), this, SLOT(seekPlaylist(int)));
connect(m_playlistDock, SIGNAL(showStatusMessage(QString)), this, SLOT(showStatusMessage(QString)));
connect(m_playlistDock->model(), SIGNAL(created()), this, SLOT(onPlaylistCreated()));
connect(m_playlistDock->model(), SIGNAL(cleared()), this, SLOT(onPlaylistCleared()));
connect(m_playlistDock->model(), SIGNAL(closed()), this, SLOT(onPlaylistClosed()));
connect(m_playlistDock->model(), SIGNAL(modified()), this, SLOT(onPlaylistModified()));
connect(m_playlistDock->model(), SIGNAL(loaded()), this, SLOT(updateMarkers()));
connect(m_playlistDock->model(), SIGNAL(modified()), this, SLOT(updateMarkers()));
tabifyDockWidget(m_recentDock, m_propertiesDock);
tabifyDockWidget(m_propertiesDock, m_playlistDock);
m_recentDock->raise();
m_encodeDock = new EncodeDock(this);
m_encodeDock->hide();
addDockWidget(Qt::RightDockWidgetArea, m_encodeDock);
ui->menuView->addAction(m_encodeDock->toggleViewAction());
ui->mainToolBar->addAction(ui->actionEncode);
connect(this, SIGNAL(producerOpened()), m_encodeDock, SLOT(onProducerOpened()));
connect(m_encodeDock, SIGNAL(visibilityChanged(bool)), ui->actionEncode, SLOT(setChecked(bool)));
connect(m_encodeDock, SIGNAL(captureStateChanged(bool)), m_player, SLOT(onCaptureStateChanged(bool)));
connect(m_encodeDock, SIGNAL(captureStateChanged(bool)), m_propertiesDock, SLOT(setDisabled(bool)));
connect(m_encodeDock, SIGNAL(captureStateChanged(bool)), m_recentDock, SLOT(setDisabled(bool)));
connect(m_encodeDock, SIGNAL(captureStateChanged(bool)), ui->actionOpen, SLOT(setDisabled(bool)));
connect(m_encodeDock, SIGNAL(captureStateChanged(bool)), ui->actionOpenOther, SLOT(setDisabled(bool)));
connect(m_encodeDock, SIGNAL(captureStateChanged(bool)), ui->actionExit, SLOT(setDisabled(bool)));
connect(m_encodeDock, SIGNAL(captureStateChanged(bool)), this, SLOT(onCaptureStateChanged(bool)));
m_jobsDock = new JobsDock(this);
m_jobsDock->hide();
addDockWidget(Qt::RightDockWidgetArea, m_jobsDock);
tabifyDockWidget(m_encodeDock, m_jobsDock);
ui->menuView->addAction(m_jobsDock->toggleViewAction());
connect(&JOBS, SIGNAL(jobAdded()), m_jobsDock, SLOT(show()));
connect(&JOBS, SIGNAL(jobAdded()), m_jobsDock, SLOT(raise()));
connect(m_jobsDock, SIGNAL(visibilityChanged(bool)), this, SLOT(onJobsVisibilityChanged(bool)));
//.........这里部分代码省略.........
开发者ID:deedos,项目名称:shotcut,代码行数:101,代码来源:mainwindow.cpp
示例15: Q_UNUSED
void
DebugWindow::closeEvent( QCloseEvent* e )
{
Q_UNUSED( e )
emit closed();
}
开发者ID:Apricity-OS,项目名称:calamares,代码行数:6,代码来源:DebugWindow.cpp
示例16: closed
~frontend_ui()
{
closed(); // this is here only to make frontend_manager's life harder - it should ignore this signal.
}
开发者ID:tyoma,项目名称:micro-profiler,代码行数:4,代码来源:FrontendManagerTests.cpp
示例17: switch
void TypeTypeForm::editClicked()
{
int index = m_listView->selected();
if (index < 0)
return;
switch (m_currentEditMode) {
case Type:
{
ElementTypeForm *typeForm = new ElementTypeForm(m_type->type().at(index), this->mainWindow());
typeForm->setTitle(tr("Type"));
QObject::connect(typeForm, SIGNAL(closed(Operation,QVariant)),
this, SLOT(typeFormClosed(Operation,QVariant)));
this->mainWindow()->pushWidget(typeForm);
}
break;
case Genre:
{
TypeGroupForm *genreForm = new TypeGroupForm(m_type->genre().at(index), this->mainWindow());
genreForm->setTitle(tr("Genre"));
genreForm->setGeneralDoc(tr("A group of attributes to describe the genre."));
genreForm->setDefinitionDoc(tr("Free text for an optional definition."));
genreForm->setLinkDoc(tr("A link to a term or only identify a classification scheme."));
genreForm->setLabelDoc(tr("Free text field. This can be used to repeat the term name of the classification scheme term identified by a typeLink.\nExample: 'non-fiction/information'."));
genreForm->addLinksMap(mainWindow()->getMap("ebu_ContentAlertSchemeCodeCS"));
genreForm->addLinksMap(mainWindow()->getMap("ebu_ContentGenreCS"));
genreForm->addLinksMap(mainWindow()->getMap("ebu_EditorialFormatCodeCS"));
genreForm->addLinksMap(mainWindow()->getMap("ebu_IntentionCodeCS"));
genreForm->addLinksMap(mainWindow()->getMap("tva_ContentCommercialCS"));
genreForm->addLinksMap(mainWindow()->getMap("tva_ContentAlertCS"));
QObject::connect(genreForm, SIGNAL(closed(Operation,QVariant)),
this, SLOT(genreFormClosed(Operation,QVariant)));
this->mainWindow()->pushWidget(genreForm);
}
break;
case ObjectType:
{
TypeGroupForm *objectTypeForm = new TypeGroupForm(m_type->objectType().at(index), this->mainWindow());
objectTypeForm->setTitle(tr("Object Type"));
objectTypeForm->setGeneralDoc(tr("A group of attributes to describe the objectType."));
objectTypeForm->setDefinitionDoc(tr("Free text for an optional definition.\nExample: 'A short description of the resource'."));
objectTypeForm->setLinkDoc(tr("A link to a term or only identify a classification scheme."));
objectTypeForm->setLabelDoc(tr("Free text field. This can be used to repeat the term name of the classification scheme term identified by a typeLink."));
objectTypeForm->addLinksMap(mainWindow()->getMap("ebu_ObjectTypeCS"));
QObject::connect(objectTypeForm, SIGNAL(closed(Operation,QVariant)),
this, SLOT(objectTypeFormClosed(Operation,QVariant)));
this->mainWindow()->pushWidget(objectTypeForm);
}
break;
case TargetAudience:
{
TypeGroupForm *targetAudienceForm = new TypeGroupForm(m_type->targetAudience().at(index), this->mainWindow());
targetAudienceForm->setTitle(tr("Target Audience"));
targetAudienceForm->setGeneralDoc(tr("A group of attributes to describe the target audience (parental guidance, geographical or occupantional groups, etc.)."));
targetAudienceForm->setDefinitionDoc(tr("An optional definition.\nExample: code for MPAA 'general' rating."));
targetAudienceForm->setLinkDoc(tr("A link to a term or only identify a classification scheme."));
targetAudienceForm->setLabelDoc(tr("Free text field. This can be used to repeat the term name of the classification scheme term identified by a typeLink.\nExample: 'General'."));
targetAudienceForm->addLinksMap(mainWindow()->getMap("ebu_IntendedAudienceCodeCS"));
targetAudienceForm->addLinksMap(mainWindow()->getMap("ebu_ParentalGuidanceCodeCS"));
QObject::connect(targetAudienceForm, SIGNAL(closed(Operation,QVariant)),
this, SLOT(targetAudienceFormClosed(Operation,QVariant)));
this->mainWindow()->pushWidget(targetAudienceForm);
}
break;
}
}
开发者ID:Nazardo,项目名称:QEbu,代码行数:66,代码来源:typetypeform.cpp
示例18: emulate_close
void emulate_close()
{ closed(); }
开发者ID:tyoma,项目名称:micro-profiler,代码行数:2,代码来源:FrontendManagerTests.cpp
示例19: closed
void CDialogLibrarySearch::on_pushButtonCancel_clicked()
{
emit closed();
close();
}
开发者ID:c3c,项目名称:quazaa,代码行数:5,代码来源:dialoglibrarysearch.cpp
示例20: closed
void MasterPalette::closeEvent(QCloseEvent* ev)
{
emit closed(false);
QWidget::closeEvent(ev);
}
开发者ID:uwei,项目名称:MuseScore,代码行数:5,代码来源:masterpalette.cpp
注:本文中的closed函数示例由纯净天空整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。 |
请发表评论