| 
    KiCad PCB EDA Suite
    
   | 
 
This file is part of the common library. More...
Go to the source code of this file.
Macros | |
| #define | KICAD_MESSAGE_DIALOG_BASE wxMessageDialog | 
| #define | KICAD_RICH_MESSAGE_DIALOG_BASE wxRichMessageDialog | 
Functions | |
| KICOMMON_API bool | AskOverrideLock (wxWindow *aParent, const wxString &aMessage) | 
| Display a dialog indicating the file is already open, with an option to reset the lock.   | |
| KICOMMON_API bool | HandleUnsavedChanges (wxWindow *aParent, const wxString &aMessage, const std::function< bool()> &aSaveFunction) | 
| Display a dialog with Save, Cancel and Discard Changes buttons.   | |
| KICOMMON_API int | GetLastUnsavedChangesResponse () | 
| Return the result code from the last call to HandleUnsavedChanges(): wxID_YES, wxID_NO or wxID_CANCEL (or -1 if none yet).   | |
| KICOMMON_API int | UnsavedChangesDialog (wxWindow *aParent, const wxString &aMessage, bool *aApplyToAll) | 
| A specialized version of HandleUnsavedChanges which handles an apply-to-all checkbox.   | |
| KICOMMON_API int | UnsavedChangesDialog (wxWindow *aParent, const wxString &aMessage) | 
| KICOMMON_API bool | ConfirmRevertDialog (wxWindow *parent, const wxString &aMessage) | 
| Display a confirmation dialog for a revert action.   | |
| KICOMMON_API void | DisplayError (wxWindow *aParent, const wxString &aText) | 
| Display an error or warning message box with aMessage.   | |
| KICOMMON_API void | DisplayErrorMessage (wxWindow *aParent, const wxString &aMessage, const wxString &aExtraInfo=wxEmptyString) | 
| Display an error message with aMessage.   | |
| KICOMMON_API void | DisplayInfoMessage (wxWindow *parent, const wxString &aMessage, const wxString &aExtraInfo=wxEmptyString) | 
| Display an informational message box with aMessage.   | |
| KICOMMON_API bool | IsOK (wxWindow *aParent, const wxString &aMessage) | 
| Display a yes/no dialog with aMessage and returns the user response.   | |
| KICOMMON_API int | OKOrCancelDialog (wxWindow *aParent, const wxString &aWarning, const wxString &aMessage, const wxString &aDetailedMessage=wxEmptyString, const wxString &aOKLabel=wxEmptyString, const wxString &aCancelLabel=wxEmptyString, bool *aApplyToAll=nullptr) | 
| Display a warning dialog with aMessage and returns the user response.   | |
| KICOMMON_API int | SelectSingleOption (wxWindow *aParent, const wxString &aTitle, const wxString &aMessage, const wxArrayString &aOptions) | 
| Display a dialog with radioboxes asking the user to select an option.   | |
| #define KICAD_MESSAGE_DIALOG_BASE wxMessageDialog | 
Definition at line 46 of file confirm.h.
Referenced by AskOverrideLock(), ConfirmRevertDialog(), SYMBOL_EDIT_FRAME::DeleteSymbolFromLibrary(), DisplayError(), DisplayErrorMessage(), DisplayInfoMessage(), and UnsavedChangesDialog().
| #define KICAD_RICH_MESSAGE_DIALOG_BASE wxRichMessageDialog | 
Definition at line 47 of file confirm.h.
Referenced by IsOK(), OKOrCancelDialog(), and UnsavedChangesDialog().
| KICOMMON_API bool AskOverrideLock | ( | wxWindow * | aParent, | 
| const wxString & | aMessage ) | 
Display a dialog indicating the file is already open, with an option to reset the lock.
Definition at line 42 of file confirm.cpp.
References _, and KICAD_MESSAGE_DIALOG_BASE.
Referenced by PCB_EDIT_FRAME::OpenProjectFiles(), SCH_EDIT_FRAME::OpenProjectFiles(), and KICAD_MANAGER_FRAME::ProjectChanged().
| KICOMMON_API bool ConfirmRevertDialog | ( | wxWindow * | parent, | 
| const wxString & | aMessage ) | 
Display a confirmation dialog for a revert action.
Definition at line 118 of file confirm.cpp.
References _, and KICAD_MESSAGE_DIALOG_BASE.
Referenced by SYMBOL_EDIT_FRAME::Revert(), and FOOTPRINT_EDIT_FRAME::RevertFootprint().
| KICOMMON_API void DisplayError | ( | wxWindow * | aParent, | 
| const wxString & | aText ) | 
Display an error or warning message box with aMessage.
Definition at line 177 of file confirm.cpp.
References _, and KICAD_MESSAGE_DIALOG_BASE.
Referenced by DIALOG_COPPER_ZONE::AcceptOptions(), DESIGN_BLOCK_PANE::AddDesignBlockLibrary(), FOOTPRINT_VIEWER_FRAME::AddFootprintToPCB(), PCB_BASE_EDIT_FRAME::AddLibrary(), SYMBOL_EDIT_FRAME::AddLibraryFile(), SYMBOL_EDIT_FRAME::backupFile(), SCH_EDIT_FRAME::CheckSheetForRecursion(), DIALOG_GEN_FOOTPRINT_POSITION::CreateAsciiFiles(), MICROWAVE_TOOL::createFootprint(), DIALOG_GEN_FOOTPRINT_POSITION::CreateGerberFiles(), SIMULATOR::CreateInstance(), DESIGN_BLOCK_PANE::createNewDesignBlockLibrary(), PCB_BASE_EDIT_FRAME::createNewLibrary(), SYMBOL_EDIT_FRAME::DdAddLibrary(), DESIGN_BLOCK_PANE::DeleteDesignBlockFromLibrary(), DESIGN_BLOCK_PANE::DeleteDesignBlockLibrary(), FOOTPRINT_EDIT_FRAME::DeleteFootprintFromLibrary(), DESIGN_BLOCK_PANE::EditDesignBlockProperties(), SYMBOL_EDITOR_CONTROL::EditLibrarySymbol(), DIALOG_SIM_COMMAND::evaluateDCControls(), BOARD_EDITOR_CONTROL::ExportCmpFile(), FOOTPRINT_EDIT_FRAME::ExportFootprint(), PCB_EDIT_FRAME::ExportFootprintsToLibrary(), BOARD_EDITOR_CONTROL::ExportGenCAD(), GBR_TO_PCB_EXPORTER::ExportPcb(), SYMBOL_EDIT_FRAME::ExportSymbol(), BOARD_EDITOR_CONTROL::GenBOMFileFromBoard(), BOARD_EDITOR_CONTROL::GenD356File(), DIALOG_GENDRILL::genDrillAndMapFiles(), BOARD_EDITOR_CONTROL::GenerateODBPPFiles(), FOOTPRINT_EDIT_FRAME::ImportFootprint(), SCH_EDITOR_CONTROL::ImportFPAssignments(), SYMBOL_EDIT_FRAME::ImportSymbol(), DIALOG_PRINT_GENERIC::initPrintData(), PROJECT_SCH::LegacySchLibs(), SYMBOL_EDIT_FRAME::LoadSymbol(), SCH_EDIT_FRAME::NewProject(), DIALOG_LIB_FIELDS_TABLE::OnAddField(), DIALOG_SYMBOL_FIELDS_TABLE::OnAddField(), PANEL_GRID_SETTINGS::OnAddGrid(), PCB_NET_INSPECTOR_PANEL::onAddNet(), DIALOG_FOOTPRINT_PROPERTIES::OnDeleteField(), DIALOG_FOOTPRINT_PROPERTIES_FP_EDITOR::OnDeleteField(), DIALOG_LABEL_PROPERTIES::OnDeleteField(), DIALOG_LIB_SYMBOL_PROPERTIES::OnDeleteField(), DIALOG_SHEET_PROPERTIES::OnDeleteField(), DIALOG_SYMBOL_PROPERTIES::OnDeleteField(), PANEL_GRID_SETTINGS::onEditGrid(), DIALOG_SYMBOL_FIELDS_TABLE::OnExport(), PCB_BASE_FRAME::OnFpChangeDebounceTimer(), PANEL_JOBSET::OnGenerateAllDestinationsClick(), PROJECT_TREE_PANE::onGitSwitchBranch(), DIALOG_LIB_SYMBOL_PROPERTIES::OnGridCellChanging(), DIALOG_SYMBOL_PROPERTIES::OnGridCellChanging(), SCH_EDIT_FRAME::OnOpenCvpcb(), PANEL_DESTINATION::OnOpenOutput(), DIALOG_PLOT::onOpenOutputDirectory(), DIALOG_PRINT_GENERIC::onPrintButtonClick(), DIALOG_PRINT_GENERIC::onPrintPreview(), DIALOG_SYMBOL_FIELDS_TABLE::OnRemoveField(), DIALOG_LIB_FIELDS_TABLE::OnRenameField(), DIALOG_SYMBOL_FIELDS_TABLE::OnRenameField(), PCB_NET_INSPECTOR_PANEL::onRenameSelectedNet(), DIALOG_DRC::OnSaveReport(), DIALOG_SHEET_PROPERTIES::onSheetFilenameChanged(), PCB_DRAW_PANEL_GAL::OnShow(), SCH_EDIT_FRAME::OnUpdatePCB(), DIALOG_FOOTPRINT_PROPERTIES::OnUpdateUI(), DIALOG_FOOTPRINT_PROPERTIES_FP_EDITOR::OnUpdateUI(), DIALOG_LIB_SYMBOL_PROPERTIES::OnUpdateUI(), DIALOG_SYMBOL_FIELDS_TABLE::OnViewControlsCellChanged(), PCB_EDIT_FRAME::OpenProjectFiles(), SCH_EDIT_FRAME::OpenProjectFiles(), SCH_EDITOR_CONTROL::Paste(), DESIGN_BLOCK_GRID_TRICKS::paste_text(), FP_GRID_TRICKS::paste_text(), SYMBOL_GRID_TRICKS::paste_text(), DIALOG_PLOT::Plot(), PCB_CONTROL::pruneItemLayers(), MWAVE_POLYGONAL_SHAPE_DLG::ReadDataShapeDescr(), KIGFX::VERTEX_MANAGER::Reserve(), PCB_EDIT_FRAME::SaveBoardAsDesignBlock(), PCB_EDIT_FRAME::saveBoardAsFile(), PCB_EDIT_FRAME::SaveBoardToDesignBlock(), FOOTPRINT_EDIT_FRAME::SaveFootprintInLibrary(), FOOTPRINT_EDIT_FRAME::SaveFootprintToBoard(), FOOTPRINT_EDIT_FRAME::SaveLibraryAs(), PCB_EDIT_FRAME::SavePcbCopy(), PCB_EDIT_FRAME::SavePcbFile(), ROUTER_TOOL::saveRouterDebugLog(), SCH_EDIT_FRAME::saveSchematicFile(), SCH_EDIT_FRAME::SaveSelectionAsDesignBlock(), PCB_EDIT_FRAME::SaveSelectionToDesignBlock(), SCH_EDIT_FRAME::SaveSelectionToDesignBlock(), PCB_EDIT_FRAME::saveSelectionToDesignBlock(), SCH_EDIT_FRAME::SaveSheetAsDesignBlock(), SCH_EDIT_FRAME::SaveSheetToDesignBlock(), SCH_BASE_FRAME::SelectLibrary(), KIGFX::GPU_MANAGER::SetShader(), NETLIST_EXPORTER_ALLEGRO::toAllegroPackages(), DIALOG_IMPORT_SETTINGS::TransferDataFromWindow(), DIALOG_LABEL_PROPERTIES::TransferDataFromWindow(), DIALOG_NON_COPPER_ZONES_EDITOR::TransferDataFromWindow(), DIALOG_PRINT::TransferDataFromWindow(), DIALOG_RULE_AREA_PROPERTIES::TransferDataFromWindow(), DIALOG_SCH_IMPORT_SETTINGS::TransferDataFromWindow(), DIALOG_SHEET_PROPERTIES::TransferDataFromWindow(), DIALOG_SIM_COMMAND::TransferDataFromWindow(), DIALOG_TEXT_PROPERTIES::TransferDataFromWindow(), DIALOG_TEXTBOX_PROPERTIES::TransferDataFromWindow(), DIALOG_TRACK_VIA_PROPERTIES::TransferDataFromWindow(), DIALOG_TRACK_VIA_SIZE::TransferDataFromWindow(), SPICE_VALIDATOR::Validate(), KIGFX::VERTEX_MANAGER::Vertex(), KIGFX::VERTEX_MANAGER::Vertices(), and LEGACY_RESCUER::WriteRescueLibrary().
| KICOMMON_API void DisplayErrorMessage | ( | wxWindow * | aParent, | 
| const wxString & | aMessage, | ||
| const wxString & | aExtraInfo = wxEmptyString ) | 
Display an error message with aMessage.
| aParent | is the parent window | 
| aMessage | is the message text to display | 
| aExtraInfo | is extra data that can be optionally displayed in a collapsible pane | 
Definition at line 202 of file confirm.cpp.
References _, and KICAD_MESSAGE_DIALOG_BASE.
Referenced by PANEL_ZONE_PROPERTIES::AcceptOptions(), FOOTPRINT_VIEWER_FRAME::AddFootprintToPCB(), FILENAME_RESOLVER::addPath(), SYMBOL_EDITOR_CONTROL::AddSymbolToSchematic(), SIMULATOR_FRAME_UI::AddTuner(), PANEL_SETUP_LAYERS::addUserDefinedLayer(), PCB_CONTROL::AppendBoard(), SIMULATOR_FRAME_UI::applyTuners(), CVPCB_ASSOCIATION_TOOL::Associate(), CVPCB_MAINFRAME::AssociateFootprint(), PANEL_SETUP_TUNING_PROFILE_INFO::calculateTrackParametersForCell(), checkGlError(), PANEL_IMAGE_EDITOR::CheckValues(), CONVERT_TOOL::CreatePolys(), UNIT_BINDER::delayedFocusHandler(), PROJECT_TREE_ITEM::Delete(), DESIGN_BLOCK_PANE::DeleteDesignBlockLibrary(), PCB_DESIGN_BLOCK_PREVIEW_WIDGET::DisplayDesignBlock(), EDA_DRAW_PANEL_GAL::DoRePaint(), WIDGET_HOTKEY_LIST::editItem(), EESCHEMA_JOBS_HANDLER::EESCHEMA_JOBS_HANDLER(), ExecuteFile(), FOOTPRINT_EDIT_FRAME::ExportFootprint(), BOARD_EDITOR_CONTROL::ExportNetlist(), PCB_EDIT_FRAME::ExportSpecctraFile(), SYMBOL_EDIT_FRAME::ExportSymbol(), BOARD_EDITOR_CONTROL::ExportVRML(), BACK_ANNOTATE::FetchNetlistFromPCB(), PCB_EDIT_FRAME::FetchNetlistFromSchematic(), PL_EDITOR_FRAME::Files_io(), DIALOG_EXPORT_ODBPP::GenerateODBPPFiles(), GetAssociatedDocument(), SYMBOL_LIBRARY_MANAGER::GetBufferedSymbol(), DESIGN_BLOCK_PANE::GetDesignBlock(), EDA_BASE_FRAME::GetFileFromHistory(), DISPLAY_FOOTPRINTS_FRAME::GetFootprint(), DIALOG_PLOT_SCHEMATIC::getOutputPath(), SYMBOL_LIBRARY_MANAGER::GetSymbol(), SCH_EDIT_FRAME::importFile(), KICAD_MANAGER_FRAME::ImportNonKiCadProject(), PCB_EDIT_FRAME::ImportSpecctraSession(), SYMBOL_EDIT_FRAME::ImportSymbol(), PGM_BASE::InitPgm(), EDA_BASE_FRAME::IsWritable(), FOOTPRINT_EDIT_FRAME::KiwayMailIn(), SYMBOL_EDIT_FRAME::KiwayMailIn(), PL_EDITOR_FRAME::LoadDrawingSheetFile(), PCB::IFACE::loadGlobalLibTable(), SCH_EDIT_FRAME::LoadSheetFromFile(), SYMBOL_EDIT_FRAME::LoadSymbol(), SYMBOL_EDIT_FRAME::LoadSymbolFromCurrentLib(), SIMULATOR_FRAME::LoadWorkbook(), mergeZones(), SETTINGS_MANAGER::MigrateFromPreviousVersion(), SIMULATOR_CONTROL::NewAnalysisTab(), KICAD_MANAGER_CONTROL::NewFromRepository(), KICAD_MANAGER_CONTROL::NewProject(), KICAD_MANAGER_CONTROL::newProjectDirectory(), DIALOG_CONFIG_EQUFILES::OnAddFiles(), DIALOG_BOM::OnAddGenerator(), DIALOG_BOARD_SETUP::onAuxiliaryAction(), DIALOG_SCHEMATIC_SETUP::onAuxiliaryAction(), DIALOG_EXPORT_ODBPP::onBrowseClicked(), PANEL_SYM_LIB_TABLE::onConvertLegacyLibraries(), TEMPLATE_WIDGET::onDuplicateTemplate(), TEMPLATE_WIDGET::onEditTemplate(), DIALOG_EXPORT_STEP::onExportButton(), DIALOG_GIT_REPOSITORY::OnFileUpdated(), PROJECT_TREE_PANE::onGitInitializeProject(), PROJECT_TREE_PANE::onGitPullProject(), PROJECT_TREE_PANE::onGitPushProject(), PROJECT_TREE_PANE::onGitRemoveVCS(), SYMBOL_GRID_TRICKS::onGridCellLeftClick(), CV::IFACE::OnKifaceStart(), PANEL_DESIGN_BLOCK_LIB_TABLE::onMigrateLibraries(), PANEL_FP_LIB_TABLE::onMigrateLibraries(), DIALOG_GIT_REPOSITORY::OnOKClick(), DIALOG_EXPORT_ODBPP::onOKClick(), DIALOG_GEN_FOOTPRINT_POSITION::onOutputDirectoryBrowseClicked(), DIALOG_GENDRILL::onOutputDirectoryBrowseClicked(), DIALOG_SYMBOL_FIELDS_TABLE::OnOutputFileBrowseClicked(), PGM_KICAD::OnPgmInit(), PANEL_SETUP_NETCLASSES::OnRemoveNetclassClick(), DIALOG_BOM::OnRunGenerator(), PNS_LOG_VIEWER_FRAME::onSaveAs(), FOOTPRINT_EDIT_FRAME::OnSaveFootprintAsPng(), DIALOG_ERC::OnSaveReport(), DIALOG_SHEET_PROPERTIES::onSheetFilenameChanged(), SIMULATOR_FRAME::onUpdateSim(), DIALOG_CONFIGURE_PATHS::OnUpdateUI(), PANEL_SETUP_BUSES::OnUpdateUI(), PANEL_TEXT_VARIABLES::OnUpdateUI(), DIALOG_SIM_MODEL< T >::onWaveformChoice(), DIALOG_PAGES_SETTINGS::OnWksFileSelection(), KICAD_MANAGER_FRAME::OpenJobsFile(), OpenPDF(), PCB_EDIT_FRAME::OpenProjectFiles(), SCH_EDIT_FRAME::OpenProjectFiles(), PROJECT::PcbFootprintLibs(), PROJECT_PCB::PcbFootprintLibs(), PCBNEW_JOBS_HANDLER::PCBNEW_JOBS_HANDLER(), PCB_EDIT_FRAME::ReadNetlistFromFile(), FOOTPRINT_EDITOR_CONTROL::RenameFootprint(), PCB_EDIT_FRAME::SaveBoardAsDesignBlock(), PCB_EDIT_FRAME::SaveBoardToDesignBlock(), SYMBOL_EDIT_FRAME::saveCurrentSymbol(), SYMBOL_EDIT_FRAME::saveLibrary(), FOOTPRINT_EDIT_FRAME::SaveLibraryAs(), DIALOG_PAGES_SETTINGS::SavePageSettings(), KICAD_MANAGER_CONTROL::SaveProjectAs(), DIALOG_BOARD_STATISTICS::saveReportClicked(), PCB_EDIT_FRAME::SaveSelectionAsDesignBlock(), SCH_EDIT_FRAME::SaveSelectionAsDesignBlock(), PCB_EDIT_FRAME::SaveSelectionToDesignBlock(), SCH_EDIT_FRAME::SaveSelectionToDesignBlock(), PCB_EDIT_FRAME::saveSelectionToDesignBlock(), SCH_EDIT_FRAME::SaveSheetAsDesignBlock(), SCH_EDIT_FRAME::SaveSheetToDesignBlock(), SchGetLibSymbol(), KIWAY::SetLanguage(), BOARD_EDITOR_CONTROL::ShowEeschema(), SIMULATOR_FRAME::showNetlistErrors(), SCH_EDITOR_CONTROL::SimProbe(), SIMULATOR_FRAME::StartSimulation(), EDA_DRAW_PANEL_GAL::SwitchBackend(), PCB_EDIT_FRAME::TestStandalone(), DIALOG_DESTINATION::TransferDataFromWindow(), DIALOG_EDIT_SYMBOLS_LIBID::TransferDataFromWindow(), DIALOG_LIB_SYMBOL_PROPERTIES::TransferDataFromWindow(), DIALOG_OUTSET_ITEMS::TransferDataFromWindow(), DIALOG_PIN_PROPERTIES::TransferDataFromWindow(), DIALOG_PNS_DIFF_PAIR_DIMENSIONS::TransferDataFromWindow(), DIALOG_SIM_MODEL< T >::TransferDataToWindow(), SYMBOL_EDIT_FRAME::UpdateAfterSymbolProperties(), BOARD_EDITOR_CONTROL::UpdateSchematicFromPCB(), SIMULATOR_FRAME_UI::UpdateTunerValue(), DIALOG_SHEET_PROPERTIES::Validate(), DIALOG_SYMBOL_PROPERTIES::Validate(), and SYMBOL_LIB_TABLE_RESCUER::WriteRescueLibrary().
| KICOMMON_API void DisplayInfoMessage | ( | wxWindow * | parent, | 
| const wxString & | aMessage, | ||
| const wxString & | aExtraInfo = wxEmptyString ) | 
Display an informational message box with aMessage.
| aParent | is the parent window | 
| aMessage | is the message text to display | 
| aExtraInfo | is the extra data that can be optionally displayed in a collapsible pane | 
Definition at line 230 of file confirm.cpp.
References _, KICAD_MESSAGE_DIALOG_BASE, and traceConfirm.
Referenced by SCH_EDIT_FRAME::checkForNoFullyDefinedLibIds(), SCH_INSPECTION_TOOL::CheckSymbol(), FOOTPRINT_EDIT_FRAME::DeleteFootprintFromLibrary(), DIALOG_SYMBOL_REMAP::DIALOG_SYMBOL_REMAP(), EDA_DRAW_PANEL_GAL::DoRePaint(), FOOTPRINT_EDIT_FRAME::DuplicateFootprint(), FOOTPRINT_EDIT_FRAME::ExportFootprint(), PCB_EDIT_FRAME::ExportFootprintsToLibrary(), GERBVIEW_CONTROL::ExportToPcbnew(), BOARD_EDITOR_CONTROL::GenD356File(), DIALOG_PRINT_GENERIC::getScaleValue(), PGM_BASE::GetTextEditor(), PCB_EDIT_FRAME::inferLegacyEdgeClearance(), SIMULATOR_CONTROL::NewAnalysisTab(), TEMPLATE_WIDGET::onDuplicateTemplate(), DIALOG_SYMBOL_FIELDS_TABLE::OnExport(), PROJECT_TREE_PANE::onGitInitializeProject(), CV::IFACE::OnKifaceStart(), SCH_DRAW_PANEL::OnShow(), SCH_EDIT_FRAME::OpenProjectFiles(), DIALOG_PLOT::Plot(), BOARD_EDITOR_CONTROL::RepairBoard(), FOOTPRINT_EDITOR_CONTROL::RepairFootprint(), SCH_EDITOR_CONTROL::RepairSchematic(), FOOTPRINT_EDIT_FRAME::SaveFootprint(), FOOTPRINT_EDIT_FRAME::SaveFootprintAs(), FOOTPRINT_EDIT_FRAME::SaveLibraryAs(), ROUTER_TOOL::SelectCopperLayerPair(), PCB_BASE_FRAME::setFPWatcher(), SIMULATOR_FRAME::showNetlistErrors(), KICAD_MANAGER_CONTROL::ShowPlayer(), EDA_DRAW_PANEL_GAL::SwitchBackend(), DIALOG_LABEL_PROPERTIES::TransferDataFromWindow(), and DIALOG_FIELD_PROPERTIES::UpdateField().
| KICOMMON_API int GetLastUnsavedChangesResponse | ( | ) | 
Return the result code from the last call to HandleUnsavedChanges(): wxID_YES, wxID_NO or wxID_CANCEL (or -1 if none yet).
Definition at line 144 of file confirm.cpp.
References g_lastUnsavedChangesResult.
Referenced by PCB_EDIT_FRAME::canCloseWindow(), and SCH_EDIT_FRAME::canCloseWindow().
| KICOMMON_API bool HandleUnsavedChanges | ( | wxWindow * | aParent, | 
| const wxString & | aMessage, | ||
| const std::function< bool()> & | aSaveFunction ) | 
Display a dialog with Save, Cancel and Discard Changes buttons.
| aParent | = the parent window | 
| aMessage | = the main message to put in dialog | 
| aSaveFunction | = a function to save changes, if requested. Must return true if the save was successful and false otherwise (which will result in HandleUnsavedChanges() returning wxID_CANCEL). | 
Definition at line 131 of file confirm.cpp.
References g_lastUnsavedChangesResult, and UnsavedChangesDialog().
Referenced by SCH_EDIT_FRAME::AskToSaveChanges(), FOOTPRINT_EDIT_FRAME::CanCloseFPFromBoard(), CVPCB_MAINFRAME::canCloseWindow(), FOOTPRINT_EDIT_FRAME::canCloseWindow(), PCB_EDIT_FRAME::canCloseWindow(), PL_EDITOR_FRAME::canCloseWindow(), SCH_EDIT_FRAME::canCloseWindow(), SIMULATOR_FRAME::canCloseWindow(), FOOTPRINT_EDIT_FRAME::Clear_Pcb(), FOOTPRINT_EDITOR_CONTROL::CreateFootprint(), PL_EDITOR_FRAME::Files_io(), PANEL_JOBSET::GetCanClose(), SYMBOL_EDIT_FRAME::LoadSymbol(), SYMBOL_EDIT_FRAME::LoadSymbol(), BOARD_EDITOR_CONTROL::New(), DIALOG_LIB_FIELDS_TABLE::OnCancel(), DIALOG_LIB_EDIT_PIN_TABLE::OnClose(), DIALOG_LIB_FIELDS_TABLE::OnClose(), DIALOG_SYMBOL_FIELDS_TABLE::OnClose(), PL_EDITOR_FRAME::OnFileHistory(), and PCB_EDIT_FRAME::OpenProjectFiles().
| KICOMMON_API bool IsOK | ( | wxWindow * | aParent, | 
| const wxString & | aMessage ) | 
Display a yes/no dialog with aMessage and returns the user response.
| aParent | is the parent window. NULL can be used if the parent is the top level window. | 
| aMessage | is the message to display in the dialog box. | 
Definition at line 259 of file confirm.cpp.
References _, and KICAD_RICH_MESSAGE_DIALOG_BASE.
Referenced by STARTWIZARD::CheckAndRun(), PANEL_SETUP_NETCLASSES::checkReload(), PANEL_SETUP_SEVERITIES::checkReload(), PANEL_TEXT_VARIABLES::checkReload(), PANEL_IMAGE_EDITOR::CheckValues(), SCH_EDIT_TOOL::CleanupSheetPins(), GERBVIEW_FRAME::Clear_DrawLayers(), PCB_EDIT_FRAME::Clear_Pcb(), CVPCB_ASSOCIATION_TOOL::DeleteAll(), DESIGN_BLOCK_PANE::DeleteDesignBlockFromLibrary(), DESIGN_BLOCK_PANE::DeleteDesignBlockLibrary(), FOOTPRINT_EDIT_FRAME::DeleteFootprintFromLibrary(), SYMBOL_EDIT_FRAME::DeleteSymbolFromLibrary(), GERBVIEW_FRAME::Erase_Current_DrawLayer(), BOARD_EDITOR_CONTROL::New(), KICAD_MANAGER_CONTROL::newProjectDirectory(), DIALOG_SYMBOL_FIELDS_TABLE::onBomFmtPresetChanged(), DIALOG_SYMBOL_FIELDS_TABLE::onBomPresetChanged(), PANEL_SETUP_RULES::onCharHook(), PANEL_SYM_LIB_TABLE::onConvertLegacyLibraries(), PCB_NET_INSPECTOR_PANEL::onDeleteSelectedNet(), PCB_BASE_FRAME::OnFpChangeDebounceTimer(), PROJECT_TREE_PANE::onGitRemoveVCS(), SCH_EDIT_FRAME::OnImportProject(), APPEARANCE_CONTROLS::onLayerPresetChanged(), APPEARANCE_CONTROLS_3D::onLayerPresetChanged(), PANEL_DESIGN_BLOCK_LIB_TABLE::onMigrateLibraries(), PANEL_FP_LIB_TABLE::onMigrateLibraries(), DIALOG_GEN_FOOTPRINT_POSITION::onOutputDirectoryBrowseClicked(), DIALOG_GENDRILL::onOutputDirectoryBrowseClicked(), DIALOG_PLOT::onOutputDirectoryBrowseClicked(), DIALOG_PLOT_SCHEMATIC::onOutputDirectoryBrowseClicked(), DIALOG_SYMBOL_FIELDS_TABLE::OnOutputFileBrowseClicked(), DIALOG_LIB_FIELDS_TABLE::OnRemoveField(), DIALOG_SYMBOL_FIELDS_TABLE::OnRemoveField(), PANEL_FP_LIB_TABLE::onReset(), PANEL_SYM_LIB_TABLE::onReset(), DIALOG_SHEET_PROPERTIES::onSheetFilenameChanged(), SCH_BASE_FRAME::OnSymChangeDebounceTimer(), PCB_EDIT_FRAME::OpenProjectFiles(), SCH_EDIT_FRAME::OpenProjectFiles(), PCB_CONTROL::Paste(), SCH_EDITOR_CONTROL::Paste(), CVPCB_MAINFRAME::readNetListAndFpFiles(), SCH_EDIT_FRAME::ReadyToNetlist(), DIALOG_BOARD_REANNOTATE::ReannotateBoard(), BOARD_EDITOR_CONTROL::Revert(), SCH_EDITOR_CONTROL::Revert(), SIMULATOR_FRAME::StartSimulation(), DIALOG_PIN_PROPERTIES::TransferDataFromWindow(), PANEL_EMBEDDED_FILES::TransferDataFromWindow(), PANEL_SETUP_LAYERS::TransferDataFromWindow(), and DIALOG_LIB_SYMBOL_PROPERTIES::Validate().
| KICOMMON_API int OKOrCancelDialog | ( | wxWindow * | aParent, | 
| const wxString & | aWarning, | ||
| const wxString & | aMessage, | ||
| const wxString & | aDetailedMessage = wxEmptyString, | ||
| const wxString & | aOKLabel = wxEmptyString, | ||
| const wxString & | aCancelLabel = wxEmptyString, | ||
| bool * | aApplyToAll = nullptr ) | 
Display a warning dialog with aMessage and returns the user response.
| aParent | is the parent window. NULL can be used if the parent is the top level window. | 
| aWarning | is the warning to display in the top part of the dialog box using a bold font. | 
| aMessage | is the message to display in the lower part of the dialog box using the default system UI font. | 
| aDetailedMessage | is the message to display in the "Show detailed information" section. Passing wxEmptyString will hide this portion of the dialog. | 
| aOKLabel | is the text to display in the OK button. | 
| aCancelLabel | is the text to display in the cancel button. | 
Definition at line 150 of file confirm.cpp.
References _, and KICAD_RICH_MESSAGE_DIALOG_BASE.
Referenced by PANEL_DESIGN_BLOCK_LIB_TABLE::browseLibrariesHandler(), PANEL_FP_LIB_TABLE::browseLibrariesHandler(), PANEL_SYM_LIB_TABLE::browseLibrariesHandler(), DESIGN_BLOCK_PANE::checkOverwrite(), checkOverwriteDb(), checkOverwriteDbLayout(), checkOverwriteDbSchematic(), DIALOG_SYMBOL_FIELDS_TABLE::OnExport(), SYMBOL_EDIT_FRAME::Save(), SYMBOL_EDIT_FRAME::saveAllLibraries(), and SYMBOL_EDIT_FRAME::saveCurrentSymbol().
| KICOMMON_API int SelectSingleOption | ( | wxWindow * | aParent, | 
| const wxString & | aTitle, | ||
| const wxString & | aMessage, | ||
| const wxArrayString & | aOptions ) | 
Display a dialog with radioboxes asking the user to select an option.
| aParent | is the parent window. | 
| aTitle | is the dialog title. | 
| aMessage | is a text label displayed in the first row of the dialog. | 
| aOptions | is a vector of possible options. | 
Definition at line 289 of file confirm.cpp.
| KICOMMON_API int UnsavedChangesDialog | ( | wxWindow * | aParent, | 
| const wxString & | aMessage ) | 
Definition at line 91 of file confirm.cpp.
References _, KICAD_MESSAGE_DIALOG_BASE, and UnsavedChangesDialog().
| KICOMMON_API int UnsavedChangesDialog | ( | wxWindow * | aParent, | 
| const wxString & | aMessage, | ||
| bool * | aApplyToAll ) | 
A specialized version of HandleUnsavedChanges which handles an apply-to-all checkbox.
| aParent | = the parent window | 
| aMessage | = the main message to put in dialog | 
| aApplyToAll | = if non-null an "Apply to all" checkbox will be shown and it's value written back to the bool. | 
Definition at line 64 of file confirm.cpp.
References _, and KICAD_RICH_MESSAGE_DIALOG_BASE.
Referenced by SYMBOL_EDIT_FRAME::CanCloseSymbolFromSchematic(), HandleUnsavedChanges(), InvokeSchEditSymbolLibTable(), SYMBOL_EDIT_FRAME::saveAllLibraries(), and UnsavedChangesDialog().