mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-12-28 03:00:35 +00:00
app: add about dialog
This commit is contained in:
parent
82c8e8be59
commit
0265bc834f
1 changed files with 34 additions and 13 deletions
|
@ -105,7 +105,16 @@ public class MediaInfo.App : Window
|
||||||
sub_menu.append (citem);
|
sub_menu.append (citem);
|
||||||
citem.toggled.connect (on_fullscreen_toggled);
|
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);
|
return (menu_bar);
|
||||||
}
|
}
|
||||||
|
@ -131,5 +140,17 @@ public class MediaInfo.App : Window
|
||||||
unfullscreen();
|
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…
Reference in a new issue