this.refObj.width){ var height = this.height/(this.width/this.refObj.width) this.setAttribute('width',this.refObj.width); this.setAttribute('height',height); this.setAttribute('x',0); } if (this.height>this.refObj.height){ var width = this.width/(this.height/this.refObj.height) this.setAttribute('height',this.refObj.height); this.setAttribute('width',width); this.setAttribute('y',0); } if(this.y+this.height>this.refObj.height){ this.setAttribute('y',0); } if(this.x+this.width>this.refObj.width){ this.setAttribute('x',0); } } //only send syncCommand if alterModus is true (meaning that this is the Moderator) //otherwise just send a notification to moderator that this image has been loaded //if this is just a recordContent-modi (recordingsViewer) then there should be no syncing if (this.recorderModus) { this.refObj.storeTempValsAndLoadSyncListRecording(this); } else if (this.alterModus){ this.refObj.storeTempValsAndLoadSyncList(this); } else if (this.isLocalSync){ this.refObj.addImageToLayerHistoryToLocalLoaded.sendEvent(this); } else { this.refObj.sendLoadNotificationImage(this); } this.refObj.layers.push(this); this.oninit.sendEvent(); //This is not needed anymore as it sync's against the server sid, swagner, 11.06.2008 //this.refObj.parent.parent.isloadedImage.sendEvent(this); //send notification to wml-loader //this is send later then in normal objects cause it needs to be send after the image //has been loaded completely //if (this.refObj.isWmlLoaderImage){ // this.refObj.isWmlLoaderImage=false; // //Debug.write("1 onwmlLoaderSend.sendEvent( image )"); // if (this.refObj.onwmlLoaderSend) this.refObj.onwmlLoaderSend.sendEvent('image'); //} ]]>