41 #include "scripting/sqplus/sqplus.h" 100 : m_Project(project),
105 XRCCTRL(*
this,
"wxID_OK",
wxButton)->SetDefault();
109 for (
int i=0; i< m_Project->GetFilesCount(); ++i)
110 list->Append(m_Project->GetFile(i)->relativeFilename);
114 list->SetMinSize(
wxSize(50,50));
117 XRCCTRL(*
this,
"txtProjectName",
wxTextCtrl)->SetValue(m_Project->GetTitle());
118 XRCCTRL(*
this,
"txtProjectFilename",
wxStaticText)->SetLabel(m_Project->GetFilename());
120 XRCCTRL(*
this,
"txtProjectMakefile",
wxTextCtrl)->SetValue(m_Project->GetMakefile());
121 XRCCTRL(*
this,
"chkCustomMakefile",
wxCheckBox)->SetValue(m_Project->IsMakefileCustom());
122 XRCCTRL(*
this,
"txtExecutionDir",
wxTextCtrl)->SetValue(m_Project->GetMakefileExecutionDir());
127 XRCCTRL(*
this,
"rbPCHStrategy",
wxRadioBox)->Enable(hasPCH);
129 XRCCTRL(*
this,
"chkExtendedObjNames",
wxCheckBox)->SetValue(m_Project->GetExtendedObjectNamesGeneration());
131 XRCCTRL(*
this,
"chkShowNotes",
wxCheckBox)->SetValue(m_Project->GetShowNotesOnLoad());
132 XRCCTRL(*
this,
"txtNotes",
wxTextCtrl)->SetValue(m_Project->GetNotes());
134 XRCCTRL(*
this,
"chkCheckFiles",
wxCheckBox)->SetValue(m_Project->GetCheckForExternallyModifiedFiles());
137 DoTargetChange(
false);
151 GetSizer()->SetSizeHints(
this);
174 XRCCTRL(*
this,
"txtNotes",
wxTextCtrl)->SetValue(buffer);
231 lstTargets->SetSelection(0);
241 if (lstTargets->GetSelection() == -1)
242 lstTargets->SetSelection(0);
259 wxButton* browseI = XRCCTRL(*
this,
"btnBrowseImportLibraryFilename",
wxButton);
260 wxButton* browseD = XRCCTRL(*
this,
"btnBrowseDefinitionFileFilename",
wxButton);
265 txtP->SetValue(platforms);
277 chkCR->Enable(
false);
280 if (cmb && chkCR && txt && browse)
308 browse->Enable(
true);
315 browseO->Enable(
true);
320 txt->SetValue(
_T(
""));
322 txtI->SetValue(
_T(
""));
324 txtD->SetValue(
_T(
""));
326 txtW->SetValue(
_T(
""));
328 txtO->SetValue(
_T(
""));
330 browse->Enable(
false);
331 browseI->Enable(
false);
332 browseD->Enable(
false);
333 browseW->Enable(
false);
334 browseO->Enable(
false);
342 for (
int i = 0; i < count; ++i)
349 list->
Check(i, doit);
385 fname.
Assign(XRCCTRL(*
this,
"txtImportLibraryFilename",
wxTextCtrl)->GetValue());
388 fname.
Assign(XRCCTRL(*
this,
"txtDefinitionFileFilename",
wxTextCtrl)->GetValue());
404 for (
size_t i = 0; i < count; ++i)
435 wxButton* browseI = XRCCTRL(*
this,
"btnBrowseImportLibraryFilename",
wxButton);
436 wxButton* browseD = XRCCTRL(*
this,
"btnBrowseDefinitionFileFilename",
wxButton);
439 if (!cmb || !txt || !browse)
455 browse->Enable(
true);
461 browseO->Enable(
true);
492 txt->SetValue(fname.GetFullPath());
493 txtI->SetValue(
_T(
""));
494 txtD->SetValue(
_T(
""));
501 if (extD !=
_T(
"def"))
518 txt->SetValue(fname.GetFullPath());
524 fname.SetExt(libext);
530 txt->SetValue(fname.GetFullPath());
531 txtI->SetValue(
_T(
""));
532 txtD->SetValue(
_T(
""));
542 txt->SetValue(fname.GetFullPath());
543 txtI->SetValue(
_T(
""));
544 txtD->SetValue(
_T(
""));
548 txt->SetValue(
_T(
""));
549 txtI->SetValue(
_T(
""));
550 txtD->SetValue(
_T(
""));
551 txtW->SetValue(
_T(
""));
552 txtO->SetValue(
_T(
""));
558 browse->Enable(
false);
559 browseI->Enable(
false);
560 browseD->Enable(
false);
561 browseW->Enable(
false);
562 browseO->Enable(
false);
584 ActiveTarget = lstTargets->GetString(lstTargets->GetSelection());
621 int targetIdx = lstTargets->GetSelection();
632 _(
"New build target"));
646 lstTargets->Append(targetName);
647 lstTargets->SetSelection(lstTargets->GetCount() - 1);
658 int targetIdx = lstTargets->GetSelection();
670 _(
"Rename build target"),
676 lstTargets->SetString(targetIdx, newTargetName);
677 lstTargets->SetSelection(targetIdx);
687 int targetIdx = lstTargets->GetSelection();
698 _(
"Duplicate build target"),
709 lstTargets->Append(newTargetName);
710 lstTargets->SetSelection(lstTargets->GetCount() - 1);
721 int targetIdx = lstTargets->GetSelection();
729 caption.
Printf(
_(
"Are you sure you want to delete build target \"%s\"?"), lstTargets->GetStringSelection().c_str());
733 lstTargets->Delete(targetIdx);
734 if (lstTargets->GetCount() > 0)
736 if (static_cast<unsigned>(targetIdx) >= lstTargets->GetCount())
737 lstTargets->SetSelection(lstTargets->GetCount() - 1);
739 lstTargets->SetSelection(targetIdx);
777 _(
"This project will be saved before exporting the build target.\n" 778 "Are you sure you want to export the selected " 779 "build target to a new project?"),
791 if (event.GetId() == XRCID(
"btnBrowseWorkingDir"))
792 targettext = XRCCTRL(*
this,
"txtWorkingDir",
wxTextCtrl);
793 else if (event.GetId() == XRCID(
"btnBrowseObjectDir"))
794 targettext = XRCCTRL(*
this,
"txtObjectDir",
wxTextCtrl);
795 else if (event.GetId() == XRCID(
"btnExecutionDir"))
796 targettext = XRCCTRL(*
this,
"txtExecutionDir",
wxTextCtrl);
804 _(
"Select directory"),
805 fname.GetPath(wxPATH_GET_VOLUME | wxPATH_GET_SEPARATOR),
813 targettext->SetValue(path);
822 _(
"Select output filename"),
829 if (dlg.ShowModal() !=
wxID_OK)
831 fname.
Assign(dlg.GetPath());
839 fname.
Assign(XRCCTRL(*
this,
"txtImportLibraryFilename",
wxTextCtrl)->GetValue());
842 _(
"Select import library filename"),
849 if (dlg.ShowModal() !=
wxID_OK)
851 fname.
Assign(dlg.GetPath());
859 fname.
Assign(XRCCTRL(*
this,
"txtDefinitionFileFilename",
wxTextCtrl)->GetValue());
862 _(
"Select definition file filename"),
869 if (dlg.ShowModal() !=
wxID_OK)
871 fname.
Assign(dlg.GetPath());
891 int targetIdx = lstTargets->GetSelection();
897 for (
unsigned int i = 0; i < list->
GetCount(); ++i)
914 _(
"Select files"),
_T(
"*.*"));
915 if (wildcard.
IsEmpty())
return;
918 int targetIdx = lstTargets->GetSelection();
924 for (
unsigned int i=0; i<list->
GetCount(); ++i)
929 list->
Check(i,
true);
938 _(
"Select files"),
_T(
"*.*"));
939 if (wildcard.
IsEmpty())
return;
942 int targetIdx = lstTargets->GetSelection();
948 for (
unsigned int i=0; i<list->
GetCount(); ++i)
953 list->
Check(i,
false);
966 static const wxString clearout_buildscripts =
_T(
"SetBuildOptions <- null;");
974 SqPlus::SquirrelFunction<void> setopts(
"SetBuildOptions");
976 if (setopts.func.IsNull())
981 catch (SquirrelError& e)
995 cbMessageBox(
_(
"A target with this name already exists in this project!"),
1002 cbMessageBox(
_(
"A virtual target with this name already exists in this project!"),
1007 const wxString forbidden =
_T(
";,!@#$%^&*\"':`~=?\\><");
1010 cbMessageBox(
_(
"The name contains at least one invalid character:\n\n") + forbidden,
1021 for (
size_t i = 0; i < scripts.
GetCount(); ++i)
1027 msg <<
_(
"Invalid build script: ") + scripts[i] <<
_T(
'\n');
1028 msg <<
_(
"First seen in: ") + base->
GetTitle() << _T(
'\n');
1057 if (ctrl->GetSelection())
1058 fname.
Assign(ctrl->GetStringSelection());
1059 else if (ctrl->GetCount())
1060 fname.
Assign(ctrl->GetString(ctrl->GetCount() - 1));
1067 _(
"Select script file(s)"),
1070 _(
"Script files (*.script)|*.script"));
1073 if (dlg.ShowModal() !=
wxID_OK)
1077 for (
size_t i = 0; i < paths.
GetCount(); ++i)
1082 ctrl->SetSelection(ctrl->GetCount()-1);
1096 if (!ctrl || ctrl->GetSelection() == -1)
1099 wxString script = ctrl->GetStringSelection();
1109 int isel = ctrl->GetSelection();
1111 ctrl->SetSelection(isel < (
int)(ctrl->GetCount()) ? isel : --isel );
1117 if (event.GetId() == XRCID(
"btnPlatform"))
1118 txtP = XRCCTRL(*
this,
"txtPlatform",
wxTextCtrl);
1120 txtP = XRCCTRL(*
this,
"txtPlatformProj",
wxTextCtrl);
1121 bool isAll = txtP->GetValue().Contains(
_(
"All"));
1124 MultiSelectDlg dlg(
this, arr, isAll,
_(
"Select supported platforms:"),
_(
"Build target platforms"));
1128 for (
size_t i = 0; i < sel.
GetCount(); ++i)
1136 txtP->SetValue(
_(
"All"));
1140 txtP->SetValue(platform);
1148 if (!ctrl || ctrl->GetSelection() <= 0)
1157 int isel = ctrl->GetSelection();
1158 wxString ssel = ctrl->GetStringSelection();
1163 ctrl->Insert(ssel, isel);
1164 scripts.
Insert(ssel, isel);
1165 ctrl->SetSelection(isel);
1172 if (!ctrl || ctrl->GetSelection() == (int)(ctrl->GetCount()) - 1)
1181 int isel = ctrl->GetSelection();
1182 wxString ssel = ctrl->GetStringSelection();
1187 ctrl->Insert(ssel, isel);
1188 scripts.
Insert(ssel, isel);
1189 ctrl->SetSelection(isel);
1199 bool en = lstTargets->GetSelection() >= 0;
1202 XRCCTRL(*
this,
"btnFileOptions",
wxButton)->Enable(filesEn);
1205 XRCCTRL(*
this,
"btnBuildOrder",
wxButton)->Enable(lstTargets->GetCount() > 1);
1206 XRCCTRL(*
this,
"btnEditBuildTarget",
wxButton)->Enable(en);
1207 XRCCTRL(*
this,
"btnCopyBuildTarget",
wxButton)->Enable(en);
1208 XRCCTRL(*
this,
"btnDelBuildTarget",
wxButton)->Enable(en && lstTargets->GetCount() > 1);
1213 XRCCTRL(*
this,
"btnExportTarget",
wxButton)->Enable(en);
1216 bool customMake = XRCCTRL(*
this,
"chkCustomMakefile",
wxCheckBox)->GetValue();
1217 XRCCTRL(*
this,
"rbPCHStrategy",
wxRadioBox)->Enable(!customMake);
1218 XRCCTRL(*
this,
"txtObjectDir",
wxTextCtrl)->Enable(!customMake && en);
1219 XRCCTRL(*
this,
"txtObjectDir",
wxTextCtrl)->Enable(!customMake && en);
1220 XRCCTRL(*
this,
"btnBrowseObjectDir",
wxButton)->Enable(!customMake && en);
1221 XRCCTRL(*
this,
"btnToggleCheckmarks",
wxButton)->Enable(!customMake && en);
1222 XRCCTRL(*
this,
"btnCheckmarksOn",
wxButton)->Enable(!customMake && en);
1223 XRCCTRL(*
this,
"btnCheckmarksOff",
wxButton)->Enable(!customMake && en);
1224 list->Enable(!customMake);
1227 XRCCTRL(*
this,
"txtExecutionDir",
wxTextCtrl)->Enable(customMake);
1228 XRCCTRL(*
this,
"btnExecutionDir",
wxButton)->Enable(customMake);
1232 tc->Enable(!customMake);
1236 lstPreScripts->Enable(scrsel);
1237 bool presel = lstPreScripts->GetSelection() != -1;
1238 XRCCTRL(*
this,
"btnAddPreScripts",
wxButton)->Enable(scrsel);
1239 XRCCTRL(*
this,
"btnRemovePreScripts",
wxButton)->Enable(scrsel && presel);
1240 XRCCTRL(*
this,
"spnPreScripts",
wxSpinButton)->Enable(scrsel && presel && lstPreScripts->GetCount() > 1);
1241 XRCCTRL(*
this,
"btnCheckScripts",
wxButton)->Enable(!customMake);
1246 if (XRCCTRL(*
this,
"txtProjectName",
wxTextCtrl)->GetValue().Trim().IsEmpty())
1248 cbMessageBox(
_(
"The project title (name) cannot be empty."),
_(
"Error"),
1259 if (lstTargets->GetSelection() == -1)
1260 lstTargets->SetSelection(0);
1271 wxButton* browseI = XRCCTRL(*
this,
"btnBrowseImportLibraryFilename",
wxButton);
1272 wxButton* browseD = XRCCTRL(*
this,
"btnBrowseDefinitionFileFilename",
wxButton);
1286 if (lstTargets->GetSelection() == -1)
1287 lstTargets->SetSelection(0);
1298 wxButton* browseI = XRCCTRL(*
this,
"btnBrowseImportLibraryFilename",
wxButton);
1299 wxButton* browseD = XRCCTRL(*
this,
"btnBrowseDefinitionFileFilename",
wxButton);
1312 static void UpdateNameInTree(
cbProject *project)
void DoBeforeTargetChange(bool force=false)
wxTreeItemId GetProjectNode()
wxArrayString GetSelectedStrings() const
ProjectFile * GetFileByFilename(const wxString &filename, bool isRelative=true, bool isUnixFilename=false)
Access a file of the project.
void EndModal(int retCode)
void OnCreateImportFileClick(wxCommandEvent &event)
DLLIMPORT wxArrayString GetArrayFromString(const wxString &text, const wxString &separator=DEFAULT_ARRAY_SEP, bool trimSpaces=true)
ProjectBuildTarget * DuplicateBuildTarget(int index, const wxString &newName=wxEmptyString)
Duplicate a build target.
void EndModal(int retCode)
void OnRemoveBuildTargetClick(wxCommandEvent &event)
virtual bool AddPage(wxWindow *page, const wxString &text, bool select=false, int imageId=NO_IMAGE)
virtual void GetTargetFilenameGenerationPolicy(TargetFilenameGenerationPolicy &prefixOut, TargetFilenameGenerationPolicy &extensionOut) const
void SetMakefileCustom(bool custom)
Mark if the project should use a custom Makefile for compilation.
cbCompilerPlugin * m_pCompiler
void OnCreateDefFileClick(wxCommandEvent &event)
bool DoCheckScripts(CompileTargetBase *base)
TargetFilenameGenerationPolicy
A target's filename can either be auto-generated based on the running platform, or completely specifi...
PluginManager * GetPluginManager() const
void OnExportTargetClick(wxCommandEvent &event)
void SetModeForPCH(PCHMode mode)
Set the mode to handle precompiled headers.
virtual bool GetCreateDefFile() const
Valid only for targets generating dynamic libraries (DLLs or SOs).
virtual bool GetUseConsoleRunner() const
Valid only for targets generating a console executable.
virtual void SetObjectOutput(const wxString &dirname)
Set the target's objects output dir.
void Assign(const wxFileName &filepath)
void ReOrderTargets(const wxArrayString &nameOrder)
Reorder the list of build targets.
void OnFileOptionsClick(wxCommandEvent &event)
static Manager * Get()
Use Manager::Get() to get a pointer to its instance Manager::Get() is guaranteed to never return an i...
void OnRemoveScript(wxCommandEvent &event)
void OnOK(wxCommandEvent &event)
void OnAddScript(wxCommandEvent &event)
virtual void SetCreateDefFile(bool createIt)
Set if the target creates a DEF imports file.
bool ShowOptions(wxWindow *parent)
Show the file properties dialog.
void SetShowNotesOnLoad(bool show)
Set show project notes on load automatically.
virtual wxString GetString(unsigned int n) const
void OnTargetBuildOptionsClick(wxCommandEvent &event)
void OnScriptMoveDown(wxSpinEvent &event)
virtual void DeleteAllItems()
DLLIMPORT wxString cbGetTextFromUser(const wxString &message, const wxString &caption=cbGetTextFromUserPromptStr, const wxString &default_value=wxEmptyString, wxWindow *parent=NULL, int x=wxDefaultCoord, int y=wxDefaultCoord, bool centre=true)
bool ValidateTargetName(const wxString &name)
DLLIMPORT wxString ChooseDirectory(wxWindow *parent, const wxString &message=_("Select directory"), const wxString &initialPath=_T(""), const wxString &basePath=_T(""), bool askToMakeRelative=false, bool showCreateDirButton=false)
int Index(const wxString &sz, bool bCase=true, bool bFromEnd=false) const
virtual void SetSelection(int n)
virtual wxString GetTitle() const =0
void OnBrowseImportLibraryFilenameClick(wxCommandEvent &event)
virtual wxTreeItemId GetSelection() const
Target produces an executable.
void OnEditBuildTargetClick(wxCommandEvent &event)
PCHMode
Precompiled headers mode.
virtual void AddBuildScript(const wxString &script)
static Compiler * GetCompiler(size_t index)
void OnCheckScripts(wxCommandEvent &event)
virtual void OnApply()=0
Called when the user chooses to apply the configuration.
virtual void OnCancel()=0
Called when the user chooses to cancel the configuration.
void OnScriptMoveUp(wxSpinEvent &event)
cbProjectManagerUI & GetUI()
DLLIMPORT wxString GetStringFromArray(const wxArrayString &array, const wxString &separator=DEFAULT_ARRAY_SEP, bool SeparatorAtEnd=true)
bool IsAbsolute(wxPathFormat format=wxPATH_NATIVE) const
DLLIMPORT wxString GetFilterAll()
Generates a simple special filter "All files".
virtual void SetTargetFilenameGenerationPolicy(TargetFilenameGenerationPolicy prefix, TargetFilenameGenerationPolicy extension)
A target's filename can either be auto-generated based on the running platform, or completely specifi...
#define wxICON_INFORMATION
bool IsChecked(unsigned int item) const
virtual wxString GetItemText(const wxTreeItemId &item) const
wxString & Remove(size_t pos)
void OnEditDepsClick(wxCommandEvent &event)
virtual void SetUseConsoleRunner(bool useIt)
Set if ConsoleRunner should be used.
virtual void SetImportLibraryFilename(const wxString &filename)
Set the target's import library filename.
virtual const wxArrayString & GetBuildScripts() const
Represents a file in a Code::Blocks project.
A generic Code::Blocks event.
virtual wxString GetOutputFilename()
Read the target's output filename.
virtual bool GetCreateStaticLib()
Valid only for targets generating dynamic libraries (DLLs or SOs).
void OnProjectDepsClick(wxCommandEvent &event)
void OnBrowseOutputFilenameClick(wxCommandEvent &event)
const DLLIMPORT wxString DYNAMICLIB_EXT
virtual TargetType GetTargetType() const
Read the target's type.
virtual void SetDefinitionFileFilename(const wxString &filename)
Set the target's definition file filename.
void OnBrowseDirClick(wxCommandEvent &event)
ProjectManager * GetProjectManager() const
Functions returning pointers to the respective sub-manager instances.
const wxArrayString & GetArray()
bool LoadScript(const wxString &filename)
Loads a script.
bool MakeRelativeTo(const wxString &pathBase=wxEmptyString, wxPathFormat format=wxPATH_NATIVE)
void Insert(wxString lItem, size_t nIndex, size_t copies=1)
bool wxMatchWild(const wxString &pattern, const wxString &text, bool dot_special)
Represents a Code::Blocks project.
void OnAddBuildTargetClick(wxCommandEvent &event)
size_t find_first_of(const char *sz, size_t nStart=0) const
void OnBuildOrderClick(wxCommandEvent &event)
virtual wxString GetDynamicLibImportFilename()
Read the target's dynamic library import filename (produced if target type is ttDynamicLib) ...
virtual void SetOutputFilename(const wxString &filename)
Set the target's output filename.
void OnProjectTypeChanged(wxCommandEvent &event)
virtual const wxString & GetTitle() const
Read the target's title.
void GetProjectConfigurationPanels(wxWindow *parent, cbProject *project, ConfigurationPanelsArray &arrayToFill)
void RemoveBuildTarget(const wxString &targetName)
Remove this file from the specified build target.
Target produces a dynamic library.
void Check(unsigned int item, bool check=true)
virtual void SelectItem(const wxTreeItemId &item, bool select=true)
const DLLIMPORT wxString STATICLIB_EXT
void SetCheckForExternallyModifiedFiles(bool check)
Set check for externally modified files.
virtual cbTreeCtrl * GetTree()=0
Retrieve a pointer to the project manager's tree (GUI).
Target produces a native binary.
LogManager * GetLogManager() const
bool IsScriptValid(ProjectBuildTarget *target, const wxString &script)
wxString & Item(size_t nIndex)
virtual wxString GetBasePath() const
Read the target's base path, e.g. if GetFilename() returns "/usr/local/bin/xxx", base path will retur...
void DisplayErrors(SquirrelError *exception=nullptr, bool clearErrors=true)
Display error dialog.
virtual wxString GetWorkingDir()
Read the target's working dir for execution (valid only for executable targets)
This is a base class for all classes needing compilation parameters.
static wxUniChar GetPathSeparator(wxPathFormat format=wxPATH_NATIVE)
virtual void SetWorkingDir(const wxString &dirname)
Set the target's working dir on execution (valid only for executable targets)
void SelectWildCard(const wxString &wild, bool select=true, bool clearOld=false)
void NotifyPlugins(CodeBlocksEvent &event)
const DLLIMPORT wxString NATIVE_EXT
EVTIMPORT const wxEventType cbEVT_PROJECT_TARGETS_MODIFIED
virtual void SetCreateStaticLib(bool createIt)
Set if an import library should be created.
MacrosManager * GetMacrosManager() const
No automatic generation; let the user specify the full filename.
virtual void SetItemText(const wxTreeItemId &item, const wxString &text)
const wxString & _(const wxString &string)
void ReplaceMacros(wxString &buffer, ProjectBuildTarget *target=nullptr, bool subrequest=false)
Base class for plugin configuration panels.
wxEventType wxEVT_KEY_DOWN
void OnCopyBuildTargetClick(wxCommandEvent &event)
int GetBuildTargetsCount()
void SetMakefile(const wxString &makefile)
Set the Makefile filename used when exporting a Makefile for the project, or when using a custom Make...
virtual int GetSelection() const
Target produces a static library.
ProjectBuildTarget * GetBuildTarget(int index)
Access a build target.
virtual void Expand(const wxTreeItemId &item)
const DLLIMPORT wxString EXECUTABLE_EXT
Abstract base class for compilers.
void OnKeyDown(wxKeyEvent &event)
void OnBuildTargetChanged(wxCommandEvent &event)
virtual void RemoveBuildScript(const wxString &script)
void OnFileMarkOffClick(wxCommandEvent &event)
DLLIMPORT void PlaceWindow(wxTopLevelWindow *w, cbPlaceDialogMode mode=pdlBest, bool enforce=false)
wxString GetPath(int flags=wxPATH_GET_VOLUME, wxPathFormat format=wxPATH_NATIVE) const
void SetProject(cbProject *project)
virtual const wxString & GetCompilerID() const
Read the target's compiler.
Target produces a console executable (without GUI) (distinction between ttExecutable and ttConsoleOnl...
void OnBrowseDefinitionFileFilenameClick(wxCommandEvent &event)
void Log(const wxString &msg, int i=app_log, Logger::level lv=Logger::info)
wxString GetFullName() const
void OnProjectBuildOptionsClick(wxCommandEvent &event)
virtual const CompilerSwitches & GetSwitches() const
Get the compiler's generic switches.
void SetTargetType(TargetType pt) override
Set the target's type to pt.
void SetExt(const wxString &ext)
void DoTargetChange(bool saveOld=true)
void OnUpdateUI(wxUpdateUIEvent &event)
void OnScriptsOverviewSelChanged(wxTreeEvent &event)
wxString & Prepend(const wxString &str)
cbCompilerPlugin * GetFirstCompiler() const
virtual wxTreeItemId AddRoot(const wxString &text, int image=-1, int selImage=-1, wxTreeItemData *data=NULL)
size_t Add(const wxString &str, size_t copies=1)
bool HasVirtualBuildTarget(const wxString &alias) const
Does a virtual build target exist?
bool StartsWith(const wxString &prefix, wxString *rest=NULL) const
void SetTitle(const wxString &title) override
Changes project title.
Represents a Code::Blocks project build target.
bool Normalize(int flags=wxPATH_NORM_ALL, const wxString &cwd=wxEmptyString, wxPathFormat format=wxPATH_NATIVE)
void SetExtendedObjectNamesGeneration(bool ext)
Sets object names generation to extended/normal mode.
virtual wxTreeItemId GetRootItem() const
void OnVirtualTargets(wxCommandEvent &event)
static wxXmlResource * Get()
virtual void SetTargetType(TargetType pt)
Set the target's type to pt.
void SetNotes(const wxString ¬es)
Set notes on the project.
ProjectBuildTarget * AddBuildTarget(const wxString &targetName)
Add a new build target.
ScriptingManager * GetScriptingManager() const
void RemoveAt(size_t nIndex, size_t count=1)
void AddBuildTarget(const wxString &targetName)
Make this file belong to an additional build target.
int Printf(const wxString &pszFormat,...)
void SetName(const wxString &name)
virtual wxString GetObjectOutput() const
Read the target's objects output dir.
wxString GetFullPath(wxPathFormat format=wxPATH_NATIVE) const
TargetType
Enum to define the type of output the target produces.
void SetParentDialog(wxWindow *dialog)
Sets the panel's parent dialog.
bool LoadBuffer(const wxString &buffer, const wxString &debugName=_T("CommandLine"))
Loads a string buffer.
virtual void SetValue(bool state)
bool RemoveBuildTarget(int index)
Remove a build target.
virtual wxString GetDynamicLibDefFilename()
Read the target's dynamic library definition file filename (produced if target type is ttDynamicLib) ...
virtual void SetBuildScripts(const wxArrayString &scripts)
void OnFileMarkOnClick(wxCommandEvent &event)
void SetMakefileExecutionDir(const wxString &dir)
Allow the specification of specific execution directory if the project use a custom Makefile...
void OnFileToggleMarkClick(wxCommandEvent &event)
wxObject * LoadObject(wxWindow *parent, const wxString &name, const wxString &classname)
ConfigurationPanelsArray m_PluginPanels
Dialog that contains a "Don't annoy me" checkbox.
virtual unsigned int GetCount() const
DLLIMPORT int cbMessageBox(const wxString &message, const wxString &caption=wxEmptyString, int style=wxOK, wxWindow *parent=NULL, int x=-1, int y=-1)
wxMessageBox wrapper.
wxTreeItemId AppendItem(const wxTreeItemId &parent, const wxString &text, int image=-1, int selImage=-1, wxTreeItemData *data=NULL)
bool RenameBuildTarget(int index, const wxString &targetName)
Rename a build target.
wxArrayString buildTargets
An array of strings, containing the names of all the build targets this file belongs to...
bool ExportTargetAsProject(int index)
Export a target as a new project.
Base class for build target classes Each Code::Blocks project consists of at least one target...
Target only runs commands in pre-build and/or post-build steps.