Merged in dfighter1985/ryzomcore/dfighter-tools (pull request #93)
Further GUI Editor improvements --HG-- branch : develop
This commit is contained in:
commit
cd7f9035bc
52 changed files with 996 additions and 214 deletions
|
@ -492,7 +492,9 @@ namespace NLGUI
|
|||
bool isEditorSelected() const{ return editorSelected; }
|
||||
|
||||
void setPosParent( const std::string &id );
|
||||
void getPosParent( std::string &id ) const;
|
||||
void setSizeParent( const std::string &id );
|
||||
void getSizeParent( std::string &id ) const;
|
||||
|
||||
void setSerializable( bool b ){ serializable = b; }
|
||||
bool IsSerializable() const{ return serializable; }
|
||||
|
|
|
@ -28,6 +28,7 @@
|
|||
#include "nel/gui/proc.h"
|
||||
#include "nel/gui/widget_manager.h"
|
||||
#include "nel/gui/link_data.h"
|
||||
#include "nel/gui/variable_data.h"
|
||||
|
||||
namespace NLGUI
|
||||
{
|
||||
|
@ -100,20 +101,6 @@ namespace NLGUI
|
|||
virtual void setupOptions() = 0;
|
||||
};
|
||||
|
||||
|
||||
struct VariableData
|
||||
{
|
||||
std::string entry;
|
||||
std::string type;
|
||||
std::string value;
|
||||
uint32 size;
|
||||
|
||||
VariableData()
|
||||
{
|
||||
size = 0;
|
||||
}
|
||||
};
|
||||
|
||||
CInterfaceParser();
|
||||
virtual ~CInterfaceParser();
|
||||
|
||||
|
@ -353,7 +340,15 @@ namespace NLGUI
|
|||
std::map< std::string, std::string > pointerSettings;
|
||||
std::map< std::string, std::map< std::string, std::string > > keySettings;
|
||||
|
||||
std::string _WorkDir;
|
||||
|
||||
public:
|
||||
/// Sets the working directory, where files should be looked for
|
||||
void setWorkDir( const std::string &workdir ){ _WorkDir = workdir; }
|
||||
|
||||
/// Looks up a file in either the working directory or using CPath::lookup
|
||||
std::string lookup( const std::string &file );
|
||||
|
||||
void initLUA();
|
||||
void uninitLUA();
|
||||
bool isLuaInitialized() const{ return luaInitialized; }
|
||||
|
@ -378,6 +373,7 @@ namespace NLGUI
|
|||
|
||||
void setEditorMode( bool b ){ editorMode = b; }
|
||||
|
||||
void setVariable( const VariableData &v );
|
||||
bool serializeVariables( xmlNodePtr parentNode ) const;
|
||||
bool serializeProcs( xmlNodePtr parentNode ) const;
|
||||
bool serializePointerSettings( xmlNodePtr parentNode ) const;
|
||||
|
|
|
@ -23,6 +23,7 @@
|
|||
#include "nel/misc/types_nl.h"
|
||||
#include "nel/gui/proc.h"
|
||||
#include "nel/gui/link_data.h"
|
||||
#include "nel/gui/variable_data.h"
|
||||
|
||||
namespace NLGUI
|
||||
{
|
||||
|
@ -83,11 +84,13 @@ namespace NLGUI
|
|||
virtual void removeLinkData( uint32 id ) = 0;
|
||||
virtual bool getLinkData( uint32 id, SLinkData &linkData ) = 0;
|
||||
virtual void updateLinkData( uint32 id, const SLinkData &linkData ) = 0;
|
||||
virtual void setVariable( const VariableData &v ) = 0;
|
||||
virtual bool serializeVariables( xmlNodePtr parentNode ) const = 0;
|
||||
virtual bool serializeProcs( xmlNodePtr parentNode ) const = 0;
|
||||
virtual bool serializePointerSettings( xmlNodePtr parentNode ) const = 0;
|
||||
virtual bool serializeKeySettings( xmlNodePtr parentNode ) const = 0;
|
||||
virtual CViewBase* createClass( const std::string &name ) = 0;
|
||||
virtual void setWorkDir( const std::string &workdir ) = 0;
|
||||
};
|
||||
}
|
||||
|
||||
|
|
46
code/nel/include/nel/gui/root_group.h
Normal file
46
code/nel/include/nel/gui/root_group.h
Normal file
|
@ -0,0 +1,46 @@
|
|||
// Ryzom - MMORPG Framework <http://dev.ryzom.com/projects/ryzom/>
|
||||
// Copyright (C) 2010 Winch Gate Property Limited
|
||||
//
|
||||
// This program is free software: you can redistribute it and/or modify
|
||||
// it under the terms of the GNU Affero General Public License as
|
||||
// published by the Free Software Foundation, either version 3 of the
|
||||
// License, or (at your option) any later version.
|
||||
//
|
||||
// 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 Affero General Public License for more details.
|
||||
//
|
||||
// You should have received a copy of the GNU Affero General Public License
|
||||
// along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
|
||||
#ifndef ROOT_GROUP_H
|
||||
#define ROOT_GROUP_H
|
||||
|
||||
#include <string>
|
||||
#include <map>
|
||||
|
||||
#include "nel/gui/interface_group.h"
|
||||
|
||||
namespace NLGUI
|
||||
{
|
||||
|
||||
class CRootGroup : public CInterfaceGroup
|
||||
{
|
||||
public:
|
||||
CRootGroup(const TCtorParam ¶m);
|
||||
virtual ~CRootGroup();
|
||||
|
||||
virtual CInterfaceElement* getElement (const std::string &id);
|
||||
virtual void addGroup (CInterfaceGroup *child, sint eltOrder = -1);
|
||||
virtual bool delGroup (CInterfaceGroup *child, bool dontDelete = false);
|
||||
|
||||
private:
|
||||
std::map< std::string, CInterfaceGroup* > _Accel;
|
||||
};
|
||||
|
||||
}
|
||||
|
||||
#endif
|
||||
|
41
code/nel/include/nel/gui/variable_data.h
Normal file
41
code/nel/include/nel/gui/variable_data.h
Normal file
|
@ -0,0 +1,41 @@
|
|||
// Ryzom - MMORPG Framework <http://dev.ryzom.com/projects/ryzom/>
|
||||
// Copyright (C) 2010 Winch Gate Property Limited
|
||||
//
|
||||
// This program is free software: you can redistribute it and/or modify
|
||||
// it under the terms of the GNU Affero General Public License as
|
||||
// published by the Free Software Foundation, either version 3 of the
|
||||
// License, or (at your option) any later version.
|
||||
//
|
||||
// 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 Affero General Public License for more details.
|
||||
//
|
||||
// You should have received a copy of the GNU Affero General Public License
|
||||
// along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
#ifndef VARIABLE_DATA_H
|
||||
#define VARIABLE_DATA_H
|
||||
|
||||
#include "nel/misc/types_nl.h"
|
||||
|
||||
namespace NLGUI
|
||||
{
|
||||
struct VariableData
|
||||
{
|
||||
std::string entry;
|
||||
std::string type;
|
||||
std::string value;
|
||||
uint32 size;
|
||||
|
||||
VariableData()
|
||||
{
|
||||
size = 0;
|
||||
}
|
||||
};
|
||||
|
||||
}
|
||||
|
||||
|
||||
#endif
|
||||
|
|
@ -529,6 +529,8 @@ namespace NLGUI
|
|||
bool unGroupSelection();
|
||||
void setMultiSelection( bool b ){ multiSelection = b; }
|
||||
|
||||
bool createNewGUI( const std::string &project, const std::string &window );
|
||||
|
||||
private:
|
||||
CWidgetManager();
|
||||
~CWidgetManager();
|
||||
|
|
|
@ -147,12 +147,16 @@ namespace NLGUI
|
|||
}
|
||||
if( name == "posparent" )
|
||||
{
|
||||
return CWidgetManager::getInstance()->getParser()->getParentPosAssociation( (CInterfaceElement*)this );
|
||||
std::string pp;
|
||||
getPosParent( pp );
|
||||
return pp;
|
||||
}
|
||||
else
|
||||
if( name == "sizeparent" )
|
||||
{
|
||||
return CWidgetManager::getInstance()->getParser()->getParentSizeAssociation( (CInterfaceElement*)this );
|
||||
std::string sp;
|
||||
getSizeParent( sp );
|
||||
return sp;
|
||||
}
|
||||
else
|
||||
if( name == "global_color" )
|
||||
|
@ -294,11 +298,13 @@ namespace NLGUI
|
|||
xmlNewProp( node, BAD_CAST "w", BAD_CAST toString( _W ).c_str() );
|
||||
xmlNewProp( node, BAD_CAST "h", BAD_CAST toString( _H ).c_str() );
|
||||
xmlNewProp( node, BAD_CAST "posref", BAD_CAST HotSpotCoupleToString( _ParentPosRef, _PosRef ).c_str() );
|
||||
xmlNewProp( node, BAD_CAST "posparent",
|
||||
BAD_CAST CWidgetManager::getInstance()->getParser()->getParentPosAssociation( (CInterfaceElement*)this ).c_str() );
|
||||
|
||||
std::string pp;
|
||||
getPosParent( pp );
|
||||
xmlNewProp( node, BAD_CAST "posparent", BAD_CAST pp.c_str() );
|
||||
xmlNewProp( node, BAD_CAST "sizeref", BAD_CAST getSizeRefAsString().c_str() );
|
||||
xmlNewProp( node, BAD_CAST "sizeparent",
|
||||
BAD_CAST CWidgetManager::getInstance()->getParser()->getParentSizeAssociation( (CInterfaceElement*)this ).c_str() );
|
||||
getSizeParent( pp );
|
||||
xmlNewProp( node, BAD_CAST "sizeparent", BAD_CAST pp.c_str() );
|
||||
|
||||
xmlNewProp( node, BAD_CAST "global_color", BAD_CAST toString( _ModulateGlobalColor ).c_str() );
|
||||
xmlNewProp( node, BAD_CAST "render_layer", BAD_CAST toString( _RenderLayer ).c_str() );
|
||||
|
@ -1528,40 +1534,128 @@ namespace NLGUI
|
|||
|
||||
void CInterfaceElement::setPosParent( const std::string &id )
|
||||
{
|
||||
std::string Id = stripId( id );
|
||||
|
||||
if( Id != "parent" )
|
||||
// Parent or empty id simply means the group parent
|
||||
if( ( id == "parent" ) || ( id.empty() ) )
|
||||
{
|
||||
std::string idParent;
|
||||
if( _Parent != NULL )
|
||||
idParent = _Parent->getId() + ":";
|
||||
else
|
||||
idParent = "ui:";
|
||||
CWidgetManager::getInstance()->getParser()->addParentPositionAssociation( this, idParent + Id );
|
||||
setParentPos( getParent() );
|
||||
return;
|
||||
}
|
||||
|
||||
CInterfaceElement *pp = NULL;
|
||||
|
||||
// Check if it's a short Id
|
||||
std::string::size_type idx = id.find( "ui:" );
|
||||
if( idx == std::string::npos )
|
||||
{
|
||||
// If it is, find the widget in the parent group and set as posparent
|
||||
CInterfaceGroup *p = getParent();
|
||||
if( p != NULL )
|
||||
{
|
||||
pp = p->findFromShortId( id );
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
// If it is not, find using the widgetmanager
|
||||
// TODO: refactor, shouldn't use a singleton
|
||||
pp = CWidgetManager::getInstance()->getElementFromId( id );
|
||||
}
|
||||
|
||||
if( pp != NULL )
|
||||
setParentPos( pp );
|
||||
|
||||
}
|
||||
|
||||
void CInterfaceElement::getPosParent( std::string &id ) const
|
||||
{
|
||||
|
||||
// If there's no pos parent set, then the parent group is the pos parent
|
||||
if( getParentPos() == NULL )
|
||||
{
|
||||
id = "parent";
|
||||
return;
|
||||
}
|
||||
|
||||
// If pos parent and parent are the same then ofc the parent group is the pos parent...
|
||||
CInterfaceElement *p = getParent();
|
||||
if( getParentPos() == p )
|
||||
{
|
||||
id = "parent";
|
||||
return;
|
||||
}
|
||||
|
||||
// If parent is in the same group, use the short id
|
||||
p = getParentPos();
|
||||
if( p->isInGroup( getParent() ) )
|
||||
{
|
||||
id = p->getShortId();
|
||||
return;
|
||||
}
|
||||
|
||||
// Otherwise use the full id
|
||||
id = p->getId();
|
||||
}
|
||||
|
||||
void CInterfaceElement::setSizeParent( const std::string &id )
|
||||
{
|
||||
std::string Id = stripId( id );
|
||||
std::string idParent;
|
||||
|
||||
if( Id != "parent" )
|
||||
// Parent or empty id simply means the group parent
|
||||
if( ( id == "parent" ) || ( id.empty() ) )
|
||||
{
|
||||
if( _Parent != NULL )
|
||||
idParent = _Parent->getId() + ":";
|
||||
else
|
||||
idParent = "ui:";
|
||||
CWidgetManager::getInstance()->getParser()->addParentSizeAssociation( this, idParent + Id );
|
||||
setParentSize( getParent() );
|
||||
return;
|
||||
}
|
||||
|
||||
CInterfaceElement *pp = NULL;
|
||||
|
||||
// Check if it's a short Id
|
||||
std::string::size_type idx = id.find( "ui:" );
|
||||
if( idx == std::string::npos )
|
||||
{
|
||||
// If it is, find the widget in the parent group and set as posparent
|
||||
CInterfaceGroup *p = getParent();
|
||||
if( p != NULL )
|
||||
{
|
||||
pp = p->findFromShortId( id );
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
if( _Parent != NULL )
|
||||
{
|
||||
idParent = _Parent->getId();
|
||||
CWidgetManager::getInstance()->getParser()->addParentSizeAssociation( this, idParent );
|
||||
}
|
||||
// If it is not, find using the widgetmanager
|
||||
// TODO: refactor, shouldn't use a singleton
|
||||
pp = CWidgetManager::getInstance()->getElementFromId( id );
|
||||
}
|
||||
|
||||
if( pp != NULL )
|
||||
setParentSize( pp );
|
||||
}
|
||||
|
||||
void CInterfaceElement::getSizeParent( std::string &id ) const
|
||||
{
|
||||
CInterfaceElement *p = getParentSize();
|
||||
|
||||
// If there's no parent set then the size parent is the parent
|
||||
if( p == NULL )
|
||||
{
|
||||
id = "parent";
|
||||
return;
|
||||
}
|
||||
|
||||
// If the size parent is the same as the group parent, then the size parent is the parent ofc
|
||||
if( p == getParent() )
|
||||
{
|
||||
id = "parent";
|
||||
return;
|
||||
}
|
||||
|
||||
// If the size parent is in the parent group, use the short Id
|
||||
if( p->isInGroup( getParent() ) )
|
||||
{
|
||||
id = p->getShortId();
|
||||
return;
|
||||
}
|
||||
|
||||
// Otherwise use the full Id
|
||||
id = p->getId();
|
||||
}
|
||||
|
||||
void CInterfaceElement::registerDeletionWatcher( IDeletionWatcher *watcher )
|
||||
|
|
|
@ -37,6 +37,7 @@
|
|||
#include "nel/gui/lua_helper.h"
|
||||
#include "nel/gui/lua_ihm.h"
|
||||
#include "nel/gui/lua_manager.h"
|
||||
#include "nel/gui/root_group.h"
|
||||
|
||||
#ifdef LUA_NEVRAX_VERSION
|
||||
#include "lua_ide_dll_nevrax/include/lua_ide_dll/ide_interface.h" // external debugger
|
||||
|
@ -113,86 +114,6 @@ namespace NLGUI
|
|||
return node;
|
||||
}
|
||||
|
||||
|
||||
|
||||
// ----------------------------------------------------------------------------
|
||||
// CRootGroup
|
||||
// ----------------------------------------------------------------------------
|
||||
|
||||
class CRootGroup : public CInterfaceGroup
|
||||
{
|
||||
public:
|
||||
CRootGroup(const TCtorParam ¶m)
|
||||
: CInterfaceGroup(param)
|
||||
{ }
|
||||
|
||||
/// Destructor
|
||||
virtual ~CRootGroup() { }
|
||||
|
||||
virtual CInterfaceElement* getElement (const std::string &id)
|
||||
{
|
||||
if (_Id == id)
|
||||
return this;
|
||||
|
||||
if (id.substr(0, _Id.size()) != _Id)
|
||||
return NULL;
|
||||
|
||||
vector<CViewBase*>::const_iterator itv;
|
||||
for (itv = _Views.begin(); itv != _Views.end(); itv++)
|
||||
{
|
||||
CViewBase *pVB = *itv;
|
||||
if (pVB->getId() == id)
|
||||
return pVB;
|
||||
}
|
||||
|
||||
vector<CCtrlBase*>::const_iterator itc;
|
||||
for (itc = _Controls.begin(); itc != _Controls.end(); itc++)
|
||||
{
|
||||
CCtrlBase* ctrl = *itc;
|
||||
if (ctrl->getId() == id)
|
||||
return ctrl;
|
||||
}
|
||||
|
||||
// Accelerate
|
||||
string sTmp = id;
|
||||
sTmp = sTmp.substr(_Id.size()+1,sTmp.size());
|
||||
string::size_type pos = sTmp.find(':');
|
||||
if (pos != string::npos)
|
||||
sTmp = sTmp.substr(0,pos);
|
||||
|
||||
map<string,CInterfaceGroup*>::iterator it = _Accel.find(sTmp);
|
||||
if (it != _Accel.end())
|
||||
{
|
||||
CInterfaceGroup *pIG = it->second;
|
||||
return pIG->getElement(id);
|
||||
}
|
||||
return NULL;
|
||||
}
|
||||
|
||||
virtual void addGroup (CInterfaceGroup *child, sint eltOrder = -1)
|
||||
{
|
||||
string sTmp = child->getId();
|
||||
sTmp = sTmp.substr(_Id.size()+1,sTmp.size());
|
||||
_Accel.insert(pair<string,CInterfaceGroup*>(sTmp, child));
|
||||
CInterfaceGroup::addGroup(child,eltOrder);
|
||||
}
|
||||
|
||||
virtual bool delGroup (CInterfaceGroup *child, bool dontDelete = false)
|
||||
{
|
||||
string sTmp = child->getId();
|
||||
sTmp = sTmp.substr(_Id.size()+1,sTmp.size());
|
||||
map<string,CInterfaceGroup*>::iterator it = _Accel.find(sTmp);
|
||||
if (it != _Accel.end())
|
||||
{
|
||||
_Accel.erase(it);
|
||||
}
|
||||
return CInterfaceGroup::delGroup(child,dontDelete);
|
||||
}
|
||||
|
||||
private:
|
||||
map<string,CInterfaceGroup*> _Accel;
|
||||
};
|
||||
|
||||
// ----------------------------------------------------------------------------
|
||||
// CInterfaceParser
|
||||
// ----------------------------------------------------------------------------
|
||||
|
@ -233,6 +154,22 @@ namespace NLGUI
|
|||
destStream.seek(0, NLMISC::IStream::begin);
|
||||
}
|
||||
|
||||
std::string CInterfaceParser::lookup( const std::string &file )
|
||||
{
|
||||
std::string filename;
|
||||
|
||||
if( editorMode && !_WorkDir.empty() )
|
||||
{
|
||||
std::string wdpath = CPath::standardizePath( _WorkDir ) + file;
|
||||
if( CFile::fileExists( wdpath ) )
|
||||
filename = wdpath;
|
||||
}
|
||||
if( filename.empty() )
|
||||
filename = CPath::lookup( file );
|
||||
|
||||
return filename;
|
||||
}
|
||||
|
||||
// ----------------------------------------------------------------------------
|
||||
bool CInterfaceParser::parseInterface (const std::vector<std::string> & strings, bool reload, bool isFilename, bool checkInData)
|
||||
{
|
||||
|
@ -270,7 +207,7 @@ namespace NLGUI
|
|||
{
|
||||
//get the first file document pointer
|
||||
firstFileName = *it;
|
||||
string filename = CPath::lookup(firstFileName);
|
||||
string filename = lookup( firstFileName );
|
||||
bool isInData = false;
|
||||
string::size_type pos = filename.find ("@");
|
||||
if (pos != string::npos)
|
||||
|
@ -283,7 +220,7 @@ namespace NLGUI
|
|||
isInData = true;
|
||||
}
|
||||
|
||||
if ((needCheck && !isInData) || !file.open (CPath::lookup(firstFileName)))
|
||||
if ((needCheck && !isInData) || !file.open (lookup(firstFileName)))
|
||||
{
|
||||
// todo hulud interface syntax error
|
||||
nlwarning ("could not open file %s, skipping xml parsing",firstFileName.c_str());
|
||||
|
@ -331,7 +268,7 @@ namespace NLGUI
|
|||
{
|
||||
saveParseResult = true;
|
||||
std::string archive = CPath::lookup(nextFileName + "_compressed", false, false);
|
||||
std::string current = CPath::lookup(nextFileName, false, false);
|
||||
std::string current = lookup(nextFileName);
|
||||
if (!archive.empty() && !current.empty())
|
||||
{
|
||||
if (CFile::getFileModificationDate(current) <= CFile::getFileModificationDate(archive))
|
||||
|
@ -351,7 +288,7 @@ namespace NLGUI
|
|||
{
|
||||
if (isFilename)
|
||||
{
|
||||
if (!file.open(CPath::lookup(nextFileName, false, false)))
|
||||
if (!file.open(lookup(nextFileName)))
|
||||
{
|
||||
// todo hulud interface syntax error
|
||||
nlwarning ("could not open file %s, skipping xml parsing",nextFileName.c_str());
|
||||
|
@ -3014,6 +2951,34 @@ namespace NLGUI
|
|||
itr->second = linkData;
|
||||
}
|
||||
|
||||
void CInterfaceParser::setVariable( const VariableData &v )
|
||||
{
|
||||
CInterfaceProperty prop;
|
||||
const std::string &type = v.type;
|
||||
const std::string &value = v.value;
|
||||
const std::string &entry = v.entry;
|
||||
|
||||
if( type == "sint64" )
|
||||
prop.readSInt64( value.c_str(), entry );
|
||||
else
|
||||
if( type == "sint32" )
|
||||
prop.readSInt32( value.c_str(), entry );
|
||||
else
|
||||
if( type == "float" || type == "double" )
|
||||
prop.readDouble( value.c_str(), entry );
|
||||
else
|
||||
if( type == "bool" )
|
||||
prop.readBool( value.c_str(), entry );
|
||||
else
|
||||
if( type == "rgba" )
|
||||
prop.readRGBA( value.c_str(), entry );
|
||||
else
|
||||
if( type == "hotspot" )
|
||||
prop.readHotSpot( value.c_str(), entry );
|
||||
|
||||
variableCache[ entry ] = v;
|
||||
}
|
||||
|
||||
|
||||
bool CInterfaceParser::serializeVariables( xmlNodePtr parentNode ) const
|
||||
{
|
||||
|
|
94
code/nel/src/gui/root_group.cpp
Normal file
94
code/nel/src/gui/root_group.cpp
Normal file
|
@ -0,0 +1,94 @@
|
|||
// Ryzom - MMORPG Framework <http://dev.ryzom.com/projects/ryzom/>
|
||||
// Copyright (C) 2010 Winch Gate Property Limited
|
||||
//
|
||||
// This program is free software: you can redistribute it and/or modify
|
||||
// it under the terms of the GNU Affero General Public License as
|
||||
// published by the Free Software Foundation, either version 3 of the
|
||||
// License, or (at your option) any later version.
|
||||
//
|
||||
// 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 Affero General Public License for more details.
|
||||
//
|
||||
// You should have received a copy of the GNU Affero General Public License
|
||||
// along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
|
||||
#include "nel/gui/root_group.h"
|
||||
#include <vector>
|
||||
|
||||
namespace NLGUI
|
||||
{
|
||||
|
||||
CRootGroup::CRootGroup(const TCtorParam ¶m) :
|
||||
CInterfaceGroup(param)
|
||||
{
|
||||
}
|
||||
|
||||
CRootGroup::~CRootGroup()
|
||||
{
|
||||
}
|
||||
|
||||
CInterfaceElement* CRootGroup::getElement (const std::string &id)
|
||||
{
|
||||
if (_Id == id)
|
||||
return this;
|
||||
|
||||
if (id.substr(0, _Id.size()) != _Id)
|
||||
return NULL;
|
||||
|
||||
std::vector<CViewBase*>::const_iterator itv;
|
||||
for (itv = _Views.begin(); itv != _Views.end(); itv++)
|
||||
{
|
||||
CViewBase *pVB = *itv;
|
||||
if (pVB->getId() == id)
|
||||
return pVB;
|
||||
}
|
||||
|
||||
std::vector<CCtrlBase*>::const_iterator itc;
|
||||
for (itc = _Controls.begin(); itc != _Controls.end(); itc++)
|
||||
{
|
||||
CCtrlBase* ctrl = *itc;
|
||||
if (ctrl->getId() == id)
|
||||
return ctrl;
|
||||
}
|
||||
|
||||
// Accelerate
|
||||
std::string sTmp = id;
|
||||
sTmp = sTmp.substr(_Id.size()+1,sTmp.size());
|
||||
std::string::size_type pos = sTmp.find(':');
|
||||
if (pos != std::string::npos)
|
||||
sTmp = sTmp.substr(0,pos);
|
||||
|
||||
std::map<std::string,CInterfaceGroup*>::iterator it = _Accel.find(sTmp);
|
||||
if (it != _Accel.end())
|
||||
{
|
||||
CInterfaceGroup *pIG = it->second;
|
||||
return pIG->getElement(id);
|
||||
}
|
||||
return NULL;
|
||||
}
|
||||
|
||||
void CRootGroup::addGroup (CInterfaceGroup *child, sint eltOrder)
|
||||
{
|
||||
std::string sTmp = child->getId();
|
||||
sTmp = sTmp.substr(_Id.size()+1,sTmp.size());
|
||||
_Accel.insert(std::pair<std::string,CInterfaceGroup*>(sTmp, child));
|
||||
CInterfaceGroup::addGroup(child,eltOrder);
|
||||
}
|
||||
|
||||
bool CRootGroup::delGroup (CInterfaceGroup *child, bool dontDelete)
|
||||
{
|
||||
std::string sTmp = child->getId();
|
||||
sTmp = sTmp.substr(_Id.size()+1,sTmp.size());
|
||||
std::map<std::string,CInterfaceGroup*>::iterator it = _Accel.find(sTmp);
|
||||
if (it != _Accel.end())
|
||||
{
|
||||
_Accel.erase(it);
|
||||
}
|
||||
return CInterfaceGroup::delGroup(child,dontDelete);
|
||||
}
|
||||
|
||||
}
|
||||
|
|
@ -35,6 +35,7 @@
|
|||
#include "nel/gui/reflect_register.h"
|
||||
#include "nel/gui/editor_selection_watcher.h"
|
||||
#include "nel/misc/events.h"
|
||||
#include "nel/gui/root_group.h"
|
||||
|
||||
namespace NLGUI
|
||||
{
|
||||
|
@ -1041,6 +1042,8 @@ namespace NLGUI
|
|||
resetGlobalAlphasProps();
|
||||
|
||||
activeAnims.clear();
|
||||
|
||||
editorSelection.clear();
|
||||
}
|
||||
|
||||
|
||||
|
@ -3604,6 +3607,68 @@ namespace NLGUI
|
|||
}
|
||||
|
||||
|
||||
bool CWidgetManager::createNewGUI( const std::string &project, const std::string &window )
|
||||
{
|
||||
reset();
|
||||
|
||||
for( int i = 0; i < _MasterGroups.size(); i++ )
|
||||
delete _MasterGroups[i].Group;
|
||||
_MasterGroups.clear();
|
||||
|
||||
// First create the master group
|
||||
CRootGroup *root = new CRootGroup( CViewBase::TCtorParam() );
|
||||
|
||||
SMasterGroup mg;
|
||||
mg.Group = root;
|
||||
|
||||
root->setIdRecurse( project );
|
||||
root->setW( 1024 );
|
||||
root->setH( 768 );
|
||||
root->setActive( true );
|
||||
|
||||
// Create the first / main window
|
||||
CInterfaceGroup *wnd = new CInterfaceGroup( CViewBase::TCtorParam() );
|
||||
wnd->setW( 1024 );
|
||||
wnd->setH( 768 );
|
||||
wnd->setParent( root );
|
||||
wnd->setParentPos( root );
|
||||
wnd->setParentSize( root );
|
||||
wnd->setPosRef( Hotspot_MM );
|
||||
wnd->setParentPosRef( Hotspot_MM );
|
||||
wnd->setIdRecurse( window );
|
||||
wnd->setActive( true );
|
||||
|
||||
// Add the window
|
||||
root->addElement( wnd );
|
||||
mg.addWindow( wnd, wnd->getPriority() );
|
||||
_MasterGroups.push_back( mg );
|
||||
|
||||
_Pointer = new CViewPointer( CViewBase::TCtorParam() );
|
||||
|
||||
IParser *parser = getParser();
|
||||
|
||||
|
||||
// Set base color to white
|
||||
VariableData v;
|
||||
v.type = "sint32";
|
||||
v.value = "255";
|
||||
|
||||
v.entry = "UI:SAVE:COLOR:R";
|
||||
parser->setVariable( v );
|
||||
|
||||
v.entry = "UI:SAVE:COLOR:G";
|
||||
parser->setVariable( v );
|
||||
|
||||
v.entry = "UI:SAVE:COLOR:B";
|
||||
parser->setVariable( v );
|
||||
|
||||
v.entry = "UI:SAVE:COLOR:A";
|
||||
parser->setVariable( v );
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
|
||||
CWidgetManager::CWidgetManager()
|
||||
{
|
||||
LinkHack();
|
||||
|
|
|
@ -36,6 +36,7 @@ SET(OVQT_PLUGIN_GUI_EDITOR_HDR
|
|||
texture_property_manager.h
|
||||
expression_editor.h
|
||||
expr_link_dlg.h
|
||||
new_gui_dlg.h
|
||||
)
|
||||
|
||||
SET(OVQT_PLUGIN_GUI_EDITOR_UIS
|
||||
|
@ -55,6 +56,7 @@ SET(OVQT_PLUGIN_GUI_EDITOR_UIS
|
|||
texture_chooser.ui
|
||||
expression_editor.ui
|
||||
expr_link_dlg.ui
|
||||
new_gui_dlg.ui
|
||||
)
|
||||
|
||||
SET(QT_USE_QTGUI TRUE)
|
||||
|
|
|
@ -44,6 +44,7 @@
|
|||
#include "editor_selection_watcher.h"
|
||||
#include "editor_message_processor.h"
|
||||
#include "add_widget_widget.h"
|
||||
#include "new_gui_dlg.h"
|
||||
|
||||
namespace GUIEditor
|
||||
{
|
||||
|
@ -181,6 +182,8 @@ namespace GUIEditor
|
|||
currentProject = projectFiles.projectName.c_str();
|
||||
currentProjectFile = fileName;
|
||||
projectWindow->setupFiles( projectFiles );
|
||||
GUICtrl->setWorkDir( _lastDir );
|
||||
|
||||
if( GUICtrl->parse( projectFiles ) )
|
||||
{
|
||||
hierarchyView->buildHierarchy( projectFiles.masterGroup );
|
||||
|
@ -197,6 +200,85 @@ namespace GUIEditor
|
|||
|
||||
void GUIEditorWindow::newDocument()
|
||||
{
|
||||
NewGUIDlg d;
|
||||
int result = d.exec();
|
||||
|
||||
if( result == QDialog::Rejected )
|
||||
return;
|
||||
|
||||
close();
|
||||
|
||||
std::string proj = d.getProjectName().toUtf8().constData();
|
||||
std::string wnd = d.getWindowName().toUtf8().constData();
|
||||
std::string mg = std::string( "ui:" ) + proj;
|
||||
std::string dir = d.getProjectDirectory().toUtf8().constData();
|
||||
_lastDir = dir.c_str();
|
||||
std::string uiFile = "ui_" + proj + ".xml";
|
||||
|
||||
QList< QString > mapList;
|
||||
d.getMapList( mapList );
|
||||
|
||||
bool b = GUICtrl->createNewGUI( proj, wnd );
|
||||
if( !b )
|
||||
{
|
||||
QMessageBox::information( this,
|
||||
tr( "Creating new GUI project" ),
|
||||
tr( "Failed to create new GUI project :(" ) );
|
||||
reset();
|
||||
return;
|
||||
}
|
||||
|
||||
hierarchyView->buildHierarchy( mg );
|
||||
|
||||
projectFiles.projectName = proj;
|
||||
projectFiles.masterGroup = mg;
|
||||
projectFiles.activeGroup = std::string( "ui:" ) + proj + ":" + wnd;
|
||||
projectFiles.version = SProjectFiles::NEW;
|
||||
projectFiles.guiFiles.push_back( uiFile );
|
||||
|
||||
for( int i = 0; i < mapList.size(); i++ )
|
||||
{
|
||||
projectFiles.mapFiles.push_back( mapList[ i ].toUtf8().constData() );
|
||||
}
|
||||
|
||||
b = GUICtrl->loadMapFiles( projectFiles.mapFiles );
|
||||
if( !b )
|
||||
{
|
||||
QMessageBox::information( this,
|
||||
tr( "Creating new GUI project" ),
|
||||
tr( "Failed to create new GUI project: Couldn't load map files. " ) );
|
||||
reset();
|
||||
return;
|
||||
}
|
||||
|
||||
projectWindow->setupFiles( projectFiles );
|
||||
|
||||
currentProject = proj.c_str();
|
||||
currentProjectFile = std::string( dir + "/" + proj + ".xml" ).c_str();
|
||||
|
||||
|
||||
// Save the project file
|
||||
CProjectFileSerializer serializer;
|
||||
serializer.setFile( currentProjectFile.toUtf8().constData() );
|
||||
if( !serializer.serialize( projectFiles ) )
|
||||
{
|
||||
QMessageBox::critical( this,
|
||||
tr( "Failed to save project" ),
|
||||
tr( "There was an error while trying to save the project." ) );
|
||||
return;
|
||||
}
|
||||
|
||||
// Save the GUI file
|
||||
WidgetSerializer widgetSerializer;
|
||||
widgetSerializer.setFile( dir + "/" + uiFile );
|
||||
widgetSerializer.setActiveGroup( projectFiles.activeGroup );
|
||||
if( !widgetSerializer.serialize( projectFiles.masterGroup ) )
|
||||
{
|
||||
QMessageBox::critical( this,
|
||||
tr( "Failed to save project" ),
|
||||
tr( "There was an error while trying to save the project." ) );
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
void GUIEditorWindow::save()
|
||||
|
@ -217,8 +299,23 @@ namespace GUIEditor
|
|||
// Can't save old projects any further, since the widgets are in multiple files in them
|
||||
// using templates, styles and whatnot. There's no way to restore the original XML structure
|
||||
// after it's loaded
|
||||
if( projectParser.getProjectVersion() == OLD )
|
||||
if( projectFiles.version == SProjectFiles::OLD )
|
||||
return;
|
||||
|
||||
std::string f = _lastDir.toUtf8().constData();
|
||||
f += "/";
|
||||
f += projectFiles.guiFiles[ 0 ];
|
||||
|
||||
WidgetSerializer widgetSerializer;
|
||||
widgetSerializer.setFile( f );
|
||||
widgetSerializer.setActiveGroup( projectFiles.activeGroup );
|
||||
if( !widgetSerializer.serialize( projectFiles.masterGroup ) )
|
||||
{
|
||||
QMessageBox::critical( this,
|
||||
tr( "Failed to save project" ),
|
||||
tr( "There was an error while trying to save the project." ) );
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
void GUIEditorWindow::saveAs()
|
||||
|
@ -231,42 +328,36 @@ namespace GUIEditor
|
|||
|
||||
if( dir.isEmpty() )
|
||||
return;
|
||||
_lastDir = dir;
|
||||
|
||||
projectFiles.guiFiles.clear();
|
||||
projectFiles.guiFiles.push_back( "ui_" + projectFiles.projectName + ".xml" );
|
||||
projectFiles.version = NEW;
|
||||
|
||||
QString newFile =
|
||||
dir + "/" + projectFiles.projectName.c_str() + ".xml";
|
||||
|
||||
CProjectFileSerializer serializer;
|
||||
serializer.setFile( newFile.toUtf8().constData() );
|
||||
if( !serializer.serialize( projectFiles ) )
|
||||
if( projectFiles.version == SProjectFiles::OLD )
|
||||
{
|
||||
QMessageBox::critical( this,
|
||||
tr( "Failed to save project" ),
|
||||
tr( "There was an error while trying to save the project." ) );
|
||||
return;
|
||||
projectFiles.guiFiles.clear();
|
||||
projectFiles.guiFiles.push_back( "ui_" + projectFiles.projectName + ".xml" );
|
||||
projectFiles.version = SProjectFiles::NEW;
|
||||
|
||||
}
|
||||
|
||||
std::string guiFile =
|
||||
std::string( dir.toUtf8().constData() ) + "/" + "ui_" + projectFiles.projectName + ".xml";
|
||||
currentProjectFile = _lastDir;
|
||||
currentProjectFile += "/";
|
||||
currentProjectFile += projectFiles.projectName.c_str();
|
||||
currentProjectFile += ".xml";
|
||||
|
||||
WidgetSerializer widgetSerializer;
|
||||
widgetSerializer.setFile( guiFile );
|
||||
widgetSerializer.setActiveGroup( projectFiles.activeGroup );
|
||||
if( !widgetSerializer.serialize( projectFiles.masterGroup ) )
|
||||
{
|
||||
QMessageBox::critical( this,
|
||||
tr( "Failed to save project" ),
|
||||
tr( "There was an error while trying to save the project." ) );
|
||||
return;
|
||||
}
|
||||
|
||||
QMessageBox::information( this,
|
||||
tr( "Save successful" ),
|
||||
tr( "Project saved successfully!" ) );
|
||||
save();
|
||||
}
|
||||
|
||||
void GUIEditorWindow::reset()
|
||||
{
|
||||
projectFiles.clearAll();
|
||||
projectWindow->clear();
|
||||
hierarchyView->clearHierarchy();
|
||||
GUICtrl->reset();
|
||||
browserCtrl.clear();
|
||||
linkList->clear();
|
||||
procList->clear();
|
||||
currentProject = "";
|
||||
currentProjectFile = "";
|
||||
projectParser.clear();
|
||||
}
|
||||
|
||||
bool GUIEditorWindow::close()
|
||||
|
@ -286,16 +377,7 @@ namespace GUIEditor
|
|||
disconnect( w, SIGNAL( sgnSelectionChanged() ), hierarchyView, SLOT( onSelectionChanged() ) );
|
||||
disconnect( w, SIGNAL( sgnSelectionChanged() ), &browserCtrl, SLOT( onSelectionChanged() ) );
|
||||
|
||||
projectFiles.clearAll();
|
||||
projectWindow->clear();
|
||||
hierarchyView->clearHierarchy();
|
||||
GUICtrl->reset();
|
||||
browserCtrl.clear();
|
||||
linkList->clear();
|
||||
procList->clear();
|
||||
currentProject = "";
|
||||
currentProjectFile = "";
|
||||
projectParser.clear();
|
||||
reset();
|
||||
|
||||
return true;
|
||||
}
|
||||
|
@ -356,14 +438,14 @@ namespace GUIEditor
|
|||
void GUIEditorWindow::createMenus()
|
||||
{
|
||||
Core::MenuManager *mm = Core::ICore::instance()->menuManager();
|
||||
//QAction *newAction = mm->action( Core::Constants::NEW );
|
||||
QAction *newAction = mm->action( Core::Constants::NEW );
|
||||
QAction *saveAction = mm->action( Core::Constants::SAVE );
|
||||
QAction *saveAsAction = mm->action( Core::Constants::SAVE_AS );
|
||||
QAction *closeAction = mm->action( Core::Constants::CLOSE );
|
||||
QAction *delAction = mm->action( Core::Constants::DEL );
|
||||
|
||||
//if( newAction != NULL )
|
||||
// newAction->setEnabled( true );
|
||||
if( newAction != NULL )
|
||||
newAction->setEnabled( true );
|
||||
if( saveAction != NULL )
|
||||
saveAction->setEnabled( true );
|
||||
if( saveAsAction != NULL )
|
||||
|
|
|
@ -70,6 +70,7 @@ protected:
|
|||
void showEvent( QShowEvent *evnt );
|
||||
|
||||
private:
|
||||
void reset();
|
||||
void createMenus();
|
||||
void removeMenus();
|
||||
|
||||
|
|
|
@ -89,20 +89,8 @@ namespace GUIEditor
|
|||
reset();
|
||||
IParser *parser = CWidgetManager::getInstance()->getParser();
|
||||
|
||||
std::vector< std::string >::iterator itr;
|
||||
for( itr = files.mapFiles.begin(); itr != files.mapFiles.end(); ++itr )
|
||||
{
|
||||
std::string &file = *itr;
|
||||
std::string::size_type i = file.find_last_of( '.' );
|
||||
std::string mapFile = file.substr( 0, i );
|
||||
mapFile.append( ".txt" );
|
||||
|
||||
if( !CViewRenderer::getInstance()->loadTextures( file, mapFile, false ) )
|
||||
{
|
||||
CViewRenderer::getInstance()->reset();
|
||||
return false;
|
||||
}
|
||||
}
|
||||
if( !loadMapFiles( files.mapFiles ) )
|
||||
return false;
|
||||
|
||||
if( !parser->parseInterface( files.guiFiles, false ) )
|
||||
return false;
|
||||
|
@ -114,11 +102,49 @@ namespace GUIEditor
|
|||
if( e != NULL )
|
||||
e->setActive( true );
|
||||
|
||||
timerID = startTimer( 200 );
|
||||
guiLoaded = true;
|
||||
Q_EMIT guiLoadComplete();
|
||||
onGUILoaded();
|
||||
|
||||
CWidgetManager::getInstance()->registerSelectionWatcher( watcher );
|
||||
return true;
|
||||
}
|
||||
|
||||
bool NelGUICtrl::loadMapFiles( const std::vector< std::string > &v )
|
||||
{
|
||||
std::vector< std::string >::const_iterator itr;
|
||||
for( itr = v.begin(); itr != v.end(); ++itr )
|
||||
{
|
||||
const std::string &file = *itr;
|
||||
std::string::size_type i = file.find_last_of( '.' );
|
||||
std::string mapFile = file.substr( 0, i );
|
||||
mapFile.append( ".txt" );
|
||||
|
||||
if( !CViewRenderer::getInstance()->loadTextures( file, mapFile, false ) )
|
||||
{
|
||||
CViewRenderer::getInstance()->reset();
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
bool NelGUICtrl::createNewGUI( const std::string &project, const std::string &window )
|
||||
{
|
||||
reset();
|
||||
bool ok = CWidgetManager::getInstance()->createNewGUI( project, window );
|
||||
if( !ok )
|
||||
return false;
|
||||
|
||||
std::string mg = std::string( "ui:" ) + project;
|
||||
std::string ag = mg + ":" + window;
|
||||
|
||||
CWidgetManager::getInstance()->updateAllLocalisedElements();
|
||||
CWidgetManager::getInstance()->activateMasterGroup( mg, true );
|
||||
|
||||
CInterfaceElement *e = CWidgetManager::getInstance()->getElementFromId( ag );
|
||||
if( e != NULL )
|
||||
e->setActive( true );
|
||||
|
||||
onGUILoaded();
|
||||
|
||||
return true;
|
||||
}
|
||||
|
@ -160,6 +186,15 @@ namespace GUIEditor
|
|||
}
|
||||
}
|
||||
|
||||
void NelGUICtrl::onGUILoaded()
|
||||
{
|
||||
timerID = startTimer( 200 );
|
||||
guiLoaded = true;
|
||||
Q_EMIT guiLoadComplete();
|
||||
|
||||
CWidgetManager::getInstance()->registerSelectionWatcher( watcher );
|
||||
}
|
||||
|
||||
void NelGUICtrl::show()
|
||||
{
|
||||
if( timerID == 0 )
|
||||
|
@ -187,6 +222,12 @@ namespace GUIEditor
|
|||
}
|
||||
}
|
||||
|
||||
void NelGUICtrl::setWorkDir( const QString &dir )
|
||||
{
|
||||
IParser *parser = CWidgetManager::getInstance()->getParser();
|
||||
parser->setWorkDir( std::string( dir.toUtf8().constData() ) );
|
||||
}
|
||||
|
||||
QWidget* NelGUICtrl::getViewPort()
|
||||
{
|
||||
return w;
|
||||
|
|
|
@ -43,6 +43,8 @@ namespace GUIEditor
|
|||
|
||||
void init();
|
||||
bool parse( SProjectFiles &files );
|
||||
bool loadMapFiles( const std::vector< std::string > &v );
|
||||
bool createNewGUI( const std::string &project, const std::string &window );
|
||||
void draw();
|
||||
void reset();
|
||||
CEditorSelectionWatcher* getWatcher(){ return watcher; }
|
||||
|
@ -52,6 +54,8 @@ namespace GUIEditor
|
|||
void show();
|
||||
void hide();
|
||||
|
||||
void setWorkDir( const QString &dir );
|
||||
|
||||
Q_SIGNALS:
|
||||
void guiLoadComplete();
|
||||
|
||||
|
@ -59,6 +63,8 @@ Q_SIGNALS:
|
|||
void timerEvent( QTimerEvent *evnt );
|
||||
|
||||
private:
|
||||
void onGUILoaded();
|
||||
|
||||
int timerID;
|
||||
bool guiLoaded;
|
||||
CEditorSelectionWatcher *watcher;
|
||||
|
|
135
code/studio/src/plugins/gui_editor/new_gui_dlg.cpp
Normal file
135
code/studio/src/plugins/gui_editor/new_gui_dlg.cpp
Normal file
|
@ -0,0 +1,135 @@
|
|||
// Ryzom Core Studio - GUI Editor Plugin
|
||||
//
|
||||
// Copyright (C) 2014 Laszlo Kis-Adam
|
||||
// Copyright (C) 2010 Ryzom Core <http://ryzomcore.org/>
|
||||
//
|
||||
// This program is free software: you can redistribute it and/or modify
|
||||
// it under the terms of the GNU Affero General Public License as
|
||||
// published by the Free Software Foundation, either version 3 of the
|
||||
// License, or (at your option) any later version.
|
||||
//
|
||||
// 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 Affero General Public License for more details.
|
||||
//
|
||||
// You should have received a copy of the GNU Affero General Public License
|
||||
// along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
#include "new_gui_dlg.h"
|
||||
#include <QMessageBox>
|
||||
#include <QFileDialog>
|
||||
|
||||
NewGUIDlg::NewGUIDlg( QWidget *parent ) :
|
||||
QDialog( parent )
|
||||
{
|
||||
m_ui.setupUi( this );
|
||||
|
||||
connect( m_ui.okButton, SIGNAL( clicked( bool ) ), this, SLOT( onOKClicked() ) );
|
||||
connect( m_ui.cancelButton, SIGNAL( clicked( bool ) ), this, SLOT( onCancelClicked() ) );
|
||||
connect( m_ui.projectDirTB, SIGNAL( clicked( bool ) ), this, SLOT( onProjectDirTBClicked() ) );
|
||||
connect( m_ui.addButton, SIGNAL( clicked( bool ) ), this, SLOT( onAddClicked() ) );
|
||||
connect( m_ui.removeButton, SIGNAL( clicked( bool ) ), this, SLOT( onRemoveClicked() ) );
|
||||
|
||||
}
|
||||
|
||||
NewGUIDlg::~NewGUIDlg()
|
||||
{
|
||||
}
|
||||
|
||||
QString NewGUIDlg::getProjectName() const
|
||||
{
|
||||
return m_ui.projectEdit->text();
|
||||
}
|
||||
|
||||
QString NewGUIDlg::getWindowName() const
|
||||
{
|
||||
return m_ui.windowEdit->text();
|
||||
}
|
||||
|
||||
QString NewGUIDlg::getProjectDirectory() const
|
||||
{
|
||||
return m_ui.projectDirEdit->text();
|
||||
}
|
||||
|
||||
void NewGUIDlg::getMapList( QList< QString > &l )
|
||||
{
|
||||
l.clear();
|
||||
|
||||
for( int i = 0; i < m_ui.mapList->count(); i++ )
|
||||
{
|
||||
l.push_back( m_ui.mapList->item( i )->text() );
|
||||
}
|
||||
}
|
||||
|
||||
void NewGUIDlg::onOKClicked()
|
||||
{
|
||||
if( m_ui.projectEdit->text().isEmpty() )
|
||||
{
|
||||
QMessageBox::information( this,
|
||||
tr( "New project" ),
|
||||
tr( "You must specify a project name!" ) );
|
||||
return;
|
||||
}
|
||||
|
||||
if( m_ui.windowEdit->text().isEmpty() )
|
||||
{
|
||||
QMessageBox::information( this,
|
||||
tr( "New project" ),
|
||||
tr( "You must specify a window name!" ) );
|
||||
return;
|
||||
}
|
||||
|
||||
if( m_ui.projectDirEdit->text().isEmpty() )
|
||||
{
|
||||
QMessageBox::information( this,
|
||||
tr( "New project" ),
|
||||
tr( "You must specify a project directory!" ) );
|
||||
return;
|
||||
}
|
||||
|
||||
accept();
|
||||
}
|
||||
|
||||
void NewGUIDlg::onCancelClicked()
|
||||
{
|
||||
reject();
|
||||
}
|
||||
|
||||
void NewGUIDlg::onProjectDirTBClicked()
|
||||
{
|
||||
QString dir = QFileDialog::getExistingDirectory( this,
|
||||
tr( "Specify project directory" ),
|
||||
"." );
|
||||
if( dir.isEmpty() )
|
||||
return;
|
||||
|
||||
m_ui.projectDirEdit->setText( dir );
|
||||
}
|
||||
|
||||
void NewGUIDlg::onAddClicked()
|
||||
{
|
||||
if( m_ui.mapEdit->text().isEmpty() )
|
||||
return;
|
||||
|
||||
QList< QListWidgetItem* > l = m_ui.mapList->findItems( m_ui.mapEdit->text(), Qt::MatchContains );
|
||||
if( !l.isEmpty() )
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
m_ui.mapList->addItem( m_ui.mapEdit->text() );
|
||||
m_ui.mapEdit->clear();
|
||||
}
|
||||
|
||||
void NewGUIDlg::onRemoveClicked()
|
||||
{
|
||||
QListWidgetItem *item = m_ui.mapList->currentItem();
|
||||
if( item == NULL )
|
||||
return;
|
||||
|
||||
delete item;
|
||||
}
|
||||
|
||||
|
||||
|
50
code/studio/src/plugins/gui_editor/new_gui_dlg.h
Normal file
50
code/studio/src/plugins/gui_editor/new_gui_dlg.h
Normal file
|
@ -0,0 +1,50 @@
|
|||
// Ryzom Core Studio - GUI Editor Plugin
|
||||
//
|
||||
// Copyright (C) 2014 Laszlo Kis-Adam
|
||||
// Copyright (C) 2010 Ryzom Core <http://ryzomcore.org/>
|
||||
//
|
||||
// This program is free software: you can redistribute it and/or modify
|
||||
// it under the terms of the GNU Affero General Public License as
|
||||
// published by the Free Software Foundation, either version 3 of the
|
||||
// License, or (at your option) any later version.
|
||||
//
|
||||
// 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 Affero General Public License for more details.
|
||||
//
|
||||
// You should have received a copy of the GNU Affero General Public License
|
||||
// along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
#ifndef NEW_GUI_DLG_H
|
||||
#define NEW_GUI_DLG_H
|
||||
|
||||
#include "ui_new_gui_dlg.h"
|
||||
#include <QList>
|
||||
|
||||
class NewGUIDlg : public QDialog
|
||||
{
|
||||
Q_OBJECT
|
||||
|
||||
public:
|
||||
NewGUIDlg( QWidget *parent = NULL );
|
||||
~NewGUIDlg();
|
||||
|
||||
QString getProjectName() const;
|
||||
QString getWindowName() const;
|
||||
QString getProjectDirectory() const;
|
||||
void getMapList( QList< QString > &l );
|
||||
|
||||
private Q_SLOTS:
|
||||
void onOKClicked();
|
||||
void onCancelClicked();
|
||||
void onProjectDirTBClicked();
|
||||
void onAddClicked();
|
||||
void onRemoveClicked();
|
||||
|
||||
private:
|
||||
Ui::NewGUIDialog m_ui;
|
||||
};
|
||||
|
||||
#endif
|
||||
|
130
code/studio/src/plugins/gui_editor/new_gui_dlg.ui
Normal file
130
code/studio/src/plugins/gui_editor/new_gui_dlg.ui
Normal file
|
@ -0,0 +1,130 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<ui version="4.0">
|
||||
<class>NewGUIDialog</class>
|
||||
<widget class="QDialog" name="NewGUIDialog">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>0</x>
|
||||
<y>0</y>
|
||||
<width>399</width>
|
||||
<height>354</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="windowTitle">
|
||||
<string>New GUI</string>
|
||||
</property>
|
||||
<layout class="QGridLayout" name="gridLayout_2">
|
||||
<item row="0" column="0">
|
||||
<widget class="QLabel" name="label">
|
||||
<property name="text">
|
||||
<string>Project name</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="0" column="1" colspan="2">
|
||||
<widget class="QLineEdit" name="projectEdit"/>
|
||||
</item>
|
||||
<item row="1" column="0">
|
||||
<widget class="QLabel" name="label_2">
|
||||
<property name="text">
|
||||
<string>Window name</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="1" column="1" colspan="2">
|
||||
<widget class="QLineEdit" name="windowEdit"/>
|
||||
</item>
|
||||
<item row="2" column="0">
|
||||
<widget class="QLabel" name="label_3">
|
||||
<property name="text">
|
||||
<string>Project directory</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="2" column="1" colspan="2">
|
||||
<widget class="QLineEdit" name="projectDirEdit"/>
|
||||
</item>
|
||||
<item row="2" column="3">
|
||||
<widget class="QToolButton" name="projectDirTB">
|
||||
<property name="text">
|
||||
<string>...</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="3" column="0" colspan="4">
|
||||
<widget class="QGroupBox" name="groupBox">
|
||||
<property name="title">
|
||||
<string>Map files</string>
|
||||
</property>
|
||||
<layout class="QGridLayout" name="gridLayout">
|
||||
<item row="0" column="1">
|
||||
<widget class="QPushButton" name="addButton">
|
||||
<property name="text">
|
||||
<string>Add</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="0" column="0">
|
||||
<widget class="QLineEdit" name="mapEdit"/>
|
||||
</item>
|
||||
<item row="1" column="1">
|
||||
<widget class="QPushButton" name="removeButton">
|
||||
<property name="text">
|
||||
<string>Remove</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="1" column="0" rowspan="2">
|
||||
<widget class="QListWidget" name="mapList"/>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="4" column="0" colspan="2">
|
||||
<spacer name="horizontalSpacer">
|
||||
<property name="orientation">
|
||||
<enum>Qt::Horizontal</enum>
|
||||
</property>
|
||||
<property name="sizeHint" stdset="0">
|
||||
<size>
|
||||
<width>107</width>
|
||||
<height>20</height>
|
||||
</size>
|
||||
</property>
|
||||
</spacer>
|
||||
</item>
|
||||
<item row="4" column="2" colspan="2">
|
||||
<layout class="QHBoxLayout" name="horizontalLayout">
|
||||
<item>
|
||||
<widget class="QPushButton" name="okButton">
|
||||
<property name="sizePolicy">
|
||||
<sizepolicy hsizetype="Fixed" vsizetype="Fixed">
|
||||
<horstretch>0</horstretch>
|
||||
<verstretch>0</verstretch>
|
||||
</sizepolicy>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>OK</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QPushButton" name="cancelButton">
|
||||
<property name="sizePolicy">
|
||||
<sizepolicy hsizetype="Fixed" vsizetype="Fixed">
|
||||
<horstretch>0</horstretch>
|
||||
<verstretch>0</verstretch>
|
||||
</sizepolicy>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Cancel</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
<resources/>
|
||||
<connections/>
|
||||
</ui>
|
|
@ -16,6 +16,7 @@
|
|||
|
||||
|
||||
#include "project_file_parser.h"
|
||||
#include "nel/misc/debug.h"
|
||||
|
||||
namespace GUIEditor
|
||||
{
|
||||
|
@ -57,12 +58,13 @@ namespace GUIEditor
|
|||
projectFiles.projectName = files.projectName;
|
||||
projectFiles.masterGroup = files.masterGroup;
|
||||
projectFiles.activeGroup = files.activeGroup;
|
||||
projectFiles.version = files.version;
|
||||
}
|
||||
|
||||
unsigned long CProjectFileParser::getProjectVersion() const
|
||||
{
|
||||
if( !loaded )
|
||||
return OLD;
|
||||
return SProjectFiles::OLD;
|
||||
|
||||
return files.version;
|
||||
}
|
||||
|
@ -70,7 +72,7 @@ namespace GUIEditor
|
|||
void CProjectFileParser::clear()
|
||||
{
|
||||
files.projectName = "";
|
||||
files.version = OLD;
|
||||
files.version = SProjectFiles::OLD;
|
||||
files.activeGroup = "";
|
||||
files.guiFiles.clear();
|
||||
files.mapFiles.clear();
|
||||
|
@ -208,7 +210,9 @@ namespace GUIEditor
|
|||
reader.readNext();
|
||||
}
|
||||
if( files.mapFiles.empty() )
|
||||
return false;
|
||||
{
|
||||
nlinfo( "No map file(s) specified in project file." );
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
|
|
|
@ -25,7 +25,7 @@ namespace GUIEditor
|
|||
if( fileName.empty() )
|
||||
return false;
|
||||
|
||||
if( project.version >= MAX_PROJECTFILE_VERSION )
|
||||
if( project.version >= SProjectFiles::MAX_PROJECTFILE_VERSION )
|
||||
return false;
|
||||
|
||||
out.open( fileName.c_str() );
|
||||
|
|
|
@ -23,16 +23,17 @@
|
|||
|
||||
namespace GUIEditor
|
||||
{
|
||||
enum ProjectVersion
|
||||
{
|
||||
OLD = 0,
|
||||
NEW = 1,
|
||||
MAX_PROJECTFILE_VERSION
|
||||
};
|
||||
|
||||
struct SProjectFiles
|
||||
{
|
||||
public:
|
||||
|
||||
enum ProjectVersion
|
||||
{
|
||||
OLD = 0,
|
||||
NEW = 1,
|
||||
MAX_PROJECTFILE_VERSION
|
||||
};
|
||||
|
||||
std::string projectName;
|
||||
unsigned long version;
|
||||
std::string masterGroup;
|
||||
|
|
|
@ -728,9 +728,6 @@ namespace GUIEditor
|
|||
{
|
||||
std::string j = element->getProperty( prop.propName );
|
||||
|
||||
if( j.empty() )
|
||||
return;
|
||||
|
||||
QtProperty *pp = actionMgr->addProperty( prop.propName.c_str() );
|
||||
if( pp == NULL )
|
||||
return;
|
||||
|
|
|
@ -93,8 +93,6 @@ namespace GUIEditor
|
|||
return false;
|
||||
}
|
||||
|
||||
ag->setActive( false );
|
||||
|
||||
if( mg->serializeSubGroups( root ) == NULL )
|
||||
{
|
||||
ag->setActive( true );
|
||||
|
@ -103,8 +101,6 @@ namespace GUIEditor
|
|||
return false;
|
||||
}
|
||||
|
||||
ag->setActive( true );
|
||||
|
||||
if( !mg->serializeLinks( root ) )
|
||||
{
|
||||
xmlFreeNode( root );
|
||||
|
|
|
@ -2,6 +2,7 @@
|
|||
<header>
|
||||
<name>CtrlButton</name>
|
||||
<guiname>CCtrlButton</guiname>
|
||||
<classname>button</classname>
|
||||
<ancestor>CtrlBaseButton</ancestor>
|
||||
<description></description>
|
||||
<abstract>false</abstract>
|
||||
|
|
|
@ -2,6 +2,7 @@
|
|||
<header>
|
||||
<name>CtrlColPick</name>
|
||||
<guiname>CCtrlColPick</guiname>
|
||||
<classname>colpick</classname>
|
||||
<ancestor>CtrlBase</ancestor>
|
||||
<description></description>
|
||||
<abstract>false</abstract>
|
||||
|
|
|
@ -2,6 +2,7 @@
|
|||
<header>
|
||||
<name>CtrlScroll</name>
|
||||
<guiname>CCtrlScroll</guiname>
|
||||
<classname>scroll</classname>
|
||||
<ancestor>CtrlBase</ancestor>
|
||||
<description></description>
|
||||
<abstract>false</abstract>
|
||||
|
|
|
@ -2,6 +2,7 @@
|
|||
<header>
|
||||
<name>CtrlTextButton</name>
|
||||
<guiname>CCtrlTextButton</guiname>
|
||||
<classname>text_button</classname>
|
||||
<ancestor>CtrlBaseButton</ancestor>
|
||||
<description></description>
|
||||
<abstract>false</abstract>
|
||||
|
@ -11,22 +12,22 @@
|
|||
<property>
|
||||
<name>tx_normal</name>
|
||||
<type>string</type>
|
||||
<default></default>
|
||||
<default>but</default>
|
||||
</property>
|
||||
<property>
|
||||
<name>tx_pushed</name>
|
||||
<type>string</type>
|
||||
<default></default>
|
||||
<default>but</default>
|
||||
</property>
|
||||
<property>
|
||||
<name>tx_over</name>
|
||||
<type>string</type>
|
||||
<default></default>
|
||||
<default>but_over</default>
|
||||
</property>
|
||||
<property>
|
||||
<name>hardtext</name>
|
||||
<type>string</type>
|
||||
<default></default>
|
||||
<default>push me</default>
|
||||
</property>
|
||||
<property>
|
||||
<name>wmargin</name>
|
||||
|
@ -156,7 +157,7 @@
|
|||
<property>
|
||||
<name>line_maxw</name>
|
||||
<type>int</type>
|
||||
<default>0</default>
|
||||
<default>100</default>
|
||||
</property>
|
||||
<property>
|
||||
<name>multi_line_space</name>
|
||||
|
|
|
@ -2,6 +2,7 @@
|
|||
<header>
|
||||
<name>DBGroupSelectNumber</name>
|
||||
<guiname>CDBGroupSelectNumber</guiname>
|
||||
<classname>select_number</classname>
|
||||
<ancestor>InterfaceGroup</ancestor>
|
||||
<description></description>
|
||||
<abstract>false</abstract>
|
||||
|
|
|
@ -2,6 +2,7 @@
|
|||
<header>
|
||||
<name>DBViewBar</name>
|
||||
<guiname>CDBViewBar</guiname>
|
||||
<classname>bar</classname>
|
||||
<ancestor>ViewBitmap</ancestor>
|
||||
<description></description>
|
||||
<abstract>false</abstract>
|
||||
|
|
|
@ -2,6 +2,7 @@
|
|||
<header>
|
||||
<name>DBViewBar3</name>
|
||||
<guiname>CDBViewBar3</guiname>
|
||||
<classname>bar3</classname>
|
||||
<ancestor>ViewBitmap</ancestor>
|
||||
<description></description>
|
||||
<abstract>false</abstract>
|
||||
|
|
|
@ -2,6 +2,7 @@
|
|||
<header>
|
||||
<name>DBViewDigit</name>
|
||||
<guiname>CDBViewDigit</guiname>
|
||||
<classname>digit</classname>
|
||||
<ancestor>CtrlBase</ancestor>
|
||||
<description></description>
|
||||
<abstract>false</abstract>
|
||||
|
|
|
@ -2,6 +2,7 @@
|
|||
<header>
|
||||
<name>DBViewNumber</name>
|
||||
<guiname>CDBViewNumber</guiname>
|
||||
<classname>text_number</classname>
|
||||
<ancestor>ViewText</ancestor>
|
||||
<description></description>
|
||||
<abstract>false</abstract>
|
||||
|
|
|
@ -2,6 +2,7 @@
|
|||
<header>
|
||||
<name>DBViewQuantity</name>
|
||||
<guiname>CDBViewQuantity</guiname>
|
||||
<classname>text_quantity</classname>
|
||||
<ancestor>ViewText</ancestor>
|
||||
<description></description>
|
||||
<abstract>false</abstract>
|
||||
|
|
|
@ -2,6 +2,7 @@
|
|||
<header>
|
||||
<name>GroupContainer</name>
|
||||
<guiname>CGroupContainer</guiname>
|
||||
<classname>container</classname>
|
||||
<ancestor>InterfaceGroup</ancestor>
|
||||
<description></description>
|
||||
<abstract>false</abstract>
|
||||
|
|
|
@ -2,6 +2,7 @@
|
|||
<header>
|
||||
<name>GroupEditBox</name>
|
||||
<guiname>CGroupEditBox</guiname>
|
||||
<classname>edit_box</classname>
|
||||
<ancestor>InterfaceGroup</ancestor>
|
||||
<description></description>
|
||||
<abstract>false</abstract>
|
||||
|
|
|
@ -2,6 +2,7 @@
|
|||
<header>
|
||||
<name>GroupHTML</name>
|
||||
<guiname>CGroupHTML</guiname>
|
||||
<classname>html</classname>
|
||||
<ancestor>GroupScrollText</ancestor>
|
||||
<description></description>
|
||||
<abstract>false</abstract>
|
||||
|
|
|
@ -2,6 +2,7 @@
|
|||
<header>
|
||||
<name>GroupHeader</name>
|
||||
<guiname>CGroupHeader</guiname>
|
||||
<classname>header</classname>
|
||||
<ancestor>GroupList</ancestor>
|
||||
<description></description>
|
||||
<abstract>false</abstract>
|
||||
|
|
|
@ -2,6 +2,7 @@
|
|||
<header>
|
||||
<name>GroupList</name>
|
||||
<guiname>CGroupList</guiname>
|
||||
<classname>list</classname>
|
||||
<ancestor>InterfaceGroup</ancestor>
|
||||
<description></description>
|
||||
<abstract>false</abstract>
|
||||
|
|
|
@ -2,6 +2,7 @@
|
|||
<header>
|
||||
<name>GroupMenu</name>
|
||||
<guiname>CGroupMenu</guiname>
|
||||
<classname>menu</classname>
|
||||
<ancestor>GroupModal</ancestor>
|
||||
<description></description>
|
||||
<abstract>false</abstract>
|
||||
|
|
|
@ -2,6 +2,7 @@
|
|||
<header>
|
||||
<name>GroupModal</name>
|
||||
<guiname>CGroupModal</guiname>
|
||||
<classname>modal</classname>
|
||||
<ancestor>GroupFrame</ancestor>
|
||||
<description></description>
|
||||
<abstract>false</abstract>
|
||||
|
|
|
@ -2,6 +2,7 @@
|
|||
<header>
|
||||
<name>GroupScrollText</name>
|
||||
<guiname>CGroupScrollText</guiname>
|
||||
<classname>scroll_text</classname>
|
||||
<ancestor>InterfaceGroup</ancestor>
|
||||
<description></description>
|
||||
<abstract>false</abstract>
|
||||
|
|
|
@ -2,6 +2,7 @@
|
|||
<header>
|
||||
<name>GroupTab</name>
|
||||
<guiname>CGroupTab</guiname>
|
||||
<classname>tab</classname>
|
||||
<ancestor>InterfaceGroup</ancestor>
|
||||
<description></description>
|
||||
<abstract>false</abstract>
|
||||
|
|
|
@ -2,6 +2,7 @@
|
|||
<header>
|
||||
<name>GroupTable</name>
|
||||
<guiname>CGroupTable</guiname>
|
||||
<classname>table</classname>
|
||||
<ancestor>InterfaceGroup</ancestor>
|
||||
<description></description>
|
||||
<abstract>false</abstract>
|
||||
|
|
|
@ -2,6 +2,7 @@
|
|||
<header>
|
||||
<name>GroupTree</name>
|
||||
<guiname>CGroupTree</guiname>
|
||||
<classname>tree</classname>
|
||||
<ancestor>InterfaceGroup</ancestor>
|
||||
<description></description>
|
||||
<abstract>false</abstract>
|
||||
|
|
|
@ -2,6 +2,7 @@
|
|||
<header>
|
||||
<name>InterfaceGroup</name>
|
||||
<guiname>CInterfaceGroup</guiname>
|
||||
<classname>interface_group</classname>
|
||||
<ancestor>CtrlBase</ancestor>
|
||||
<description></description>
|
||||
<abstract>false</abstract>
|
||||
|
|
|
@ -2,6 +2,7 @@
|
|||
<header>
|
||||
<name>InterfaceGroupWheel</name>
|
||||
<guiname>CInterfaceGroupWheel</guiname>
|
||||
<classname>group_wheel</classname>
|
||||
<ancestor>InterfaceGroup</ancestor>
|
||||
<description></description>
|
||||
<abstract>false</abstract>
|
||||
|
|
|
@ -2,6 +2,7 @@
|
|||
<header>
|
||||
<name>ViewBitmap</name>
|
||||
<guiname>CViewBitmap</guiname>
|
||||
<classname>bitmap</classname>
|
||||
<ancestor>CtrlBase</ancestor>
|
||||
<description></description>
|
||||
<abstract>false</abstract>
|
||||
|
|
|
@ -2,6 +2,7 @@
|
|||
<header>
|
||||
<name>ViewBitmapCombo</name>
|
||||
<guiname>CViewBitmapCombo</guiname>
|
||||
<classname>bitmap_combo</classname>
|
||||
<ancestor>CtrlBase</ancestor>
|
||||
<description></description>
|
||||
<abstract>false</abstract>
|
||||
|
|
|
@ -2,6 +2,7 @@
|
|||
<header>
|
||||
<name>ViewText</name>
|
||||
<guiname>CViewText</guiname>
|
||||
<classname>text</classname>
|
||||
<ancestor>InterfaceElement</ancestor>
|
||||
<description></description>
|
||||
<abstract>false</abstract>
|
||||
|
@ -46,7 +47,7 @@
|
|||
<property>
|
||||
<name>line_maxw</name>
|
||||
<type>int</type>
|
||||
<default>0</default>
|
||||
<default>100</default>
|
||||
</property>
|
||||
<property>
|
||||
<name>multi_line_space</name>
|
||||
|
@ -101,7 +102,7 @@
|
|||
<property>
|
||||
<name>hardtext</name>
|
||||
<type>string</type>
|
||||
<default></default>
|
||||
<default>Some text</default>
|
||||
</property>
|
||||
<property>
|
||||
<name>hardtext_format</name>
|
||||
|
|
|
@ -2,6 +2,7 @@
|
|||
<header>
|
||||
<name>ViewTextFormated</name>
|
||||
<guiname>CViewTextFormated</guiname>
|
||||
<classname>text_formated</classname>
|
||||
<ancestor>ViewText</ancestor>
|
||||
<description></description>
|
||||
<abstract>false</abstract>
|
||||
|
|
|
@ -2,6 +2,7 @@
|
|||
<header>
|
||||
<name>ViewTextID</name>
|
||||
<guiname>CViewTextID</guiname>
|
||||
<classname>text_id</classname>
|
||||
<ancestor>ViewText</ancestor>
|
||||
<description></description>
|
||||
<abstract>false</abstract>
|
||||
|
|
|
@ -2,6 +2,7 @@
|
|||
<header>
|
||||
<name>ViewTextIDFormated</name>
|
||||
<guiname>CViewTextIDFormated</guiname>
|
||||
<classname>text_id_formated</classname>
|
||||
<ancestor>ViewTextID</ancestor>
|
||||
<description></description>
|
||||
<abstract>false</abstract>
|
||||
|
|
Loading…
Reference in a new issue