MCPcopy Create free account
hub / github.com/baldurk/renderdoc / checkAllowDelete

Method checkAllowDelete

qrenderdoc/Windows/Dialogs/LiveCapture.cpp:621–644  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

619}
620
621bool LiveCapture::checkAllowDelete()
622{
623 bool needcheck = false;
624
625 for(int i = 0; i < ui->captures->count(); i++)
626 {
627 Capture *cap = GetCapture(ui->captures->item(i));
628 needcheck |= !cap->saved;
629 }
630
631 if(!needcheck || ui->captures->selectedItems().empty())
632 return true;
633
634 ToolWindowManager::raiseToolWindow(this);
635
636 QMessageBox::StandardButton res =
637 RDDialog::question(this, tr("Unsaved capture(s)", "", ui->captures->selectedItems().size()),
638 tr("Are you sure you wish to delete the capture(s)?\nAny capture "
639 "currently opened will be closed",
640 "", ui->captures->selectedItems().size()),
641 RDDialog::YesNoCancel);
642
643 return (res == QMessageBox::Yes);
644}
645
646void LiveCapture::updateAPIStatus()
647{

Callers

nothing calls this directly

Calls 7

GetCaptureFunction · 0.85
questionFunction · 0.85
itemMethod · 0.80
trFunction · 0.50
countMethod · 0.45
emptyMethod · 0.45
sizeMethod · 0.45

Tested by

no test coverage detected