mirror of
https://github.com/TorqueGameEngines/Torque3D.git
synced 2026-04-25 14:25:38 +00:00
clean out unnecessary position set
add a new route for the asset browser to create things in the form of ".on" @ %assetType @ "GUIEditorDropped(" @ %assetDef @ ",\"" @ %pos @ "\");";
demonstrate it with a soundasset creating a GuiAudioCtrl when drug onto the canvas
This commit is contained in:
parent
54a4510bc6
commit
733c9d4b6d
3 changed files with 29 additions and 12 deletions
|
|
@ -290,13 +290,7 @@ function GuiEditCanvas::createObject( %this, %cmd )
|
|||
|
||||
function GuiEditCanvas::onFinishCreateObject( %this, %objId )
|
||||
{
|
||||
GuiEditor.getCurrentAddSet().add( %objId );
|
||||
|
||||
if( %objId.isMemberOfClass( "GuiControl" ) )
|
||||
{
|
||||
%objId.position = "0 0";
|
||||
}
|
||||
|
||||
GuiEditor.getCurrentAddSet().add( %objId );
|
||||
%this.onObjectCreated( %objId );
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue