You can subscribe to this list here.
| 2005 |
Jan
(98) |
Feb
(101) |
Mar
(60) |
Apr
(38) |
May
(26) |
Jun
|
Jul
|
Aug
(159) |
Sep
(78) |
Oct
(31) |
Nov
|
Dec
|
|---|---|---|---|---|---|---|---|---|---|---|---|---|
| 2009 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
(4) |
Sep
(6) |
Oct
|
Nov
(1) |
Dec
(3) |
| 2010 |
Jan
|
Feb
|
Mar
|
Apr
(3) |
May
(5) |
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
| 2011 |
Jan
(8) |
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
Update of /cvsroot/wxdevcenter/wxDevCenter/src In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv20135/src Modified Files: MainFrame.cpp Application.cpp DocManager.cpp ArtProvider.cpp FileSystemStandard.cpp Command.cpp AboutBox.cpp FileSystemCtrl.cpp Log Message: Override wxArtProvider::GetBitmap/GetIcon to return a valid icon whatever the wxArtProvider found. Index: ArtProvider.cpp =================================================================== RCS file: /cvsroot/wxdevcenter/wxDevCenter/src/ArtProvider.cpp,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** ArtProvider.cpp 13 Aug 2005 14:07:37 -0000 1.1 --- ArtProvider.cpp 14 Sep 2005 20:01:53 -0000 1.2 *************** *** 55,63 **** } ! wxBitmap EmptyBitmap(16, 16, 24); wxIcon EmptyIcon; EmptyIcon.CopyFromBitmap(EmptyBitmap); IB.AddIcon(EmptyIcon); ! for(unsigned int n=0; n<arFiles.GetCount(); n++) IB.AddIcon(arFiles[n], wxBITMAP_TYPE_ANY); --- 55,63 ---- } ! /* wxBitmap EmptyBitmap(16, 16, 24); wxIcon EmptyIcon; EmptyIcon.CopyFromBitmap(EmptyBitmap); IB.AddIcon(EmptyIcon); ! */ for(unsigned int n=0; n<arFiles.GetCount(); n++) IB.AddIcon(arFiles[n], wxBITMAP_TYPE_ANY); *************** *** 65,66 **** --- 65,93 ---- return IB.GetIcon(size); } + + wxBitmap ArtProvider::GetBitmap(const wxArtID& id, const wxArtClient& client, const wxSize& size) + { + wxBitmap bmp = wxArtProvider::GetBitmap(id, client, size); + if(bmp.Ok()) + { + return bmp; + } + else + { + return wxArtProvider::GetBitmap( wxART_MISSING_IMAGE, client, size); + } + } + + wxIcon ArtProvider::GetIcon(const wxArtID& id, const wxArtClient& client, const wxSize& size) + { + wxIcon ico = wxArtProvider::GetIcon(id, client, size); + if(ico.Ok()) + { + return ico; + } + else + { + return wxArtProvider::GetIcon( wxART_MISSING_IMAGE, client, size); + } + } + Index: AboutBox.cpp =================================================================== RCS file: /cvsroot/wxdevcenter/wxDevCenter/src/AboutBox.cpp,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** AboutBox.cpp 24 Aug 2005 15:57:00 -0000 1.4 --- AboutBox.cpp 14 Sep 2005 20:01:53 -0000 1.5 *************** *** 25,33 **** #include <wxDevCenter/AboutBox.h> #include <wxDevCenter/Plugin.h> #include <wx/statbmp.h> #include <wx/stattext.h> #include <wx/notebook.h> - #include <wx/artprov.h> --- 25,33 ---- #include <wxDevCenter/AboutBox.h> #include <wxDevCenter/Plugin.h> + #include <wxDevCenter/ArtProvider.h> #include <wx/statbmp.h> #include <wx/stattext.h> #include <wx/notebook.h> *************** *** 88,93 **** { SetBackgroundColour(*wxWHITE); ! m_WXDCLogo = wxArtProvider::GetBitmap(wxT("wxDevCenter"), wxART_OTHER, wxSize(64, 64)); ! m_WXLogo = wxArtProvider::GetBitmap(wxT("wxWidgets"), wxART_OTHER, wxSize(116, 49)); } --- 88,93 ---- { SetBackgroundColour(*wxWHITE); ! m_WXDCLogo = ArtProvider::GetBitmap(wxT("wxDevCenter"), wxART_OTHER, wxSize(64, 64)); ! m_WXLogo = ArtProvider::GetBitmap(wxT("wxWidgets"), wxART_OTHER, wxSize(116, 49)); } Index: FileSystemStandard.cpp =================================================================== RCS file: /cvsroot/wxdevcenter/wxDevCenter/src/FileSystemStandard.cpp,v retrieving revision 1.17 retrieving revision 1.18 diff -C2 -d -r1.17 -r1.18 *** FileSystemStandard.cpp 17 Aug 2005 16:33:17 -0000 1.17 --- FileSystemStandard.cpp 14 Sep 2005 20:01:53 -0000 1.18 *************** *** 26,32 **** #include <wxDevCenter/FileSystemStandard.h> #include <wx/utils.h> #include <wx/wfstream.h> - #include <wx/artprov.h> using namespace wxDevCenter; --- 26,33 ---- #include <wxDevCenter/FileSystemStandard.h> + #include <wxDevCenter/ArtProvider.h> + #include <wx/utils.h> #include <wx/wfstream.h> using namespace wxDevCenter; *************** *** 76,94 **** wxImageList* pIL = new wxImageList(width, width, true, WXDC_STDFS_FILETYPES + Application::GetApp().GetDocManager().GetDocTemplateCount()); ! pIL->Add(wxArtProvider::GetIcon(wxART_MAKE_ART_ID(none), wxART_FRAME_ICON, wxSize(width, width))); ! pIL->Add(wxArtProvider::GetIcon(wxART_MAKE_ART_ID(unknow), wxART_FRAME_ICON, wxSize(width, width))); ! pIL->Add(wxArtProvider::GetIcon(wxART_MAKE_ART_ID(dir), wxART_FRAME_ICON, wxSize(width, width))); ! pIL->Add(wxArtProvider::GetIcon(wxART_MAKE_ART_ID(desktop), wxART_FRAME_ICON, wxSize(width, width))); ! pIL->Add(wxArtProvider::GetIcon(wxART_MAKE_ART_ID(desktop), wxART_FRAME_ICON, wxSize(width, width))); ! pIL->Add(wxArtProvider::GetIcon(wxART_MAKE_ART_ID(docs), wxART_FRAME_ICON, wxSize(width, width))); ! pIL->Add(wxArtProvider::GetIcon(wxART_MAKE_ART_ID(computer), wxART_FRAME_ICON, wxSize(width, width))); ! pIL->Add(wxArtProvider::GetIcon(wxART_MAKE_ART_ID(floppy), wxART_FRAME_ICON, wxSize(width, width))); ! pIL->Add(wxArtProvider::GetIcon(wxART_MAKE_ART_ID(harddrive), wxART_FRAME_ICON, wxSize(width, width))); ! pIL->Add(wxArtProvider::GetIcon(wxART_MAKE_ART_ID(cd-dvd), wxART_FRAME_ICON, wxSize(width, width))); ! pIL->Add(wxArtProvider::GetIcon(wxART_MAKE_ART_ID(ramdisk), wxART_FRAME_ICON, wxSize(width, width))); ! pIL->Add(wxArtProvider::GetIcon(wxART_MAKE_ART_ID(remote), wxART_FRAME_ICON, wxSize(width, width))); for(unsigned long l=0; l<Application::GetApp().GetDocManager().GetDocTemplateCount(); l++) ! pIL->Add(wxArtProvider::GetIcon(Application::GetApp().GetDocManager().GetDocTemplate(l).GetViewTemplate(0).strIcons, wxART_FRAME_ICON, wxSize(width, width))); return pIL; --- 77,95 ---- wxImageList* pIL = new wxImageList(width, width, true, WXDC_STDFS_FILETYPES + Application::GetApp().GetDocManager().GetDocTemplateCount()); ! pIL->Add(ArtProvider::GetIcon(wxART_MAKE_ART_ID(none), wxART_FRAME_ICON, wxSize(width, width))); ! pIL->Add(ArtProvider::GetIcon(wxART_MAKE_ART_ID(unknow), wxART_FRAME_ICON, wxSize(width, width))); ! pIL->Add(ArtProvider::GetIcon(wxART_MAKE_ART_ID(dir), wxART_FRAME_ICON, wxSize(width, width))); ! pIL->Add(ArtProvider::GetIcon(wxART_MAKE_ART_ID(desktop), wxART_FRAME_ICON, wxSize(width, width))); ! pIL->Add(ArtProvider::GetIcon(wxART_MAKE_ART_ID(desktop), wxART_FRAME_ICON, wxSize(width, width))); ! pIL->Add(ArtProvider::GetIcon(wxART_MAKE_ART_ID(docs), wxART_FRAME_ICON, wxSize(width, width))); ! pIL->Add(ArtProvider::GetIcon(wxART_MAKE_ART_ID(computer), wxART_FRAME_ICON, wxSize(width, width))); ! pIL->Add(ArtProvider::GetIcon(wxART_MAKE_ART_ID(floppy), wxART_FRAME_ICON, wxSize(width, width))); ! pIL->Add(ArtProvider::GetIcon(wxART_MAKE_ART_ID(harddrive), wxART_FRAME_ICON, wxSize(width, width))); ! pIL->Add(ArtProvider::GetIcon(wxART_MAKE_ART_ID(cd-dvd), wxART_FRAME_ICON, wxSize(width, width))); ! pIL->Add(ArtProvider::GetIcon(wxART_MAKE_ART_ID(ramdisk), wxART_FRAME_ICON, wxSize(width, width))); ! pIL->Add(ArtProvider::GetIcon(wxART_MAKE_ART_ID(remote), wxART_FRAME_ICON, wxSize(width, width))); for(unsigned long l=0; l<Application::GetApp().GetDocManager().GetDocTemplateCount(); l++) ! pIL->Add(ArtProvider::GetIcon(Application::GetApp().GetDocManager().GetDocTemplate(l).GetViewTemplate(0).strIcons, wxART_FRAME_ICON, wxSize(width, width))); return pIL; Index: FileSystemCtrl.cpp =================================================================== RCS file: /cvsroot/wxdevcenter/wxDevCenter/src/FileSystemCtrl.cpp,v retrieving revision 1.11 retrieving revision 1.12 diff -C2 -d -r1.11 -r1.12 *** FileSystemCtrl.cpp 17 Aug 2005 15:01:06 -0000 1.11 --- FileSystemCtrl.cpp 14 Sep 2005 20:01:53 -0000 1.12 *************** *** 26,29 **** --- 26,30 ---- #include <wxDevCenter/FileSystem.h> + #include <wxDevCenter/ArtProvider.h> #include <wx/toolbar.h> *************** *** 31,35 **** #include <wx/splitter.h> #include <wx/tokenzr.h> - #include <wx/artprov.h> using namespace wxDevCenter; --- 32,35 ---- *************** *** 300,304 **** { FileSystemPanel *pPanel = new FileSystemPanel(m_pBook, -1, pFileSystem); ! m_pImageList->Add(wxArtProvider::GetBitmap(pFileSystem->GetIconName(), wxART_OTHER, wxSize(48, 48))); m_pBook->AddPage(pPanel, pFileSystem->GetFileSystemName(), true, m_pImageList->GetImageCount()-1); } --- 300,304 ---- { FileSystemPanel *pPanel = new FileSystemPanel(m_pBook, -1, pFileSystem); ! m_pImageList->Add(ArtProvider::GetBitmap(pFileSystem->GetIconName(), wxART_OTHER, wxSize(48, 48))); m_pBook->AddPage(pPanel, pFileSystem->GetFileSystemName(), true, m_pImageList->GetImageCount()-1); } Index: DocManager.cpp =================================================================== RCS file: /cvsroot/wxdevcenter/wxDevCenter/src/DocManager.cpp,v retrieving revision 1.12 retrieving revision 1.13 diff -C2 -d -r1.12 -r1.13 *** DocManager.cpp 13 Aug 2005 14:07:37 -0000 1.12 --- DocManager.cpp 14 Sep 2005 20:01:53 -0000 1.13 *************** *** 26,32 **** #include <wxDevCenter/MainFrame.h> #include <wxDevCenter/MDIFrame.h> #include <wx/arrimpl.cpp> - #include <wx/artprov.h> using namespace wxDevCenter; --- 26,32 ---- #include <wxDevCenter/MainFrame.h> #include <wxDevCenter/MDIFrame.h> + #include <wxDevCenter/ArtProvider.h> #include <wx/arrimpl.cpp> using namespace wxDevCenter; *************** *** 409,413 **** for(unsigned int n=0; n<GetDocTemplateCount(); n++) ! pIL->Add(wxArtProvider::GetIcon(GetDocTemplate(n).GetViewTemplate(0).strIcons, wxART_OTHER, wxSize(iSize, iSize))); return pIL; } --- 409,413 ---- for(unsigned int n=0; n<GetDocTemplateCount(); n++) ! pIL->Add(ArtProvider::GetIcon(GetDocTemplate(n).GetViewTemplate(0).strIcons, wxART_OTHER, wxSize(iSize, iSize))); return pIL; } Index: MainFrame.cpp =================================================================== RCS file: /cvsroot/wxdevcenter/wxDevCenter/src/MainFrame.cpp,v retrieving revision 1.21 retrieving revision 1.22 diff -C2 -d -r1.21 -r1.22 *** MainFrame.cpp 14 Sep 2005 15:40:03 -0000 1.21 --- MainFrame.cpp 14 Sep 2005 20:01:53 -0000 1.22 *************** *** 33,39 **** #include <wxDevCenter/Command.h> #include <wxDevCenter/Layout.h> - - #include <wx/artprov.h> #include <wx/dataobj.h> #include <wx/dnd.h> --- 33,38 ---- #include <wxDevCenter/Command.h> #include <wxDevCenter/Layout.h> + #include <wxDevCenter/ArtProvider.h> #include <wx/dataobj.h> #include <wx/dnd.h> *************** *** 114,118 **** // Chargement de l'icone de l'application. ! m_Icon = wxArtProvider::GetIcon(wxART_MAKE_ART_ID(wxDevCenter), wxART_FRAME_ICON, wxSize(16, 16)); SetIcon(m_Icon); --- 113,117 ---- // Chargement de l'icone de l'application. ! m_Icon = ArtProvider::GetIcon(wxART_MAKE_ART_ID(wxDevCenter), wxART_FRAME_ICON, wxSize(16, 16)); SetIcon(m_Icon); *************** *** 337,344 **** wxString strIconName = pNewView->GetViewTemplate()->strIcons; wxIconBundle IB; ! IB.AddIcon(wxArtProvider::GetIcon(strIconName, wxART_FRAME_ICON, wxSize(16, 16))); ! IB.AddIcon(wxArtProvider::GetIcon(strIconName, wxART_FRAME_ICON, wxSize(32, 32))); ! IB.AddIcon(wxArtProvider::GetIcon(strIconName, wxART_FRAME_ICON, wxSize(48, 48))); ! IB.AddIcon(wxArtProvider::GetIcon(strIconName, wxART_FRAME_ICON, wxSize(64, 64))); SetIcons(IB); wxString strName; --- 336,343 ---- wxString strIconName = pNewView->GetViewTemplate()->strIcons; wxIconBundle IB; ! IB.AddIcon(ArtProvider::GetIcon(strIconName, wxART_FRAME_ICON, wxSize(16, 16))); ! IB.AddIcon(ArtProvider::GetIcon(strIconName, wxART_FRAME_ICON, wxSize(32, 32))); ! IB.AddIcon(ArtProvider::GetIcon(strIconName, wxART_FRAME_ICON, wxSize(48, 48))); ! IB.AddIcon(ArtProvider::GetIcon(strIconName, wxART_FRAME_ICON, wxSize(64, 64))); SetIcons(IB); wxString strName; Index: Application.cpp =================================================================== RCS file: /cvsroot/wxdevcenter/wxDevCenter/src/Application.cpp,v retrieving revision 1.33 retrieving revision 1.34 diff -C2 -d -r1.33 -r1.34 *** Application.cpp 14 Sep 2005 14:19:11 -0000 1.33 --- Application.cpp 14 Sep 2005 20:01:53 -0000 1.34 *************** *** 494,503 **** // Groupe "Fichier" pCmdGroup = new CommandGroup(WXDC_MENU_FILES); ! pCmdGroup->AppendCommand(IDM_FILE_NEW, WXDC_MENU_FILE_NEW); ! pCmdGroup->AppendCommand(IDM_FILE_OPEN, WXDC_MENU_FILE_OPEN); pCmdGroup->AppendCommand(IDM_FILE_CLOSE, WXDC_MENU_FILE_CLOSE); pCmdGroup->AppendCommand(IDM_FILE_CLOSEALL, WXDC_MENU_FILE_CLOSEALL); ! pCmdGroup->AppendCommand(IDM_FILE_SAVE, WXDC_MENU_FILE_SAVE); ! pCmdGroup->AppendCommand(IDM_FILE_SAVEAS, WXDC_MENU_FILE_SAVEAS); pCmdGroup->AppendSeparator(); pCmdGroup->AppendCommand(IDM_PROJECT_NEW, WXDC_MENU_PROJECT_NEW); --- 494,503 ---- // Groupe "Fichier" pCmdGroup = new CommandGroup(WXDC_MENU_FILES); ! pCmdGroup->AppendCommand(IDM_FILE_NEW, WXDC_MENU_FILE_NEW, wxT(""), wxART_NEW); ! pCmdGroup->AppendCommand(IDM_FILE_OPEN, WXDC_MENU_FILE_OPEN, wxT(""), wxART_FILE_OPEN); pCmdGroup->AppendCommand(IDM_FILE_CLOSE, WXDC_MENU_FILE_CLOSE); pCmdGroup->AppendCommand(IDM_FILE_CLOSEALL, WXDC_MENU_FILE_CLOSEALL); ! pCmdGroup->AppendCommand(IDM_FILE_SAVE, WXDC_MENU_FILE_SAVE, wxT(""), wxART_FILE_SAVE); ! pCmdGroup->AppendCommand(IDM_FILE_SAVEAS, WXDC_MENU_FILE_SAVEAS, wxT(""), wxART_FILE_SAVE_AS); pCmdGroup->AppendSeparator(); pCmdGroup->AppendCommand(IDM_PROJECT_NEW, WXDC_MENU_PROJECT_NEW); *************** *** 505,513 **** pCmdGroup->AppendCommand(IDM_PROJECT_CLOSE, WXDC_MENU_PROJECT_CLOSE); pCmdGroup->AppendSeparator(); ! pCmdGroup->AppendCommand(IDM_FILE_PRINT, WXDC_MENU_FILE_PRINT); pCmdGroup->AppendCommand(IDM_FILE_PRINTSETUP, WXDC_MENU_FILE_PRINTSETUP); pCmdGroup->AppendCommand(IDM_FILE_PRINTPREVIEW, WXDC_MENU_FILE_PRINTPREVIEW); pCmdGroup->AppendSeparator(); ! pCmdGroup->AppendCommand(wxID_EXIT, WXDC_MENU_APP_EXIT); CommandManager::GetCommandManager().AddCommandManager(pCmdGroup, NULL, CmdGrpType_Application); --- 505,513 ---- pCmdGroup->AppendCommand(IDM_PROJECT_CLOSE, WXDC_MENU_PROJECT_CLOSE); pCmdGroup->AppendSeparator(); ! pCmdGroup->AppendCommand(IDM_FILE_PRINT, WXDC_MENU_FILE_PRINT, wxT(""), wxART_PRINT); pCmdGroup->AppendCommand(IDM_FILE_PRINTSETUP, WXDC_MENU_FILE_PRINTSETUP); pCmdGroup->AppendCommand(IDM_FILE_PRINTPREVIEW, WXDC_MENU_FILE_PRINTPREVIEW); pCmdGroup->AppendSeparator(); ! pCmdGroup->AppendCommand(wxID_EXIT, WXDC_MENU_APP_EXIT, wxT(""), wxART_QUIT); CommandManager::GetCommandManager().AddCommandManager(pCmdGroup, NULL, CmdGrpType_Application); *************** *** 521,526 **** // pCmdGroup->AppendCommand(IDM_WINDOW_WORKBAR, WXDC_MENU_WINDOW_WORKBAR, new wxMenu); pCmdGroup->AppendSeparator(); ! pCmdGroup->AppendCommand(IDM_WINDOW_NEXT, WXDC_MENU_WINDOW_NEXT); ! pCmdGroup->AppendCommand(IDM_WINDOW_PREV, WXDC_MENU_WINDOW_PREV); pCmdGroup->AppendSeparator(); // pCmdGroup->AppendCommand(pMenu, WXDC_MENU_WINDOW); --- 521,526 ---- // pCmdGroup->AppendCommand(IDM_WINDOW_WORKBAR, WXDC_MENU_WINDOW_WORKBAR, new wxMenu); pCmdGroup->AppendSeparator(); ! pCmdGroup->AppendCommand(IDM_WINDOW_NEXT, WXDC_MENU_WINDOW_NEXT, wxT(""), wxART_GO_FORWARD); ! pCmdGroup->AppendCommand(IDM_WINDOW_PREV, WXDC_MENU_WINDOW_PREV, wxT(""), wxART_GO_BACK); pCmdGroup->AppendSeparator(); // pCmdGroup->AppendCommand(pMenu, WXDC_MENU_WINDOW); *************** *** 529,536 **** // Menu Aide pCmdGroup = new CommandGroup(WXDC_MENU_HELP); ! pCmdGroup->AppendCommand(IDM_HELP_CONTENT, WXDC_MENU_HELP_CONTENT); ! pCmdGroup->AppendCommand(IDM_HELP_INDEX, WXDC_MENU_HELP_INDEX); pCmdGroup->AppendSeparator(); ! pCmdGroup->AppendCommand(IDM_HELP_ABOUT, WXDC_MENU_HELP_ABOUT); CommandManager::GetCommandManager().AddCommandManager(pCmdGroup, NULL, CmdGrpType_Help); } --- 529,536 ---- // Menu Aide pCmdGroup = new CommandGroup(WXDC_MENU_HELP); ! pCmdGroup->AppendCommand(IDM_HELP_CONTENT, WXDC_MENU_HELP_CONTENT, wxT(""), wxART_HELP); ! pCmdGroup->AppendCommand(IDM_HELP_INDEX, WXDC_MENU_HELP_INDEX, wxT(""), wxART_HELP); pCmdGroup->AppendSeparator(); ! pCmdGroup->AppendCommand(IDM_HELP_ABOUT, WXDC_MENU_HELP_ABOUT, wxT(""), wxART_HELP); CommandManager::GetCommandManager().AddCommandManager(pCmdGroup, NULL, CmdGrpType_Help); } Index: Command.cpp =================================================================== RCS file: /cvsroot/wxdevcenter/wxDevCenter/src/Command.cpp,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** Command.cpp 14 Sep 2005 14:19:11 -0000 1.2 --- Command.cpp 14 Sep 2005 20:01:53 -0000 1.3 *************** *** 26,31 **** #include <wxDevCenter/Application.h> #include <wxDevCenter/Layout.h> ! ! #include <wx/artprov.h> // Utilisation du namespace --- 26,30 ---- #include <wxDevCenter/Application.h> #include <wxDevCenter/Layout.h> ! #include <wxDevCenter/ArtProvider.h> // Utilisation du namespace *************** *** 104,108 **** } if(!GetIconName().IsEmpty()) ! pMI->SetBitmap(wxArtProvider::GetBitmap(GetIconName())); return pMI; } --- 103,107 ---- } if(!GetIconName().IsEmpty()) ! pMI->SetBitmap(ArtProvider::GetBitmap(GetIconName())); return pMI; } |
|
From: Emilien K. <cur...@us...> - 2005-09-14 20:02:00
|
Update of /cvsroot/wxdevcenter/wxDevCenter/include/wxDevCenter In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv20135/include/wxDevCenter Modified Files: ArtProvider.h Log Message: Override wxArtProvider::GetBitmap/GetIcon to return a valid icon whatever the wxArtProvider found. Index: ArtProvider.h =================================================================== RCS file: /cvsroot/wxdevcenter/wxDevCenter/include/wxDevCenter/ArtProvider.h,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** ArtProvider.h 13 Aug 2005 14:07:37 -0000 1.1 --- ArtProvider.h 14 Sep 2005 20:01:53 -0000 1.2 *************** *** 43,46 **** --- 43,49 ---- */ virtual wxBitmap CreateBitmap(const wxArtID& id, const wxArtClient& client, const wxSize& size); + public: + static wxBitmap GetBitmap(const wxArtID& id, const wxArtClient& client = wxART_OTHER, const wxSize& size = wxDefaultSize); + static wxIcon GetIcon(const wxArtID& id, const wxArtClient& client = wxART_OTHER, const wxSize& size = wxDefaultSize); }; |
|
From: Emilien K. <cur...@us...> - 2005-09-14 20:01:51
|
Update of /cvsroot/wxdevcenter/StdPlugin/src/Bitmap In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv20062/src/Bitmap Modified Files: BitmapDocView.cpp BitmapProp.cpp Log Message: Override wxArtProvider::GetBitmap/GetIcon to return a valid icon whatever the wxArtProvider found. Index: BitmapProp.cpp =================================================================== RCS file: /cvsroot/wxdevcenter/StdPlugin/src/Bitmap/BitmapProp.cpp,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** BitmapProp.cpp 25 Aug 2005 20:36:08 -0000 1.1 --- BitmapProp.cpp 14 Sep 2005 20:01:43 -0000 1.2 *************** *** 8,14 **** #include <wxDevCenter/StdPlugin.h> #include <wxDevCenter/StdPlugin/Bitmap/BitmapProp.h> #include <wx/bmpbuttn.h> - #include <wx/artprov.h> #include <wx/confbase.h> --- 8,14 ---- #include <wxDevCenter/StdPlugin.h> #include <wxDevCenter/StdPlugin/Bitmap/BitmapProp.h> + #include <wxDevCenter/ArtProvider.h> #include <wx/bmpbuttn.h> #include <wx/confbase.h> *************** *** 172,177 **** m_pResUnitChoice = new wxChoice(this, ID_RESUNIT_CHOICE, wxDefaultPosition, wxDefaultSize, 0, NULL); ! wxBitmapButton *pBmp1 = new wxBitmapButton(this, ID_LANDSCAPE, wxArtProvider::GetIcon(wxT("StdPlugin.Bitmap/landscape"), wxART_BUTTON, wxSize(16, 16))), ! *pBmp2 = new wxBitmapButton(this, ID_PORTRAIT, wxArtProvider::GetIcon(wxT("StdPlugin.Bitmap/portrait"), wxART_BUTTON, wxSize(16, 16))); // Mise en page --- 172,177 ---- m_pResUnitChoice = new wxChoice(this, ID_RESUNIT_CHOICE, wxDefaultPosition, wxDefaultSize, 0, NULL); ! wxBitmapButton *pBmp1 = new wxBitmapButton(this, ID_LANDSCAPE, ArtProvider::GetIcon(wxT("StdPlugin.Bitmap/landscape"), wxART_BUTTON, wxSize(16, 16))), ! *pBmp2 = new wxBitmapButton(this, ID_PORTRAIT, ArtProvider::GetIcon(wxT("StdPlugin.Bitmap/portrait"), wxART_BUTTON, wxSize(16, 16))); // Mise en page Index: BitmapDocView.cpp =================================================================== RCS file: /cvsroot/wxdevcenter/StdPlugin/src/Bitmap/BitmapDocView.cpp,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** BitmapDocView.cpp 14 Sep 2005 15:36:25 -0000 1.2 --- BitmapDocView.cpp 14 Sep 2005 20:01:43 -0000 1.3 *************** *** 11,19 **** #include <wxDevCenter/FileSystem.h> #include <wxDevCenter/DocView.h> #include <wx/dcmemory.h> #include <wx/toolbar.h> #include <wx/clipbrd.h> - #include <wx/artprov.h> --- 11,19 ---- #include <wxDevCenter/FileSystem.h> #include <wxDevCenter/DocView.h> + #include <wxDevCenter/ArtProvider.h> #include <wx/dcmemory.h> #include <wx/toolbar.h> #include <wx/clipbrd.h> *************** *** 1058,1095 **** wxBitmap bmp; ! bmp = wxArtProvider::GetBitmap(wxT("StdPlugin.Bitmap/handdraw")); pTB->AddTool(ID_TOOL_HANDDRAW, WXDC_BITMAP_TOOL_HANDDRAW, bmp, WXDC_BITMAP_TOOLHELP_HANDDRAW, wxITEM_CHECK); ! bmp = wxArtProvider::GetBitmap(wxT("StdPlugin.Bitmap/spray")); pTB->AddTool(ID_TOOL_SPRAY, WXDC_BITMAP_TOOL_SPRAY, bmp, WXDC_BITMAP_TOOLHELP_SPRAY, wxITEM_CHECK); pTB->AddSeparator(); ! bmp = wxArtProvider::GetBitmap(wxT("StdPlugin.Bitmap/line")); pTB->AddTool(ID_TOOL_LINE, WXDC_BITMAP_TOOL_LINE, bmp, WXDC_BITMAP_TOOLHELP_LINE, wxITEM_CHECK); ! bmp = wxArtProvider::GetBitmap(wxT("StdPlugin.Bitmap/rect")); pTB->AddTool(ID_TOOL_RECT, WXDC_BITMAP_TOOL_RECT, bmp, WXDC_BITMAP_TOOLHELP_RECT, wxITEM_CHECK); ! bmp = wxArtProvider::GetBitmap(wxT("StdPlugin.Bitmap/ellipse")); pTB->AddTool(ID_TOOL_ELLIPSE, WXDC_BITMAP_TOOL_ELLIPSE, bmp, WXDC_BITMAP_TOOLHELP_ELLIPSE, wxITEM_CHECK); ! bmp = wxArtProvider::GetBitmap(wxT("StdPlugin.Bitmap/rrect")); pTB->AddTool(ID_TOOL_RRECT, WXDC_BITMAP_TOOL_RRECT, bmp, WXDC_BITMAP_TOOLHELP_RRECT, wxITEM_CHECK); ! bmp = wxArtProvider::GetBitmap(wxT("StdPlugin.Bitmap/sizeall")); pTB->AddTool(ID_TOOL_SIZEALL, WXDC_BITMAP_TOOL_SIZEALL, bmp, WXDC_BITMAP_TOOLHELP_SIZEALL, wxITEM_CHECK); pTB->AddSeparator(); ! bmp = wxArtProvider::GetBitmap(wxT("StdPlugin.Bitmap/selection")); pTB->AddTool(ID_TOOL_SELECTION, WXDC_BITMAP_TOOL_SELECTION, bmp, WXDC_BITMAP_TOOLHELP_SELECTION, wxITEM_CHECK); ! bmp = wxArtProvider::GetBitmap(wxT("StdPlugin.Bitmap/selall")); pTB->AddTool(ID_TOOL_SELALL, WXDC_BITMAP_TOOL_SELALL, bmp, WXDC_BITMAP_TOOLHELP_SELALL, wxITEM_CHECK); ! bmp = wxArtProvider::GetBitmap(wxT("StdPlugin.Bitmap/selmove")); pTB->AddTool(ID_TOOL_SELMOVE, WXDC_BITMAP_TOOL_SELMOVE, bmp, WXDC_BITMAP_TOOL_SELMOVE, wxITEM_CHECK); ! bmp = wxArtProvider::GetBitmap(wxT("StdPlugin.Bitmap/selremove")); pTB->AddTool(ID_TOOL_SELREMOVE, WXDC_BITMAP_TOOL_SELREMOVE, bmp, WXDC_BITMAP_TOOLHELP_SELREMOVE, wxITEM_CHECK); ! bmp = wxArtProvider::GetBitmap(wxT("StdPlugin.Bitmap/selcut")); pTB->AddTool(wxID_CUT, WXDC_BITMAP_TOOL_SELCUT, bmp, WXDC_BITMAP_TOOLHELP_SELCUT, wxITEM_CHECK); ! bmp = wxArtProvider::GetBitmap(wxT("StdPlugin.Bitmap/selcopy")); pTB->AddTool(wxID_COPY, WXDC_BITMAP_TOOL_SELCOPY, bmp, WXDC_BITMAP_TOOLHELP_SELCOPY, wxITEM_CHECK); ! bmp = wxArtProvider::GetBitmap(wxT("StdPlugin.Bitmap/selpaste")); pTB->AddTool(wxID_PASTE, WXDC_BITMAP_TOOL_SELPASTE, bmp, WXDC_BITMAP_TOOLHELP_SELPASTE, wxITEM_CHECK); --- 1058,1095 ---- wxBitmap bmp; ! bmp = ArtProvider::GetBitmap(wxT("StdPlugin.Bitmap/handdraw")); pTB->AddTool(ID_TOOL_HANDDRAW, WXDC_BITMAP_TOOL_HANDDRAW, bmp, WXDC_BITMAP_TOOLHELP_HANDDRAW, wxITEM_CHECK); ! bmp = ArtProvider::GetBitmap(wxT("StdPlugin.Bitmap/spray")); pTB->AddTool(ID_TOOL_SPRAY, WXDC_BITMAP_TOOL_SPRAY, bmp, WXDC_BITMAP_TOOLHELP_SPRAY, wxITEM_CHECK); pTB->AddSeparator(); ! bmp = ArtProvider::GetBitmap(wxT("StdPlugin.Bitmap/line")); pTB->AddTool(ID_TOOL_LINE, WXDC_BITMAP_TOOL_LINE, bmp, WXDC_BITMAP_TOOLHELP_LINE, wxITEM_CHECK); ! bmp = ArtProvider::GetBitmap(wxT("StdPlugin.Bitmap/rect")); pTB->AddTool(ID_TOOL_RECT, WXDC_BITMAP_TOOL_RECT, bmp, WXDC_BITMAP_TOOLHELP_RECT, wxITEM_CHECK); ! bmp = ArtProvider::GetBitmap(wxT("StdPlugin.Bitmap/ellipse")); pTB->AddTool(ID_TOOL_ELLIPSE, WXDC_BITMAP_TOOL_ELLIPSE, bmp, WXDC_BITMAP_TOOLHELP_ELLIPSE, wxITEM_CHECK); ! bmp = ArtProvider::GetBitmap(wxT("StdPlugin.Bitmap/rrect")); pTB->AddTool(ID_TOOL_RRECT, WXDC_BITMAP_TOOL_RRECT, bmp, WXDC_BITMAP_TOOLHELP_RRECT, wxITEM_CHECK); ! bmp = ArtProvider::GetBitmap(wxT("StdPlugin.Bitmap/sizeall")); pTB->AddTool(ID_TOOL_SIZEALL, WXDC_BITMAP_TOOL_SIZEALL, bmp, WXDC_BITMAP_TOOLHELP_SIZEALL, wxITEM_CHECK); pTB->AddSeparator(); ! bmp = ArtProvider::GetBitmap(wxT("StdPlugin.Bitmap/selection")); pTB->AddTool(ID_TOOL_SELECTION, WXDC_BITMAP_TOOL_SELECTION, bmp, WXDC_BITMAP_TOOLHELP_SELECTION, wxITEM_CHECK); ! bmp = ArtProvider::GetBitmap(wxT("StdPlugin.Bitmap/selall")); pTB->AddTool(ID_TOOL_SELALL, WXDC_BITMAP_TOOL_SELALL, bmp, WXDC_BITMAP_TOOLHELP_SELALL, wxITEM_CHECK); ! bmp = ArtProvider::GetBitmap(wxT("StdPlugin.Bitmap/selmove")); pTB->AddTool(ID_TOOL_SELMOVE, WXDC_BITMAP_TOOL_SELMOVE, bmp, WXDC_BITMAP_TOOL_SELMOVE, wxITEM_CHECK); ! bmp = ArtProvider::GetBitmap(wxT("StdPlugin.Bitmap/selremove")); pTB->AddTool(ID_TOOL_SELREMOVE, WXDC_BITMAP_TOOL_SELREMOVE, bmp, WXDC_BITMAP_TOOLHELP_SELREMOVE, wxITEM_CHECK); ! bmp = ArtProvider::GetBitmap(wxT("StdPlugin.Bitmap/selcut")); pTB->AddTool(wxID_CUT, WXDC_BITMAP_TOOL_SELCUT, bmp, WXDC_BITMAP_TOOLHELP_SELCUT, wxITEM_CHECK); ! bmp = ArtProvider::GetBitmap(wxT("StdPlugin.Bitmap/selcopy")); pTB->AddTool(wxID_COPY, WXDC_BITMAP_TOOL_SELCOPY, bmp, WXDC_BITMAP_TOOLHELP_SELCOPY, wxITEM_CHECK); ! bmp = ArtProvider::GetBitmap(wxT("StdPlugin.Bitmap/selpaste")); pTB->AddTool(wxID_PASTE, WXDC_BITMAP_TOOL_SELPASTE, bmp, WXDC_BITMAP_TOOLHELP_SELPASTE, wxITEM_CHECK); *************** *** 1189,1203 **** pTB->SetToolBitmapSize(wxSize(96, 15)); wxBitmap bmp; ! bmp = wxArtProvider::GetBitmap(wxT("StdPlugin.Bitmap/solid")); pTB->AddTool(ID_PEN_SOLID, wxT("Solid"), bmp, wxT("Solid pen"), wxITEM_CHECK); ! bmp = wxArtProvider::GetBitmap(wxT("StdPlugin.Bitmap/transparent")); pTB->AddTool(ID_PEN_TRANSPARENT, wxT("Transparent"), bmp, wxT("Transparent pen"), wxITEM_CHECK); ! bmp = wxArtProvider::GetBitmap(wxT("StdPlugin.Bitmap/dot")); pTB->AddTool(ID_PEN_DOT, wxT("Dot"), bmp, wxT("Dot pen"), wxITEM_CHECK); ! bmp = wxArtProvider::GetBitmap(wxT("StdPlugin.Bitmap/long_dash")); pTB->AddTool(ID_PEN_LONG_DASH, wxT("Long dash"), bmp, wxT("Long dash pen"), wxITEM_CHECK); ! bmp = wxArtProvider::GetBitmap(wxT("StdPlugin.Bitmap/short_dash")); pTB->AddTool(ID_PEN_SHORT_DASH, wxT("Short dash"), bmp, wxT("Short dash pen"), wxITEM_CHECK); ! bmp = wxArtProvider::GetBitmap(wxT("StdPlugin.Bitmap/dot_dash")); pTB->AddTool(ID_PEN_DOT_DASH, wxT("Dot...dash"), bmp, wxT("Dot...dash pen"), wxITEM_CHECK); pTB->Realize(); --- 1189,1203 ---- pTB->SetToolBitmapSize(wxSize(96, 15)); wxBitmap bmp; ! bmp = ArtProvider::GetBitmap(wxT("StdPlugin.Bitmap/solid")); pTB->AddTool(ID_PEN_SOLID, wxT("Solid"), bmp, wxT("Solid pen"), wxITEM_CHECK); ! bmp = ArtProvider::GetBitmap(wxT("StdPlugin.Bitmap/transparent")); pTB->AddTool(ID_PEN_TRANSPARENT, wxT("Transparent"), bmp, wxT("Transparent pen"), wxITEM_CHECK); ! bmp = ArtProvider::GetBitmap(wxT("StdPlugin.Bitmap/dot")); pTB->AddTool(ID_PEN_DOT, wxT("Dot"), bmp, wxT("Dot pen"), wxITEM_CHECK); ! bmp = ArtProvider::GetBitmap(wxT("StdPlugin.Bitmap/long_dash")); pTB->AddTool(ID_PEN_LONG_DASH, wxT("Long dash"), bmp, wxT("Long dash pen"), wxITEM_CHECK); ! bmp = ArtProvider::GetBitmap(wxT("StdPlugin.Bitmap/short_dash")); pTB->AddTool(ID_PEN_SHORT_DASH, wxT("Short dash"), bmp, wxT("Short dash pen"), wxITEM_CHECK); ! bmp = ArtProvider::GetBitmap(wxT("StdPlugin.Bitmap/dot_dash")); pTB->AddTool(ID_PEN_DOT_DASH, wxT("Dot...dash"), bmp, wxT("Dot...dash pen"), wxITEM_CHECK); pTB->Realize(); |
|
From: Emilien K. <cur...@us...> - 2005-09-14 15:40:11
|
Update of /cvsroot/wxdevcenter/wxDevCenter/src In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv18366/src Modified Files: MainFrame.cpp Log Message: Remove old menu system. Index: MainFrame.cpp =================================================================== RCS file: /cvsroot/wxdevcenter/wxDevCenter/src/MainFrame.cpp,v retrieving revision 1.20 retrieving revision 1.21 diff -C2 -d -r1.20 -r1.21 *** MainFrame.cpp 14 Sep 2005 14:19:11 -0000 1.20 --- MainFrame.cpp 14 Sep 2005 15:40:03 -0000 1.21 *************** *** 290,346 **** { wxMenuBar *pMenuBar = new wxMenuBar(); ! /* wxMenu *pMenu; ! ! // Menu Fichier ! pMenu = new wxMenu(); ! pMenu->Append(IDM_FILE_NEW, WXDC_MENU_FILE_NEW); ! pMenu->Append(IDM_FILE_OPEN, WXDC_MENU_FILE_OPEN); ! pMenu->Append(IDM_FILE_CLOSE, WXDC_MENU_FILE_CLOSE); ! pMenu->Append(IDM_FILE_CLOSEALL, WXDC_MENU_FILE_CLOSEALL); ! pMenu->Append(IDM_FILE_SAVE, WXDC_MENU_FILE_SAVE); ! pMenu->Append(IDM_FILE_SAVEAS, WXDC_MENU_FILE_SAVEAS); ! pMenu->AppendSeparator(); ! pMenu->Append(IDM_PROJECT_NEW, WXDC_MENU_PROJECT_NEW); ! pMenu->Append(IDM_PROJECT_OPEN, WXDC_MENU_PROJECT_OPEN); ! pMenu->Append(IDM_PROJECT_CLOSE, WXDC_MENU_PROJECT_CLOSE); ! pMenu->AppendSeparator(); ! pMenu->Append(IDM_FILE_PRINT, WXDC_MENU_FILE_PRINT); ! pMenu->Append(IDM_FILE_PRINTSETUP, WXDC_MENU_FILE_PRINTSETUP); ! pMenu->Append(IDM_FILE_PRINTPREVIEW, WXDC_MENU_FILE_PRINTPREVIEW); ! pMenu->AppendSeparator(); ! pMenu->Append(wxID_EXIT, WXDC_MENU_APP_EXIT); ! pMenuBar->Append(pMenu, WXDC_MENU_FILES); ! ! // Menu Fenetres ! pMenu = new wxMenu(); ! pMenu->Append(IDM_WINDOW_CLONE, WXDC_MENU_WINDOW_CLONE); ! pMenu->Append(IDM_WINDOW_NEW, WXDC_MENU_WINDOW_NEW); ! pMenu->Append(IDM_WINDOW_CLOSE, WXDC_MENU_WINDOW_CLOSE); ! pMenu->Append(IDM_WINDOW_CLOSEALL, WXDC_MENU_WINDOW_CLOSEALL); ! pMenu->AppendSeparator(); ! m_pMenuItemWorkBar = pMenu->Append(IDM_WINDOW_WORKBAR, WXDC_MENU_WINDOW_WORKBAR, new wxMenu); ! pMenu->AppendSeparator(); ! pMenu->Append(IDM_WINDOW_NEXT, WXDC_MENU_WINDOW_NEXT); ! pMenu->Append(IDM_WINDOW_PREV, WXDC_MENU_WINDOW_PREV); ! pMenu->AppendSeparator(); ! pMenuBar->Append(pMenu, WXDC_MENU_WINDOW); ! ! // Menu Aide ! pMenu = new wxMenu(); ! pMenu->Append(IDM_HELP_CONTENT, WXDC_MENU_HELP_CONTENT); ! pMenu->Append(IDM_HELP_INDEX, WXDC_MENU_HELP_INDEX); ! pMenu->AppendSeparator(); ! pMenu->Append(IDM_HELP_ABOUT, WXDC_MENU_HELP_ABOUT); ! pMenuBar->Append(pMenu, WXDC_MENU_HELP); ! ! ! // Fixe la barre de menus ! */ SetMenuBar(pMenuBar); ! CommandManager::GetCommandManager().PopulateMenuBar(GetMenuBar(), GetLayout()); ! ! /* m_iMenuSeparator = 1; // Reconstruit le sous menu des workbars ! RebuildWorkBarMenu();*/ } --- 290,298 ---- { wxMenuBar *pMenuBar = new wxMenuBar(); ! SetMenuBar(pMenuBar); ! CommandManager::GetCommandManager().PopulateMenuBar(GetMenuBar(), GetLayout()); // Reconstruit le sous menu des workbars ! //RebuildWorkBarMenu(); } *************** *** 368,372 **** void MainFrame::OnCurrentViewChanging(ViewEvent &event) { - // RemoveViewMenu(event.GetOldView()); CommandManager::GetCommandManager().PopulateMenuBar(GetMenuBar(), GetLayout()); SetIcon(m_Icon); --- 320,323 ---- *************** *** 382,386 **** if(pNewView!=NULL) { - // InsertViewMenu(pNewView); CommandManager::GetCommandManager().PopulateMenuBar(GetMenuBar(), GetLayout()); --- 333,336 ---- *************** *** 462,466 **** { // wxMenu *pMenu = m_pMenuItemWorkBar->GetSubMenu(); - // m_pLayoutManager->SetWindowMenu(pMenu); } --- 412,415 ---- |
|
From: Emilien K. <cur...@us...> - 2005-09-14 15:37:14
|
Update of /cvsroot/wxdevcenter/wxDevCenter/include/wxDevCenter In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv17413/include/wxDevCenter Modified Files: DocView.h Frame.h Log Message: Remove old menu system. Index: DocView.h =================================================================== RCS file: /cvsroot/wxdevcenter/wxDevCenter/include/wxDevCenter/DocView.h,v retrieving revision 1.20 retrieving revision 1.21 diff -C2 -d -r1.20 -r1.21 *** DocView.h 17 Aug 2005 16:33:17 -0000 1.20 --- DocView.h 14 Sep 2005 15:37:06 -0000 1.21 *************** *** 112,116 **** friend class TopFrame; friend class Document; - friend class MenuBar; /** Déclaration de classe dynamique. Déclare la classe comme pouvant être crée dynamiquement depuis ses infos RTTI de caractère.*/ --- 112,115 ---- *************** *** 123,143 **** /** Document attaché. Document auquel est attaché la vue.*/ Document *m_pDocument; - /** Tableau des menus propres. Tableau des menus qui interagissent directement avec la vue ou avec le document (via la vue).*/ - MenuArray m_aMenu; /** Adresse du patron de vue.*/ ViewTemplate *m_pViewTemplate; - /** Demande l'insertion des menus spécifiques dans la barre de menus. - * @param pMenuBar Barre de menu où insérer les menus spécifiques. - * @param iInsert Position dans la barre de menu où sont typiquement insérés les menus. - */ - virtual void InsertMenu(wxMenuBar* pMenuBar, int iInsert); - /** Demande la suppression des menus spécifiques dans la barre de menus. - * @param pMenuBar Barre de menu d'où supprimer les menus spécifiques. - * @param iInsert Position dans la barre de menu où sont typiquement insérés les menus. - */ - virtual void RemoveMenu(wxMenuBar* pMenuBar, int iInsert); - /** Appelé par le document en cas de changement de chemin/nom. */ --- 122,129 ---- Index: Frame.h =================================================================== RCS file: /cvsroot/wxdevcenter/wxDevCenter/include/wxDevCenter/Frame.h,v retrieving revision 1.12 retrieving revision 1.13 diff -C2 -d -r1.12 -r1.13 *** Frame.h 14 Sep 2005 14:19:10 -0000 1.12 --- Frame.h 14 Sep 2005 15:37:06 -0000 1.13 *************** *** 128,160 **** /** - * Liste des menus spécifiques aux vues - */ - - class WXDC_DLL_BASE MenuArray : public wxObject - { - protected: - WX_DEFINE_USER_EXPORTED_ARRAY(wxMenu*, MenuArrayMenu, class WXDC_DLL_BASE); - MenuArrayMenu m_ListMenu; - wxArrayString m_ListTopLabel; - public: - MenuArray(); - ~MenuArray(); - - int GetCount()const{return m_ListMenu.GetCount();} - bool IsEmpty()const{return m_ListMenu.IsEmpty();} - void Empty(){m_ListMenu.Empty(); m_ListTopLabel.Empty();} - void Append(wxMenu *pMenu, wxString strLabel){Insert(GetCount(), pMenu, strLabel);} - void Insert(int pos, wxMenu *pMenu, wxString strLabel){m_ListMenu.Insert(pMenu, pos); m_ListTopLabel.Insert(strLabel, pos);} - void RemoveAt(int pos, int nb=1){m_ListMenu.RemoveAt(pos, nb);m_ListTopLabel.RemoveAt(pos, nb);} - - wxMenu* GetMenu(int pos){return m_ListMenu[pos];} - wxString GetLabel(int pos)const {return m_ListTopLabel[pos];} - - void SetMenu(int pos, wxMenu *pMenu){m_ListMenu[pos] = pMenu;} - void SetLabel(int pos, wxString strLabel){m_ListTopLabel[pos] = strLabel;} - }; - - - /** * Classe de base pour les fenêtres cadres mères. * --- 128,131 ---- *************** *** 162,166 **** * de niveau maximum. Ce sont elles qui contiennent les barres de menus * ainsi que la barre de status et les barres d'outils génériques. - * @see wxDevCenter::MainFrame */ class WXDC_DLL_BASE TopFrame : public wxFrame --- 133,136 ---- *************** *** 173,197 **** ViewFrame* m_pViewFrame; - /** Position d'insertion des menus spécifiques dans la barre des menus.*/ - int m_iMenuSeparator; - - /** Flag de présence du menu spécifique de vue dans la barre de menu. - * @warning Utile à cause d'un bug de wx qui envoie deux fois les event de changement d'onglet actif. - */ - bool m_bHasViewMenu; - - /** Insère le menu spécifique de la vue active. - * @param pView Vue qui doit insérer ses menus spécifiques. - */ - void InsertViewMenu(View* pView); - /** Retire le menu spécifique de la vue active. - * @param pView Vue qui doit retirer ses menus spécifiques. - */ - void RemoveViewMenu(View* pView); - /** Surcharge le procédé d'exécution des évènements.*/ virtual bool ProcessEvent(wxEvent& event); - public: /** Constructeur.*/ --- 143,149 ---- |
|
From: Emilien K. <cur...@us...> - 2005-09-14 15:37:14
|
Update of /cvsroot/wxdevcenter/wxDevCenter/src In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv17413/src Modified Files: Frame.cpp View.cpp Log Message: Remove old menu system. Index: Frame.cpp =================================================================== RCS file: /cvsroot/wxdevcenter/wxDevCenter/src/Frame.cpp,v retrieving revision 1.10 retrieving revision 1.11 diff -C2 -d -r1.10 -r1.11 *** Frame.cpp 14 Sep 2005 14:19:11 -0000 1.10 --- Frame.cpp 14 Sep 2005 15:37:06 -0000 1.11 *************** *** 60,80 **** ! ////////////////////////////////////////////////////////////////////// ! // MenuList ! ////////////////////////////////////////////////////////////////////// ! ! MenuArray::MenuArray():wxObject(), ! m_ListMenu(), ! m_ListTopLabel() ! { ! } ! ! MenuArray::~MenuArray() ! { ! } ! ! ! ! ////////////////////////////////////////////////////////////////////// // TopFrame ////////////////////////////////////////////////////////////////////// --- 60,64 ---- ! ///////////////////////////////////////////////////////////////////// // TopFrame ////////////////////////////////////////////////////////////////////// *************** *** 87,93 **** TopFrame::TopFrame(const wxString& title, const wxPoint& pos, const wxSize& size, long style): wxFrame(NULL, -1, title, pos, size, style), ! m_pViewFrame(NULL), ! m_iMenuSeparator(0), ! m_bHasViewMenu(false) { } --- 71,75 ---- TopFrame::TopFrame(const wxString& title, const wxPoint& pos, const wxSize& size, long style): wxFrame(NULL, -1, title, pos, size, style), ! m_pViewFrame(NULL) { } *************** *** 118,144 **** - - // Insère le menu spécifique de la vue active. - void TopFrame::InsertViewMenu(View* pView) - { - if(!m_bHasViewMenu) - if(GetMenuBar()!=NULL && pView!=NULL) - { - pView->InsertMenu(GetMenuBar(), m_iMenuSeparator); - m_bHasViewMenu = true; - } - } - - // Retire le menu spécifique de la vue active. - void TopFrame::RemoveViewMenu(View* pView) - { - if(m_bHasViewMenu) - if(GetMenuBar()!=NULL && pView!=NULL) - { - pView->RemoveMenu(GetMenuBar(), m_iMenuSeparator); - m_bHasViewMenu = false; - } - } - // Surcharge du processus de destruction. bool TopFrame::Destroy() --- 100,103 ---- Index: View.cpp =================================================================== RCS file: /cvsroot/wxdevcenter/wxDevCenter/src/View.cpp,v retrieving revision 1.8 retrieving revision 1.9 diff -C2 -d -r1.8 -r1.9 *** View.cpp 3 Aug 2005 19:21:23 -0000 1.8 --- View.cpp 14 Sep 2005 15:37:06 -0000 1.9 *************** *** 46,53 **** View::~View(void) { - for(int i=0; i<(int)m_aMenu.GetCount();i++) - delete m_aMenu.GetMenu(i); - m_aMenu.Empty(); - } --- 46,49 ---- *************** *** 128,145 **** } - // Demande l'insertion des menus spécifiques dans la barre de menus. - void View::InsertMenu(wxMenuBar* pMenuBar, int iInsert) - { - for(int i=0; i<m_aMenu.GetCount(); i++) - pMenuBar->Insert(iInsert+i, m_aMenu.GetMenu(i), m_aMenu.GetLabel(i)); - } - - // Demande la suppression des menus spécifiques dans la barre de menus. - void View::RemoveMenu(wxMenuBar* pMenuBar, int iInsert) - { - for(int i=0; i<m_aMenu.GetCount(); i++) - m_aMenu.SetMenu(i, pMenuBar->Remove(iInsert)); - } - // Appelé par le document en cas de changement de chemin/nom. void View::OnChangeFilename() --- 124,127 ---- |
|
From: Emilien K. <cur...@us...> - 2005-09-14 15:36:39
|
Update of /cvsroot/wxdevcenter/StdPlugin/src/Text In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv17156/src/Text Modified Files: SimpleTextDocView.cpp Log Message: Add Command support (menu/toolbar unification). Add begining of layout support. Index: SimpleTextDocView.cpp =================================================================== RCS file: /cvsroot/wxdevcenter/StdPlugin/src/Text/SimpleTextDocView.cpp,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** SimpleTextDocView.cpp 25 Aug 2005 20:36:07 -0000 1.1 --- SimpleTextDocView.cpp 14 Sep 2005 15:36:25 -0000 1.2 *************** *** 26,29 **** --- 26,30 ---- #include <wxDevCenter/StdPlugin/Text/SimpleTextDocView.h> + #include <wx/stream.h> #include <wx/sstream.h> *************** *** 45,48 **** --- 46,51 ---- + + /** Définition du type de document 'Texte simple'.*/ wxDevCenter::DocType TxtType(WXDC_DOCTYPE_TEXT_NAME, CLASSINFO(SimpleTextDocument), WXDC_DOCTYPE_TEXT_DESCRIPT, wxT("txt;log"), *************** *** 63,66 **** --- 66,92 ---- + //! Identifiacteurs de menus + #define IDM_SHOW_LINENUMBER 6000 // IDM_VIEW_MIN + #define IDM_SHOW_LINEENDING 6001 + #define IDM_SHOW_INDENTGUIDES 6002 + #define IDM_SHOW_LONGLINES 6003 + #define IDM_SHOW_SPACECHAR 6004 + #define IDM_SHOW_OPTION 6005 + + #define IDM_EDIT_FINDNEXT 6020 + #define IDM_EDIT_REPLACE 6021 + + + #define IDM_LANG_START 6100 + #define IDM_LANG_NULL (IDM_LANG_START + wxSTC_LEX_NULL) + #define IDM_LANG_CPP (IDM_LANG_START + wxSTC_LEX_CPP) + #define IDM_LANG_LUA (IDM_LANG_START + wxSTC_LEX_LUA) + #define IDM_LANG_END 6199 + + wxDevCenter::CommandGroup* SimpleTextView::s_pEditCommandGroup = NULL; + wxDevCenter::CommandGroup* SimpleTextView::s_pViewCommandGroup = NULL; + wxDevCenter::CommandGroup* SimpleTextView::s_pLangCommandGroup = NULL; + + ////////////////////////////////////////////////////////////////////// // LanguageProperty *************** *** 100,105 **** } - - /** Traduction d'une couleur vers sa forme de sauvegarde de config. * @param col Couleur à sauvegarder. --- 126,129 ---- *************** *** 662,684 **** #define ID_TEXT 1 - //! Identifiacteurs de menus - #define IDM_SHOW_LINENUMBER 6000 // IDM_VIEW_MIN - #define IDM_SHOW_LINEENDING 6001 - #define IDM_SHOW_INDENTGUIDES 6002 - #define IDM_SHOW_LONGLINES 6003 - #define IDM_SHOW_SPACECHAR 6004 - #define IDM_SHOW_OPTION 6005 - - #define IDM_EDIT_FINDNEXT 6020 - #define IDM_EDIT_REPLACE 6021 - - - #define IDM_LANG_START 6100 - #define IDM_LANG_NULL (IDM_LANG_START + wxSTC_LEX_NULL) - #define IDM_LANG_CPP (IDM_LANG_START + wxSTC_LEX_CPP) - #define IDM_LANG_LUA (IDM_LANG_START + wxSTC_LEX_LUA) - #define IDM_LANG_END 6199 - - BEGIN_EVENT_TABLE(SimpleTextView, View) EVT_SIZE(SimpleTextView::OnSize) --- 686,689 ---- *************** *** 740,771 **** m_pFindReplaceDialog(NULL) { ! wxMenu *pMenu; ! pMenu = new wxMenu(); ! pMenu->Append(IDM_EDIT_UNDO, WXDC_MENU_EDIT_UNDO); ! pMenu->Append(IDM_EDIT_REDO, WXDC_MENU_EDIT_REDO); ! pMenu->AppendSeparator(); ! pMenu->Append(IDM_EDIT_CUT, WXDC_MENU_EDIT_CUT); ! pMenu->Append(IDM_EDIT_COPY, WXDC_MENU_EDIT_COPY); ! pMenu->Append(IDM_EDIT_PASTE, WXDC_MENU_EDIT_PASTE); ! pMenu->Append(IDM_EDIT_CLEAR, WXDC_MENU_EDIT_DEL); ! m_aMenu.Append(pMenu, WXDC_MENU_EDIT); ! pMenu = new wxMenu(); ! pMenu->AppendCheckItem(IDM_SHOW_LINENUMBER, WXDC_MENU_VIEW_SIMPLETEXT_LINENUMBER); ! pMenu->AppendCheckItem(IDM_SHOW_LINEENDING, WXDC_MENU_VIEW_SIMPLETEXT_LINEENDING); ! pMenu->AppendCheckItem(IDM_SHOW_INDENTGUIDES, WXDC_MENU_VIEW_SIMPLETEXT_INDENTGUIDES); ! pMenu->AppendCheckItem(IDM_SHOW_LONGLINES, WXDC_MENU_VIEW_SIMPLETEXT_LONGLINES); ! pMenu->AppendCheckItem(IDM_SHOW_SPACECHAR, WXDC_MENU_VIEW_SIMPLETEXT_SPACECHAR); ! pMenu->AppendSeparator(); ! pMenu->Append(IDM_SHOW_OPTION, WXDC_MENU_VIEW_OPTIONS); ! m_aMenu.Append(pMenu, WXDC_MENU_VIEW); ! pMenu = new wxMenu(); ! pMenu->Append(IDM_EDIT_FIND, WXDC_MENU_FIND_FIND); ! pMenu->Append(IDM_EDIT_FINDNEXT, WXDC_MENU_FIND_FINDNEXT); ! pMenu->Append(IDM_EDIT_REPLACE, WXDC_MENU_FIND_REPLACE); ! m_aMenu.Append(pMenu, WXDC_MENU_FIND); ! pMenu = new wxMenu(); ! for(int i=1; i<WXDC_NB_LEX; i++) ! pMenu->AppendCheckItem(IDM_LANG_START + i, g_LangagePropertyArray[i].strName); ! m_aMenu.Append(pMenu, WXDC_MENU_LANGUAGE); } --- 745,749 ---- m_pFindReplaceDialog(NULL) { ! CreateCommandGroups(); } *************** *** 779,782 **** --- 757,803 ---- } + // Create command groups if any. + void SimpleTextView::CreateCommandGroups() + { + if(s_pEditCommandGroup==NULL) + { + s_pEditCommandGroup = new wxDevCenter::CommandGroup(WXDC_MENU_EDIT); + s_pEditCommandGroup->AppendCommand(IDM_EDIT_UNDO, WXDC_MENU_EDIT_UNDO); + s_pEditCommandGroup->AppendCommand(IDM_EDIT_REDO, WXDC_MENU_EDIT_REDO); + s_pEditCommandGroup->AppendSeparator(); + s_pEditCommandGroup->AppendCommand(IDM_EDIT_CUT, WXDC_MENU_EDIT_CUT); + s_pEditCommandGroup->AppendCommand(IDM_EDIT_COPY, WXDC_MENU_EDIT_COPY); + s_pEditCommandGroup->AppendCommand(IDM_EDIT_PASTE, WXDC_MENU_EDIT_PASTE); + s_pEditCommandGroup->AppendCommand(IDM_EDIT_CLEAR, WXDC_MENU_EDIT_DEL); + s_pEditCommandGroup->AppendSeparator(); + s_pEditCommandGroup->AppendCommand(IDM_EDIT_FIND, WXDC_MENU_FIND_FIND); + s_pEditCommandGroup->AppendCommand(IDM_EDIT_FINDNEXT, WXDC_MENU_FIND_FINDNEXT); + s_pEditCommandGroup->AppendCommand(IDM_EDIT_REPLACE, WXDC_MENU_FIND_REPLACE); + wxDevCenter::CommandManager::GetCommandManager().AddCommandManager(s_pEditCommandGroup, CLASSINFO(SimpleTextView), CmdGrpType_View); + } + + if(s_pViewCommandGroup==NULL) + { + s_pViewCommandGroup = new wxDevCenter::CommandGroup(WXDC_MENU_VIEW); + s_pViewCommandGroup->AppendChechCommand(IDM_SHOW_LINENUMBER, WXDC_MENU_VIEW_SIMPLETEXT_LINENUMBER); + s_pViewCommandGroup->AppendChechCommand(IDM_SHOW_LINEENDING, WXDC_MENU_VIEW_SIMPLETEXT_LINEENDING); + s_pViewCommandGroup->AppendChechCommand(IDM_SHOW_INDENTGUIDES, WXDC_MENU_VIEW_SIMPLETEXT_INDENTGUIDES); + s_pViewCommandGroup->AppendChechCommand(IDM_SHOW_LONGLINES, WXDC_MENU_VIEW_SIMPLETEXT_LONGLINES); + s_pViewCommandGroup->AppendChechCommand(IDM_SHOW_SPACECHAR, WXDC_MENU_VIEW_SIMPLETEXT_SPACECHAR); + s_pViewCommandGroup->AppendSeparator(); + s_pViewCommandGroup->AppendCommand(IDM_SHOW_OPTION, WXDC_MENU_VIEW_OPTIONS); + wxDevCenter::CommandManager::GetCommandManager().AddCommandManager(s_pViewCommandGroup, CLASSINFO(SimpleTextView), CmdGrpType_View); + } + + if(s_pLangCommandGroup==NULL) + { + s_pLangCommandGroup = new wxDevCenter::CommandGroup(WXDC_MENU_LANGUAGE); + for(int i=1; i<WXDC_NB_LEX; i++) + s_pLangCommandGroup->AppendChechCommand(IDM_LANG_START + i, g_LangagePropertyArray[i].strName); + wxDevCenter::CommandManager::GetCommandManager().AddCommandManager(s_pLangCommandGroup, CLASSINFO(SimpleTextView), CmdGrpType_View); + } + } + + bool SimpleTextView::OnCreate() { |
|
From: Emilien K. <cur...@us...> - 2005-09-14 15:36:39
|
Update of /cvsroot/wxdevcenter/StdPlugin/include/wxDevCenter/StdPlugin/Text In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv17156/include/wxDevCenter/StdPlugin/Text Modified Files: SimpleTextDocView.h Log Message: Add Command support (menu/toolbar unification). Add begining of layout support. Index: SimpleTextDocView.h =================================================================== RCS file: /cvsroot/wxdevcenter/StdPlugin/include/wxDevCenter/StdPlugin/Text/SimpleTextDocView.h,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** SimpleTextDocView.h 25 Aug 2005 20:36:08 -0000 1.1 --- SimpleTextDocView.h 14 Sep 2005 15:36:25 -0000 1.2 *************** *** 36,39 **** --- 36,40 ---- #include <wxDevCenter/DocView.h> + #include <wxDevCenter/Command.h> class wxStyledTextCtrl; *************** *** 217,220 **** --- 218,225 ---- protected: + static wxDevCenter::CommandGroup* s_pEditCommandGroup; + static wxDevCenter::CommandGroup* s_pViewCommandGroup; + static wxDevCenter::CommandGroup* s_pLangCommandGroup; + /** Contrôle Scintilla. Zone de texte stylée proprement dite.*/ wxStyledTextCtrl *m_pText; *************** *** 255,258 **** --- 260,266 ---- wxFindReplaceData m_FindReplaceData; + /** Create command groups if any.*/ + static void CreateCommandGroups(); + bool OnCreate(); void OnInitialUpdate(); |
|
From: Emilien K. <cur...@us...> - 2005-09-14 15:36:39
|
Update of /cvsroot/wxdevcenter/StdPlugin/include/wxDevCenter/StdPlugin/Bitmap In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv17156/include/wxDevCenter/StdPlugin/Bitmap Modified Files: BitmapDocView.h Log Message: Add Command support (menu/toolbar unification). Add begining of layout support. Index: BitmapDocView.h =================================================================== RCS file: /cvsroot/wxdevcenter/StdPlugin/include/wxDevCenter/StdPlugin/Bitmap/BitmapDocView.h,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** BitmapDocView.h 25 Aug 2005 20:36:07 -0000 1.1 --- BitmapDocView.h 14 Sep 2005 15:36:25 -0000 1.2 *************** *** 20,23 **** --- 20,24 ---- #include <wxDevCenter/DocView.h> #include <wxDevCenter/WorkBar.h> + #include <wxDevCenter/Command.h> #include <wxDevCenter/StdPlugin/Bitmap/BitmapCtrl.h> #include <wxDevCenter/StdPlugin/extmouse.h> *************** *** 452,455 **** --- 453,465 ---- DECLARE_EVENT_TABLE(); protected: + static wxDevCenter::CommandGroup* s_pEditCommandGroup; + static wxDevCenter::CommandGroup* s_pToolsCommandGroup; + static wxDevCenter::CommandGroup* s_pPenCommandGroup; + static wxDevCenter::CommandGroup* s_pViewCommandGroup; + + /** Create command groups if any.*/ + static void CreateCommandGroups(); + + virtual bool OnCreate(); void OnInitialUpdate(); |
|
From: Emilien K. <cur...@us...> - 2005-09-14 15:36:39
|
Update of /cvsroot/wxdevcenter/StdPlugin/src/Bitmap In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv17156/src/Bitmap Modified Files: BitmapDocView.cpp Log Message: Add Command support (menu/toolbar unification). Add begining of layout support. Index: BitmapDocView.cpp =================================================================== RCS file: /cvsroot/wxdevcenter/StdPlugin/src/Bitmap/BitmapDocView.cpp,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** BitmapDocView.cpp 25 Aug 2005 20:36:08 -0000 1.1 --- BitmapDocView.cpp 14 Sep 2005 15:36:25 -0000 1.2 *************** *** 963,966 **** --- 963,972 ---- END_EVENT_TABLE() + wxDevCenter::CommandGroup* BitmapView::s_pEditCommandGroup = NULL; + wxDevCenter::CommandGroup* BitmapView::s_pToolsCommandGroup = NULL; + wxDevCenter::CommandGroup* BitmapView::s_pPenCommandGroup = NULL; + wxDevCenter::CommandGroup* BitmapView::s_pViewCommandGroup = NULL; + + BitmapView::BitmapView(): *************** *** 970,1014 **** m_BVD(BVD_NONE) { ! wxMenu *pMenu; ! ! pMenu = new wxMenu(); ! pMenu->Append(wxID_CUT , WXDC_BITMAP_MENU_EDIT_SELCUT); ! pMenu->Append(wxID_COPY , WXDC_BITMAP_MENU_EDIT_SELCOPY); ! pMenu->Append(wxID_PASTE , WXDC_BITMAP_MENU_EDIT_SELPASTE); ! pMenu->AppendSeparator(); ! pMenu->AppendCheckItem(ID_TOOL_SELALL , WXDC_BITMAP_MENU_EDIT_SELALL); ! pMenu->AppendCheckItem(ID_TOOL_SELREMOVE , WXDC_BITMAP_MENU_EDIT_SELREMOVE); ! m_aMenu.Append(pMenu, WXDC_BITMAP_MENU_EDIT); ! ! pMenu = new wxMenu(); ! pMenu->AppendCheckItem(ID_TOOL_HANDDRAW , WXDC_BITMAP_MENU_TOOLS_HANDDRAW); ! pMenu->AppendCheckItem(ID_TOOL_SPRAY , WXDC_BITMAP_MENU_TOOLS_SPRAY); ! pMenu->AppendSeparator(); ! pMenu->AppendCheckItem(ID_TOOL_LINE , WXDC_BITMAP_MENU_TOOLS_LINE); ! pMenu->AppendCheckItem(ID_TOOL_RECT , WXDC_BITMAP_MENU_TOOLS_RECT); ! pMenu->AppendCheckItem(ID_TOOL_RRECT , WXDC_BITMAP_MENU_TOOLS_RRECT); ! pMenu->AppendCheckItem(ID_TOOL_ELLIPSE , WXDC_BITMAP_MENU_TOOLS_ELLIPSE); ! pMenu->AppendSeparator(); ! pMenu->AppendCheckItem(ID_TOOL_SELECTION , WXDC_BITMAP_MENU_TOOLS_SELECTION); ! pMenu->AppendCheckItem(ID_TOOL_SELMOVE , WXDC_BITMAP_MENU_TOOLS_SELMOVE); ! pMenu->AppendSeparator(); ! pMenu->AppendCheckItem(ID_TOOL_SIZEALL , WXDC_BITMAP_MENU_TOOLS_SIZEALL); ! m_aMenu.Append(pMenu, WXDC_BITMAP_MENU_TOOLS); ! pMenu = new wxMenu(); ! pMenu->AppendCheckItem(ID_PEN_SOLID , WXDC_BITMAP_MENU_PEN_SOLID ); ! pMenu->AppendCheckItem(ID_PEN_TRANSPARENT , WXDC_BITMAP_MENU_PEN_TRANSPARENT); ! pMenu->AppendCheckItem(ID_PEN_DOT , WXDC_BITMAP_MENU_PEN_DOT ); ! pMenu->AppendCheckItem(ID_PEN_LONG_DASH , WXDC_BITMAP_MENU_PEN_LONG_DASH ); ! pMenu->AppendCheckItem(ID_PEN_SHORT_DASH , WXDC_BITMAP_MENU_PEN_SHORT_DASH ); ! pMenu->AppendCheckItem(ID_PEN_DOT_DASH , WXDC_BITMAP_MENU_PEN_DOT_DASH ); ! m_aMenu.Append(pMenu, WXDC_BITMAP_MENU_PEN); ! pMenu = new wxMenu(); ! pMenu->AppendCheckItem(IDM_VIEW_EXTRASCROLL, WXDC_BITMAP_MENU_VIEW_EXTRASCROLL); ! pMenu->Append(IDM_VIEW_CENTER, WXDC_BITMAP_MENU_VIEW_CENTER); ! m_aMenu.Append(pMenu, WXDC_BITMAP_MENU_VIEW); } --- 976,1035 ---- m_BVD(BVD_NONE) { ! CreateCommandGroups(); ! } ! // Create command groups if any. ! void BitmapView::CreateCommandGroups() ! { ! if(s_pEditCommandGroup==NULL) ! { ! s_pEditCommandGroup = new wxDevCenter::CommandGroup(WXDC_BITMAP_MENU_EDIT); ! s_pEditCommandGroup->AppendCommand(wxID_CUT , WXDC_BITMAP_MENU_EDIT_SELCUT, wxT(""), wxT("StdPlugin.Bitmap/selcut")); ! s_pEditCommandGroup->AppendCommand(wxID_COPY , WXDC_BITMAP_MENU_EDIT_SELCOPY, wxT(""), wxT("StdPlugin.Bitmap/selcopy")); ! s_pEditCommandGroup->AppendCommand(wxID_PASTE , WXDC_BITMAP_MENU_EDIT_SELPASTE, wxT(""), wxT("StdPlugin.Bitmap/selpaste")); ! s_pEditCommandGroup->AppendSeparator(); ! s_pEditCommandGroup->AppendCommand(ID_TOOL_SELALL , WXDC_BITMAP_MENU_EDIT_SELALL, wxT(""), wxT("StdPlugin.Bitmap/selall")); ! s_pEditCommandGroup->AppendCommand(ID_TOOL_SELREMOVE , WXDC_BITMAP_MENU_EDIT_SELREMOVE, wxT(""), wxT("StdPlugin.Bitmap/selremove")); ! wxDevCenter::CommandManager::GetCommandManager().AddCommandManager(s_pEditCommandGroup, CLASSINFO(BitmapView), CmdGrpType_View); ! } + if(s_pToolsCommandGroup==NULL) + { + s_pToolsCommandGroup = new wxDevCenter::CommandGroup(WXDC_BITMAP_MENU_TOOLS); + s_pToolsCommandGroup->AppendChechCommand(ID_TOOL_HANDDRAW , WXDC_BITMAP_MENU_TOOLS_HANDDRAW, wxT(""), wxT("StdPlugin.Bitmap/handdraw")); + s_pToolsCommandGroup->AppendChechCommand(ID_TOOL_SPRAY , WXDC_BITMAP_MENU_TOOLS_SPRAY, wxT(""), wxT("StdPlugin.Bitmap/spray")); + s_pToolsCommandGroup->AppendSeparator(); + s_pToolsCommandGroup->AppendChechCommand(ID_TOOL_LINE , WXDC_BITMAP_MENU_TOOLS_LINE, wxT(""), wxT("StdPlugin.Bitmap/line")); + s_pToolsCommandGroup->AppendChechCommand(ID_TOOL_RECT , WXDC_BITMAP_MENU_TOOLS_RECT, wxT(""), wxT("StdPlugin.Bitmap/rect")); + s_pToolsCommandGroup->AppendChechCommand(ID_TOOL_RRECT , WXDC_BITMAP_MENU_TOOLS_RRECT, wxT(""), wxT("StdPlugin.Bitmap/rrect")); + s_pToolsCommandGroup->AppendChechCommand(ID_TOOL_ELLIPSE , WXDC_BITMAP_MENU_TOOLS_ELLIPSE, wxT(""), wxT("StdPlugin.Bitmap/ellipse")); + s_pToolsCommandGroup->AppendSeparator(); + s_pToolsCommandGroup->AppendChechCommand(ID_TOOL_SELECTION , WXDC_BITMAP_MENU_TOOLS_SELECTION, wxT(""), wxT("StdPlugin.Bitmap/selection")); + s_pToolsCommandGroup->AppendChechCommand(ID_TOOL_SELMOVE , WXDC_BITMAP_MENU_TOOLS_SELMOVE, wxT(""), wxT("StdPlugin.Bitmap/selmove")); + s_pToolsCommandGroup->AppendSeparator(); + s_pToolsCommandGroup->AppendChechCommand(ID_TOOL_SIZEALL , WXDC_BITMAP_MENU_TOOLS_SIZEALL, wxT(""), wxT("StdPlugin.Bitmap/sizeall")); + wxDevCenter::CommandManager::GetCommandManager().AddCommandManager(s_pToolsCommandGroup, CLASSINFO(BitmapView), CmdGrpType_View); + } ! if(s_pPenCommandGroup==NULL) ! { ! s_pPenCommandGroup = new wxDevCenter::CommandGroup(WXDC_BITMAP_MENU_PEN); ! s_pPenCommandGroup->AppendChechCommand(ID_PEN_SOLID , WXDC_BITMAP_MENU_PEN_SOLID ); ! s_pPenCommandGroup->AppendChechCommand(ID_PEN_TRANSPARENT , WXDC_BITMAP_MENU_PEN_TRANSPARENT); ! s_pPenCommandGroup->AppendChechCommand(ID_PEN_DOT , WXDC_BITMAP_MENU_PEN_DOT ); ! s_pPenCommandGroup->AppendChechCommand(ID_PEN_LONG_DASH , WXDC_BITMAP_MENU_PEN_LONG_DASH ); ! s_pPenCommandGroup->AppendChechCommand(ID_PEN_SHORT_DASH , WXDC_BITMAP_MENU_PEN_SHORT_DASH ); ! s_pPenCommandGroup->AppendChechCommand(ID_PEN_DOT_DASH , WXDC_BITMAP_MENU_PEN_DOT_DASH ); ! wxDevCenter::CommandManager::GetCommandManager().AddCommandManager(s_pPenCommandGroup, CLASSINFO(BitmapView), CmdGrpType_View); ! } + if(s_pViewCommandGroup==NULL) + { + s_pViewCommandGroup = new wxDevCenter::CommandGroup(WXDC_BITMAP_MENU_VIEW); + s_pViewCommandGroup->AppendChechCommand(IDM_VIEW_EXTRASCROLL, WXDC_BITMAP_MENU_VIEW_EXTRASCROLL); + s_pViewCommandGroup->AppendCommand(IDM_VIEW_CENTER, WXDC_BITMAP_MENU_VIEW_CENTER); + wxDevCenter::CommandManager::GetCommandManager().AddCommandManager(s_pViewCommandGroup, CLASSINFO(BitmapView), CmdGrpType_View); + } + } |
|
From: Emilien K. <cur...@us...> - 2005-09-14 14:19:22
|
Update of /cvsroot/wxdevcenter/wxDevCenter/src In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv30551/src Modified Files: MDIFrame.cpp MainFrame.cpp Frame.cpp Application.cpp Command.cpp Added Files: Layout.cpp Log Message: Add Command support (menu/toolbar unification). Add begining of layout support. Index: MainFrame.cpp =================================================================== RCS file: /cvsroot/wxdevcenter/wxDevCenter/src/MainFrame.cpp,v retrieving revision 1.19 retrieving revision 1.20 diff -C2 -d -r1.19 -r1.20 *** MainFrame.cpp 26 Aug 2005 08:35:58 -0000 1.19 --- MainFrame.cpp 14 Sep 2005 14:19:11 -0000 1.20 *************** *** 31,34 **** --- 31,37 ---- #include <wxDevCenter/DocView.h> #include <wxDevCenter/WorkBar.h> + #include <wxDevCenter/Command.h> + #include <wxDevCenter/Layout.h> + #include <wx/artprov.h> *************** *** 287,291 **** { wxMenuBar *pMenuBar = new wxMenuBar(); ! wxMenu *pMenu; // Menu Fichier --- 290,294 ---- { wxMenuBar *pMenuBar = new wxMenuBar(); ! /* wxMenu *pMenu; // Menu Fichier *************** *** 333,341 **** // Fixe la barre de menus ! SetMenuBar(pMenuBar); ! m_iMenuSeparator = 1; // Reconstruit le sous menu des workbars ! RebuildWorkBarMenu(); } --- 336,346 ---- // Fixe la barre de menus ! */ SetMenuBar(pMenuBar); ! CommandManager::GetCommandManager().PopulateMenuBar(GetMenuBar(), GetLayout()); ! ! /* m_iMenuSeparator = 1; // Reconstruit le sous menu des workbars ! RebuildWorkBarMenu();*/ } *************** *** 363,367 **** void MainFrame::OnCurrentViewChanging(ViewEvent &event) { ! RemoveViewMenu(event.GetOldView()); SetIcon(m_Icon); SetTitle(WXDC_NAME); --- 368,373 ---- void MainFrame::OnCurrentViewChanging(ViewEvent &event) { ! // RemoveViewMenu(event.GetOldView()); ! CommandManager::GetCommandManager().PopulateMenuBar(GetMenuBar(), GetLayout()); SetIcon(m_Icon); SetTitle(WXDC_NAME); *************** *** 376,380 **** if(pNewView!=NULL) { ! InsertViewMenu(pNewView); wxString strIconName = pNewView->GetViewTemplate()->strIcons; wxIconBundle IB; --- 382,388 ---- if(pNewView!=NULL) { ! // InsertViewMenu(pNewView); ! CommandManager::GetCommandManager().PopulateMenuBar(GetMenuBar(), GetLayout()); ! wxString strIconName = pNewView->GetViewTemplate()->strIcons; wxIconBundle IB; *************** *** 453,459 **** void MainFrame::RebuildWorkBarMenu() { ! wxMenu *pMenu = m_pMenuItemWorkBar->GetSubMenu(); ! m_pLayoutManager->SetWindowMenu(pMenu); } --- 461,467 ---- void MainFrame::RebuildWorkBarMenu() { ! // wxMenu *pMenu = m_pMenuItemWorkBar->GetSubMenu(); ! // m_pLayoutManager->SetWindowMenu(pMenu); } Index: Frame.cpp =================================================================== RCS file: /cvsroot/wxdevcenter/wxDevCenter/src/Frame.cpp,v retrieving revision 1.9 retrieving revision 1.10 diff -C2 -d -r1.9 -r1.10 *** Frame.cpp 14 May 2005 12:15:56 -0000 1.9 --- Frame.cpp 14 Sep 2005 14:19:11 -0000 1.10 *************** *** 148,151 **** --- 148,157 ---- } + // Retourne le layout attaché à la fenetre. + wxDevCenter::Layout TopFrame::GetLayout() + { + wxDevCenter::Layout lay(this); + return lay; + } ////////////////////////////////////////////////////////////////////// Index: Application.cpp =================================================================== RCS file: /cvsroot/wxdevcenter/wxDevCenter/src/Application.cpp,v retrieving revision 1.32 retrieving revision 1.33 diff -C2 -d -r1.32 -r1.33 *** Application.cpp 26 Aug 2005 08:35:58 -0000 1.32 --- Application.cpp 14 Sep 2005 14:19:11 -0000 1.33 *************** *** 35,38 **** --- 35,39 ---- #include <wxDevCenter/Project.h> #include <wxDevCenter/ArtProvider.h> + #include <wxDevCenter/Command.h> #include <wx/dynlib.h> *************** *** 98,101 **** --- 99,105 ---- m_FileSystemManager.Register(m_pStandardFileSystem, true); + // Initialise les menus par défaut. + InitCommandGroups(); + // Crée la fenetre principale m_pMainFrame = new MainFrame(); *************** *** 482,483 **** --- 486,536 ---- (*GetPagesSetupDialogData()) = Dialog.GetPageSetupData(); } + + // Initie les groupes de commandes de l'application. + void Application::InitCommandGroups() + { + CommandGroup *pCmdGroup; + + // Groupe "Fichier" + pCmdGroup = new CommandGroup(WXDC_MENU_FILES); + pCmdGroup->AppendCommand(IDM_FILE_NEW, WXDC_MENU_FILE_NEW); + pCmdGroup->AppendCommand(IDM_FILE_OPEN, WXDC_MENU_FILE_OPEN); + pCmdGroup->AppendCommand(IDM_FILE_CLOSE, WXDC_MENU_FILE_CLOSE); + pCmdGroup->AppendCommand(IDM_FILE_CLOSEALL, WXDC_MENU_FILE_CLOSEALL); + pCmdGroup->AppendCommand(IDM_FILE_SAVE, WXDC_MENU_FILE_SAVE); + pCmdGroup->AppendCommand(IDM_FILE_SAVEAS, WXDC_MENU_FILE_SAVEAS); + pCmdGroup->AppendSeparator(); + pCmdGroup->AppendCommand(IDM_PROJECT_NEW, WXDC_MENU_PROJECT_NEW); + pCmdGroup->AppendCommand(IDM_PROJECT_OPEN, WXDC_MENU_PROJECT_OPEN); + pCmdGroup->AppendCommand(IDM_PROJECT_CLOSE, WXDC_MENU_PROJECT_CLOSE); + pCmdGroup->AppendSeparator(); + pCmdGroup->AppendCommand(IDM_FILE_PRINT, WXDC_MENU_FILE_PRINT); + pCmdGroup->AppendCommand(IDM_FILE_PRINTSETUP, WXDC_MENU_FILE_PRINTSETUP); + pCmdGroup->AppendCommand(IDM_FILE_PRINTPREVIEW, WXDC_MENU_FILE_PRINTPREVIEW); + pCmdGroup->AppendSeparator(); + pCmdGroup->AppendCommand(wxID_EXIT, WXDC_MENU_APP_EXIT); + CommandManager::GetCommandManager().AddCommandManager(pCmdGroup, NULL, CmdGrpType_Application); + + // Menu Fenetres + pCmdGroup = new CommandGroup(WXDC_MENU_WINDOW); + pCmdGroup->AppendCommand(IDM_WINDOW_CLONE, WXDC_MENU_WINDOW_CLONE); + pCmdGroup->AppendCommand(IDM_WINDOW_NEW, WXDC_MENU_WINDOW_NEW); + pCmdGroup->AppendCommand(IDM_WINDOW_CLOSE, WXDC_MENU_WINDOW_CLOSE); + pCmdGroup->AppendCommand(IDM_WINDOW_CLOSEALL, WXDC_MENU_WINDOW_CLOSEALL); + pCmdGroup->AppendSeparator(); + // pCmdGroup->AppendCommand(IDM_WINDOW_WORKBAR, WXDC_MENU_WINDOW_WORKBAR, new wxMenu); + pCmdGroup->AppendSeparator(); + pCmdGroup->AppendCommand(IDM_WINDOW_NEXT, WXDC_MENU_WINDOW_NEXT); + pCmdGroup->AppendCommand(IDM_WINDOW_PREV, WXDC_MENU_WINDOW_PREV); + pCmdGroup->AppendSeparator(); + // pCmdGroup->AppendCommand(pMenu, WXDC_MENU_WINDOW); + CommandManager::GetCommandManager().AddCommandManager(pCmdGroup, NULL, CmdGrpType_Frame); + + // Menu Aide + pCmdGroup = new CommandGroup(WXDC_MENU_HELP); + pCmdGroup->AppendCommand(IDM_HELP_CONTENT, WXDC_MENU_HELP_CONTENT); + pCmdGroup->AppendCommand(IDM_HELP_INDEX, WXDC_MENU_HELP_INDEX); + pCmdGroup->AppendSeparator(); + pCmdGroup->AppendCommand(IDM_HELP_ABOUT, WXDC_MENU_HELP_ABOUT); + CommandManager::GetCommandManager().AddCommandManager(pCmdGroup, NULL, CmdGrpType_Help); + } Index: MDIFrame.cpp =================================================================== RCS file: /cvsroot/wxdevcenter/wxDevCenter/src/MDIFrame.cpp,v retrieving revision 1.7 retrieving revision 1.8 diff -C2 -d -r1.7 -r1.8 *** MDIFrame.cpp 2 Aug 2005 12:50:54 -0000 1.7 --- MDIFrame.cpp 14 Sep 2005 14:19:11 -0000 1.8 *************** *** 224,225 **** --- 224,233 ---- } + View* MDIFrame::GetCurrentView()const + { + if(GetSelection()!=wxNOT_FOUND) + return wxDynamicCast(GetCurrentPage(), View); + else + return NULL; + } + --- NEW FILE: Layout.cpp --- (This appears to be a binary file; contents omitted.) Index: Command.cpp =================================================================== RCS file: /cvsroot/wxdevcenter/wxDevCenter/src/Command.cpp,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** Command.cpp 28 Aug 2005 15:57:10 -0000 1.1 --- Command.cpp 14 Sep 2005 14:19:11 -0000 1.2 *************** *** 25,28 **** --- 25,29 ---- #include <wxDevCenter/Command.h> #include <wxDevCenter/Application.h> + #include <wxDevCenter/Layout.h> #include <wx/artprov.h> *************** *** 47,53 **** m_strHelp(wxT("")), m_strIconName(wxT("")), ! m_kind(wxITEM_NORMAL), ! m_isChecked(false), ! m_isEnabled(false) { --- 48,52 ---- m_strHelp(wxT("")), m_strIconName(wxT("")), ! m_kind(wxITEM_NORMAL) { *************** *** 63,74 **** m_strHelp(cmd.m_strHelp), m_strIconName(cmd.m_strIconName), ! m_kind(cmd.m_kind), ! m_isChecked(cmd.m_isChecked), ! m_isEnabled(cmd.m_isEnabled) { } // Constructor. ! Command::Command(int iID, CommandGroup* pGroup, CommandGroup* pSubGroup, wxString strLabel, wxString strHelp, wxString strIconName, wxItemKind kind, bool isChecked, bool isEnabled): wxObject(), m_iID(iID), --- 62,71 ---- m_strHelp(cmd.m_strHelp), m_strIconName(cmd.m_strIconName), ! m_kind(cmd.m_kind) { } // Constructor. ! Command::Command(int iID, CommandGroup* pGroup, CommandGroup* pSubGroup, wxString strLabel, wxString strHelp, wxString strIconName, wxItemKind kind): wxObject(), m_iID(iID), *************** *** 78,84 **** m_strHelp(strHelp), m_strIconName(strIconName), ! m_kind(kind), ! m_isChecked(isChecked), ! m_isEnabled(isEnabled) { } --- 75,92 ---- m_strHelp(strHelp), m_strIconName(strIconName), ! m_kind(kind) ! { ! } ! ! // Direct init constructor. ! Command::Command(int iID, wxString strLabel, wxString strHelp, wxString strIconName, wxItemKind kind): ! wxObject(), ! m_iID(iID), ! m_pGroup(NULL), ! m_pSubGroup(NULL), ! m_strLabel(strLabel), ! m_strHelp(strHelp), ! m_strIconName(strIconName), ! m_kind(kind) { } *************** *** 86,92 **** // Create a menu item corrsponding to the command. ! wxMenuItem* Command::CreateMenuItem()const { ! wxMenuItem* pMI = new wxMenuItem(NULL, GetID(), GetLabel(), GetHelp(), GetKind()); if(GetSubGroup()!=NULL) { --- 94,100 ---- // Create a menu item corrsponding to the command. ! wxMenuItem* Command::CreateMenuItem(wxMenu* pMenu)const { ! wxMenuItem* pMI = new wxMenuItem(pMenu, GetID(), GetLabel(), GetHelp(), GetKind()); if(GetSubGroup()!=NULL) { *************** *** 97,102 **** if(!GetIconName().IsEmpty()) pMI->SetBitmap(wxArtProvider::GetBitmap(GetIconName())); - pMI->Enable(IsEnabled()); - pMI->Check(IsChecked()); return pMI; } --- 105,108 ---- *************** *** 106,114 **** *****/ ! CommandGroup::CommandGroup(wxString strLabel, wxString strIconName): ObjectManager<Command>(), m_strLabel(strLabel), m_strIconName(strIconName) { } --- 112,126 ---- *****/ ! CommandGroup::CommandGroup(wxString strLabel, wxString strIconName, Command* pCommands, long nbCommands): ObjectManager<Command>(), m_strLabel(strLabel), m_strIconName(strIconName) { + while(nbCommands>0) + { + Command* pCmd = &(pCommands[nbCommands--]); + pCmd->SetGroup(this); + Register(pCmd); + } } *************** *** 116,120 **** Command* CommandGroup::AppendCommand(int ID, wxString strLabel, wxString strHelp, wxString strIconName) { ! Command* pCmd = new Command(ID, this, NULL, strLabel, strHelp, strIconName, wxITEM_NORMAL, false, true); Register(pCmd); return pCmd; --- 128,132 ---- Command* CommandGroup::AppendCommand(int ID, wxString strLabel, wxString strHelp, wxString strIconName) { ! Command* pCmd = new Command(ID, this, NULL, strLabel, strHelp, strIconName, wxITEM_NORMAL); Register(pCmd); return pCmd; *************** *** 122,128 **** // Append a checkable command. ! Command* CommandGroup::AppendChechCommand(int ID, wxString strLabel, wxString strHelp, wxString strIconName, bool isChecked) { ! Command* pCmd = new Command(ID, this, NULL, strLabel, strHelp, strIconName, wxITEM_CHECK, isChecked, true); Register(pCmd); return pCmd; --- 134,140 ---- // Append a checkable command. ! Command* CommandGroup::AppendChechCommand(int ID, wxString strLabel, wxString strHelp, wxString strIconName) { ! Command* pCmd = new Command(ID, this, NULL, strLabel, strHelp, strIconName, wxITEM_CHECK); Register(pCmd); return pCmd; *************** *** 132,136 **** Command* CommandGroup::AppendSeparator() { ! Command* pCmd = new Command(wxID_SEPARATOR, this, NULL, wxT(""), wxT(""), wxT(""), wxITEM_SEPARATOR, false, true); Register(pCmd); return pCmd; --- 144,148 ---- Command* CommandGroup::AppendSeparator() { ! Command* pCmd = new Command(wxID_SEPARATOR, this, NULL, wxT(""), wxT(""), wxT(""), wxITEM_SEPARATOR); Register(pCmd); return pCmd; *************** *** 140,149 **** Command* CommandGroup::AppendSubGroup(int ID, CommandGroup* pSubGroup) { ! Command* pCmd = new Command(ID, this, pSubGroup, pSubGroup->m_strLabel, wxT(""), pSubGroup->m_strIconName, wxITEM_NORMAL, false, true); Register(pCmd); return pCmd; } ! // Create a menu corrsponding to the command. wxMenu* CommandGroup::CreateMenu()const { --- 152,161 ---- Command* CommandGroup::AppendSubGroup(int ID, CommandGroup* pSubGroup) { ! Command* pCmd = new Command(ID, this, pSubGroup, pSubGroup->m_strLabel, wxT(""), pSubGroup->m_strIconName, wxITEM_NORMAL); Register(pCmd); return pCmd; } ! // Create a menu corresponding to the command. wxMenu* CommandGroup::CreateMenu()const { *************** *** 152,167 **** for(long l=0; l<(long)GetCount(); l++) { ! pMenu->Append(Item(l).CreateMenuItem()); } return pMenu; } /***** * CommandManager *****/ CommandManager::CommandManager(): ! ObjectManager<CommandGroup>() { } --- 164,191 ---- for(long l=0; l<(long)GetCount(); l++) { ! pMenu->Append(Item(l).CreateMenuItem(pMenu)); } return pMenu; } + /***** + * SelfRegisteredCommandGroup + *****/ + + // Standard constructor. + SelfRegisteredCommandGroup::SelfRegisteredCommandGroup(wxClassInfo* pRefClassInfo, CommandGroupType Type, wxString strLabel, wxString strIconName, Command* pCommands, long nbCommands): + CommandGroup(strLabel, strIconName, pCommands, nbCommands) + { + CommandManager::GetCommandManager().AddCommandManager(this, pRefClassInfo, Type); + } /***** * CommandManager *****/ + + CommandManager CommandManager::s_CommandManager; CommandManager::CommandManager(): ! wxObject() { } *************** *** 173,177 **** pGroup->SetRefInfo(pRefClassInfo); pGroup->SetType(Type); ! Register(pGroup); return true; } --- 197,256 ---- pGroup->SetRefInfo(pRefClassInfo); pGroup->SetType(Type); ! m_CommandGroups[Type].Register(pGroup); return true; } + + // Peuple une barre de menu. + bool CommandManager::PopulateMenuBar(wxMenuBar* pMenuBar, const Layout& layout) + { + if(pMenuBar==NULL) + return false; + // Vide la barre de menu. + while(pMenuBar->GetMenuCount()>0) + delete pMenuBar->Remove(pMenuBar->GetMenuCount()-1); + + // Pour chaque type de groupe. + for(long lGroupType=0; lGroupType<CommandGroupNumber; lGroupType++) + { + switch(lGroupType) + { + case CmdGrpType_Document: + // Pour chaque groupe, ajouter si le type de document correspond. + for(long lGroup=0; lGroup<(long)m_CommandGroups[lGroupType].GetCount(); lGroup++) + { + CommandGroup &CmdGrp = m_CommandGroups[lGroupType].Item(lGroup); + if(CmdGrp.GetRefInfo()->GetClassName()==layout.GetDocClass()) + pMenuBar->Append(CmdGrp.CreateMenu(), CmdGrp.GetLabel()); + } + break; + case CmdGrpType_View: + // Pour chaque groupe, ajouter si le type de vue correspond. + for(long lGroup=0; lGroup<(long)m_CommandGroups[lGroupType].GetCount(); lGroup++) + { + CommandGroup &CmdGrp = m_CommandGroups[lGroupType].Item(lGroup); + if(CmdGrp.GetRefInfo()->GetClassName()==layout.GetViewClass()) + pMenuBar->Append(CmdGrp.CreateMenu(), CmdGrp.GetLabel()); + } + break; + case CmdGrpType_WorkBar: + case CmdGrpType_Project: + case CmdGrpType_Workspace: + /** @todo Ajouter le code d'ajout des menus des workbars.*/ + /** @todo Ajouter le code d'ajout des menus du projet.*/ + /** @todo Ajouter le code d'ajout des menus de l'espace de travail.*/ + break; + default: + // Pour chaque groupe, tout ajouter + for(long lGroup=0; lGroup<(long)m_CommandGroups[lGroupType].GetCount(); lGroup++) + { + CommandGroup &CmdGrp = m_CommandGroups[lGroupType].Item(lGroup); + pMenuBar->Append(CmdGrp.CreateMenu(), CmdGrp.GetLabel()); + } + break; + } + } + + + return true; + } + |
|
From: Emilien K. <cur...@us...> - 2005-09-14 14:19:19
|
Update of /cvsroot/wxdevcenter/wxDevCenter/include/wxDevCenter In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv30551/include/wxDevCenter Modified Files: Frame.h MDIFrame.h Command.h Application.h Added Files: Layout.h Log Message: Add Command support (menu/toolbar unification). Add begining of layout support. Index: Command.h =================================================================== RCS file: /cvsroot/wxdevcenter/wxDevCenter/include/wxDevCenter/Command.h,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** Command.h 28 Aug 2005 15:57:10 -0000 1.1 --- Command.h 14 Sep 2005 14:19:10 -0000 1.2 *************** *** 31,34 **** --- 31,36 ---- { + class Layout; + class CommandGroup; *************** *** 51,58 **** /** Kind of command.*/ wxItemKind m_kind; - /** Is check.*/ - bool m_isChecked; - /** Is enable.*/ - bool m_isEnabled; public: /** Default constructor.*/ --- 53,56 ---- *************** *** 61,65 **** Command(const Command& cmd); /** Constructor.*/ ! Command(int iID, CommandGroup* pGroup, CommandGroup* pSubGroup, wxString strLabel, wxString strHelp, wxString strIconName, wxItemKind kind, bool isChecked, bool isEnabled); int GetID()const{return m_iID;} --- 59,66 ---- Command(const Command& cmd); /** Constructor.*/ ! Command(int iID, CommandGroup* pGroup, CommandGroup* pSubGroup, wxString strLabel, wxString strHelp, wxString strIconName, wxItemKind kind); ! ! /** Direct init constructor.*/ ! Command(int iID, wxString strLabel, wxString strHelp, wxString strIconName, wxItemKind kind); int GetID()const{return m_iID;} *************** *** 70,75 **** wxString GetIconName()const{return m_strIconName;} wxItemKind GetKind()const{return m_kind;} - bool IsChecked()const{return m_isChecked;} - bool IsEnabled()const{return m_isEnabled;} void SetID(int iID){m_iID = iID;} --- 71,74 ---- *************** *** 80,88 **** void SetIconName(wxString strIconName){m_strIconName = strIconName;} void SetKind(wxItemKind kind){m_kind = kind;} - void Check(bool isChecked){m_isChecked = isChecked;} - void Enable(bool isEnable){m_isEnabled = isEnable;} /** Create a menu item corrsponding to the command.*/ ! wxMenuItem* CreateMenuItem()const; }; --- 79,85 ---- void SetIconName(wxString strIconName){m_strIconName = strIconName;} void SetKind(wxItemKind kind){m_kind = kind;} /** Create a menu item corrsponding to the command.*/ ! wxMenuItem* CreateMenuItem(wxMenu* pMenu)const; }; *************** *** 90,101 **** enum CommandGroupType { ! Unknow = -1, ! Autodetect, ! Application, ! Workspace, ! Project, ! Document, ! View, ! WorkBar }; --- 87,101 ---- enum CommandGroupType { ! CmdGrpType_Unknow = -1, ! CmdGrpType_Autodetect, ! CmdGrpType_Application, ! CmdGrpType_Document, ! CmdGrpType_View, ! CmdGrpType_WorkBar, ! CmdGrpType_Project, ! CmdGrpType_Workspace, ! CmdGrpType_Frame, ! CmdGrpType_Help, ! CommandGroupNumber }; *************** *** 111,115 **** public: ! CommandGroup(wxString strLabel=wxT(""), wxString strIconName=wxT("")); CommandGroupType GetType()const{return m_Type;} --- 111,120 ---- public: ! /** Standard constructor. ! * @param strLabel Label of the command group. ! * @param strIconName Name of the icon. ! * @param pCommands Address of command array to attach. ! * @param nbCommands Number of command in the array to attach.*/ ! CommandGroup(wxString strLabel=wxT(""), wxString strIconName=wxT(""), Command* pCommands=NULL, long nbCommands=0); CommandGroupType GetType()const{return m_Type;} *************** *** 125,131 **** /** Append a command.*/ ! Command* AppendCommand(int ID, wxString strLabel, wxString strHelp, wxString strIconName); /** Append a checkable command.*/ ! Command* AppendChechCommand(int ID, wxString strLabel, wxString strHelp, wxString strIconName, bool isChecked); /** Append a separator.*/ Command* AppendSeparator(); --- 130,136 ---- /** Append a command.*/ ! Command* AppendCommand(int ID, wxString strLabel, wxString strHelp=wxT(""), wxString strIconName=wxT("")); /** Append a checkable command.*/ ! Command* AppendChechCommand(int ID, wxString strLabel, wxString strHelp=wxT(""), wxString strIconName=wxT("")); /** Append a separator.*/ Command* AppendSeparator(); *************** *** 133,149 **** Command* AppendSubGroup(int ID, CommandGroup* pSubGroup); ! /** Create a menu corrsponding to the command.*/ wxMenu* CreateMenu()const; }; /** Gestionnaire de commandes.*/ ! class WXDC_DLL_BASE CommandManager : protected ObjectManager<CommandGroup> { public: CommandManager(); /** Ajoute un groupe de commandes.*/ ! bool AddCommandManager(CommandGroup* pGroup, wxClassInfo* pRefClassInfo, CommandGroupType Type=Autodetect); }; --- 138,183 ---- Command* AppendSubGroup(int ID, CommandGroup* pSubGroup); ! /** Create a menu corresponding to the command.*/ wxMenu* CreateMenu()const; }; + /***** + * SelfRegisteredCommandGroup + *****/ + class WXDC_DLL_BASE SelfRegisteredCommandGroup : public CommandGroup + { + public: + /** Standard constructor. + * @param pRefClassInfo ClassInfo of attached class. + * @param Type Type of CommandGroup. + * @param strLabel Label of the command group. + * @param strIconName Name of the icon. + * @param pCommands Address of command array to attach. + * @param nbCommands Number of command in the array to attach.*/ + SelfRegisteredCommandGroup(wxClassInfo* pRefClassInfo, CommandGroupType Type, wxString strLabel, wxString strIconName, Command* pCommands, long nbCommands); + }; + /** Gestionnaire de commandes.*/ ! class WXDC_DLL_BASE CommandManager : public wxObject { + private: + /** Le seul et unique gestionnaire de commandes.*/ + static CommandManager s_CommandManager; + + protected: + /** Tableaux des Groupes de commandes. Un par type de groupe.*/ + ObjectManager<CommandGroup> m_CommandGroups[CommandGroupNumber]; public: + // Retourne le CommandManager. + static CommandManager& GetCommandManager(){return s_CommandManager;} + CommandManager(); /** Ajoute un groupe de commandes.*/ ! bool AddCommandManager(CommandGroup* pGroup, wxClassInfo* pRefClassInfo, CommandGroupType Type=CmdGrpType_Autodetect); ! ! /** Peuple une barre de menu.*/ ! bool PopulateMenuBar(wxMenuBar* pMenuBar, const Layout& layout); }; Index: Application.h =================================================================== RCS file: /cvsroot/wxdevcenter/wxDevCenter/include/wxDevCenter/Application.h,v retrieving revision 1.16 retrieving revision 1.17 diff -C2 -d -r1.16 -r1.17 *** Application.h 26 Aug 2005 08:35:58 -0000 1.16 --- Application.h 14 Sep 2005 14:19:10 -0000 1.17 *************** *** 248,261 **** /** @} */ ! /** Initialise la ligne de commande. * @param parser Parseur de ligne de commande. */ void OnInitCmdLine(wxCmdLineParser& parser); - /** Parse la ligne de commande pour récupérer toutes les options voulues. * @param parser Parseur de ligne de commande. */ bool OnCmdLineParsed(wxCmdLineParser& parser); }; --- 248,265 ---- /** @} */ ! /** @name CmdLine ! * @{ */ /** Initialise la ligne de commande. * @param parser Parseur de ligne de commande. */ void OnInitCmdLine(wxCmdLineParser& parser); /** Parse la ligne de commande pour récupérer toutes les options voulues. * @param parser Parseur de ligne de commande. */ bool OnCmdLineParsed(wxCmdLineParser& parser); + /* @} */ + + /** Initie les groupes de commandes de l'application.*/ + void InitCommandGroups(); }; Index: Frame.h =================================================================== RCS file: /cvsroot/wxdevcenter/wxDevCenter/include/wxDevCenter/Frame.h,v retrieving revision 1.11 retrieving revision 1.12 diff -C2 -d -r1.11 -r1.12 *** Frame.h 26 Aug 2005 08:35:58 -0000 1.11 --- Frame.h 14 Sep 2005 14:19:10 -0000 1.12 *************** *** 32,35 **** --- 32,37 ---- #define __WXDEVCENTER_FRAME + #include <wxDevCenter/Layout.h> + namespace wxDevCenter { *************** *** 201,205 **** void SetViewFrame(ViewFrame* pViewFrame){m_pViewFrame = pViewFrame;} /** Retourne la fenetre cadre fille des vues.*/ ! ViewFrame* GetViewFrame(){return m_pViewFrame;} --- 203,207 ---- void SetViewFrame(ViewFrame* pViewFrame){m_pViewFrame = pViewFrame;} /** Retourne la fenetre cadre fille des vues.*/ ! ViewFrame* GetViewFrame()const{return m_pViewFrame;} *************** *** 220,223 **** --- 222,230 ---- virtual bool ShowWorkBar(WorkBar* WXUNUSED(pWorkBar), bool WXUNUSED(bShow)){return false;} + + /** Retourne le layout attaché à la fenetre. + * @return Layout.*/ + virtual wxDevCenter::Layout GetLayout(); + /** Surcharge du processus de destruction. * Utilisé pour vider le cadre de ses WorkBar et la désenregistrer du WorkBarManager.*/ *************** *** 254,257 **** --- 261,266 ---- virtual void RemoveView(View *pView)=0; + + virtual View* GetCurrentView()const=0; }; Index: MDIFrame.h =================================================================== RCS file: /cvsroot/wxdevcenter/wxDevCenter/include/wxDevCenter/MDIFrame.h,v retrieving revision 1.6 retrieving revision 1.7 diff -C2 -d -r1.6 -r1.7 *** MDIFrame.h 4 Apr 2005 08:11:21 -0000 1.6 --- MDIFrame.h 14 Sep 2005 14:19:10 -0000 1.7 *************** *** 71,74 **** --- 71,76 ---- virtual bool CanProcessEventFromParent(); + virtual View* GetCurrentView()const; + }; --- NEW FILE: Layout.h --- /** * @file wxDevCenter/Layout.h * @author Cursor * * @brief Class declaration for layout management (toolbar, workbar ...). */ // // wxDevCenter // // This program is free software; you can redistribute it and/or modify // it under the terms of the GNU General Public License as published by // the Free Software Foundation; only version 2 of the License. // // This program is distributed in the hope that it will be useful, // but WITHOUT ANY WARRANTY; without even the implied warranty of // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the // GNU General Public License for more details. // // You should have received a copy of the GNU General Public License // along with this program; if not, write to the Free Software // Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA // 02111-1307, USA. #ifndef __WXDEVCENTER_LAYOUT #define __WXDEVCENTER_LAYOUT namespace wxDevCenter { class TopFrame; /** Layout descriptor.*/ class WXDC_DLL_BASE Layout : public wxObject { protected: /** Current project class name.*/ wxString m_strProjectClass; /** Current document class name.*/ wxString m_strDocClass; /** Current view class name.*/ wxString m_strViewClass; /** Current workbars.*/ wxArrayString m_arstrWorkbarClass; public: Layout(); Layout(const Layout& layout); Layout(const TopFrame* pFrame); virtual ~Layout(); void SetProjectClass(wxString strProjectClass){m_strProjectClass = strProjectClass;} void SetDocClass(wxString strDocClass){m_strDocClass = strDocClass;} void SetViewClass(wxString strViewClass){m_strViewClass = strViewClass;} void AddWorkbarClass(wxString strWorkBarClass){m_arstrWorkbarClass.Add(strWorkBarClass);} void RemoveWorkbarClass(wxString strWorkBarClass){if(m_arstrWorkbarClass.Index(strWorkBarClass)!=wxNOT_FOUND)m_arstrWorkbarClass.Remove(strWorkBarClass);} wxString GetProjectClass()const{return m_strProjectClass;} wxString GetDocClass()const{return m_strDocClass;} wxString GetViewClass()const{return m_strViewClass;} const wxArrayString& GetWorkBarClass()const{return m_arstrWorkbarClass;} bool IsProjectClass(wxString strProjectClass)const{return m_strProjectClass == strProjectClass;} bool IsDocClass(wxString strDocClass)const{return m_strDocClass == strDocClass;} bool IsViewClass(wxString strViewClass)const{return m_strViewClass == strViewClass;} bool HasWorkBarClass(wxString strWorkBarClass)const{return m_arstrWorkbarClass.Index(strWorkBarClass)!=wxNOT_FOUND;} protected: /** Initialise Layout from a frame.*/ void InitFromTopFrame(const TopFrame* pFrame); }; /** * Layout manager. */ class LayoutManager : public wxObject { public: LayoutManager(); virtual ~LayoutManager(); }; } #endif /*__WXDEVCENTER_LAYOUT*/ |
|
From: Emilien K. <cur...@us...> - 2005-09-14 14:19:19
|
Update of /cvsroot/wxdevcenter/wxDevCenter/build In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv30551/build Modified Files: install.bkl wxDevCenter.bkl Log Message: Add Command support (menu/toolbar unification). Add begining of layout support. Index: install.bkl =================================================================== RCS file: /cvsroot/wxdevcenter/wxDevCenter/build/install.bkl,v retrieving revision 1.10 retrieving revision 1.11 diff -C2 -d -r1.10 -r1.11 *** install.bkl 28 Aug 2005 15:57:10 -0000 1.10 --- install.bkl 14 Sep 2005 14:19:11 -0000 1.11 *************** *** 27,30 **** --- 27,31 ---- wxDevCenter/Frame.h wxDevCenter/language.h + wxDevCenter/Layout.h wxDevCenter/MainFrame.h wxDevCenter/Manager.h Index: wxDevCenter.bkl =================================================================== RCS file: /cvsroot/wxdevcenter/wxDevCenter/build/wxDevCenter.bkl,v retrieving revision 1.12 retrieving revision 1.13 diff -C2 -d -r1.12 -r1.13 *** wxDevCenter.bkl 28 Aug 2005 15:57:10 -0000 1.12 --- wxDevCenter.bkl 14 Sep 2005 14:19:11 -0000 1.13 *************** *** 65,68 **** --- 65,69 ---- src/FileTools.cpp src/Frame.cpp + src/Layout.cpp src/MainFrame.cpp src/Manager.cpp |
|
From: Emilien K. <cur...@us...> - 2005-09-14 14:19:19
|
Update of /cvsroot/wxdevcenter/wxDevCenter In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv30551 Modified Files: GNUmakefile Log Message: Add Command support (menu/toolbar unification). Add begining of layout support. Index: GNUmakefile =================================================================== RCS file: /cvsroot/wxdevcenter/wxDevCenter/GNUmakefile,v retrieving revision 1.10 retrieving revision 1.11 diff -C2 -d -r1.10 -r1.11 *** GNUmakefile 28 Aug 2005 15:57:10 -0000 1.10 --- GNUmakefile 14 Sep 2005 14:19:11 -0000 1.11 *************** *** 87,90 **** --- 87,91 ---- ./build/$(BUILD)/wxDevCenterLib_FileTools.o \ ./build/$(BUILD)/wxDevCenterLib_Frame.o \ + ./build/$(BUILD)/wxDevCenterLib_Layout.o \ ./build/$(BUILD)/wxDevCenterLib_MainFrame.o \ ./build/$(BUILD)/wxDevCenterLib_Manager.o \ *************** *** 173,177 **** install: all install_wxDevCenterLib install_wxDevCenter $(INSTALL) -d $(prefix)/include ! for f in wxDevCenter.h wxDevCenterPlugin.h wxDevCenter/AboutBox.h wxDevCenter/Application.h wxDevCenter/ArtProvider.h wxDevCenter/Command.h wxDevCenter/Config.h wxDevCenter/DocView.h wxDevCenter/Element.h wxDevCenter/FileSystem.h wxDevCenter/FileSystemCtrl.h wxDevCenter/FileSystemListCtrl.h wxDevCenter/FileSystemTreeCtrl.h wxDevCenter/FileSystemStandard.h wxDevCenter/FileTools.h wxDevCenter/Frame.h wxDevCenter/language.h wxDevCenter/MainFrame.h wxDevCenter/Manager.h wxDevCenter/MDIFrame.h wxDevCenter/Plugin.h wxDevCenter/Project.h wxDevCenter/setup.h wxDevCenter/StatusBar.h wxDevCenter/WorkBar.h wxDevCenter/unix/Config.h wxDevCenter/unix/FileSystemStandard.h; do \ if test ! -d $(prefix)/include/`dirname $$f` ; then \ $(INSTALL) -d $(prefix)/include/`dirname $$f`; \ --- 174,178 ---- install: all install_wxDevCenterLib install_wxDevCenter $(INSTALL) -d $(prefix)/include ! for f in wxDevCenter.h wxDevCenterPlugin.h wxDevCenter/AboutBox.h wxDevCenter/Application.h wxDevCenter/ArtProvider.h wxDevCenter/Command.h wxDevCenter/Config.h wxDevCenter/DocView.h wxDevCenter/Element.h wxDevCenter/FileSystem.h wxDevCenter/FileSystemCtrl.h wxDevCenter/FileSystemListCtrl.h wxDevCenter/FileSystemTreeCtrl.h wxDevCenter/FileSystemStandard.h wxDevCenter/FileTools.h wxDevCenter/Frame.h wxDevCenter/language.h wxDevCenter/Layout.h wxDevCenter/MainFrame.h wxDevCenter/Manager.h wxDevCenter/MDIFrame.h wxDevCenter/Plugin.h wxDevCenter/Project.h wxDevCenter/setup.h wxDevCenter/StatusBar.h wxDevCenter/WorkBar.h wxDevCenter/unix/Config.h wxDevCenter/unix/FileSystemStandard.h; do \ if test ! -d $(prefix)/include/`dirname $$f` ; then \ $(INSTALL) -d $(prefix)/include/`dirname $$f`; \ *************** *** 275,278 **** --- 276,282 ---- $(CXX) -c -o $@ $(WXDEVCENTERLIB_CXXFLAGS) $(CPPDEPS) $< + ./build/$(BUILD)/wxDevCenterLib_Layout.o: ./src/Layout.cpp + $(CXX) -c -o $@ $(WXDEVCENTERLIB_CXXFLAGS) $(CPPDEPS) $< + ./build/$(BUILD)/wxDevCenterLib_MainFrame.o: ./src/MainFrame.cpp $(CXX) -c -o $@ $(WXDEVCENTERLIB_CXXFLAGS) $(CPPDEPS) $< |
|
From: Emilien K. <cur...@us...> - 2005-08-28 15:57:18
|
Update of /cvsroot/wxdevcenter/wxDevCenter In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv10580 Modified Files: GNUmakefile Log Message: Begin of command manager. Index: GNUmakefile =================================================================== RCS file: /cvsroot/wxdevcenter/wxDevCenter/GNUmakefile,v retrieving revision 1.9 retrieving revision 1.10 diff -C2 -d -r1.9 -r1.10 *** GNUmakefile 23 Aug 2005 17:03:14 -0000 1.9 --- GNUmakefile 28 Aug 2005 15:57:10 -0000 1.10 *************** *** 74,77 **** --- 74,78 ---- ./build/$(BUILD)/wxDevCenterLib_Application.o \ ./build/$(BUILD)/wxDevCenterLib_ArtProvider.o \ + ./build/$(BUILD)/wxDevCenterLib_Command.o \ ./build/$(BUILD)/wxDevCenterLib_Config.o \ ./build/$(BUILD)/wxDevCenterLib_DocManager.o \ *************** *** 172,176 **** install: all install_wxDevCenterLib install_wxDevCenter $(INSTALL) -d $(prefix)/include ! for f in wxDevCenter.h wxDevCenterPlugin.h wxDevCenter/AboutBox.h wxDevCenter/Application.h wxDevCenter/ArtProvider.h wxDevCenter/Config.h wxDevCenter/DocView.h wxDevCenter/Element.h wxDevCenter/FileSystem.h wxDevCenter/FileSystemCtrl.h wxDevCenter/FileSystemListCtrl.h wxDevCenter/FileSystemTreeCtrl.h wxDevCenter/FileSystemStandard.h wxDevCenter/FileTools.h wxDevCenter/Frame.h wxDevCenter/language.h wxDevCenter/MainFrame.h wxDevCenter/Manager.h wxDevCenter/MDIFrame.h wxDevCenter/Plugin.h wxDevCenter/Project.h wxDevCenter/setup.h wxDevCenter/StatusBar.h wxDevCenter/WorkBar.h wxDevCenter/unix/Config.h wxDevCenter/unix/FileSystemStandard.h; do \ if test ! -d $(prefix)/include/`dirname $$f` ; then \ $(INSTALL) -d $(prefix)/include/`dirname $$f`; \ --- 173,177 ---- install: all install_wxDevCenterLib install_wxDevCenter $(INSTALL) -d $(prefix)/include ! for f in wxDevCenter.h wxDevCenterPlugin.h wxDevCenter/AboutBox.h wxDevCenter/Application.h wxDevCenter/ArtProvider.h wxDevCenter/Command.h wxDevCenter/Config.h wxDevCenter/DocView.h wxDevCenter/Element.h wxDevCenter/FileSystem.h wxDevCenter/FileSystemCtrl.h wxDevCenter/FileSystemListCtrl.h wxDevCenter/FileSystemTreeCtrl.h wxDevCenter/FileSystemStandard.h wxDevCenter/FileTools.h wxDevCenter/Frame.h wxDevCenter/language.h wxDevCenter/MainFrame.h wxDevCenter/Manager.h wxDevCenter/MDIFrame.h wxDevCenter/Plugin.h wxDevCenter/Project.h wxDevCenter/setup.h wxDevCenter/StatusBar.h wxDevCenter/WorkBar.h wxDevCenter/unix/Config.h wxDevCenter/unix/FileSystemStandard.h; do \ if test ! -d $(prefix)/include/`dirname $$f` ; then \ $(INSTALL) -d $(prefix)/include/`dirname $$f`; \ *************** *** 235,238 **** --- 236,242 ---- $(CXX) -c -o $@ $(WXDEVCENTERLIB_CXXFLAGS) $(CPPDEPS) $< + ./build/$(BUILD)/wxDevCenterLib_Command.o: ./src/Command.cpp + $(CXX) -c -o $@ $(WXDEVCENTERLIB_CXXFLAGS) $(CPPDEPS) $< + ./build/$(BUILD)/wxDevCenterLib_Config.o: ./src/Config.cpp $(CXX) -c -o $@ $(WXDEVCENTERLIB_CXXFLAGS) $(CPPDEPS) $< |
|
From: Emilien K. <cur...@us...> - 2005-08-28 15:57:18
|
Update of /cvsroot/wxdevcenter/wxDevCenter/include/wxDevCenter In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv10580/include/wxDevCenter Added Files: Command.h Log Message: Begin of command manager. --- NEW FILE: Command.h --- (This appears to be a binary file; contents omitted.) |
|
From: Emilien K. <cur...@us...> - 2005-08-28 15:57:18
|
Update of /cvsroot/wxdevcenter/wxDevCenter/src In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv10580/src Added Files: Command.cpp Log Message: Begin of command manager. --- NEW FILE: Command.cpp --- (This appears to be a binary file; contents omitted.) |
|
From: Emilien K. <cur...@us...> - 2005-08-28 15:57:18
|
Update of /cvsroot/wxdevcenter/wxDevCenter/build In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv10580/build Modified Files: wxDevCenter.bkl install.bkl Log Message: Begin of command manager. Index: install.bkl =================================================================== RCS file: /cvsroot/wxdevcenter/wxDevCenter/build/install.bkl,v retrieving revision 1.9 retrieving revision 1.10 diff -C2 -d -r1.9 -r1.10 *** install.bkl 23 Aug 2005 17:03:13 -0000 1.9 --- install.bkl 28 Aug 2005 15:57:10 -0000 1.10 *************** *** 15,18 **** --- 15,19 ---- wxDevCenter/Application.h wxDevCenter/ArtProvider.h + wxDevCenter/Command.h wxDevCenter/Config.h wxDevCenter/DocView.h Index: wxDevCenter.bkl =================================================================== RCS file: /cvsroot/wxdevcenter/wxDevCenter/build/wxDevCenter.bkl,v retrieving revision 1.11 retrieving revision 1.12 diff -C2 -d -r1.11 -r1.12 *** wxDevCenter.bkl 13 Aug 2005 16:27:34 -0000 1.11 --- wxDevCenter.bkl 28 Aug 2005 15:57:10 -0000 1.12 *************** *** 52,55 **** --- 52,56 ---- src/Application.cpp src/ArtProvider.cpp + src/Command.cpp src/Config.cpp src/DocManager.cpp |
|
From: Emilien K. <cur...@us...> - 2005-08-26 08:36:10
|
Update of /cvsroot/wxdevcenter/wxDevCenter/include/wxDevCenter In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv8143/include/wxDevCenter Modified Files: language.h Application.h Frame.h Log Message: Base of the printing system : Add standard menus. Add handle for default page setup. Index: Frame.h =================================================================== RCS file: /cvsroot/wxdevcenter/wxDevCenter/include/wxDevCenter/Frame.h,v retrieving revision 1.10 retrieving revision 1.11 diff -C2 -d -r1.10 -r1.11 *** Frame.h 2 Aug 2005 12:50:54 -0000 1.10 --- Frame.h 26 Aug 2005 08:35:58 -0000 1.11 *************** *** 42,45 **** --- 42,48 ---- #define IDM_FILE_CLOSE wxID_CLOSE #define IDM_FILE_CLOSEALL 0x0005 + #define IDM_FILE_PRINT wxID_PRINT + #define IDM_FILE_PRINTSETUP wxID_PRINT_SETUP + #define IDM_FILE_PRINTPREVIEW wxID_PREVIEW #define IDM_PROJECT_OPEN 0x0100 *************** *** 60,66 **** #define IDM_WINDOW_WORKBAR_LAST 0x03FF ! #define IDM_HELP_ABOUT 0x0400 ! #define IDM_HELP_INDEX 0x0401 ! #define IDM_HELP_CONTENT 0x0402 --- 63,69 ---- #define IDM_WINDOW_WORKBAR_LAST 0x03FF ! #define IDM_HELP_ABOUT wxID_ABOUT ! #define IDM_HELP_INDEX wxID_HELP_CONTEXT ! #define IDM_HELP_CONTENT wxID_HELP_CONTENTS Index: language.h =================================================================== RCS file: /cvsroot/wxdevcenter/wxDevCenter/include/wxDevCenter/language.h,v retrieving revision 1.9 retrieving revision 1.10 diff -C2 -d -r1.9 -r1.10 *** language.h 11 Aug 2005 09:58:17 -0000 1.9 --- language.h 26 Aug 2005 08:35:58 -0000 1.10 *************** *** 92,95 **** --- 92,98 ---- #define WXDC_MENU_FILE_SAVE "Save active document\tCtrl+S" #define WXDC_MENU_FILE_SAVEAS "Save active document as\tCtrl+Alt+S" + #define WXDC_MENU_FILE_PRINT "Print ...\tCtrl+P" + #define WXDC_MENU_FILE_PRINTSETUP "Page setup ..." + #define WXDC_MENU_FILE_PRINTPREVIEW "Print preview" #define WXDC_MENU_PROJECT_OPEN "Open project ...\tCtrl+Alt+O" Index: Application.h =================================================================== RCS file: /cvsroot/wxdevcenter/wxDevCenter/include/wxDevCenter/Application.h,v retrieving revision 1.15 retrieving revision 1.16 diff -C2 -d -r1.15 -r1.16 *** Application.h 17 Aug 2005 16:33:17 -0000 1.15 --- Application.h 26 Aug 2005 08:35:58 -0000 1.16 *************** *** 88,91 **** --- 88,94 ---- Configuration m_ConfigManager; + /** Données de configuration de la mise en pages.*/ + wxPageSetupDialogData* m_pPageSetupDialogData; + /** Interception de la demande de sortie de l'application.*/ void OnExitMenu(wxCommandEvent& event); *************** *** 230,234 **** --- 233,252 ---- /** @} */ + /** @name Print + * @{*/ + /** Retourne les infos de mise en page.*/ + wxPageSetupDialogData* GetPagesSetupDialogData(); + /* @} */ + protected: + /** @name Print + * @{ */ + /** Intercepte les évènements de mise à jour des menus d'impressions pour les annuler.*/ + void OnUpdatePrint(wxUpdateUIEvent& event); + /** Intercepte la demande de configuration des pages.*/ + void OnPageSetup(wxCommandEvent& event); + /** @} */ + + /** Initialise la ligne de commande. * @param parser Parseur de ligne de commande. |
|
From: Emilien K. <cur...@us...> - 2005-08-26 08:36:10
|
Update of /cvsroot/wxdevcenter/wxDevCenter/src In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv8143/src Modified Files: MainFrame.cpp Application.cpp Log Message: Base of the printing system : Add standard menus. Add handle for default page setup. Index: Application.cpp =================================================================== RCS file: /cvsroot/wxdevcenter/wxDevCenter/src/Application.cpp,v retrieving revision 1.31 retrieving revision 1.32 diff -C2 -d -r1.31 -r1.32 *** Application.cpp 17 Aug 2005 16:33:17 -0000 1.31 --- Application.cpp 26 Aug 2005 08:35:58 -0000 1.32 *************** *** 41,44 **** --- 41,45 ---- #include <wx/datetime.h> #include <wx/cmdline.h> + #include <wx/printdlg.h> *************** *** 48,51 **** --- 49,56 ---- BEGIN_EVENT_TABLE(Application, wxApp) EVT_MENU(wxID_EXIT, Application::OnExitMenu) + + EVT_UPDATE_UI(IDM_FILE_PRINT, Application::OnUpdatePrint) + EVT_UPDATE_UI(IDM_FILE_PRINTPREVIEW, Application::OnUpdatePrint) + EVT_MENU(IDM_FILE_PRINTSETUP, Application::OnPageSetup) END_EVENT_TABLE() *************** *** 138,142 **** Application::Application(void): wxApp(), ! m_pStandardFileSystem(NULL) { ms_pTheApp = this; --- 143,148 ---- Application::Application(void): wxApp(), ! m_pStandardFileSystem(NULL), ! m_pPageSetupDialogData(NULL) { ms_pTheApp = this; *************** *** 145,148 **** --- 151,156 ---- Application::~Application(void) { + if(m_pPageSetupDialogData!=NULL) + delete m_pPageSetupDialogData; } *************** *** 447,448 **** --- 455,483 ---- } + + /*** + * Impression + ***/ + + // Retourne les infos de mise en page. + wxPageSetupDialogData* Application::GetPagesSetupDialogData() + { + if(m_pPageSetupDialogData==NULL) + m_pPageSetupDialogData = new wxPageSetupDialogData; + return m_pPageSetupDialogData; + } + + // Intercepte les évènements de mise à jour des menus d'impressions pour les annuler. + void Application::OnUpdatePrint(wxUpdateUIEvent& event) + { + if(!event.GetSetEnabled()) + event.Enable(false); + } + + // Intercepte la demande de configuration des pages. + void Application::OnPageSetup(wxCommandEvent& WXUNUSED(event)) + { + wxPageSetupDialog Dialog(NULL, GetPagesSetupDialogData()); + if(Dialog.ShowModal()==wxID_OK) + (*GetPagesSetupDialogData()) = Dialog.GetPageSetupData(); + } Index: MainFrame.cpp =================================================================== RCS file: /cvsroot/wxdevcenter/wxDevCenter/src/MainFrame.cpp,v retrieving revision 1.18 retrieving revision 1.19 diff -C2 -d -r1.18 -r1.19 *** MainFrame.cpp 13 Aug 2005 14:07:37 -0000 1.18 --- MainFrame.cpp 26 Aug 2005 08:35:58 -0000 1.19 *************** *** 302,305 **** --- 302,309 ---- pMenu->Append(IDM_PROJECT_CLOSE, WXDC_MENU_PROJECT_CLOSE); pMenu->AppendSeparator(); + pMenu->Append(IDM_FILE_PRINT, WXDC_MENU_FILE_PRINT); + pMenu->Append(IDM_FILE_PRINTSETUP, WXDC_MENU_FILE_PRINTSETUP); + pMenu->Append(IDM_FILE_PRINTPREVIEW, WXDC_MENU_FILE_PRINTPREVIEW); + pMenu->AppendSeparator(); pMenu->Append(wxID_EXIT, WXDC_MENU_APP_EXIT); pMenuBar->Append(pMenu, WXDC_MENU_FILES); |
|
From: Emilien K. <cur...@us...> - 2005-08-25 20:36:18
|
Update of /cvsroot/wxdevcenter/StdPlugin/src In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv32099/src Removed Files: BitmapDocView.cpp BitmapCtrl.cpp SimpleTextDocView.cpp BitmapProp.cpp Log Message: Rearrange bakefile and source file hierarchy. --- SimpleTextDocView.cpp DELETED --- --- BitmapCtrl.cpp DELETED --- --- BitmapProp.cpp DELETED --- --- BitmapDocView.cpp DELETED --- |
|
From: Emilien K. <cur...@us...> - 2005-08-25 20:36:17
|
Update of /cvsroot/wxdevcenter/StdPlugin In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv32099 Modified Files: StdPlugin.bkl GNUmakefile Log Message: Rearrange bakefile and source file hierarchy. Index: GNUmakefile =================================================================== RCS file: /cvsroot/wxdevcenter/StdPlugin/GNUmakefile,v retrieving revision 1.8 retrieving revision 1.9 diff -C2 -d -r1.8 -r1.9 *** GNUmakefile 25 Aug 2005 17:06:39 -0000 1.8 --- GNUmakefile 25 Aug 2005 20:36:08 -0000 1.9 *************** *** 138,143 **** install: all install_Text install_Bitmap $(INSTALL) -d $(prefix)/include/wxDevCenter ! for f in StdPlugin.h StdPlugin/BitmapCtrl.h StdPlugin/BitmapDocView.h StdPlugin/BitmapProp.h StdPlugin/Controls.h StdPlugin/extmouse.h StdPlugin/language.h StdPlugin/SimpleTextDocView.h; do \ if test ! -d $(prefix)/include/wxDevCenter/`dirname $$f` ; then \ $(INSTALL) -d $(prefix)/include/wxDevCenter/`dirname $$f`; \ --- 138,150 ---- install: all install_Text install_Bitmap + $(INSTALL) -d $(prefix)/share/wxDevCenter/plugins + for f in StdPlugin.Text/plugin.xml; do \ + if test ! -d $(prefix)/share/wxDevCenter/plugins/`dirname $$f` ; then \ + $(INSTALL) -d $(prefix)/share/wxDevCenter/plugins/`dirname $$f`; \ + fi; \ + $(INSTALL) -m 644 plugins//$$f $(prefix)/share/wxDevCenter/plugins/$$f; \ + done $(INSTALL) -d $(prefix)/include/wxDevCenter ! for f in StdPlugin/Bitmap/BitmapCtrl.h StdPlugin/Bitmap/BitmapDocView.h StdPlugin/Bitmap/BitmapProp.h; do \ if test ! -d $(prefix)/include/wxDevCenter/`dirname $$f` ; then \ $(INSTALL) -d $(prefix)/include/wxDevCenter/`dirname $$f`; \ *************** *** 146,156 **** done $(INSTALL) -d $(prefix)/share/wxDevCenter/data - for f in icons/filetypes/bmp.ico icons/StdPlugin.Bitmap/brush.png icons/StdPlugin.Bitmap/ellipse.png icons/StdPlugin.Bitmap/handdraw.png icons/StdPlugin.Bitmap/line.png icons/StdPlugin.Bitmap/rect.png icons/StdPlugin.Bitmap/rrect.png icons/StdPlugin.Bitmap/selall.png icons/StdPlugin.Bitmap/selcopy.png icons/StdPlugin.Bitmap/selcut.png icons/StdPlugin.Bitmap/selection.png icons/StdPlugin.Bitmap/selmove.png icons/StdPlugin.Bitmap/selpaste.png icons/StdPlugin.Bitmap/selremove.png icons/StdPlugin.Bitmap/sizeall.png icons/StdPlugin.Bitmap/spray.png icons/StdPlugin.Bitmap/dot.png icons/StdPlugin.Bitmap/dot_dash.png icons/StdPlugin.Bitmap/long_dash.png icons/StdPlugin.Bitmap/short_dash.png icons/StdPlugin.Bitmap/solid.png icons/StdPlugin.Bitmap/transparent.png icons/StdPlugin.Bitmap/landscape.png icons/StdPlugin.Bitmap/portrait.png; do \ - if test ! -d $(prefix)/share/wxDevCenter/data/`dirname $$f` ; then \ - $(INSTALL) -d $(prefix)/share/wxDevCenter/data/`dirname $$f`; \ - fi; \ - $(INSTALL) -m 644 data//$$f $(prefix)/share/wxDevCenter/data/$$f; \ - done - $(INSTALL) -d $(prefix)/share/wxDevCenter/data for f in icons/filetypes/txt.ico icons/scintilla.png; do \ if test ! -d $(prefix)/share/wxDevCenter/data/`dirname $$f` ; then \ --- 153,156 ---- *************** *** 159,171 **** $(INSTALL) -m 644 data//$$f $(prefix)/share/wxDevCenter/data/$$f; \ done ! $(INSTALL) -d $(prefix)/share/wxDevCenter/features ! for f in StdPlugin/feature.xml; do \ ! if test ! -d $(prefix)/share/wxDevCenter/features/`dirname $$f` ; then \ ! $(INSTALL) -d $(prefix)/share/wxDevCenter/features/`dirname $$f`; \ fi; \ ! $(INSTALL) -m 644 features//$$f $(prefix)/share/wxDevCenter/features/$$f; \ done $(INSTALL) -d $(prefix)/share/wxDevCenter/plugins ! for f in StdPlugin.Bitmap/plugin.xml StdPlugin.Text/plugin.xml; do \ if test ! -d $(prefix)/share/wxDevCenter/plugins/`dirname $$f` ; then \ $(INSTALL) -d $(prefix)/share/wxDevCenter/plugins/`dirname $$f`; \ --- 159,171 ---- $(INSTALL) -m 644 data//$$f $(prefix)/share/wxDevCenter/data/$$f; \ done ! $(INSTALL) -d $(prefix)/share/wxDevCenter/conf ! for f in StdPlugin.Text.conf StdPlugin.Text/.conf StdPlugin.Text/ADA.conf StdPlugin.Text/APDL.conf StdPlugin.Text/ASM.conf StdPlugin.Text/ASP.conf StdPlugin.Text/AU3.conf StdPlugin.Text/AVE.conf StdPlugin.Text/BAAM.conf StdPlugin.Text/BASH.conf StdPlugin.Text/Batch.conf StdPlugin.Text/Bullant.conf StdPlugin.Text/CLW-no-case.conf StdPlugin.Text/CLW.conf StdPlugin.Text/Config.conf StdPlugin.Text/CPP-no-case.conf StdPlugin.Text/CPP.conf StdPlugin.Text/CSS.conf StdPlugin.Text/Diff.conf StdPlugin.Text/Eiffel.conf StdPlugin.Text/EiffelKW.conf StdPlugin.Text/ERLANG.conf StdPlugin.Text/Error-list.conf StdPlugin.Text/ESCRIPT.conf StdPlugin.Text/F77.conf StdPlugin.Text/FORTH.conf StdPlugin.Text/Fortran.conf StdPlugin.Text/GUI2CLI.conf StdPlugin.Text/HTML.conf StdPlugin.Text/KIX.conf StdPlugin.Text/LaTeX.conf StdPlugin.Text/Lisp.conf StdPlugin.Text/LOT.conf StdPlugin.Text/LOUT.conf StdPlugin.Text/LUA.conf StdPlugin.Text/Makefile.conf StdPlugin.Text/MATLab.conf StdPlugin.Text/METAPOST.conf StdPlugin.Text/MMIXAL.conf StdPlugin.Text/MS-SQL.conf StdPlugin.Text/NN-Cron-Table.conf StdPlugin.Text/NSIS.conf StdPlugin.Text/Octave.conf StdPlugin.Text/Pascal.conf StdPlugin.Text/Perl.conf StdPlugin.Text/PHP.conf StdPlugin.Text/POV.conf StdPlugin.Text/Power-Basic.conf StdPlugin.Text/Properties.conf StdPlugin.Text/PS.conf StdPlugin.Text/Python.conf StdPlugin.Text/Ruby.conf StdPlugin.Text/Scriptol.conf StdPlugin.Text/SPECMAN.conf StdPlugin.Text/SQL.conf StdPlugin.Text/TCL.conf StdPlugin.Text/TeX.conf StdPlugin.Text/Text.conf StdPlugin.Text/Verilog.conf StdPlugin.Text/Visual-Basic-Script.conf StdPlugin.Text/Visual-Basic.conf StdPlugin.Text/XCode.conf StdPlugin.Text/XML.conf StdPlugin.Text/YAML.conf; do \ ! if test ! -d $(prefix)/share/wxDevCenter/conf/`dirname $$f` ; then \ ! $(INSTALL) -d $(prefix)/share/wxDevCenter/conf/`dirname $$f`; \ fi; \ ! $(INSTALL) -m 644 conf//$$f $(prefix)/share/wxDevCenter/conf/$$f; \ done $(INSTALL) -d $(prefix)/share/wxDevCenter/plugins ! for f in StdPlugin.Bitmap/plugin.xml; do \ if test ! -d $(prefix)/share/wxDevCenter/plugins/`dirname $$f` ; then \ $(INSTALL) -d $(prefix)/share/wxDevCenter/plugins/`dirname $$f`; \ *************** *** 173,178 **** $(INSTALL) -m 644 plugins//$$f $(prefix)/share/wxDevCenter/plugins/$$f; \ done $(INSTALL) -d $(prefix)/share/wxDevCenter/conf ! for f in StdPlugin.Bitmap.conf StdPlugin.Text.conf StdPlugin.Text/.conf StdPlugin.Text/ADA.conf StdPlugin.Text/APDL.conf StdPlugin.Text/ASM.conf StdPlugin.Text/ASP.conf StdPlugin.Text/AU3.conf StdPlugin.Text/AVE.conf StdPlugin.Text/BAAM.conf StdPlugin.Text/BASH.conf StdPlugin.Text/Batch.conf StdPlugin.Text/Bullant.conf StdPlugin.Text/CLW-no-case.conf StdPlugin.Text/CLW.conf StdPlugin.Text/Config.conf StdPlugin.Text/CPP-no-case.conf StdPlugin.Text/CPP.conf StdPlugin.Text/CSS.conf StdPlugin.Text/Diff.conf StdPlugin.Text/Eiffel.conf StdPlugin.Text/EiffelKW.conf StdPlugin.Text/ERLANG.conf StdPlugin.Text/Error-list.conf StdPlugin.Text/ESCRIPT.conf StdPlugin.Text/F77.conf StdPlugin.Text/FORTH.conf StdPlugin.Text/Fortran.conf StdPlugin.Text/GUI2CLI.conf StdPlugin.Text/HTML.conf StdPlugin.Text/KIX.conf StdPlugin.Text/LaTeX.conf StdPlugin.Text/Lisp.conf StdPlugin.Text/LOT.conf StdPlugin.Text/LOUT.conf StdPlugin.Text/LUA.conf StdPlugin.Text/Makefile.conf StdPlugin.Text/MATLab.conf StdPlugin.Text/METAPOST.conf StdPlugin.Text/MMIXAL.conf StdPlugin.Text/MS-SQL.conf StdPlugin.Text/NN-Cron-Table.conf StdPlugin.Text/NSIS.conf StdPlugin.Text/Octave.conf StdPlugin.Text/Pascal.conf StdPlugin.Text/Perl.conf StdPlugin.Text/PHP.conf StdPlugin.Text/POV.conf StdPlugin.Text/Power-Basic.conf StdPlugin.Text/Properties.conf StdPlugin.Text/PS.conf StdPlugin.Text/Python.conf StdPlugin.Text/Ruby.conf StdPlugin.Text/Scriptol.conf StdPlugin.Text/SPECMAN.conf StdPlugin.Text/SQL.conf StdPlugin.Text/TCL.conf StdPlugin.Text/TeX.conf StdPlugin.Text/Text.conf StdPlugin.Text/Verilog.conf StdPlugin.Text/Visual-Basic-Script.conf StdPlugin.Text/Visual-Basic.conf StdPlugin.Text/XCode.conf StdPlugin.Text/XML.conf StdPlugin.Text/YAML.conf; do \ if test ! -d $(prefix)/share/wxDevCenter/conf/`dirname $$f` ; then \ $(INSTALL) -d $(prefix)/share/wxDevCenter/conf/`dirname $$f`; \ --- 173,192 ---- $(INSTALL) -m 644 plugins//$$f $(prefix)/share/wxDevCenter/plugins/$$f; \ done + $(INSTALL) -d $(prefix)/include/wxDevCenter + for f in StdPlugin/Bitmap/BitmapCtrl.h StdPlugin/Bitmap/BitmapDocView.h StdPlugin/Bitmap/BitmapProp.h; do \ + if test ! -d $(prefix)/include/wxDevCenter/`dirname $$f` ; then \ + $(INSTALL) -d $(prefix)/include/wxDevCenter/`dirname $$f`; \ + fi; \ + $(INSTALL) -m 644 include/wxDevCenter//$$f $(prefix)/include/wxDevCenter/$$f; \ + done + $(INSTALL) -d $(prefix)/share/wxDevCenter/data + for f in icons/filetypes/bmp.ico icons/StdPlugin.Bitmap/brush.png icons/StdPlugin.Bitmap/ellipse.png icons/StdPlugin.Bitmap/handdraw.png icons/StdPlugin.Bitmap/line.png icons/StdPlugin.Bitmap/rect.png icons/StdPlugin.Bitmap/rrect.png icons/StdPlugin.Bitmap/selall.png icons/StdPlugin.Bitmap/selcopy.png icons/StdPlugin.Bitmap/selcut.png icons/StdPlugin.Bitmap/selection.png icons/StdPlugin.Bitmap/selmove.png icons/StdPlugin.Bitmap/selpaste.png icons/StdPlugin.Bitmap/selremove.png icons/StdPlugin.Bitmap/sizeall.png icons/StdPlugin.Bitmap/spray.png icons/StdPlugin.Bitmap/dot.png icons/StdPlugin.Bitmap/dot_dash.png icons/StdPlugin.Bitmap/long_dash.png icons/StdPlugin.Bitmap/short_dash.png icons/StdPlugin.Bitmap/solid.png icons/StdPlugin.Bitmap/transparent.png icons/StdPlugin.Bitmap/landscape.png icons/StdPlugin.Bitmap/portrait.png; do \ + if test ! -d $(prefix)/share/wxDevCenter/data/`dirname $$f` ; then \ + $(INSTALL) -d $(prefix)/share/wxDevCenter/data/`dirname $$f`; \ + fi; \ + $(INSTALL) -m 644 data//$$f $(prefix)/share/wxDevCenter/data/$$f; \ + done $(INSTALL) -d $(prefix)/share/wxDevCenter/conf ! for f in StdPlugin.Bitmap.conf; do \ if test ! -d $(prefix)/share/wxDevCenter/conf/`dirname $$f` ; then \ $(INSTALL) -d $(prefix)/share/wxDevCenter/conf/`dirname $$f`; \ *************** *** 180,183 **** --- 194,211 ---- $(INSTALL) -m 644 conf//$$f $(prefix)/share/wxDevCenter/conf/$$f; \ done + $(INSTALL) -d $(prefix)/include/wxDevCenter + for f in StdPlugin.h StdPlugin/Controls.h StdPlugin/extmouse.h StdPlugin/language.h; do \ + if test ! -d $(prefix)/include/wxDevCenter/`dirname $$f` ; then \ + $(INSTALL) -d $(prefix)/include/wxDevCenter/`dirname $$f`; \ + fi; \ + $(INSTALL) -m 644 include/wxDevCenter//$$f $(prefix)/include/wxDevCenter/$$f; \ + done + $(INSTALL) -d $(prefix)/share/wxDevCenter/features + for f in StdPlugin/feature.xml; do \ + if test ! -d $(prefix)/share/wxDevCenter/features/`dirname $$f` ; then \ + $(INSTALL) -d $(prefix)/share/wxDevCenter/features/`dirname $$f`; \ + fi; \ + $(INSTALL) -m 644 features//$$f $(prefix)/share/wxDevCenter/features/$$f; \ + done uninstall: *************** *** 210,223 **** $(CXX) -c -o $@ $(TEXT_CXXFLAGS) $(CPPDEPS) $< ! ./build/$(BUILD)/Text_SimpleTextDocView.o: ./src/SimpleTextDocView.cpp $(CXX) -c -o $@ $(TEXT_CXXFLAGS) $(CPPDEPS) $< ! ./build/$(BUILD)/Bitmap_BitmapCtrl.o: ./src/BitmapCtrl.cpp $(CXX) -c -o $@ $(BITMAP_CXXFLAGS) $(CPPDEPS) $< ! ./build/$(BUILD)/Bitmap_BitmapDocView.o: ./src/BitmapDocView.cpp $(CXX) -c -o $@ $(BITMAP_CXXFLAGS) $(CPPDEPS) $< ! ./build/$(BUILD)/Bitmap_BitmapProp.o: ./src/BitmapProp.cpp $(CXX) -c -o $@ $(BITMAP_CXXFLAGS) $(CPPDEPS) $< --- 238,251 ---- $(CXX) -c -o $@ $(TEXT_CXXFLAGS) $(CPPDEPS) $< ! ./build/$(BUILD)/Text_SimpleTextDocView.o: ./src/Text/SimpleTextDocView.cpp $(CXX) -c -o $@ $(TEXT_CXXFLAGS) $(CPPDEPS) $< ! ./build/$(BUILD)/Bitmap_BitmapCtrl.o: ./src/Bitmap/BitmapCtrl.cpp $(CXX) -c -o $@ $(BITMAP_CXXFLAGS) $(CPPDEPS) $< ! ./build/$(BUILD)/Bitmap_BitmapDocView.o: ./src/Bitmap/BitmapDocView.cpp $(CXX) -c -o $@ $(BITMAP_CXXFLAGS) $(CPPDEPS) $< ! ./build/$(BUILD)/Bitmap_BitmapProp.o: ./src/Bitmap/BitmapProp.cpp $(CXX) -c -o $@ $(BITMAP_CXXFLAGS) $(CPPDEPS) $< Index: StdPlugin.bkl =================================================================== RCS file: /cvsroot/wxdevcenter/StdPlugin/StdPlugin.bkl,v retrieving revision 1.5 retrieving revision 1.6 diff -C2 -d -r1.5 -r1.6 *** StdPlugin.bkl 25 Apr 2005 15:40:13 -0000 1.5 --- StdPlugin.bkl 25 Aug 2005 20:36:08 -0000 1.6 *************** *** 2,8 **** <makefile> ! <include file="build/wx.bkl" /> ! <include file="build/StdPlugin.bkl" /> ! <include file="build/install.bkl" /> --- 2,12 ---- <makefile> ! <include file="build/bakefiles/wx.bkl" /> ! <include file="build/bakefiles/StdPlugin.bkl" /> ! ! <include file="build/bakefiles/Text.bkl" /> ! <include file="build/bakefiles/Bitmap.bkl" /> ! ! <include file="build/bakefiles/install.bkl" /> |
|
From: Emilien K. <cur...@us...> - 2005-08-25 20:36:17
|
Update of /cvsroot/wxdevcenter/StdPlugin/src/Bitmap In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv32099/src/Bitmap Added Files: BitmapCtrl.cpp BitmapDocView.cpp BitmapProp.cpp Log Message: Rearrange bakefile and source file hierarchy. --- NEW FILE: BitmapCtrl.cpp --- (This appears to be a binary file; contents omitted.) --- NEW FILE: BitmapProp.cpp --- (This appears to be a binary file; contents omitted.) --- NEW FILE: BitmapDocView.cpp --- (This appears to be a binary file; contents omitted.) |
|
From: Emilien K. <cur...@us...> - 2005-08-25 20:36:16
|
Update of /cvsroot/wxdevcenter/StdPlugin/include/wxDevCenter/StdPlugin/Text In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv32099/include/wxDevCenter/StdPlugin/Text Added Files: SimpleTextDocView.h Log Message: Rearrange bakefile and source file hierarchy. --- NEW FILE: SimpleTextDocView.h --- (This appears to be a binary file; contents omitted.) |
|
From: Emilien K. <cur...@us...> - 2005-08-25 20:36:16
|
Update of /cvsroot/wxdevcenter/StdPlugin/include/wxDevCenter/StdPlugin In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv32099/include/wxDevCenter/StdPlugin Removed Files: SimpleTextDocView.h BitmapProp.h BitmapDocView.h BitmapCtrl.h Log Message: Rearrange bakefile and source file hierarchy. --- BitmapCtrl.h DELETED --- --- BitmapDocView.h DELETED --- --- BitmapProp.h DELETED --- --- SimpleTextDocView.h DELETED --- |