예제 #1
0
 protected override void Show(IDialogVisualizerService windowService, IVisualizerObjectProvider objectProvider)
 {
     Stream incomingData = objectProvider.GetData();
     BinaryFormatter formatter = new BinaryFormatter();
     string name = (string)formatter.Deserialize(incomingData);
     Bitmap pixeldata = (Bitmap)formatter.Deserialize(incomingData);
     using (BitmapForm form = new BitmapForm()) {
         form.Text = name;
         form.Bitmap = pixeldata;
         windowService.ShowDialog(form);
     }
 }
예제 #2
0
        protected override void Show(IDialogVisualizerService windowService, IVisualizerObjectProvider objectProvider)
        {
            Stream          incomingData = objectProvider.GetData();
            BinaryFormatter formatter    = new BinaryFormatter();
            string          name         = (string)formatter.Deserialize(incomingData);
            Bitmap          pixeldata    = (Bitmap)formatter.Deserialize(incomingData);

            using (BitmapForm form = new BitmapForm()) {
                form.Text   = name;
                form.Bitmap = pixeldata;
                windowService.ShowDialog(form);
            }
        }