Exemplo n.º 1
0
 void button_Clicked(object obj, EventArgs args)
 {
     Gtk.Window parent = (Gtk.Window)GetAncestor(Gtk.Window.GType);
     using (SelectImageDialog dlg = new SelectImageDialog(parent, project)) {
         dlg.Icon = (ImageInfo)Value;
         if (dlg.Run() == (int)Gtk.ResponseType.Ok)
         {
             Value = dlg.Icon;
         }
     }
 }
Exemplo n.º 2
0
 protected void OnSelectImage(object s, EventArgs args)
 {
     using (SelectImageDialog dlg = new SelectImageDialog(dialog, project)) {
         if (dlg.Run() == (int)Gtk.ResponseType.Ok)
         {
             singleIcon        = dlg.Icon;
             imageLabel.Text   = singleIcon.Label;
             imageImage.Pixbuf = singleIcon.GetThumbnail(project, 16);
             UpdateButtons();
         }
     }
 }
Exemplo n.º 3
0
 protected void OnAddSource(object s, EventArgs args)
 {
     using (SelectImageDialog dlg = new SelectImageDialog(dialog, project)) {
         if (dlg.Run() == (int)Gtk.ResponseType.Ok)
         {
             ProjectIconSource src = new ProjectIconSource();
             src.Image         = dlg.Icon;
             src.AllWildcarded = true;
             AddSource(src);
             UpdateButtons();
         }
     }
 }
Exemplo n.º 4
0
 void button_Clicked(object obj, EventArgs args)
 {
     Gtk.Window parent = (Gtk.Window)GetAncestor (Gtk.Window.GType);
     using (SelectImageDialog dlg = new SelectImageDialog (parent, project)) {
         dlg.Icon = (ImageInfo) Value;
         if (dlg.Run () == (int) Gtk.ResponseType.Ok)
             Value = dlg.Icon;
     }
 }
Exemplo n.º 5
0
 protected void OnSelectImage(object s, EventArgs args)
 {
     using (SelectImageDialog dlg = new SelectImageDialog (dialog, project)) {
         if (dlg.Run () == (int) Gtk.ResponseType.Ok) {
             singleIcon = dlg.Icon;
             imageLabel.Text = singleIcon.Label;
             imageImage.Pixbuf = singleIcon.GetThumbnail (project, 16);
             UpdateButtons ();
         }
     }
 }
Exemplo n.º 6
0
 protected void OnAddSource(object s, EventArgs args)
 {
     using (SelectImageDialog dlg = new SelectImageDialog (dialog, project)) {
         if (dlg.Run () == (int) Gtk.ResponseType.Ok) {
             ProjectIconSource src = new ProjectIconSource ();
             src.Image = dlg.Icon;
             src.AllWildcarded = true;
             AddSource (src);
             UpdateButtons ();
         }
     }
 }