Advertisement
nemolaod

TETS#3

Mar 12th, 2013
94
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Vala 0.98 KB | None | 0 0
  1. using Gtk;
  2.  
  3. //namespace GtkForms{  
  4.   public class GtkForms : GLib.Object
  5.   {
  6.      // public Window Window(){var window1 = new Window();return window1;}
  7.      
  8.       public class Windows  
  9.       {
  10.          public void Show(int x , int y)
  11.          {
  12.            var window = new Window();
  13.            window.title = "إلبس :3";
  14.            window.border_width = 10;
  15.            window.window_position = WindowPosition.CENTER;
  16.            window.set_default_size ( x, y);
  17.            window.destroy.connect (Gtk.main_quit);
  18.            
  19.            var button = new Button ();
  20.            button.Show(ref window);      
  21.            
  22.            window.show_all ();
  23.            
  24.          }
  25.       }
  26.      
  27.       public class Buttons
  28.       {
  29.        
  30.         public Button Show(ref Window _win)
  31.         {
  32.           var button = new Button();
  33.           _win.add(button);
  34.          
  35.           return button;          
  36.         }    
  37.        
  38.       }
  39.      
  40.      
  41.  
  42.  }
  43. //}
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement