~mefrio-g/dexter-rolodex/dexter-vala

« back to all changes in this revision

Viewing changes to src/MainWindow.vala

  • Committer: Mario Guerriero
  • Date: 2011-11-22 18:01:38 UTC
  • Revision ID: mefrio.g@gmail.com-20111122180138-cisoclcmo277388c
added a .desktop file and fixed some EDS things

Show diffs side-by-side

added added

removed removed

Lines of Context:
30
30
                
31
31
                private const string TITLE = "Dexter";
32
32
                public GLib.SList <E.Contact> contacts;
33
 
                public E.Contact selected;
34
33
        
35
34
        public Gtk.ActionGroup main_actions;
36
35
        Gtk.UIManager ui;
89
88
                        ebook = new EBook (this);
90
89
                        ebook.initialize ();
91
90
                        
 
91
                        var contact = new E.Contact ();
 
92
                        contact.full_name = "Mario Guerriero";
 
93
                        ebook.add_contact (contact);
 
94
                        
92
95
                        draw_ui ();
93
 
                        connect_signals ();
94
 
 
95
 
                        toolbar.set_buttons_sensitive (false);
96
 
 
97
 
                }
98
 
                
99
 
                public void connect_signals () {
100
 
                        destroy.connect (Gtk.main_quit);
 
96
 
 
97
                        toolbar.set_buttons_sensitive (false);          
 
98
            
101
99
                }
102
100
                
103
101
                public void draw_ui (bool is_welcome = false) {
156
154
            
157
155
            void action_delete () {
158
156
                var delete_dialog = new Dexter.Dialogs.Delete (this);
159
 
                        delete_dialog.show_all ();
 
157
                        delete_dialog.show_all ();                      
160
158
            }
161
159
            
162
160
            void action_join () {
178
176
          /* tooltip */                  N_("Quit"),
179
177
                                         action_quit },
180
178
           { "Add", Gtk.Stock.NEW,
181
 
          /* label, accelerator */       N_("Add Contact"), "<Control>a",
 
179
          /* label, accelerator */       N_("Add Contact"), null,
182
180
          /* tooltip */                  N_("Add a new contact"),
183
181
                                         action_add },
184
182