app: add about dialog
This commit is contained in:
parent
82c8e8be59
commit
0265bc834f
@ -105,7 +105,16 @@ public class MediaInfo.App : Window
|
||||
sub_menu.append (citem);
|
||||
citem.toggled.connect (on_fullscreen_toggled);
|
||||
|
||||
// TODO: add "help" menu with "about" item
|
||||
// add "help" menu with "about" item
|
||||
item = new MenuItem.with_label (_("Help"));
|
||||
menu_bar.append (item);
|
||||
|
||||
sub_menu = new Menu ();
|
||||
item.set_submenu (sub_menu);
|
||||
|
||||
item = new ImageMenuItem.from_stock (STOCK_ABOUT, accel_group);
|
||||
sub_menu.append (item);
|
||||
item.activate.connect (on_about_clicked);
|
||||
|
||||
return (menu_bar);
|
||||
}
|
||||
@ -131,5 +140,17 @@ public class MediaInfo.App : Window
|
||||
unfullscreen();
|
||||
}
|
||||
}
|
||||
|
||||
private void on_about_clicked (MenuItem item)
|
||||
{
|
||||
AboutDialog dlg = new AboutDialog ();
|
||||
|
||||
dlg.set_version(Config.PACKAGE_VERSION);
|
||||
dlg.set_program_name("GStreamer Media Info");
|
||||
dlg.set_comments(_("Quickly browse, play and analyze media files."));
|
||||
dlg.set_copyright("Stefan Sauer <ensonic@users.sf.net>");
|
||||
dlg.run();
|
||||
dlg.hide();
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user