- table = new Gtk.HBox (false, 6);
- table.pack_start (image, false, false, 0);
- table.pack_start (label, true, true, 0);
-
- this.delete_button = new Button.with_label (_("Delete"));
- this.details_button = new Button.with_label (_("View details"));
- this.send_button = new Button.with_label (_("Send"));
- set_atk_name_description (delete_button, _("Delete"), _("Delete this ID Card"));
- set_atk_name_description (details_button, _("Details"), _("View the details of this ID Card"));
- set_atk_name_description (send_button, _("Send"), _("Send this ID Card"));
- this.hbutton_box = new HButtonBox ();
- hbutton_box.pack_end (delete_button);
- hbutton_box.pack_end (details_button);
- hbutton_box.pack_end (send_button);
- send_button.set_sensitive (false);
-
- delete_button.clicked.connect (delete_button_cb);
- details_button.clicked.connect (details_button_cb);
- send_button.clicked.connect (send_button_cb);
-
- this.main_vbox = new VBox (false, 12);
- main_vbox.pack_start (table, true, true, 0);
- main_vbox.pack_start (hbutton_box, false, false, 0);
- main_vbox.set_border_width (12);
-
- event_box = new EventBox ();
- event_box.add (main_vbox);
- event_box.button_press_event.connect (button_press_cb);
- this.pack_start (event_box, true, true);
-
- this.show_all ();
- this.hbutton_box.hide ();
-
- set_idcard_color ();
- }
+ table = new Gtk.HBox(false, 6);
+ var image = new Image.from_pixbuf(get_pixbuf(id_card));
+ if (this.id_card.is_no_identity()) {
+ image.clear();
+ // Use padding to make the image size = 48x48 (size = 2x padding)
+ image.set_padding(24, 24);
+ }
+ table.pack_start(image, false, false, 0);
+ table.pack_start(label, true, true, 0);
+ this.arrow = new Arrow(ArrowType.RIGHT, ARROW_SHADOW);
+ table.pack_start(arrow, false, false);