From 0c49712dea28b3b047fb7e012983d21736f492f7 Mon Sep 17 00:00:00 2001 From: Jarod42 Date: Sat, 13 Apr 2024 23:29:47 +0200 Subject: [PATCH] Remove CodeDesigner Plugin: - No longer provided. - no longer compile. --- CodeDesigner/CMakeLists.txt | 27 - CodeDesigner/CodeDesigner.project | 226 --- CodeDesigner/codedesigner.cpp | 649 -------- CodeDesigner/codedesigner.h | 89 - CodeDesigner/codedesignerdlg.cpp | 41 - CodeDesigner/codedesignerdlg.h | 27 - CodeDesigner/codedesigneritembasedlg.cpp | 137 -- CodeDesigner/codedesigneritembasedlg.fbp | 1467 ----------------- CodeDesigner/codedesigneritembasedlg.h | 71 - CodeDesigner/codedesigneritemdlg.cpp | 94 -- CodeDesigner/codedesigneritemdlg.h | 47 - CodeDesigner/codedesignersettingsbasedlg.cpp | 89 - CodeDesigner/codedesignersettingsbasedlg.fbp | 951 ----------- CodeDesigner/codedesignersettingsbasedlg.h | 62 - CodeDesigner/confcodedesigner.cpp | 22 - CodeDesigner/confcodedesigner.h | 34 - CodeDesigner/icons/ClassDiag.xpm | 22 - CodeDesigner/icons/SimpleStateChartDiag.xpm | 23 - CodeDesigner/icons/StateChartDiag.xpm | 22 - Runtime/templates/codedesigner/CDTemplate.cdp | 141 -- .../templates/codedesigner/HSCHTemplate.cdp | 113 -- .../codedesigner/HSCHTemplateWithMain.cdp | 150 -- .../templates/codedesigner/SCHTemplate.cdp | 113 -- .../codedesigner/SCHTemplateWithMain.cdp | 150 -- 24 files changed, 4767 deletions(-) delete mode 100644 CodeDesigner/CMakeLists.txt delete mode 100644 CodeDesigner/CodeDesigner.project delete mode 100644 CodeDesigner/codedesigner.cpp delete mode 100644 CodeDesigner/codedesigner.h delete mode 100644 CodeDesigner/codedesignerdlg.cpp delete mode 100644 CodeDesigner/codedesignerdlg.h delete mode 100644 CodeDesigner/codedesigneritembasedlg.cpp delete mode 100644 CodeDesigner/codedesigneritembasedlg.fbp delete mode 100644 CodeDesigner/codedesigneritembasedlg.h delete mode 100644 CodeDesigner/codedesigneritemdlg.cpp delete mode 100644 CodeDesigner/codedesigneritemdlg.h delete mode 100644 CodeDesigner/codedesignersettingsbasedlg.cpp delete mode 100644 CodeDesigner/codedesignersettingsbasedlg.fbp delete mode 100644 CodeDesigner/codedesignersettingsbasedlg.h delete mode 100644 CodeDesigner/confcodedesigner.cpp delete mode 100644 CodeDesigner/confcodedesigner.h delete mode 100644 CodeDesigner/icons/ClassDiag.xpm delete mode 100644 CodeDesigner/icons/SimpleStateChartDiag.xpm delete mode 100644 CodeDesigner/icons/StateChartDiag.xpm delete mode 100644 Runtime/templates/codedesigner/CDTemplate.cdp delete mode 100644 Runtime/templates/codedesigner/HSCHTemplate.cdp delete mode 100644 Runtime/templates/codedesigner/HSCHTemplateWithMain.cdp delete mode 100644 Runtime/templates/codedesigner/SCHTemplate.cdp delete mode 100644 Runtime/templates/codedesigner/SCHTemplateWithMain.cdp diff --git a/CodeDesigner/CMakeLists.txt b/CodeDesigner/CMakeLists.txt deleted file mode 100644 index e530f531ea..0000000000 --- a/CodeDesigner/CMakeLists.txt +++ /dev/null @@ -1,27 +0,0 @@ -# set the plugin name here -set(PLUGIN_NAME "CodeDesigner") - -# Our project is called 'plugin' this is how it will be called in visual studio, and in our makefiles. -project(${PLUGIN_NAME}) - -# It was noticed that when using MinGW gcc it is essential that 'core' is mentioned before 'base'. - -# wxWidgets include (this will do all the magic to configure everything) -include("${wxWidgets_USE_FILE}") - -# Include paths -include_directories("${CL_SRC_ROOT}/Plugin" "${CL_SRC_ROOT}/sdk/wxsqlite3/include" "${CL_SRC_ROOT}/CodeLite" - "${CL_SRC_ROOT}/CodeLite/ssh" "${CL_SRC_ROOT}/PCH" "${CL_SRC_ROOT}/Interfaces") - -add_definitions(-DWXUSINGDLL_WXSQLITE3) -add_definitions(-DWXUSINGDLL_CL) -add_definitions(-DWXUSINGDLL_SDK) - -file(GLOB SRCS "*.cpp") - -# Define the output -add_library(${PLUGIN_NAME} SHARED ${SRCS}) - -# Remove the "lib" prefix from the plugin name -set_target_properties(${PLUGIN_NAME} PROPERTIES PREFIX "") -target_link_libraries(${PLUGIN_NAME} ${LINKER_OPTIONS} ${wxWidgets_LIBRARIES} -L"${CL_LIBPATH}" libcodelite plugin) diff --git a/CodeDesigner/CodeDesigner.project b/CodeDesigner/CodeDesigner.project deleted file mode 100644 index fb0e6a7e77..0000000000 --- a/CodeDesigner/CodeDesigner.project +++ /dev/null @@ -1,226 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/CodeDesigner/codedesigner.cpp b/CodeDesigner/codedesigner.cpp deleted file mode 100644 index d967732ff4..0000000000 --- a/CodeDesigner/codedesigner.cpp +++ /dev/null @@ -1,649 +0,0 @@ -#include "codedesigner.h" -#include "codedesignerdlg.h" -#include "project.h" -#include "confcodedesigner.h" -#include "procutils.h" -#include "workspace.h" -#include "processreaderthread.h" -#include "asyncprocess.h" -#include "globals.h" -#include "virtualdirectoryselector.h" -#include -#include -#include -#include -#include -#include - -#include -#include - -#include "icons/ClassDiag.xpm" -#include "icons/StateChartDiag.xpm" -#include "icons/SimpleStateChartDiag.xpm" - -#define TOPIC wxT("CODEDESIGNER SESSION") - -wxEventType wxEVT_IPC_POKE = wxNewEventType(); - -WX_DEFINE_LIST(ConnectionList); - -static CodeDesigner* thePlugin = NULL; - -// Define the plugin entry point -extern "C" EXPORT IPlugin* CreatePlugin(IManager* manager) -{ - if(thePlugin == 0) { - thePlugin = new CodeDesigner(manager); - } - return thePlugin; -} - -extern "C" EXPORT PluginInfo GetPluginInfo() -{ - PluginInfo info; - info.SetAuthor(wxT("Michal Bližňák")); - info.SetName(wxT("CodeDesigner")); - info.SetDescription(_("CodeDesigner RAD integration with CodeLite")); - info.SetVersion(wxT("v1.0")); - return info; -} - -extern "C" EXPORT int GetPluginInterfaceVersion() { return PLUGIN_INTERFACE_VERSION; } - -CodeDesigner::CodeDesigner(IManager* manager) - : IPlugin(manager) - , m_addFileMenu(true) -{ - m_longName = _("CodeDesigner RAD integration with CodeLite"); - m_shortName = wxT("CodeDesigner"); - - m_Server = NULL; - - m_mgr->GetTheApp()->Connect(XRCID("cd_open"), wxEVT_COMMAND_MENU_SELECTED, - wxCommandEventHandler(CodeDesigner::OnOpenWithCD), NULL, this); - m_mgr->GetTheApp()->Connect(XRCID("cd_open"), wxEVT_UPDATE_UI, - wxUpdateUIEventHandler(CodeDesigner::OnUpdateOpenWithCD), NULL, this); - m_mgr->GetTheApp()->Connect(XRCID("cd_new_simplestatechart"), wxEVT_COMMAND_MENU_SELECTED, - wxCommandEventHandler(CodeDesigner::OnNewSCH), NULL, this); - m_mgr->GetTheApp()->Connect(XRCID("cd_new_hierarchicalstatechart"), wxEVT_COMMAND_MENU_SELECTED, - wxCommandEventHandler(CodeDesigner::OnNewHSCH), NULL, this); - m_mgr->GetTheApp()->Connect(XRCID("cd_new_classdiagram"), wxEVT_COMMAND_MENU_SELECTED, - wxCommandEventHandler(CodeDesigner::OnNewCD), NULL, this); - - m_mgr->GetTheApp()->Connect(wxEVT_TREE_ITEM_FILE_ACTIVATED, wxCommandEventHandler(CodeDesigner::OnOpenFile), NULL, - this); - - m_mgr->GetTheApp()->Connect(wxID_ANY, wxEVT_PROC_TERMINATED, wxCommandEventHandler(CodeDesigner::OnCDTerminated), - NULL, this); - - Connect(wxID_ANY, wxEVT_IPC_POKE, wxCommandEventHandler(CodeDesigner::OnPokeData)); - - // start IPC server - StartServer(); -} - -CodeDesigner::~CodeDesigner() { delete m_Server; } - -clToolBar* CodeDesigner::CreateToolBar(wxWindow* parent) -{ - // Create the toolbar to be used by the plugin - clToolBar* tb(NULL); - - /* - // You can use the below code a snippet: - // First, check that CodeLite allows plugin to register plugins - if (m_mgr->AllowToolbar()) { - // Support both toolbars icon size - int size = m_mgr->GetToolbarIconSize(); - - // Allocate new toolbar, which will be freed later by CodeLite - tb = new clToolBar(parent, wxID_ANY, wxDefaultPosition, wxDefaultSize, clTB_DEFAULT_STYLE); - - // Set the toolbar size - tb->SetToolBitmapSize(wxSize(size, size)); - - // Add tools to the plugins toolbar. You must provide 2 sets of icons: 24x24 and 16x16 - if (size == 24) { - tb->AddTool(XRCID("new_plugin"), wxT("New CodeLite Plugin Project"), - wxXmlResource::Get()->LoadBitmap(wxT("plugin24")), wxT("New Plugin Wizard...")); - tb->AddTool(XRCID("new_class"), wxT("Create New Class"), - wxXmlResource::Get()->LoadBitmap(wxT("class24")), wxT("New Class...")); - tb->AddTool(XRCID("new_wx_project"), wxT("New wxWidget Project"), - wxXmlResource::Get()->LoadBitmap(wxT("new_wx_project24")), wxT("New wxWidget Project")); - } else { - tb->AddTool(XRCID("new_plugin"), wxT("New CodeLite Plugin Project"), - wxXmlResource::Get()->LoadBitmap(wxT("plugin16")), wxT("New Plugin Wizard...")); - tb->AddTool(XRCID("new_class"), wxT("Create New Class"), - wxXmlResource::Get()->LoadBitmap(wxT("class16")), wxT("New Class...")); - tb->AddTool(XRCID("new_wx_project"), wxT("New wxWidget Project"), - wxXmlResource::Get()->LoadBitmap(wxT("new_wx_project16")), wxT("New wxWidget Project")); - } - // And finally, we must call 'Realize()' - tb->Realize(); - } - - // return the toolbar, it can be NULL if CodeLite does not allow plugins to register toolbars - // or in case the plugin simply does not require toolbar - */ - return tb; -} - -void CodeDesigner::CreatePluginMenu(wxMenu* pluginsMenu) -{ - // You can use the below code a snippet: - wxMenu* menu = new wxMenu(); - wxMenuItem* item(NULL); - - item = new wxMenuItem(menu, XRCID("cd_settings"), _("Settings..."), wxEmptyString, wxITEM_NORMAL); - menu->Append(item); - - pluginsMenu->Append(wxID_ANY, _("CodeDesigner"), menu); - - m_mgr->GetTheApp()->Connect(XRCID("cd_settings"), wxEVT_COMMAND_MENU_SELECTED, - wxCommandEventHandler(CodeDesigner::OnSettings), NULL, this); -} - -void CodeDesigner::HookPopupMenu(wxMenu* menu, MenuType type) -{ - if(type == MenuTypeEditor) { - // TODO::Append items for the editor context menu - } else if(type == MenuTypeFileExplorer) { - // TODO::Append items for the file explorer context menu - } else if(type == MenuTypeFileView_Workspace) { - // TODO::Append items for the file view / workspace context menu - } else if(type == MenuTypeFileView_Project) { - // TODO::Append items for the file view/Project context menu - } else if(type == MenuTypeFileView_Folder) { - // TODO::Append items for the file view/Virtual folder context menu - if(!menu->FindItem(XRCID("cd_popup"))) { - m_separatorItem = menu->AppendSeparator(); - menu->Append(XRCID("cd_popup"), _("CodeDesigner"), CreatePopupMenu()); - } - } else if(type == MenuTypeFileView_File) { - // TODO::Append items for the file view/file context menu - if(m_addFileMenu) { - wxMenuItem* item = - new wxMenuItem(menu, XRCID("cd_open"), _("Open with CodeDesigner..."), wxEmptyString, wxITEM_NORMAL); - - menu->PrependSeparator(); - menu->Prepend(item); - - m_addFileMenu = false; - } - } -} - -void CodeDesigner::UnHookPopupMenu(wxMenu* menu, MenuType type) -{ - if(type == MenuTypeEditor) { - // TODO::Unhook items for the editor context menu - } else if(type == MenuTypeFileExplorer) { - // TODO::Unhook items for the file explorer context menu - } else if(type == MenuTypeFileView_Workspace) { - // TODO::Unhook items for the file view / workspace context menu - } else if(type == MenuTypeFileView_Project) { - // TODO::Unhook items for the file view/Project context menu - } else if(type == MenuTypeFileView_Folder) { - // TODO::Unhook items for the file view/Virtual folder context menu - } else if(type == MenuTypeFileView_File) { - // TODO::Unhook items for the file view/file context menu - } -} - -void CodeDesigner::UnPlug() -{ - // TODO:: perform the unplug action for this plugin -} - -void CodeDesigner::OnSettings(wxCommandEvent& e) -{ - CodeDesignerDlg dlg(m_mgr->GetTheApp()->GetTopWindow()); - - ConfCodeDesigner data; - m_mgr->GetConfigTool()->ReadObject(wxT("CodeDesigner"), &data); - - dlg.SetPort(data.GetPort()); - dlg.SetPath(data.GetPath()); - - if(dlg.ShowModal() == wxID_OK) { - bool fRestartServer = false; - - if(data.GetPort() != dlg.GetPort()) fRestartServer = true; - - data.SetPort(dlg.GetPort()); - data.SetPath(dlg.GetPath()); - - m_mgr->GetConfigTool()->WriteObject(wxT("CodeDesigner"), &data); - - if(fRestartServer) StartServer(); - } -} - -wxMenu* CodeDesigner::CreatePopupMenu() -{ - // Create the popup menu for the file explorer - // The only menu that we are interseted is the file explorer menu - wxMenu* menu = new wxMenu(); - wxMenuItem* item(NULL); - - item = new wxMenuItem(menu, XRCID("cd_new_simplestatechart"), _("New simple state chart..."), wxEmptyString, - wxITEM_NORMAL); - item->SetBitmap(wxBitmap(SimpleStateChartDiag_xpm)); - menu->Append(item); - - item = new wxMenuItem(menu, XRCID("cd_new_hierarchicalstatechart"), _("New hierarchical state chart..."), - wxEmptyString, wxITEM_NORMAL); - item->SetBitmap(wxBitmap(StateChartDiag_xpm)); - menu->Append(item); - - item = new wxMenuItem(menu, XRCID("cd_new_classdiagram"), _("New class diagram..."), wxEmptyString, wxITEM_NORMAL); - item->SetBitmap(wxBitmap(ClassDiag_xpm)); - menu->Append(item); - - return menu; -} - -void CodeDesigner::OnOpenFile(wxCommandEvent& e) -{ - wxString* fn = (wxString*)e.GetClientData(); - if(fn) { - // launch it with the default application - wxFileName fullpath(*fn); - if(fullpath.GetExt().MakeLower() != wxT("cdp")) { - e.Skip(); - return; - } -#ifdef __WXGTK__ - // Under Linux, use xdg-open - wxString cmd; - cmd << wxT("/bin/sh -c 'xdg-open \"") << fullpath.GetFullPath() << wxT("\"' 2> /dev/null"); - wxExecute(cmd); - return; -#else - - wxMimeTypesManager* mgr = wxTheMimeTypesManager; - wxFileType* type = mgr->GetFileTypeFromExtension(fullpath.GetExt()); - if(type) { - wxString cmd = type->GetOpenCommand(fullpath.GetFullPath()); - delete type; - - if(cmd.IsEmpty() == false) { - wxExecute(cmd); - return; - } - } -#endif - } - - // we failed, call event.Skip() - e.Skip(); -} - -void CodeDesigner::OnOpenWithCD(wxCommandEvent& e) -{ - // get the file name - TreeItemInfo item = m_mgr->GetSelectedTreeItemInfo(TreeFileView); - if(item.m_item.IsOk() && item.m_itemType == ProjectItem::TypeFile) { - if(item.m_fileName.GetExt() == wxT("cdp")) { - DoLaunchCD(item.m_fileName.GetFullPath()); - } else { - wxMessageBox(_("Please select a 'cdp' (CodeDesigner Project) file only"), _("CodeLite"), - wxOK | wxCENTER | wxICON_INFORMATION); - return; - } - } -} - -void CodeDesigner::DoLaunchCD(const wxString& file) -{ - wxString cdpath = GetCDPath(); - - if(cdpath.IsEmpty()) { - wxMessageBox(_("Failed to launch CodeDesigner, no path specified\nPlease set CodeDesigner path from Plugins -> " - "CodeDesigner -> Settings..."), - _("CodeLite"), wxOK | wxCENTER | wxICON_WARNING); - return; - } - - wxString cmd = wxT("$(cd) $(cd_project)"); - cmd.Replace(wxT("$(cd)"), cdpath); - cmd.Replace(wxT("$(cd_project)"), wxString::Format(wxT("\"%s\""), file.c_str())); - -#ifdef __WXMSW__ - wxExecute(cmd, wxEXEC_ASYNC); -#else - WrapInShell(cmd); - CreateAsyncProcess(this, cmd, IProcessCreateWithHiddenConsole); -#endif -} - -wxString CodeDesigner::GetCDPath() -{ - // Launch wxFB - ConfCodeDesigner confData; - m_mgr->GetConfigTool()->ReadObject(wxT("CodeDesigner"), &confData); - wxString cdpath = confData.GetPath(); - -#ifdef __WXGTK__ - if(cdpath.IsEmpty()) { - // try to locate the file at '/usr/bin' or '/usr/local/bin' - if(wxFileName::FileExists(wxT("/usr/local/bin/codedesigner"))) { - cdpath = wxT("/usr/local/bin/codedesigner"); - } else if(wxFileName::FileExists(wxT("/usr/bin/codedesigner"))) { - cdpath = wxT("/usr/bin/codedesigner"); - } - } -#endif - return cdpath; -} - -void CodeDesigner::OnUpdateOpenWithCD(wxUpdateUIEvent& e) -{ - TreeItemInfo item = m_mgr->GetSelectedTreeItemInfo(TreeFileView); - if(item.m_item.IsOk() && item.m_itemType == ProjectItem::TypeFile) { - e.Enable(item.m_fileName.GetExt() == wxT("cdp")); - } -} - -void CodeDesigner::OnCDTerminated(wxCommandEvent& e) -{ - ProcessEventData* ped = (ProcessEventData*)e.GetClientData(); - if(ped) { - if(ped->GetProcess()) delete ped->GetProcess(); - delete ped; - } -} - -void CodeDesigner::OnNewCD(wxCommandEvent& e) -{ - CodeDesignerItemDlg dlg(m_mgr->GetTheApp()->GetTopWindow(), m_mgr, false); - dlg.SetTitle(_("New Class Diagram")); - - CDItemInfo info; - info.m_PackageName = wxT("Classes"); - - dlg.SetCDInfo(info); - if(dlg.ShowModal() == wxID_OK) { - info = dlg.GetCDInfo(); - info.m_Type = cdtClassDiagram; - - DoCreateCDProject(info); - } -} - -void CodeDesigner::OnNewHSCH(wxCommandEvent& e) -{ - CodeDesignerItemDlg dlg(m_mgr->GetTheApp()->GetTopWindow(), m_mgr, true); - dlg.SetTitle(_("New Hierarchical State Chart")); - - CDItemInfo info; - info.m_PackageName = wxT("State charts"); - - dlg.SetCDInfo(info); - if(dlg.ShowModal() == wxID_OK) { - info = dlg.GetCDInfo(); - info.m_Type = cdtHierarchicalStateChart; - - DoCreateCDProject(info); - } -} - -void CodeDesigner::OnNewSCH(wxCommandEvent& e) -{ - CodeDesignerItemDlg dlg(m_mgr->GetTheApp()->GetTopWindow(), m_mgr, true); - dlg.SetTitle(_("New Simple State Chart")); - - CDItemInfo info; - info.m_PackageName = wxT("State charts"); - - dlg.SetCDInfo(info); - if(dlg.ShowModal() == wxID_OK) { - info = dlg.GetCDInfo(); - info.m_Type = cdtStateChart; - - DoCreateCDProject(info); - } -} - -void CodeDesigner::DoCreateCDProject(CDItemInfo& info) -{ - // add new virtual folder to the selected virtual directory - wxString codedesignerVD; - codedesignerVD = info.m_TreeFolderName.BeforeFirst(wxT(':')); - - m_mgr->CreateVirtualDirectory(codedesignerVD, wxT("codedesigner")); - wxString templateFile(m_mgr->GetInstallDirectory() + wxT("/templates/codedesigner/")); - // wxString - // templateFile(wxT("/home/michal/Src/Projekty/CodeLite_dev/CLInstall/share/codelite/templates/codedesigner/")); - - switch(info.m_Type) { - default: - case cdtClassDiagram: - templateFile << wxT("CDTemplate.cdp"); - break; - case cdtStateChart: - if(info.m_UseMain) - templateFile << wxT("SCHTemplateWithMain.cdp"); - else - templateFile << wxT("SCHTemplate.cdp"); - break; - case cdtHierarchicalStateChart: - if(info.m_UseMain) - templateFile << wxT("HSCHTemplateWithMain.cdp"); - else - templateFile << wxT("HSCHTemplate.cdp"); - break; - } - - wxFileName tmplFile(templateFile); - if(!tmplFile.FileExists()) { - wxMessageBox(wxString::Format(_("Can't find CodeDesigner template file '%s'"), tmplFile.GetFullPath().c_str()), - _("CodeLite"), wxOK | wxCENTER | wxICON_WARNING); - return; - } - - // place the files under the VD's project owner - wxString err_msg; - wxString project = info.m_TreeFolderName.BeforeFirst(wxT(':')); - ProjectPtr proj = m_mgr->GetWorkspace()->FindProjectByName(project, err_msg); - if(proj) { - wxString files_path = proj->GetFileName().GetPath(wxPATH_GET_SEPARATOR | wxPATH_GET_VOLUME); - // copy the file to here - wxFileName cdpFile(files_path, info.m_DiagramName.Lower() + wxT(".cdp")); - if(!wxCopyFile(tmplFile.GetFullPath(), cdpFile.GetFullPath())) { - wxMessageBox(wxString::Format(_("Failed to copy template file to '%s'"), cdpFile.GetFullPath().c_str()), - _("CodeLite"), wxOK | wxCENTER | wxICON_WARNING); - return; - } - // open the file, and replace expand its macros - wxString content; - if(!ReadFileWithConversion(cdpFile.GetFullPath().c_str(), content)) { - wxMessageBox(wxString::Format(_("Failed to read file '%s'"), cdpFile.GetFullPath().c_str()), _("CodeLite"), - wxOK | wxCENTER | wxICON_WARNING); - return; - } - - wxString fileName = info.m_DiagramName.Lower(); - - content.Replace(wxT("$(BaseFileName)"), fileName); - content.Replace(wxT("$(CIFileName)"), fileName + wxT("_ci")); - content.Replace(wxT("$(PackageName)"), info.m_PackageName); - content.Replace(wxT("$(DiagramName)"), info.m_DiagramName); - content.Replace(wxT("$(Language)"), info.m_Language); - - if(!WriteFileWithBackup(cdpFile.GetFullPath().c_str(), content, false)) { - wxMessageBox(wxString::Format(_("Failed to write file '%s'"), cdpFile.GetFullPath().c_str()), _("CodeLite"), - wxOK | wxCENTER | wxICON_WARNING); - return; - } - - // add the file to the project - wxArrayString paths; - paths.Add(cdpFile.GetFullPath()); - m_mgr->AddFilesToVirtualFolder(project + wxT(":codedesigner"), paths); - - if(info.m_GenerateCode) { - // first we launch CodeDesigner with the -g flag set - wxString genFileCmd; - genFileCmd << GetCDPath() << wxT(" -g ") << cdpFile.GetFullPath(); - - wxArrayString dummy; - ProcUtils::SafeExecuteCommand(genFileCmd, dummy); - - wxFileName cFile(cdpFile.GetPath(), fileName + wxT(".c")); - wxFileName cppFile(cdpFile.GetPath(), fileName + wxT(".cpp")); - wxFileName cCiFile(cdpFile.GetPath(), fileName + wxT("_ci.c")); - wxFileName cppCiFile(cdpFile.GetPath(), fileName + wxT("_ci.cpp")); - wxFileName headerFile(cdpFile.GetPath(), fileName + wxT(".h")); - wxFileName headerCiFile(cdpFile.GetPath(), fileName + wxT("_ci.h")); - wxFileName pyFile(cdpFile.GetPath(), fileName + wxT(".py")); - wxFileName pyCiFile(cdpFile.GetPath(), fileName + wxT("_ci.py")); - - paths.Clear(); - - if(cFile.FileExists()) paths.Add(cFile.GetFullPath()); - if(cppFile.FileExists()) paths.Add(cppFile.GetFullPath()); - if(headerFile.FileExists()) paths.Add(headerFile.GetFullPath()); - if(cCiFile.FileExists()) paths.Add(cCiFile.GetFullPath()); - if(cppCiFile.FileExists()) paths.Add(cppCiFile.GetFullPath()); - if(headerCiFile.FileExists()) paths.Add(headerCiFile.GetFullPath()); - if(pyFile.FileExists()) paths.Add(pyFile.GetFullPath()); - if(pyCiFile.FileExists()) paths.Add(pyCiFile.GetFullPath()); - - if(paths.GetCount()) { - m_mgr->AddFilesToVirtualFolder(info.m_TreeFolderName, paths); - } - - RetagWorkspace(); - } - - DoLaunchCD(cdpFile.GetFullPath()); - } -} - -void CodeDesigner::StartServer() -{ - ConfCodeDesigner data; - m_mgr->GetConfigTool()->ReadObject(wxT("CodeDesigner"), &data); - - delete m_Server; - - m_Server = new CDServer(); - if(!m_Server->Create(data.GetPort())) { - delete m_Server; - m_Server = NULL; - - // wxMessageBox( _("Unable to create CodeDesigner plugin's IPC server. Please, check communication port value"), - // _("CodeLite"), wxOK | wxICON_WARNING ); - } -} - -void CodeDesigner::RetagWorkspace() -{ - wxCommandEvent e(wxEVT_COMMAND_MENU_SELECTED, XRCID("retag_workspace")); - m_mgr->GetTheApp()->GetTopWindow()->GetEventHandler()->AddPendingEvent(e); -} - -bool CodeDesigner::AddFilesToWorkspace(wxArrayString& paths, CDConnection* connection) -{ - // get tree folder if not specified - if(connection->GetTreeFolder().IsEmpty()) { - m_mgr->GetTheApp()->GetTopWindow()->Raise(); - - VirtualDirectorySelector dlg(m_mgr->GetTheApp()->GetTopWindow(), m_mgr->GetWorkspace(), wxT("")); - dlg.SetTitle(_("Insert generated files into...")); - - if(dlg.ShowModal() == wxID_OK) { - connection->SetTreeFolder(dlg.GetVirtualDirectoryPath()); - } else - return false; - } - - // check whether given files are already included in the project - wxArrayString arrFilesToAdd; - - wxString err_msg; - wxString project = connection->GetTreeFolder().BeforeFirst(wxT(':')); - ProjectPtr proj = m_mgr->GetWorkspace()->FindProjectByName(project, err_msg); - if(proj) { - std::vector vctPresentFiles; - proj->GetFiles(vctPresentFiles, true); - - for(size_t i = 0; i < paths.GetCount(); ++i) { - wxFileName file(paths[i]); - if(std::find(vctPresentFiles.begin(), vctPresentFiles.end(), file) == vctPresentFiles.end()) { - arrFilesToAdd.Add(paths[i]); - } - } - } - - // update CodeLite workspace - if(!arrFilesToAdd.IsEmpty()) m_mgr->AddFilesToVirtualFolder(connection->GetTreeFolder(), arrFilesToAdd); - - RetagWorkspace(); - - return true; -} - -void CodeDesigner::OnPokeData(wxCommandEvent& e) -{ - wxArrayString arrFiles; - wxStringTokenizer tokens(e.GetString(), wxT("\n"), wxTOKEN_STRTOK); - - while(tokens.HasMoreTokens()) { - arrFiles.Add(tokens.GetNextToken()); - } - - AddFilesToWorkspace(arrFiles, (CDConnection*)e.GetClientData()); -} - -// IPC ///////////////////////////////////////////////////////////////////////// - -CDConnection::CDConnection(CDServer* server) { m_Server = server; } - -CDConnection::~CDConnection() { Disconnect(); } - -bool CDConnection::OnDisconnect() -{ - m_Server->Disconnect(this); - return true; -} - -bool CDConnection::OnPoke(const wxString& topic, const wxString& item, wxChar* data, int size, wxIPCFormat format) -{ - if(topic == TOPIC) { - if(item == wxT("ADD FILES")) { - wxCommandEvent e(wxEVT_IPC_POKE, wxID_ANY); - e.SetString(wxString(data)); - e.SetClientData(this); - - wxPostEvent(thePlugin, e); - } - - return true; - } else - return false; -} - -CDServer::CDServer() { m_Connections.DeleteContents(true); } - -CDServer::~CDServer() { m_Connections.Clear(); } - -wxConnectionBase* CDServer::OnAcceptConnection(const wxString& topic) -{ - if(topic == TOPIC) { - CDConnection* connection = new CDConnection(this); - m_Connections.Append(connection); - - return connection; - } else - return NULL; -} - -void CDServer::Disconnect(CDConnection* connection) -{ - if(connection) { - m_Connections.DeleteObject(connection); - } -} diff --git a/CodeDesigner/codedesigner.h b/CodeDesigner/codedesigner.h deleted file mode 100644 index b9e1da4108..0000000000 --- a/CodeDesigner/codedesigner.h +++ /dev/null @@ -1,89 +0,0 @@ -#ifndef __CodeDesigner__ -#define __CodeDesigner__ - -#include "plugin.h" -#include "codedesigneritemdlg.h" -#include -#include - -class CDServer; -class CDConnection; - -class CodeDesigner : public IPlugin -{ -public: - CodeDesigner(IManager *manager); - ~CodeDesigner(); - - IManager* GetManager() { return m_mgr; } - - void RetagWorkspace(); - bool AddFilesToWorkspace(wxArrayString& paths, CDConnection *connectio ); - - //-------------------------------------------- - //Abstract methods - //-------------------------------------------- - virtual clToolBar *CreateToolBar(wxWindow *parent); - virtual void CreatePluginMenu(wxMenu *pluginsMenu); - virtual void HookPopupMenu(wxMenu *menu, MenuType type); - virtual void UnHookPopupMenu(wxMenu *menu, MenuType type); - virtual void UnPlug(); - -protected: - bool m_addFileMenu; - wxMenuItem* m_separatorItem; - CDServer *m_Server; - - wxMenu *CreatePopupMenu(); - void DoLaunchCD(const wxString &file); - void DoCreateCDProject(CDItemInfo &info); - wxString GetCDPath(); - void StartServer(); - - void OnSettings(wxCommandEvent &e); - void OnOpenFile(wxCommandEvent &e); - void OnOpenWithCD(wxCommandEvent &e); - void OnUpdateOpenWithCD(wxUpdateUIEvent &e); - void OnCDTerminated(wxCommandEvent &e); - void OnNewSCH(wxCommandEvent &e); - void OnNewHSCH(wxCommandEvent &e); - void OnNewCD(wxCommandEvent &e); - void OnPokeData(wxCommandEvent &e); -}; - -class CDServer; - -class CDConnection : public wxConnection -{ -public: - CDConnection(CDServer *server); - virtual ~CDConnection(); - - virtual bool OnPoke(const wxString& topic, const wxString& item, wxChar *data, int size, wxIPCFormat format); - virtual bool OnDisconnect(); - - void SetTreeFolder(const wxString& TreeFolder) {this->m_TreeFolder = TreeFolder;} - const wxString& GetTreeFolder() const {return m_TreeFolder;} - -protected: - CDServer *m_Server; - wxString m_TreeFolder; -}; - -WX_DECLARE_LIST(CDConnection, ConnectionList); - -class CDServer : public wxServer -{ -public: - CDServer(); - virtual ~CDServer(); - - void Disconnect(CDConnection *connection); - - virtual wxConnectionBase *OnAcceptConnection(const wxString& topic); - -protected: - ConnectionList m_Connections; -}; - -#endif //CodeDesigner diff --git a/CodeDesigner/codedesignerdlg.cpp b/CodeDesigner/codedesignerdlg.cpp deleted file mode 100644 index 68e606b276..0000000000 --- a/CodeDesigner/codedesignerdlg.cpp +++ /dev/null @@ -1,41 +0,0 @@ -#include "codedesignerdlg.h" -#include - -CodeDesignerDlg::CodeDesignerDlg(wxWindow *parent) : CodeDesignerBaseDlg(parent) -{ -} - -CodeDesignerDlg::~CodeDesignerDlg() -{ -} - -void CodeDesignerDlg::OnButtonBrowse(wxCommandEvent& event) -{ - wxUnusedVar(event); - wxString new_path = wxFileSelector(_("Select CodeDesigner executable:"), m_textCtrlCDPath->GetValue().c_str(), wxT(""), wxT(""), wxFileSelectorDefaultWildcardStr, 0, this); - if ( !new_path.IsEmpty() ) - { - m_textCtrlCDPath->SetValue( new_path ); - } -} - -void CodeDesignerDlg::OnButtonCancel(wxCommandEvent& event) -{ - EndModal( wxID_CANCEL ); -} - -void CodeDesignerDlg::OnButtonOK(wxCommandEvent& event) -{ - m_Path = m_textCtrlCDPath->GetValue(); - m_Port = m_textCtrlComPort->GetValue(); - - EndModal( wxID_OK ); -} - -void CodeDesignerDlg::OnInit(wxInitDialogEvent& event) -{ - m_textCtrlCDPath->SetValue( m_Path ); - m_textCtrlComPort->SetValue( m_Port ); - - event.Skip(); -} diff --git a/CodeDesigner/codedesignerdlg.h b/CodeDesigner/codedesignerdlg.h deleted file mode 100644 index 1ee757eb61..0000000000 --- a/CodeDesigner/codedesignerdlg.h +++ /dev/null @@ -1,27 +0,0 @@ -#ifndef CODEDESIGNERDLG_H -#define CODEDESIGNERDLG_H - -#include "codedesignersettingsbasedlg.h" // Base class: CodeDesignerBaseDlg - -class CodeDesignerDlg : public CodeDesignerBaseDlg { - -public: - CodeDesignerDlg(wxWindow *parent); - virtual ~CodeDesignerDlg(); - - void SetPath(const wxString& Path) {this->m_Path = Path;} - void SetPort(const wxString& Port) {this->m_Port = Port;} - const wxString& GetPath() const {return m_Path;} - const wxString& GetPort() const {return m_Port;} - -protected: - wxString m_Path; - wxString m_Port; - - virtual void OnButtonBrowse(wxCommandEvent& event); - virtual void OnButtonCancel(wxCommandEvent& event); - virtual void OnButtonOK(wxCommandEvent& event); - virtual void OnInit(wxInitDialogEvent& event); -}; - -#endif // CODEDESIGNERDLG_H diff --git a/CodeDesigner/codedesigneritembasedlg.cpp b/CodeDesigner/codedesigneritembasedlg.cpp deleted file mode 100644 index c541239f4d..0000000000 --- a/CodeDesigner/codedesigneritembasedlg.cpp +++ /dev/null @@ -1,137 +0,0 @@ -/////////////////////////////////////////////////////////////////////////// -// C++ code generated with wxFormBuilder (version Nov 29 2010) -// http://www.wxformbuilder.org/ -// -// PLEASE DO "NOT" EDIT THIS FILE! -/////////////////////////////////////////////////////////////////////////// - -#include "codedesigneritembasedlg.h" - -/////////////////////////////////////////////////////////////////////////// - -CodeDesignerItemBaseDlg::CodeDesignerItemBaseDlg( wxWindow* parent, wxWindowID id, const wxString& title, const wxPoint& pos, const wxSize& size, long style ) : wxDialog( parent, id, title, pos, size, style ) -{ - this->SetSizeHints( wxDefaultSize, wxDefaultSize ); - - wxBoxSizer* mainSizer; - mainSizer = new wxBoxSizer( wxVERTICAL ); - - wxStaticBoxSizer* sbSizer1; - sbSizer1 = new wxStaticBoxSizer( new wxStaticBox( this, wxID_ANY, _("CodeDesigner project settings:") ), wxVERTICAL ); - - wxFlexGridSizer* controlsSizer; - controlsSizer = new wxFlexGridSizer( 0, 2, 0, 0 ); - controlsSizer->SetFlexibleDirection( wxBOTH ); - controlsSizer->SetNonFlexibleGrowMode( wxFLEX_GROWMODE_SPECIFIED ); - - m_staticText1 = new wxStaticText( this, wxID_ANY, _("Package name:"), wxDefaultPosition, wxDefaultSize, 0 ); - m_staticText1->Wrap( -1 ); - controlsSizer->Add( m_staticText1, 0, wxALL|wxALIGN_CENTER_VERTICAL, 5 ); - - m_textPackageName = new wxTextCtrl( this, wxID_ANY, wxEmptyString, wxDefaultPosition, wxSize( 300,-1 ), 0 ); - m_textPackageName->SetMinSize( wxSize( 300,-1 ) ); - - controlsSizer->Add( m_textPackageName, 0, wxTOP|wxBOTTOM|wxRIGHT, 5 ); - - m_staticText2 = new wxStaticText( this, wxID_ANY, _("Diagram name:"), wxDefaultPosition, wxDefaultSize, 0 ); - m_staticText2->Wrap( -1 ); - controlsSizer->Add( m_staticText2, 0, wxALL|wxALIGN_CENTER_VERTICAL, 5 ); - - m_textDiagramName = new wxTextCtrl( this, wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0 ); - controlsSizer->Add( m_textDiagramName, 0, wxTOP|wxBOTTOM|wxRIGHT|wxEXPAND, 5 ); - - m_staticText4 = new wxStaticText( this, wxID_ANY, _("Language:"), wxDefaultPosition, wxDefaultSize, 0 ); - m_staticText4->Wrap( -1 ); - controlsSizer->Add( m_staticText4, 0, wxALL|wxALIGN_CENTER_VERTICAL, 5 ); - - wxString m_choiceLanguageChoices[] = { _("C"), _("C++"), _("Python") }; - int m_choiceLanguageNChoices = sizeof( m_choiceLanguageChoices ) / sizeof( wxString ); - m_choiceLanguage = new wxChoice( this, wxID_ANY, wxDefaultPosition, wxDefaultSize, m_choiceLanguageNChoices, m_choiceLanguageChoices, 0 ); - m_choiceLanguage->SetSelection( 0 ); - controlsSizer->Add( m_choiceLanguage, 0, wxTOP|wxBOTTOM|wxRIGHT, 5 ); - - - controlsSizer->Add( 0, 0, 1, wxEXPAND, 5 ); - - m_checkBoxMain = new wxCheckBox( this, wxID_ANY, _("Application entry point"), wxDefaultPosition, wxDefaultSize, 0 ); - controlsSizer->Add( m_checkBoxMain, 0, wxTOP|wxBOTTOM|wxRIGHT, 5 ); - - - controlsSizer->Add( 0, 0, 1, wxEXPAND, 5 ); - - m_checkGenerate = new wxCheckBox( this, wxID_ANY, _("Generate source code"), wxDefaultPosition, wxDefaultSize, 0 ); - controlsSizer->Add( m_checkGenerate, 0, wxBOTTOM|wxRIGHT, 5 ); - - sbSizer1->Add( controlsSizer, 1, wxEXPAND, 5 ); - - mainSizer->Add( sbSizer1, 0, wxEXPAND|wxTOP|wxRIGHT|wxLEFT, 5 ); - - wxStaticBoxSizer* sbSizer2; - sbSizer2 = new wxStaticBoxSizer( new wxStaticBox( this, wxID_ANY, _("CodeLite settings:") ), wxVERTICAL ); - - wxFlexGridSizer* codeSizer; - codeSizer = new wxFlexGridSizer( 0, 2, 0, 0 ); - codeSizer->SetFlexibleDirection( wxBOTH ); - codeSizer->SetNonFlexibleGrowMode( wxFLEX_GROWMODE_SPECIFIED ); - - m_staticText3 = new wxStaticText( this, wxID_ANY, _("Project tree folder:"), wxDefaultPosition, wxDefaultSize, 0 ); - m_staticText3->Wrap( -1 ); - codeSizer->Add( m_staticText3, 0, wxALL|wxALIGN_CENTER_VERTICAL, 5 ); - - wxBoxSizer* treeSizer; - treeSizer = new wxBoxSizer( wxHORIZONTAL ); - - m_textTreeFolder = new wxTextCtrl( this, wxID_ANY, wxEmptyString, wxDefaultPosition, wxSize( 280,-1 ), 0 ); - m_textTreeFolder->SetBackgroundColour( wxSystemSettings::GetColour( wxSYS_COLOUR_INFOBK ) ); - m_textTreeFolder->SetMinSize( wxSize( 280,-1 ) ); - - treeSizer->Add( m_textTreeFolder, 0, wxALIGN_CENTER_VERTICAL|wxTOP|wxBOTTOM, 5 ); - - m_buttonBrowse = new wxButton( this, wxID_ANY, _("..."), wxDefaultPosition, wxDefaultSize, 0 ); - treeSizer->Add( m_buttonBrowse, 0, wxALL, 5 ); - - codeSizer->Add( treeSizer, 0, 0, 5 ); - - sbSizer2->Add( codeSizer, 0, wxEXPAND, 5 ); - - mainSizer->Add( sbSizer2, 0, wxEXPAND|wxTOP|wxRIGHT|wxLEFT, 5 ); - - m_staticline3 = new wxStaticLine( this, wxID_ANY, wxDefaultPosition, wxDefaultSize, wxLI_HORIZONTAL ); - mainSizer->Add( m_staticline3, 0, wxEXPAND | wxALL, 5 ); - - wxBoxSizer* bSizer3; - bSizer3 = new wxBoxSizer( wxHORIZONTAL ); - - m_buttonOK = new wxButton( this, wxID_ANY, _("OK"), wxDefaultPosition, wxDefaultSize, 0 ); - m_buttonOK->SetDefault(); - bSizer3->Add( m_buttonOK, 0, wxALL, 5 ); - - m_buttonCancel = new wxButton( this, wxID_ANY, _("Cancel"), wxDefaultPosition, wxDefaultSize, 0 ); - bSizer3->Add( m_buttonCancel, 0, wxALL, 5 ); - - mainSizer->Add( bSizer3, 0, wxALIGN_CENTER_HORIZONTAL, 5 ); - - this->SetSizer( mainSizer ); - this->Layout(); - mainSizer->Fit( this ); - - this->Centre( wxBOTH ); - - // Connect Events - this->Connect( wxEVT_INIT_DIALOG, wxInitDialogEventHandler( CodeDesignerItemBaseDlg::OnInit ) ); - m_checkBoxMain->Connect( wxEVT_UPDATE_UI, wxUpdateUIEventHandler( CodeDesignerItemBaseDlg::OnUpdateMain ), NULL, this ); - m_buttonBrowse->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( CodeDesignerItemBaseDlg::OnBrowse ), NULL, this ); - m_buttonOK->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( CodeDesignerItemBaseDlg::OnOk ), NULL, this ); - m_buttonCancel->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( CodeDesignerItemBaseDlg::OnCancel ), NULL, this ); -} - -CodeDesignerItemBaseDlg::~CodeDesignerItemBaseDlg() -{ - // Disconnect Events - this->Disconnect( wxEVT_INIT_DIALOG, wxInitDialogEventHandler( CodeDesignerItemBaseDlg::OnInit ) ); - m_checkBoxMain->Disconnect( wxEVT_UPDATE_UI, wxUpdateUIEventHandler( CodeDesignerItemBaseDlg::OnUpdateMain ), NULL, this ); - m_buttonBrowse->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( CodeDesignerItemBaseDlg::OnBrowse ), NULL, this ); - m_buttonOK->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( CodeDesignerItemBaseDlg::OnOk ), NULL, this ); - m_buttonCancel->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( CodeDesignerItemBaseDlg::OnCancel ), NULL, this ); - -} diff --git a/CodeDesigner/codedesigneritembasedlg.fbp b/CodeDesigner/codedesigneritembasedlg.fbp deleted file mode 100644 index f1742297ed..0000000000 --- a/CodeDesigner/codedesigneritembasedlg.fbp +++ /dev/null @@ -1,1467 +0,0 @@ - - - - - - C++ - 1 - source_name - 0 - UTF-8 - connect - codedesigneritembasedlg - 1000 - none - 1 - CodeDesignerItemBaseDlg - - . - - 1 - 1 - 0 - 0 - - 1 - 1 - 1 - 1 - 0 - - - - - 1 - wxBOTH - 0 - 1 - - 1 - 0 - Dock - 0 - Left - 1 - impl_virtual - - - 1 - - 0 - 0 - wxID_ANY - - - 0 - - - 0 - - 1 - CodeDesignerItemBaseDlg - 1 - - - 1 - - - Resizable - - 1 - - wxDEFAULT_DIALOG_STYLE - - New CodeDesigner project - 0 - - - wxFILTER_NONE - wxDefaultValidator - - - - - - - - - - - - - - - - - - - - OnInit - - - - - - - - - - - - - - - - - - - - - - - mainSizer - wxVERTICAL - none - - 5 - wxEXPAND|wxTOP|wxRIGHT|wxLEFT - 0 - - wxID_ANY - CodeDesigner project settings: - - sbSizer1 - wxVERTICAL - none - - - 5 - wxEXPAND - 1 - - 2 - wxBOTH - - - 0 - - controlsSizer - wxFLEX_GROWMODE_SPECIFIED - none - 0 - 0 - - 5 - wxALL|wxALIGN_CENTER_VERTICAL - 0 - - 1 - 1 - 1 - 1 - - - - - 1 - 0 - 1 - - 1 - 0 - Dock - 0 - Left - 1 - - 1 - - 0 - 0 - wxID_ANY - Package name: - - - 0 - - - 0 - - 1 - m_staticText1 - 1 - - - protected - 1 - - - Resizable - - 1 - - - - 0 - - - wxFILTER_NONE - wxDefaultValidator - - - - - -1 - - - - - - - - - - - - - - - - - - - - - - - - - - - 5 - wxTOP|wxBOTTOM|wxRIGHT - 0 - - 1 - 1 - 1 - 1 - - - - - 1 - 0 - 1 - - 1 - 0 - Dock - 0 - Left - 1 - - 1 - - 0 - 0 - wxID_ANY - - - 0 - - 0 - - 0 - 300,-1 - 1 - m_textPackageName - 1 - - - protected - 1 - - - Resizable - - 1 - 300,-1 - - - 0 - - - wxFILTER_NONE - wxDefaultValidator - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - 5 - wxALL|wxALIGN_CENTER_VERTICAL - 0 - - 1 - 1 - 1 - 1 - - - - - 1 - 0 - 1 - - 1 - 0 - Dock - 0 - Left - 1 - - 1 - - 0 - 0 - wxID_ANY - Diagram name: - - - 0 - - - 0 - - 1 - m_staticText2 - 1 - - - protected - 1 - - - Resizable - - 1 - - - - 0 - - - wxFILTER_NONE - wxDefaultValidator - - - - - -1 - - - - - - - - - - - - - - - - - - - - - - - - - - - 5 - wxTOP|wxBOTTOM|wxRIGHT|wxEXPAND - 0 - - 1 - 1 - 1 - 1 - - - - - 1 - 0 - 1 - - 1 - 0 - Dock - 0 - Left - 1 - - 1 - - 0 - 0 - wxID_ANY - - - 0 - - 0 - - 0 - - 1 - m_textDiagramName - 1 - - - protected - 1 - - - Resizable - - 1 - - - - 0 - - - wxFILTER_NONE - wxDefaultValidator - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - 5 - wxALL|wxALIGN_CENTER_VERTICAL - 0 - - 1 - 1 - 1 - 1 - - - - - 1 - 0 - 1 - - 1 - 0 - Dock - 0 - Left - 1 - - 1 - - 0 - 0 - wxID_ANY - Language: - - - 0 - - - 0 - - 1 - m_staticText4 - 1 - - - protected - 1 - - - Resizable - - 1 - - - - 0 - - - wxFILTER_NONE - wxDefaultValidator - - - - - -1 - - - - - - - - - - - - - - - - - - - - - - - - - - - 5 - wxTOP|wxBOTTOM|wxRIGHT - 0 - - 1 - 1 - 1 - 1 - - - - - 1 - 0 - "C" "C++" "Python" - 1 - - 1 - 0 - Dock - 0 - Left - 1 - - 1 - - 0 - 0 - wxID_ANY - - - 0 - - - 0 - - 1 - m_choiceLanguage - 1 - - - protected - 1 - - - Resizable - - 0 - 1 - - - 0 - - - wxFILTER_NONE - wxDefaultValidator - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - 5 - wxEXPAND - 1 - - 0 - protected - 0 - - - - 5 - wxTOP|wxBOTTOM|wxRIGHT - 0 - - 1 - 1 - 1 - 1 - - - - - 1 - 0 - 0 - 1 - - 1 - 0 - Dock - 0 - Left - 1 - - 1 - - 0 - 0 - wxID_ANY - Application entry point - - - 0 - - - 0 - - 1 - m_checkBoxMain - 1 - - - protected - 1 - - - Resizable - - 1 - - - - 0 - - - wxFILTER_NONE - wxDefaultValidator - - - - - - - - - - - - - - - - - - - - - - - - - - - - OnUpdateMain - - - - 5 - wxEXPAND - 1 - - 0 - protected - 0 - - - - 5 - wxBOTTOM|wxRIGHT - 0 - - 1 - 1 - 1 - 1 - - - - - 1 - 0 - 0 - 1 - - 1 - 0 - Dock - 0 - Left - 1 - - 1 - - 0 - 0 - wxID_ANY - Generate source code - - - 0 - - - 0 - - 1 - m_checkGenerate - 1 - - - protected - 1 - - - Resizable - - 1 - - - - 0 - - - wxFILTER_NONE - wxDefaultValidator - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - 5 - wxEXPAND|wxTOP|wxRIGHT|wxLEFT - 0 - - wxID_ANY - CodeLite settings: - - sbSizer2 - wxVERTICAL - none - - - 5 - wxEXPAND - 0 - - 2 - wxBOTH - - - 0 - - codeSizer - wxFLEX_GROWMODE_SPECIFIED - none - 0 - 0 - - 5 - wxALL|wxALIGN_CENTER_VERTICAL - 0 - - 1 - 1 - 1 - 1 - - - - - 1 - 0 - 1 - - 1 - 0 - Dock - 0 - Left - 1 - - 1 - - 0 - 0 - wxID_ANY - Project tree folder: - - - 0 - - - 0 - - 1 - m_staticText3 - 1 - - - protected - 1 - - - Resizable - - 1 - - - - 0 - - - wxFILTER_NONE - wxDefaultValidator - - - - - -1 - - - - - - - - - - - - - - - - - - - - - - - - - - - 5 - - 0 - - - treeSizer - wxHORIZONTAL - none - - 5 - wxALIGN_CENTER_VERTICAL|wxTOP|wxBOTTOM - 0 - - 1 - 1 - 1 - 1 - - - wxSYS_COLOUR_INFOBK - - 1 - 0 - 1 - - 1 - 0 - Dock - 0 - Left - 1 - - 1 - - 0 - 0 - wxID_ANY - - - 0 - - 0 - - 0 - 280,-1 - 1 - m_textTreeFolder - 1 - - - protected - 1 - - - Resizable - - 1 - 280,-1 - - - 0 - - - wxFILTER_NONE - wxDefaultValidator - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - 5 - wxALL - 0 - - 1 - 1 - 1 - 1 - - - - - 1 - 0 - 1 - - 1 - 0 - 0 - Dock - 0 - Left - 1 - - 1 - - 0 - 0 - wxID_ANY - ... - - - 0 - - - 0 - - 1 - m_buttonBrowse - 1 - - - protected - 1 - - - Resizable - - 1 - - - - 0 - - - wxFILTER_NONE - wxDefaultValidator - - - - - OnBrowse - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - 5 - wxEXPAND | wxALL - 0 - - 1 - 1 - 1 - 1 - - - - - 1 - 0 - 1 - - 1 - 0 - Dock - 0 - Left - 1 - - 1 - - 0 - 0 - wxID_ANY - - - 0 - - - 0 - - 1 - m_staticline3 - 1 - - - protected - 1 - - - Resizable - - 1 - - wxLI_HORIZONTAL - - 0 - - - wxFILTER_NONE - wxDefaultValidator - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - 5 - wxALIGN_CENTER_HORIZONTAL - 0 - - - bSizer3 - wxHORIZONTAL - none - - 5 - wxALL - 0 - - 1 - 1 - 1 - 1 - - - - - 1 - 0 - 1 - - 1 - 1 - 0 - Dock - 0 - Left - 1 - - 1 - - 0 - 0 - wxID_ANY - OK - - - 0 - - - 0 - - 1 - m_buttonOK - 1 - - - protected - 1 - - - Resizable - - 1 - - - - 0 - - - wxFILTER_NONE - wxDefaultValidator - - - - - OnOk - - - - - - - - - - - - - - - - - - - - - - - - - - - 5 - wxALL - 0 - - 1 - 1 - 1 - 1 - - - - - 1 - 0 - 1 - - 1 - 0 - 0 - Dock - 0 - Left - 1 - - 1 - - 0 - 0 - wxID_ANY - Cancel - - - 0 - - - 0 - - 1 - m_buttonCancel - 1 - - - protected - 1 - - - Resizable - - 1 - - - - 0 - - - wxFILTER_NONE - wxDefaultValidator - - - - - OnCancel - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/CodeDesigner/codedesigneritembasedlg.h b/CodeDesigner/codedesigneritembasedlg.h deleted file mode 100644 index 057368c0ef..0000000000 --- a/CodeDesigner/codedesigneritembasedlg.h +++ /dev/null @@ -1,71 +0,0 @@ -/////////////////////////////////////////////////////////////////////////// -// C++ code generated with wxFormBuilder (version Nov 29 2010) -// http://www.wxformbuilder.org/ -// -// PLEASE DO "NOT" EDIT THIS FILE! -/////////////////////////////////////////////////////////////////////////// - -#ifndef __codedesigneritembasedlg__ -#define __codedesigneritembasedlg__ - -#include - -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include - -/////////////////////////////////////////////////////////////////////////// - - -/////////////////////////////////////////////////////////////////////////////// -/// Class CodeDesignerItemBaseDlg -/////////////////////////////////////////////////////////////////////////////// -class CodeDesignerItemBaseDlg : public wxDialog -{ - private: - - protected: - wxStaticText* m_staticText1; - wxTextCtrl* m_textPackageName; - wxStaticText* m_staticText2; - wxTextCtrl* m_textDiagramName; - wxStaticText* m_staticText4; - wxChoice* m_choiceLanguage; - - wxCheckBox* m_checkBoxMain; - - wxCheckBox* m_checkGenerate; - wxStaticText* m_staticText3; - wxTextCtrl* m_textTreeFolder; - wxButton* m_buttonBrowse; - wxStaticLine* m_staticline3; - wxButton* m_buttonOK; - wxButton* m_buttonCancel; - - // Virtual event handlers, overide them in your derived class - virtual void OnInit( wxInitDialogEvent& event ) { event.Skip(); } - virtual void OnUpdateMain( wxUpdateUIEvent& event ) { event.Skip(); } - virtual void OnBrowse( wxCommandEvent& event ) { event.Skip(); } - virtual void OnOk( wxCommandEvent& event ) { event.Skip(); } - virtual void OnCancel( wxCommandEvent& event ) { event.Skip(); } - - - public: - - CodeDesignerItemBaseDlg( wxWindow* parent, wxWindowID id = wxID_ANY, const wxString& title = _("New CodeDesigner project"), const wxPoint& pos = wxDefaultPosition, const wxSize& size = wxDefaultSize, long style = wxDEFAULT_DIALOG_STYLE ); - ~CodeDesignerItemBaseDlg(); - -}; - -#endif //__codedesigneritembasedlg__ diff --git a/CodeDesigner/codedesigneritemdlg.cpp b/CodeDesigner/codedesigneritemdlg.cpp deleted file mode 100644 index 51896b05b3..0000000000 --- a/CodeDesigner/codedesigneritemdlg.cpp +++ /dev/null @@ -1,94 +0,0 @@ -#include "codedesigneritemdlg.h" -#include "project.h" -#include "virtualdirectoryselector.h" -#include "imanager.h" -#include "globals.h" - -CodeDesignerItemDlg::CodeDesignerItemDlg(wxWindow *parent, IManager *mgr, bool allowmain) - : CodeDesignerItemBaseDlg(parent) -{ - m_AllowMain = allowmain; - m_mgr = mgr; -} - -CodeDesignerItemDlg::~CodeDesignerItemDlg() -{ -} - -void CodeDesignerItemDlg::OnCancel(wxCommandEvent& event) -{ - EndModal( wxID_CANCEL ); -} - -void CodeDesignerItemDlg::OnInit(wxInitDialogEvent& event) -{ - TreeItemInfo item = m_mgr->GetSelectedTreeItemInfo( TreeFileView ); - if ( item.m_item.IsOk() && item.m_itemType == ProjectItem::TypeVirtualDirectory ) - { - m_textTreeFolder->SetValue(VirtualDirectorySelector::DoGetPath( m_mgr->GetTree( TreeFileView ), item.m_item, false )); - } - - m_textPackageName->SetValue( m_CDInfo.m_PackageName ); - m_checkGenerate->SetValue( true ); - - event.Skip(); -} - -void CodeDesignerItemDlg::OnOk(wxCommandEvent& event) -{ - if( m_textDiagramName->GetValue().IsEmpty() ) - { - wxMessageBox( _("Diagram name cannot be empty"), _("CodeLite"), wxICON_WARNING | wxOK ); - m_textDiagramName->SetFocus(); - return; - } - - if( m_textPackageName->GetValue().IsEmpty() ) - { - wxMessageBox( _("Package name cannot be empty"), _("CodeLite"), wxICON_WARNING | wxOK ); - m_textPackageName->SetFocus(); - return; - } - - if( m_textTreeFolder->GetValue().IsEmpty() ) - { - wxMessageBox( _("Folder name cannot be empty"), _("CodeLite"), wxICON_WARNING | wxOK ); - m_textTreeFolder->SetFocus(); - return; - } - - m_CDInfo.m_DiagramName = m_textDiagramName->GetValue(); - m_CDInfo.m_PackageName = m_textPackageName->GetValue(); - m_CDInfo.m_TreeFolderName = m_textTreeFolder->GetValue(); - m_CDInfo.m_UseMain = m_checkBoxMain->GetValue(); - m_CDInfo.m_GenerateCode = m_checkGenerate->GetValue(); - - if( m_choiceLanguage->GetStringSelection() == wxT("C") ) - { - m_CDInfo.m_Language = wxT("udCLanguage"); - } - else if( m_choiceLanguage->GetStringSelection() == wxT("C++") ) - { - m_CDInfo.m_Language = wxT("udCPPLanguage"); - } - else if( m_choiceLanguage->GetStringSelection() == wxT("Python") ) - { - m_CDInfo.m_Language = wxT("udPythonLanguage"); - } - - EndModal( wxID_OK ); -} - -void CodeDesignerItemDlg::OnUpdateMain(wxUpdateUIEvent& event) -{ - event.Enable( m_AllowMain ); -} - -void CodeDesignerItemDlg::OnBrowse(wxCommandEvent& event) -{ - VirtualDirectorySelector dlg(this, m_mgr->GetWorkspace(), m_textTreeFolder->GetValue()); - if ( dlg.ShowModal() == wxID_OK ) - { - m_textTreeFolder->SetValue( dlg.GetVirtualDirectoryPath() ); - } -} diff --git a/CodeDesigner/codedesigneritemdlg.h b/CodeDesigner/codedesigneritemdlg.h deleted file mode 100644 index abc21f16a7..0000000000 --- a/CodeDesigner/codedesigneritemdlg.h +++ /dev/null @@ -1,47 +0,0 @@ -#ifndef CODEDESIGNERITEMDLG_H -#define CODEDESIGNERITEMDLG_H - -#include "codedesigneritembasedlg.h" // Base class: CodeDesignerItemBaseDlg -class IManager; - -enum CDItemType -{ - cdtStateChart, - cdtHierarchicalStateChart, - cdtClassDiagram -}; - -struct CDItemInfo -{ - bool m_UseMain; - bool m_GenerateCode; - wxString m_PackageName; - wxString m_DiagramName; - wxString m_TreeFolderName; - wxString m_Language; - CDItemType m_Type; -}; - -class CodeDesignerItemDlg : public CodeDesignerItemBaseDlg -{ -public: - CodeDesignerItemDlg(wxWindow *parent, IManager *mgr, bool allowmain); - virtual ~CodeDesignerItemDlg(); - - void SetCDInfo(const CDItemInfo& CDInfo) {this->m_CDInfo = CDInfo;} - const CDItemInfo& GetCDInfo() const {return m_CDInfo;} - -protected: - CDItemInfo m_CDInfo; - bool m_AllowMain; - IManager *m_mgr; - - virtual void OnCancel(wxCommandEvent& event); - virtual void OnInit(wxInitDialogEvent& event); - virtual void OnOk(wxCommandEvent& event); - virtual void OnUpdateMain(wxUpdateUIEvent& event); - virtual void OnBrowse(wxCommandEvent& event); - -}; - -#endif // CODEDESIGNERITEMDLG_H diff --git a/CodeDesigner/codedesignersettingsbasedlg.cpp b/CodeDesigner/codedesignersettingsbasedlg.cpp deleted file mode 100644 index a8e08b2851..0000000000 --- a/CodeDesigner/codedesignersettingsbasedlg.cpp +++ /dev/null @@ -1,89 +0,0 @@ -/////////////////////////////////////////////////////////////////////////// -// C++ code generated with wxFormBuilder (version Nov 29 2010) -// http://www.wxformbuilder.org/ -// -// PLEASE DO "NOT" EDIT THIS FILE! -/////////////////////////////////////////////////////////////////////////// - -#include "codedesignersettingsbasedlg.h" - -/////////////////////////////////////////////////////////////////////////// - -CodeDesignerBaseDlg::CodeDesignerBaseDlg( wxWindow* parent, wxWindowID id, const wxString& title, const wxPoint& pos, const wxSize& size, long style ) : wxDialog( parent, id, title, pos, size, style ) -{ - this->SetSizeHints( wxDefaultSize, wxDefaultSize ); - - wxBoxSizer* mainSizer; - mainSizer = new wxBoxSizer( wxVERTICAL ); - - m_panel1 = new wxPanel( this, wxID_ANY, wxDefaultPosition, wxDefaultSize, wxTAB_TRAVERSAL ); - wxFlexGridSizer* fgSizer1; - fgSizer1 = new wxFlexGridSizer( 2, 3, 0, 0 ); - fgSizer1->AddGrowableCol( 1 ); - fgSizer1->SetFlexibleDirection( wxBOTH ); - fgSizer1->SetNonFlexibleGrowMode( wxFLEX_GROWMODE_SPECIFIED ); - - m_staticText1 = new wxStaticText( m_panel1, wxID_ANY, _("CodeDesigner path:"), wxDefaultPosition, wxDefaultSize, 0 ); - m_staticText1->Wrap( -1 ); - fgSizer1->Add( m_staticText1, 0, wxALL|wxALIGN_CENTER_VERTICAL, 5 ); - - m_textCtrlCDPath = new wxTextCtrl( m_panel1, wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0 ); - m_textCtrlCDPath->SetMinSize( wxSize( 400,-1 ) ); - - fgSizer1->Add( m_textCtrlCDPath, 1, wxALL|wxEXPAND, 5 ); - - m_buttonBrowse = new wxButton( m_panel1, wxID_ANY, _("..."), wxDefaultPosition, wxDefaultSize, 0 ); - fgSizer1->Add( m_buttonBrowse, 0, wxALL, 5 ); - - m_staticText3 = new wxStaticText( m_panel1, wxID_ANY, _("Communication port:"), wxDefaultPosition, wxDefaultSize, 0 ); - m_staticText3->Wrap( -1 ); - fgSizer1->Add( m_staticText3, 0, wxALL|wxALIGN_CENTER_VERTICAL, 5 ); - - m_textCtrlComPort = new wxTextCtrl( m_panel1, wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0 ); - fgSizer1->Add( m_textCtrlComPort, 1, wxALL, 5 ); - - - fgSizer1->Add( 0, 0, 1, wxEXPAND, 5 ); - - m_panel1->SetSizer( fgSizer1 ); - m_panel1->Layout(); - fgSizer1->Fit( m_panel1 ); - mainSizer->Add( m_panel1, 0, wxEXPAND | wxALL, 5 ); - - m_staticline1 = new wxStaticLine( this, wxID_ANY, wxDefaultPosition, wxDefaultSize, wxLI_HORIZONTAL ); - mainSizer->Add( m_staticline1, 0, wxEXPAND | wxALL, 5 ); - - wxBoxSizer* bSizer2; - bSizer2 = new wxBoxSizer( wxHORIZONTAL ); - - m_buttonOk = new wxButton( this, wxID_ANY, _("&OK"), wxDefaultPosition, wxDefaultSize, 0 ); - m_buttonOk->SetDefault(); - bSizer2->Add( m_buttonOk, 0, wxALL|wxALIGN_CENTER_VERTICAL, 5 ); - - m_buttonCancel = new wxButton( this, wxID_CANCEL, _("Cancel"), wxDefaultPosition, wxDefaultSize, 0 ); - bSizer2->Add( m_buttonCancel, 0, wxALL, 5 ); - - mainSizer->Add( bSizer2, 0, wxALIGN_CENTER_HORIZONTAL|wxALL, 5 ); - - this->SetSizer( mainSizer ); - this->Layout(); - mainSizer->Fit( this ); - - this->Centre( wxBOTH ); - - // Connect Events - this->Connect( wxEVT_INIT_DIALOG, wxInitDialogEventHandler( CodeDesignerBaseDlg::OnInit ) ); - m_buttonBrowse->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( CodeDesignerBaseDlg::OnButtonBrowse ), NULL, this ); - m_buttonOk->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( CodeDesignerBaseDlg::OnButtonOK ), NULL, this ); - m_buttonCancel->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( CodeDesignerBaseDlg::OnButtonCancel ), NULL, this ); -} - -CodeDesignerBaseDlg::~CodeDesignerBaseDlg() -{ - // Disconnect Events - this->Disconnect( wxEVT_INIT_DIALOG, wxInitDialogEventHandler( CodeDesignerBaseDlg::OnInit ) ); - m_buttonBrowse->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( CodeDesignerBaseDlg::OnButtonBrowse ), NULL, this ); - m_buttonOk->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( CodeDesignerBaseDlg::OnButtonOK ), NULL, this ); - m_buttonCancel->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( CodeDesignerBaseDlg::OnButtonCancel ), NULL, this ); - -} diff --git a/CodeDesigner/codedesignersettingsbasedlg.fbp b/CodeDesigner/codedesignersettingsbasedlg.fbp deleted file mode 100644 index c90913a2b6..0000000000 --- a/CodeDesigner/codedesignersettingsbasedlg.fbp +++ /dev/null @@ -1,951 +0,0 @@ - - - - - - C++ - 1 - source_name - 0 - UTF-8 - connect - codedesignersettingsbasedlg - 1000 - none - 1 - CodeDesignerSettingsBaseDlg - - . - - 1 - 1 - 0 - 0 - - 1 - 1 - 1 - 1 - 0 - - - - - 1 - wxBOTH - 0 - 1 - - 1 - 0 - Dock - 0 - Left - 1 - impl_virtual - - - 1 - - 0 - 0 - wxID_ANY - - - 0 - - - 0 - - 1 - CodeDesignerBaseDlg - 1 - - - 1 - - - Resizable - - 1 - -1,-1 - wxDEFAULT_DIALOG_STYLE - - CodeDesigner RAD Settings... - 0 - - - wxFILTER_NONE - wxDefaultValidator - - - - - - - - - - - - - - - - - - - - OnInit - - - - - - - - - - - - - - - - - - - - - - - mainSizer - wxVERTICAL - none - - 5 - wxEXPAND | wxALL - 0 - - 1 - 1 - 1 - 1 - - - - - 1 - 0 - 1 - - 1 - 0 - Dock - 0 - Left - 1 - - 1 - - 0 - 0 - wxID_ANY - - - 0 - - - 0 - - 1 - m_panel1 - 1 - - - protected - 1 - - - Resizable - - 1 - - - 0 - - - wxFILTER_NONE - wxDefaultValidator - - - - wxTAB_TRAVERSAL - - - - - - - - - - - - - - - - - - - - - - - - - 3 - wxBOTH - 1 - - 0 - - fgSizer1 - wxFLEX_GROWMODE_SPECIFIED - none - 2 - 0 - - 5 - wxALL|wxALIGN_CENTER_VERTICAL - 0 - - 1 - 1 - 1 - 1 - - - - - 1 - 0 - 1 - - 1 - 0 - Dock - 0 - Left - 1 - - 1 - - 0 - 0 - wxID_ANY - CodeDesigner path: - - - 0 - - - 0 - - 1 - m_staticText1 - 1 - - - protected - 1 - - - Resizable - - 1 - - - - 0 - - - wxFILTER_NONE - wxDefaultValidator - - - - - -1 - - - - - - - - - - - - - - - - - - - - - - - - - - - 5 - wxALL|wxEXPAND - 1 - - 1 - 1 - 1 - 1 - - - - - 1 - 0 - 1 - - 1 - 0 - Dock - 0 - Left - 1 - - 1 - - 0 - 0 - wxID_ANY - - - 0 - - 0 - - 0 - 400,-1 - 1 - m_textCtrlCDPath - 1 - - - protected - 1 - - - Resizable - - 1 - - - - 0 - - - wxFILTER_NONE - wxDefaultValidator - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - 5 - wxALL - 0 - - 1 - 1 - 1 - 1 - - - - - 1 - 0 - 1 - - 1 - 0 - 0 - Dock - 0 - Left - 1 - - 1 - - 0 - 0 - wxID_ANY - ... - - - 0 - - - 0 - - 1 - m_buttonBrowse - 1 - - - protected - 1 - - - Resizable - - 1 - - - - 0 - - - wxFILTER_NONE - wxDefaultValidator - - - - - OnButtonBrowse - - - - - - - - - - - - - - - - - - - - - - - - - - - 5 - wxALL|wxALIGN_CENTER_VERTICAL - 0 - - 1 - 1 - 1 - 1 - - - - - 1 - 0 - 1 - - 1 - 0 - Dock - 0 - Left - 1 - - 1 - - 0 - 0 - wxID_ANY - Communication port: - - - 0 - - - 0 - - 1 - m_staticText3 - 1 - - - protected - 1 - - - Resizable - - 1 - - - - 0 - - - wxFILTER_NONE - wxDefaultValidator - - - - - -1 - - - - - - - - - - - - - - - - - - - - - - - - - - - 5 - wxALL - 1 - - 1 - 1 - 1 - 1 - - - - - 1 - 0 - 1 - - 1 - 0 - Dock - 0 - Left - 1 - - 1 - - 0 - 0 - wxID_ANY - - - 0 - - 0 - - 0 - - 1 - m_textCtrlComPort - 1 - - - protected - 1 - - - Resizable - - 1 - - - - 0 - - - wxFILTER_NONE - wxDefaultValidator - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - 5 - wxEXPAND - 1 - - 0 - protected - 0 - - - - - - - 5 - wxEXPAND | wxALL - 0 - - 1 - 1 - 1 - 1 - - - - - 1 - 0 - 1 - - 1 - 0 - Dock - 0 - Left - 1 - - 1 - - 0 - 0 - wxID_ANY - - - 0 - - - 0 - - 1 - m_staticline1 - 1 - - - protected - 1 - - - Resizable - - 1 - - wxLI_HORIZONTAL - - 0 - - - wxFILTER_NONE - wxDefaultValidator - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - 5 - wxALIGN_CENTER_HORIZONTAL|wxALL - 0 - - - bSizer2 - wxHORIZONTAL - none - - 5 - wxALL|wxALIGN_CENTER_VERTICAL - 0 - - 1 - 1 - 1 - 1 - - - - - 1 - 0 - 1 - - 1 - 1 - 0 - Dock - 0 - Left - 1 - - 1 - - 0 - 0 - wxID_ANY - &OK - - - 0 - - - 0 - - 1 - m_buttonOk - 1 - - - protected - 1 - - - Resizable - - 1 - - - - 0 - - - wxFILTER_NONE - wxDefaultValidator - - - - - OnButtonOK - - - - - - - - - - - - - - - - - - - - - - - - - - - 5 - wxALL - 0 - - 1 - 1 - 1 - 1 - - - - - 1 - 0 - 1 - - 1 - 0 - 0 - Dock - 0 - Left - 1 - - 1 - - 0 - 0 - wxID_CANCEL - Cancel - - - 0 - - - 0 - - 1 - m_buttonCancel - 1 - - - protected - 1 - - - Resizable - - 1 - - - - 0 - - - wxFILTER_NONE - wxDefaultValidator - - - - - OnButtonCancel - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/CodeDesigner/codedesignersettingsbasedlg.h b/CodeDesigner/codedesignersettingsbasedlg.h deleted file mode 100644 index 12287b73ae..0000000000 --- a/CodeDesigner/codedesignersettingsbasedlg.h +++ /dev/null @@ -1,62 +0,0 @@ -/////////////////////////////////////////////////////////////////////////// -// C++ code generated with wxFormBuilder (version Nov 29 2010) -// http://www.wxformbuilder.org/ -// -// PLEASE DO "NOT" EDIT THIS FILE! -/////////////////////////////////////////////////////////////////////////// - -#ifndef __codedesignersettingsbasedlg__ -#define __codedesignersettingsbasedlg__ - -#include - -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include - -/////////////////////////////////////////////////////////////////////////// - - -/////////////////////////////////////////////////////////////////////////////// -/// Class CodeDesignerBaseDlg -/////////////////////////////////////////////////////////////////////////////// -class CodeDesignerBaseDlg : public wxDialog -{ - private: - - protected: - wxPanel* m_panel1; - wxStaticText* m_staticText1; - wxTextCtrl* m_textCtrlCDPath; - wxButton* m_buttonBrowse; - wxStaticText* m_staticText3; - wxTextCtrl* m_textCtrlComPort; - - wxStaticLine* m_staticline1; - wxButton* m_buttonOk; - wxButton* m_buttonCancel; - - // Virtual event handlers, overide them in your derived class - virtual void OnInit( wxInitDialogEvent& event ) { event.Skip(); } - virtual void OnButtonBrowse( wxCommandEvent& event ) { event.Skip(); } - virtual void OnButtonOK( wxCommandEvent& event ) { event.Skip(); } - virtual void OnButtonCancel( wxCommandEvent& event ) { event.Skip(); } - - - public: - - CodeDesignerBaseDlg( wxWindow* parent, wxWindowID id = wxID_ANY, const wxString& title = _("CodeDesigner RAD Settings..."), const wxPoint& pos = wxDefaultPosition, const wxSize& size = wxSize( -1,-1 ), long style = wxDEFAULT_DIALOG_STYLE ); - ~CodeDesignerBaseDlg(); - -}; - -#endif //__codedesignersettingsbasedlg__ diff --git a/CodeDesigner/confcodedesigner.cpp b/CodeDesigner/confcodedesigner.cpp deleted file mode 100644 index a14f655ba6..0000000000 --- a/CodeDesigner/confcodedesigner.cpp +++ /dev/null @@ -1,22 +0,0 @@ -#include "confcodedesigner.h" - -ConfCodeDesigner::ConfCodeDesigner() -{ - m_Port = wxT("50000"); -} - -ConfCodeDesigner::~ConfCodeDesigner() -{ -} - -void ConfCodeDesigner::DeSerialize(Archive& arch) -{ - arch.Read(wxT("m_port"), m_Port); - arch.Read(wxT("m_path"), m_Path); -} - -void ConfCodeDesigner::Serialize(Archive& arch) -{ - arch.Write(wxT("m_port"), m_Port); - arch.Write(wxT("m_path"), m_Path); -} diff --git a/CodeDesigner/confcodedesigner.h b/CodeDesigner/confcodedesigner.h deleted file mode 100644 index daf10e8eb4..0000000000 --- a/CodeDesigner/confcodedesigner.h +++ /dev/null @@ -1,34 +0,0 @@ -#ifndef CONFCODEDESIGNER_H -#define CONFCODEDESIGNER_H - -#include "serialized_object.h" // Base class: SerializedObject - -class ConfCodeDesigner : public SerializedObject { - -public: - ConfCodeDesigner(); - virtual ~ConfCodeDesigner(); - -public: - virtual void DeSerialize(Archive& arch); - virtual void Serialize(Archive& arch); - - void SetPort(const wxString& Port) { - this->m_Port = Port; - } - void SetPath(const wxString& Path) { - this->m_Path = Path; - } - const wxString& GetPort() const { - return m_Port; - } - const wxString& GetPath() const { - return m_Path; - } - -protected: - wxString m_Path; - wxString m_Port; -}; - -#endif // CONFCODEDESIGNER_H diff --git a/CodeDesigner/icons/ClassDiag.xpm b/CodeDesigner/icons/ClassDiag.xpm deleted file mode 100644 index 46f2669de0..0000000000 --- a/CodeDesigner/icons/ClassDiag.xpm +++ /dev/null @@ -1,22 +0,0 @@ -/* XPM */ -static const char * ClassDiag_xpm[] = { -"16 16 3 1", -" c None", -". c #800000", -"+ c #FFFFFF", -" ", -" ........... ", -" .+++++++++. ", -" .............. ", -" .++.+++++++++. ", -" .++........... ", -" .++.+++++++++. ", -" ....+++++++++. ", -" .++.+++++++++. ", -" .++........... ", -" .++.+++++++++. ", -" .++.+++++++++. ", -" ....+++++++++. ", -" .+++++++++. ", -" ........... ", -" "}; diff --git a/CodeDesigner/icons/SimpleStateChartDiag.xpm b/CodeDesigner/icons/SimpleStateChartDiag.xpm deleted file mode 100644 index 6f1bbe32a7..0000000000 --- a/CodeDesigner/icons/SimpleStateChartDiag.xpm +++ /dev/null @@ -1,23 +0,0 @@ -/* XPM */ -static const char * SimpleStateChartDiag_xpm[] = { -"16 16 4 1", -" c None", -". c #000000", -"+ c #800000", -"@ c #FFFFFF", -" ", -" . ", -" ... ", -" . ", -" . ", -" +++++++ ", -" +@@@@@@@+ ", -" +++++++++ ", -" +@@@@@@@+ ", -" +@@@@@@@+ ", -" +++++++ ", -" . ", -" . ", -" .@. ", -" . ", -" "}; diff --git a/CodeDesigner/icons/StateChartDiag.xpm b/CodeDesigner/icons/StateChartDiag.xpm deleted file mode 100644 index 8e442fab46..0000000000 --- a/CodeDesigner/icons/StateChartDiag.xpm +++ /dev/null @@ -1,22 +0,0 @@ -/* XPM */ -static const char * StateChartDiag_xpm[] = { -"16 16 3 1", -" c None", -". c #800000", -"+ c #FFFFFF", -" ", -" .............. ", -"..++++++++++++..", -"................", -".++++++++++++++.", -".++...+++...+++.", -".+.+++...+++.++.", -".+.+++.+.+++.++.", -".++...+++...+++.", -".+++++++++.++++.", -".++++++++...+++.", -".++++++++...+++.", -".+++++++++.++++.", -"..++++++++++++..", -" .............. ", -" "}; diff --git a/Runtime/templates/codedesigner/CDTemplate.cdp b/Runtime/templates/codedesigner/CDTemplate.cdp deleted file mode 100644 index a1ee7b882b..0000000000 --- a/Runtime/templates/codedesigner/CDTemplate.cdp +++ /dev/null @@ -1,141 +0,0 @@ - - - - - 1 - Project items - - - 1 - . - $(BaseFileName) - $(CIFileName) - 0 - 1 - - - 2 - $(Language) - - - 3 - 1 - 1 - 1 - 1 - - - - - - 2 - $(PackageName) - - 3 - $(DiagramName) - Diagram's description... - Class Diagram - 1 - <default> - 0 - udClassDiagramGenerator - udCPPClassAlgorithm - - - 1 - 80.000000,40.000000 - - - 0 - Class - Diagram element's description... - 1 - - -1 - Constructor - Link description... - Constructor - Class - 0 - - - -1 - Destructor - Link description... - Destructor - Class - 0 - - - - 154.000000,155.000000 - 254,253,211,255 100 - - - 2 - 60.000000,5.000000 - 35.000000,13.000000 - Class - 1 - - - - - -2 - 10.000000,10.000000 - 4.000000,4.000000 - - - - - -3 - 10.000000,24.000000 - 134.000000,32.000000 - - 500008 - 500010 - - - - - - 3 - 0.000000,20.000000 - 154.000000,66.000000 - - -2 - -3 - - - - - - - - - 9 - Constructors/destructors - - 8 - Constructor - Class constructor's description... - Class - 0 - 0 - 0 - 0 - 0 - - - 10 - Destructor - Class destructor's description... - Class - 0 - 0 - 0 - 0 - 0 - - - diff --git a/Runtime/templates/codedesigner/HSCHTemplate.cdp b/Runtime/templates/codedesigner/HSCHTemplate.cdp deleted file mode 100644 index 16332c8372..0000000000 --- a/Runtime/templates/codedesigner/HSCHTemplate.cdp +++ /dev/null @@ -1,113 +0,0 @@ - - - - - 1 - Project items - - - 1 - . - $(BaseFileName) - $(CIFileName)_CI - 0 - 1 - - - 2 - $(Language) - - - 3 - 1 - 1 - 1 - 1 - - - - - - 2 - $(PackageName) - - 3 - $(DiagramName) - Diagram's description... - State Chart - 1 - <default> - 0 - udHStateChartGenerator - udLoopCaseAlgorithm - <none> - - - 1 - 50.000000,50.000000 - - - 0 - Initial - Diagram element's description... - - - 20.000000,20.000000 - 0,0,0,255 100 - - - 2 - 0.000000,25.000000 - 30.000000,13.000000 - Initial - 1 - - - - - 5 - 510.000000,190.000000 - - - 0 - Transition connection - Transition's description... - - - 1 - 3 - - - 6 - -30.000000,-6.000000 - 60.000000,13.000000 - << / [] >> - 3 - - - - - 3 - 230.000000,130.000000 - - - 0 - Final - Diagram element's description... - - - 20.000000,20.000000 - - - 4 - 0.000000,25.000000 - 25.000000,13.000000 - Final - 1 - - - - - - - diff --git a/Runtime/templates/codedesigner/HSCHTemplateWithMain.cdp b/Runtime/templates/codedesigner/HSCHTemplateWithMain.cdp deleted file mode 100644 index b912097013..0000000000 --- a/Runtime/templates/codedesigner/HSCHTemplateWithMain.cdp +++ /dev/null @@ -1,150 +0,0 @@ - - - - - 1 - Project items - - - 1 - . - $(BaseFileName) - $(CIFileName) - 0 - 1 - - - 2 - $(Language) - - - 3 - 1 - 1 - 1 - 1 - - - - - - 2 - $(PackageName) - - 3 - $(DiagramName) - Diagram's description... - State Chart - 1 - <default> - 0 - udHStateChartGenerator - udLoopCaseAlgorithm - <none> - - - 5 - 510.000000,190.000000 - - - 0 - Transition connection - Transition's description... - - - 1 - 3 - - - 6 - -30.000000,-6.000000 - 60.000000,13.000000 - << / [] >> - 3 - - - - - 1 - 50.000000,50.000000 - - - 0 - Initial - Diagram element's description... - - - 20.000000,20.000000 - 0,0,0,255 100 - - - 2 - 0.000000,25.000000 - 30.000000,13.000000 - Initial - 1 - - - - - 3 - 230.000000,130.000000 - - - 0 - Final - Diagram element's description... - 0 - - - 20.000000,20.000000 - - - 4 - 0.000000,25.000000 - 25.000000,13.000000 - Final - 1 - - - - - - - - 5 - Generic functions - - 4 - main - Application entry point - <global> - 5 - 0 - 0 - 0 - 0 - $(DiagramName) - - 6 - argc - Number of application parameters - <global> - 0 - 5 - 0 - 0 - - - 7 - argv[] - List of application parameters - <global> - 1 - 9 - 0 - 0 - - - - diff --git a/Runtime/templates/codedesigner/SCHTemplate.cdp b/Runtime/templates/codedesigner/SCHTemplate.cdp deleted file mode 100644 index d19399eb7d..0000000000 --- a/Runtime/templates/codedesigner/SCHTemplate.cdp +++ /dev/null @@ -1,113 +0,0 @@ - - - - - 1 - Project items - - - 1 - . - $(BaseFileName) - $(CIFileName) - 0 - 1 - - - 2 - $(Language) - - - 3 - 1 - 1 - 1 - 1 - - - - - - 2 - $(PackageName) - - 3 - $(DiagramName) - Diagram's description... - Simple State Chart - 1 - <default> - 0 - udSStateChartGenerator - udLoopCaseAlgorithm - <none> - - - 3 - 510.000000,190.000000 - - - 0 - Transition connection - Transition's description... - - - 1 - 5 - - - 4 - -30.000000,-6.000000 - 60.000000,13.000000 - << / [] >> - 3 - - - - - 1 - 60.000000,20.000000 - - - 0 - Initial - Diagram element's description... - - - 20.000000,20.000000 - 0,0,0,255 100 - - - 2 - 0.000000,25.000000 - 30.000000,13.000000 - Initial - 1 - - - - - 5 - 270.000000,90.000000 - - - 0 - Final - Diagram element's description... - - - 20.000000,20.000000 - - - 6 - 0.000000,25.000000 - 25.000000,13.000000 - Final - 1 - - - - - - - diff --git a/Runtime/templates/codedesigner/SCHTemplateWithMain.cdp b/Runtime/templates/codedesigner/SCHTemplateWithMain.cdp deleted file mode 100644 index a445584ecf..0000000000 --- a/Runtime/templates/codedesigner/SCHTemplateWithMain.cdp +++ /dev/null @@ -1,150 +0,0 @@ - - - - - 1 - Project items - - - 1 - . - $(BaseFileName) - $(CIFileName) - 0 - 1 - - - 2 - $(Language) - - - 3 - 1 - 1 - 1 - 1 - - - - - - 2 - $(PackageName) - - 3 - $(DiagramName) - Diagram's description... - Simple State Chart - 1 - <default> - 0 - udSStateChartGenerator - udLoopCaseAlgorithm - <none> - - - 1 - 510.000000,190.000000 - - - 0 - Transition connection - Transition's description... - - - 3 - 5 - - - 2 - -30.000000,-6.000000 - 64.000000,13.000000 - << / [] >> - 3 - - - - - 3 - 60.000000,20.000000 - - - 0 - Initial - Diagram element's description... - - - 20.000000,20.000000 - 0,0,0,255 100 - - - 4 - 0.000000,25.000000 - 30.000000,13.000000 - Initial - 1 - - - - - 5 - 270.000000,90.000000 - - - 0 - Final - Diagram element's description... - 0 - - - 20.000000,20.000000 - - - 6 - 0.000000,25.000000 - 25.000000,13.000000 - Final - 1 - - - - - - - - 5 - Generic functions - - 4 - main - Application entry point - <global> - 5 - 0 - 0 - 0 - 0 - $(DiagramName) - - 6 - argc - Number of application parameters - <global> - 0 - 5 - 0 - 0 - - - 7 - argv[] - List of application parameters - <global> - 1 - 9 - 0 - 0 - - - -