Ejemplo n.º 1
0
 private void PasteButton_Click(object sender, EventArgs e)
 {
     if (string.IsNullOrEmpty(sClipboard))
     {
         return;
     }
     MMessageBus.ChangeTextureRequest(this, SelectedItem.InstanceID, sClipboard);
 }
Ejemplo n.º 2
0
 void SetTexture(string TextureID)
 {
     if (SelectedItem == null)
     {
         return;
     }
     MMessageBus.ChangeTextureRequest(this, SelectedItem.InstanceID, TextureID);
 }
Ejemplo n.º 3
0
        private void UploadTexture_Click(object sender, EventArgs e)
        {
            if (SelectedItem == null)
            {
                return;
            }
            ImageUploader iu = new ImageUploader();

            //iu.Show(TopLevelControl);
            iu.sTargetID = SelectedItem.InstanceID;
            if (iu.ShowDialog() == DialogResult.OK)
            {
                //sLocus now contains the URL of the uploaded image
                MMessageBus.ChangeTextureRequest(this, SelectedItem.InstanceID, iu.sPublicFile);
            }
        }
Ejemplo n.º 4
0
        private void Client_UploadFileCompleted(object sender, UploadFileCompletedEventArgs e)
        {
            progressBar1.Visible = false;
            if (e.Error != null)
            {
                Globals.Log(this, e.Error.Message);
                Status(e.Error.Message);
                Console.WriteLine(e.Error.Message);
                return;
            }
            string s = System.Text.Encoding.UTF8.GetString(e.Result, 0, e.Result.Length);

            //Console.WriteLine(s);
            Status("Upload Complete");
            sPublicFile = s.Replace("{HOST}", Globals.Network.ServerIP);
            Globals.Network.ChangePropertyRequest(Target.InstanceID, Description);
            MMessageBus.ChangeTextureRequest(this, Target.InstanceID, sPublicFile);
        }