mirror of
https://github.com/4ian/GDevelop.git
synced 2025-10-15 10:19:04 +00:00
Corrected glitch in EditorObjetsGroups.
Groups can now be moved. git-svn-id: svn://localhost@34 8062f311-0dae-4547-b526-b8ab9ac864a5
This commit is contained in:
@@ -43,6 +43,8 @@ const long EditorObjetsGroups::ID_Refresh = wxNewId();
|
||||
const long EditorObjetsGroups::ID_Help = wxNewId();
|
||||
const long EditorObjetsGroups::idRibbonAdd = wxNewId();
|
||||
const long EditorObjetsGroups::idRibbonDel = wxNewId();
|
||||
const long EditorObjetsGroups::idRibbonUp = wxNewId();
|
||||
const long EditorObjetsGroups::idRibbonDown = wxNewId();
|
||||
const long EditorObjetsGroups::idRibbonEdit = wxNewId();
|
||||
const long EditorObjetsGroups::idRibbonModName = wxNewId();
|
||||
const long EditorObjetsGroups::idRibbonHelp = wxNewId();
|
||||
@@ -115,6 +117,8 @@ mainEditorCommand(mainEditorCommand_)
|
||||
toolbar->AddTool( idAddGroup, wxT( "Ajouter un groupe" ), wxBitmap( wxImage( "res/addicon.png" ) ), _("Ajouter un groupe") );
|
||||
toolbar->AddTool( idDelGroup, wxT( "Supprimer le groupe selectionn<6E>" ), wxBitmap( wxImage( "res/deleteicon.png" ) ), _("Supprimer le groupe selectionn<6E>") );
|
||||
toolbar->AddTool( IdGroupEdit, wxT( "Modifier le groupe" ), wxBitmap( wxImage( "res/editpropicon.png" ) ), _("Modifier le groupe") );
|
||||
toolbar->AddTool( idRibbonUp, wxT( "D<EFBFBD>placer le groupe vers le haut" ), wxBitmap( wxImage( "res/up24.png" ) ), _("D<EFBFBD>placer le groupe vers le haut") );
|
||||
toolbar->AddTool( idRibbonDown, wxT( "D<EFBFBD>placer le groupe vers le bas" ), wxBitmap( wxImage( "res/down24.png" ) ), _("D<EFBFBD>placer le groupe vers le bas") );
|
||||
toolbar->AddSeparator();
|
||||
toolbar->AddTool( ID_Help, wxT( "Aide de l'<27>diteur de groupes d'objets" ), wxBitmap( wxImage( "res/helpicon.png" ) ), _("Aide de l'<27>diteur de groupes d'objets") );
|
||||
toolbar->Realize();
|
||||
@@ -151,6 +155,8 @@ void EditorObjetsGroups::CreateRibbonPage(wxRibbonPage * page)
|
||||
wxRibbonButtonBar *ribbonBar = new wxRibbonButtonBar(ribbonPanel, wxID_ANY);
|
||||
ribbonBar->AddButton(idRibbonAdd, !hideLabels ? _("Ajouter un groupe") : "", wxBitmap("res/add24.png", wxBITMAP_TYPE_ANY));
|
||||
ribbonBar->AddButton(idRibbonDel, !hideLabels ? _("Supprimer") : "", wxBitmap("res/delete24.png", wxBITMAP_TYPE_ANY));
|
||||
ribbonBar->AddButton(idRibbonUp, !hideLabels ? _("D<EFBFBD>placer vers le haut") : "", wxBitmap("res/up24.png", wxBITMAP_TYPE_ANY));
|
||||
ribbonBar->AddButton(idRibbonDown, !hideLabels ? _("D<EFBFBD>placer vers le bas") : "", wxBitmap("res/down24.png", wxBITMAP_TYPE_ANY));
|
||||
}
|
||||
{
|
||||
wxRibbonPanel *ribbonPanel = new wxRibbonPanel(page, wxID_ANY, _("Objet s<>lectionn<6E>"), wxBitmap("res/edit24.png", wxBITMAP_TYPE_ANY), wxDefaultPosition, wxDefaultSize, wxRIBBON_PANEL_DEFAULT_STYLE);
|
||||
@@ -170,6 +176,8 @@ void EditorObjetsGroups::ConnectEvents()
|
||||
{
|
||||
mainEditorCommand.GetMainEditor()->Connect(idRibbonAdd, wxEVT_COMMAND_RIBBONBUTTON_CLICKED, (wxObjectEventFunction)&EditorObjetsGroups::OnAddGroupSelected, NULL, this);
|
||||
mainEditorCommand.GetMainEditor()->Connect(idRibbonDel, wxEVT_COMMAND_RIBBONBUTTON_CLICKED, (wxObjectEventFunction)&EditorObjetsGroups::OnDelGroupSelected, NULL, this);
|
||||
mainEditorCommand.GetMainEditor()->Connect(idRibbonUp, wxEVT_COMMAND_RIBBONBUTTON_CLICKED, (wxObjectEventFunction)&EditorObjetsGroups::OnMoveUpSelected, NULL, this);
|
||||
mainEditorCommand.GetMainEditor()->Connect(idRibbonDown, wxEVT_COMMAND_RIBBONBUTTON_CLICKED, (wxObjectEventFunction)&EditorObjetsGroups::OnMoveDownSelected, NULL, this);
|
||||
mainEditorCommand.GetMainEditor()->Connect(idRibbonEdit, wxEVT_COMMAND_RIBBONBUTTON_CLICKED, (wxObjectEventFunction)&EditorObjetsGroups::OnEditGroupSelected, NULL, this);
|
||||
mainEditorCommand.GetMainEditor()->Connect(idRibbonModName, wxEVT_COMMAND_RIBBONBUTTON_CLICKED, (wxObjectEventFunction)&EditorObjetsGroups::OnModNameSelected, NULL, this);
|
||||
mainEditorCommand.GetMainEditor()->Connect(idRibbonHelp, wxEVT_COMMAND_RIBBONBUTTON_CLICKED, (wxObjectEventFunction)&EditorObjetsGroups::OnHelp, NULL, this);
|
||||
@@ -188,6 +196,72 @@ void EditorObjetsGroups::Refresh()
|
||||
|
||||
ObjetsGroupsList->ExpandAll();
|
||||
}
|
||||
|
||||
void EditorObjetsGroups::OnMoveUpSelected(wxCommandEvent& event)
|
||||
{
|
||||
string groupName = string(ObjetsGroupsList->GetItemText( itemSelected ).mb_str());
|
||||
|
||||
for (unsigned int i = 0;i<objectsGroups->size();++i)
|
||||
{
|
||||
if ( objectsGroups->at(i).GetName() == groupName )
|
||||
{
|
||||
if ( i-1 >= 0)
|
||||
{
|
||||
ObjectGroup group = objectsGroups->at(i);
|
||||
objectsGroups->erase(objectsGroups->begin()+i);
|
||||
objectsGroups->insert(objectsGroups->begin()+i-1, group);
|
||||
|
||||
Refresh();
|
||||
|
||||
//Reselect group
|
||||
wxTreeItemId item = ObjetsGroupsList->GetLastChild(ObjetsGroupsList->GetRootItem());
|
||||
while ( item.IsOk() )
|
||||
{
|
||||
if ( ObjetsGroupsList->GetItemText( item ) == groupName )
|
||||
{
|
||||
ObjetsGroupsList->SelectItem(item);
|
||||
return;
|
||||
}
|
||||
item = ObjetsGroupsList->GetPrevSibling(item);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
void EditorObjetsGroups::OnMoveDownSelected(wxCommandEvent& event)
|
||||
{
|
||||
string groupName = string(ObjetsGroupsList->GetItemText( itemSelected ).mb_str());
|
||||
|
||||
for (unsigned int i = 0;i<objectsGroups->size();++i)
|
||||
{
|
||||
if ( objectsGroups->at(i).GetName() == groupName )
|
||||
{
|
||||
if ( static_cast<unsigned>(i+1) < objectsGroups->size())
|
||||
{
|
||||
ObjectGroup group = objectsGroups->at(i);
|
||||
objectsGroups->erase(objectsGroups->begin()+i);
|
||||
objectsGroups->insert(objectsGroups->begin()+i+1, group);
|
||||
|
||||
Refresh();
|
||||
|
||||
//Reselect group
|
||||
wxTreeItemId item = ObjetsGroupsList->GetLastChild(ObjetsGroupsList->GetRootItem());
|
||||
while ( item.IsOk() )
|
||||
{
|
||||
if ( ObjetsGroupsList->GetItemText( item ) == groupName )
|
||||
{
|
||||
ObjetsGroupsList->SelectItem(item);
|
||||
return;
|
||||
}
|
||||
item = ObjetsGroupsList->GetPrevSibling(item);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Active l'<27>diteur
|
||||
@@ -285,10 +359,9 @@ void EditorObjetsGroups::OnAddGroupSelected(wxCommandEvent& event)
|
||||
!= objectsGroups->end() )
|
||||
{
|
||||
++i;
|
||||
name = _( "Nouveau groupe " );
|
||||
name += st (i);
|
||||
name = _( "Nouveau groupe" )+" "+st (i);
|
||||
}
|
||||
NewGroup.SetName( static_cast<string>(name) );
|
||||
NewGroup.SetName( string(name.mb_str()) );
|
||||
|
||||
//On l'ajoute
|
||||
objectsGroups->push_back( NewGroup );
|
||||
@@ -406,12 +479,9 @@ void EditorObjetsGroups::OnObjetsGroupsListEndLabelEdit(wxTreeEvent& event)
|
||||
i->SetName( static_cast<string>(event.GetLabel()) );
|
||||
|
||||
mainEditorCommand.NeedRefreshScene();
|
||||
Refresh();
|
||||
return;
|
||||
}
|
||||
Refresh();
|
||||
}
|
||||
Refresh();
|
||||
}
|
||||
}
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
|
@@ -75,6 +75,8 @@ class EditorObjetsGroups: public wxPanel
|
||||
static const long ID_Help;
|
||||
static const long idRibbonAdd;
|
||||
static const long idRibbonDel;
|
||||
static const long idRibbonUp;
|
||||
static const long idRibbonDown;
|
||||
static const long idRibbonEdit;
|
||||
static const long idRibbonModName;
|
||||
static const long idRibbonHelp;
|
||||
@@ -94,7 +96,9 @@ class EditorObjetsGroups: public wxPanel
|
||||
void OnObjetsGroupsListItemDoubleClicked(wxTreeEvent& event);
|
||||
void OnSetFocus(wxFocusEvent& event);
|
||||
//*)
|
||||
void OnHelp(wxCommandEvent& event);
|
||||
void OnHelp(wxCommandEvent& event);
|
||||
void OnMoveUpSelected(wxCommandEvent& event);
|
||||
void OnMoveDownSelected(wxCommandEvent& event);
|
||||
void DisableAll();
|
||||
void EnableAll();
|
||||
|
||||
|
@@ -655,7 +655,6 @@ void EditorScene::OnPlayWindowBtClick( wxCommandEvent & event )
|
||||
externalWindow.SetFramerateLimit(60);
|
||||
|
||||
sceneCanvas->scene.ChangeRenderWindow(&externalWindow);
|
||||
externalWindow.SetActive(true);
|
||||
|
||||
debugger->Play();
|
||||
}
|
||||
|
@@ -5,7 +5,7 @@
|
||||
<Option title="IDE" />
|
||||
<Option pch_mode="2" />
|
||||
<Option compiler="gcc" />
|
||||
<Option virtualFolders="Editeurs\;Editeurs\Editeur Scene\;Editeurs\Editeur Scene\Editeur objets\;Editeurs\Editeur Scene\EditorEvents\;Editeurs\Editeur Image\;Editeurs\Choix\;Racine\;Racine\Demarrage\;Editeur principal\Fichier\;Editeur principal\Outils\;Editeur principal\Aide\;Editeur principal\Autres\;Editeur principal\;Log et Memoire\;Editeur principal\Affichage\;Editeur principal\Options\;Fichiers\;LIB TinyXml\;wxSFML Canvas\;LIB MyStatusBar\;LIB nwidgets\;Editeurs\Editeur Scene\EditorEvents\Edition evenement\Choix\;Editeurs\Editeur Scene\EditorEvents\Templates\;Editeurs\Editeur Scene\EditorEvents\Renderers\;Editeurs\Editeur Scene\EditorEvents\Edition evenement\;Editeurs\Editeur Scene\EditorEvents\Events\;Editeurs\Editeur Scene\Editeur calques\;Editeur principal\Apparence\;LIB CppUnitLite\;LIB fparser\;" />
|
||||
<Option virtualFolders="Editeurs\;Editeurs\Editeur Scene\;Editeurs\Editeur Scene\Editeur objets\;Editeurs\Editeur Scene\EditorEvents\;Editeurs\Editeur Image\;Editeurs\Choix\;Racine\;Racine\Demarrage\;Editeur principal\Fichier\;Editeur principal\Outils\;Editeur principal\Aide\;Editeur principal\Autres\;Editeur principal\;Log et Memoire\;Editeur principal\Affichage\;Editeur principal\Options\;Fichiers\;LIB TinyXml\;wxSFML Canvas\;LIB MyStatusBar\;Editeurs\Editeur Scene\EditorEvents\Edition evenement\Choix\;Editeurs\Editeur Scene\EditorEvents\Templates\;Editeurs\Editeur Scene\EditorEvents\Renderers\;Editeurs\Editeur Scene\EditorEvents\Edition evenement\;Editeurs\Editeur Scene\EditorEvents\Events\;Editeurs\Editeur Scene\Editeur calques\;Editeur principal\Apparence\;LIB CppUnitLite\;" />
|
||||
<Build>
|
||||
<Target title="Debug - Edittime">
|
||||
<Option output="bin\debug\GDEditor" prefix_auto="1" extension_auto="1" />
|
||||
@@ -238,12 +238,6 @@
|
||||
<Unit filename="..\..\..\..\..\Libs\CppUnitLite\CppUnitLite\TestResult.cpp">
|
||||
<Option virtualFolder="LIB CppUnitLite\" />
|
||||
</Unit>
|
||||
<Unit filename="..\..\..\..\..\Libs\dlib-17.12\dlib\all\source.cpp">
|
||||
<Option virtualFolder="LIB nwidgets\" />
|
||||
</Unit>
|
||||
<Unit filename="..\..\..\..\..\Libs\fparser\fparser.cc">
|
||||
<Option virtualFolder="LIB fparser\" />
|
||||
</Unit>
|
||||
<Unit filename="BugReport.cpp">
|
||||
<Option weight="60" />
|
||||
<Option virtualFolder="Racine\" />
|
||||
|
2775
IDE/IDE.depend
2775
IDE/IDE.depend
File diff suppressed because it is too large
Load Diff
@@ -13,8 +13,11 @@
|
||||
<File name="ChoixCondition.cpp" open="0" top="0" tabpos="10">
|
||||
<Cursor position="1078" topLine="40" />
|
||||
</File>
|
||||
<File name="Compilation.cpp" open="1" top="0" tabpos="1">
|
||||
<Cursor position="21690" topLine="412" />
|
||||
<File name="ChoixVariableDialog.cpp" open="1" top="0" tabpos="7">
|
||||
<Cursor position="410" topLine="0" />
|
||||
</File>
|
||||
<File name="Compilation.cpp" open="0" top="0" tabpos="1">
|
||||
<Cursor position="28730" topLine="514" />
|
||||
</File>
|
||||
<File name="CompilationChecker.cpp" open="0" top="0" tabpos="1">
|
||||
<Cursor position="492" topLine="0" />
|
||||
@@ -37,8 +40,8 @@
|
||||
<File name="DndTextObjectsEditor.cpp" open="0" top="0" tabpos="0">
|
||||
<Cursor position="125" topLine="0" />
|
||||
</File>
|
||||
<File name="DndTextSceneEditor.cpp" open="0" top="0" tabpos="6">
|
||||
<Cursor position="267" topLine="0" />
|
||||
<File name="DndTextSceneEditor.cpp" open="0" top="0" tabpos="4">
|
||||
<Cursor position="239" topLine="0" />
|
||||
</File>
|
||||
<File name="EditExpression.cpp" open="0" top="0" tabpos="0">
|
||||
<Cursor position="31787" topLine="566" />
|
||||
@@ -76,8 +79,8 @@
|
||||
<File name="EditorObjetsGroups.cpp" open="0" top="0" tabpos="21">
|
||||
<Cursor position="481" topLine="0" />
|
||||
</File>
|
||||
<File name="EditorScene.cpp" open="1" top="1" tabpos="5">
|
||||
<Cursor position="16750" topLine="200" />
|
||||
<File name="EditorScene.cpp" open="0" top="0" tabpos="3">
|
||||
<Cursor position="31646" topLine="618" />
|
||||
</File>
|
||||
<File name="EdittimeScene.cpp" open="0" top="0" tabpos="3">
|
||||
<Cursor position="4974" topLine="87" />
|
||||
@@ -121,11 +124,11 @@
|
||||
<File name="MiniChoixObjet.cpp" open="0" top="0" tabpos="28">
|
||||
<Cursor position="458" topLine="0" />
|
||||
</File>
|
||||
<File name="SceneCanvas.cpp" open="1" top="0" tabpos="4">
|
||||
<Cursor position="4835" topLine="128" />
|
||||
<File name="SceneCanvas.cpp" open="0" top="0" tabpos="2">
|
||||
<Cursor position="25712" topLine="660" />
|
||||
</File>
|
||||
<File name="SceneCanvas.h" open="0" top="0" tabpos="0">
|
||||
<Cursor position="2511" topLine="66" />
|
||||
<File name="SceneCanvas.h" open="0" top="0" tabpos="5">
|
||||
<Cursor position="1684" topLine="39" />
|
||||
</File>
|
||||
<File name="SplashScreen.cpp" open="0" top="0" tabpos="7">
|
||||
<Cursor position="1411" topLine="61" />
|
||||
@@ -148,4 +151,7 @@
|
||||
<File name="gridSetup.cpp" open="0" top="0" tabpos="31">
|
||||
<Cursor position="542" topLine="0" />
|
||||
</File>
|
||||
<File name="wxSFMLCanvas.cpp" open="0" top="0" tabpos="0">
|
||||
<Cursor position="314" topLine="0" />
|
||||
</File>
|
||||
</CodeBlocks_layout_file>
|
||||
|
@@ -4,7 +4,7 @@
|
||||
namespace AutoVersion{
|
||||
|
||||
//Date Version Types
|
||||
static const char DATE[] = "07";
|
||||
static const char DATE[] = "10";
|
||||
static const char MONTH[] = "02";
|
||||
static const char YEAR[] = "2010";
|
||||
static const double UBUNTU_VERSION_STYLE = 10.02;
|
||||
@@ -16,14 +16,14 @@ namespace AutoVersion{
|
||||
//Standard Version Type
|
||||
static const long MAJOR = 1;
|
||||
static const long MINOR = 2;
|
||||
static const long BUILD = 8779;
|
||||
static const long REVISION = 44229;
|
||||
static const long BUILD = 8795;
|
||||
static const long REVISION = 44298;
|
||||
|
||||
//Miscellaneous Version Types
|
||||
static const long BUILDS_COUNT = 19324;
|
||||
#define RC_FILEVERSION 1,2,8779,44229
|
||||
#define RC_FILEVERSION_STRING "1, 2, 8779, 44229\0"
|
||||
static const char FULLVERSION_STRING[] = "1.2.8779.44229";
|
||||
static const long BUILDS_COUNT = 19375;
|
||||
#define RC_FILEVERSION 1,2,8795,44298
|
||||
#define RC_FILEVERSION_STRING "1, 2, 8795, 44298\0"
|
||||
static const char FULLVERSION_STRING[] = "1.2.8795.44298";
|
||||
|
||||
//These values are to keep track of your versioning state, don't modify them.
|
||||
static const long BUILD_HISTORY = 0;
|
||||
|
Reference in New Issue
Block a user