mirror of
https://github.com/paparazzi/paparazzi.git
synced 2026-05-27 00:37:37 +08:00
"Help->About" menu entry filled
This commit is contained in:
@@ -174,7 +174,7 @@
|
||||
<accelerator key="N" modifiers="GDK_CONTROL_MASK" signal="activate"/>
|
||||
|
||||
<child internal-child="image">
|
||||
<widget class="GtkImage" id="image81">
|
||||
<widget class="GtkImage" id="image85">
|
||||
<property name="visible">True</property>
|
||||
<property name="stock">gtk-add</property>
|
||||
<property name="icon_size">1</property>
|
||||
@@ -196,7 +196,7 @@
|
||||
<accelerator key="X" modifiers="GDK_CONTROL_MASK" signal="activate"/>
|
||||
|
||||
<child internal-child="image">
|
||||
<widget class="GtkImage" id="image82">
|
||||
<widget class="GtkImage" id="image86">
|
||||
<property name="visible">True</property>
|
||||
<property name="stock">gtk-delete</property>
|
||||
<property name="icon_size">1</property>
|
||||
@@ -254,7 +254,7 @@
|
||||
<signal name="activate" handler="on_menu_item_new session_activate" last_modification_time="Tue, 02 Oct 2007 19:48:09 GMT"/>
|
||||
|
||||
<child internal-child="image">
|
||||
<widget class="GtkImage" id="image83">
|
||||
<widget class="GtkImage" id="image87">
|
||||
<property name="visible">True</property>
|
||||
<property name="stock">gtk-add</property>
|
||||
<property name="icon_size">1</property>
|
||||
@@ -275,7 +275,7 @@
|
||||
<signal name="activate" handler="on_menu_item_save_session_activate" last_modification_time="Tue, 07 Aug 2007 08:09:29 GMT"/>
|
||||
|
||||
<child internal-child="image">
|
||||
<widget class="GtkImage" id="image84">
|
||||
<widget class="GtkImage" id="image88">
|
||||
<property name="visible">True</property>
|
||||
<property name="stock">gtk-save</property>
|
||||
<property name="icon_size">1</property>
|
||||
@@ -329,7 +329,7 @@
|
||||
<accelerator key="F11" modifiers="0" signal="activate"/>
|
||||
|
||||
<child internal-child="image">
|
||||
<widget class="GtkImage" id="image85">
|
||||
<widget class="GtkImage" id="image89">
|
||||
<property name="visible">True</property>
|
||||
<property name="stock">gtk-fullscreen</property>
|
||||
<property name="icon_size">1</property>
|
||||
@@ -356,7 +356,7 @@
|
||||
<widget class="GtkMenu" id="menuitem8_menu">
|
||||
|
||||
<child>
|
||||
<widget class="GtkMenuItem" id="about2">
|
||||
<widget class="GtkMenuItem" id="menu_item_about">
|
||||
<property name="visible">True</property>
|
||||
<property name="label" translatable="yes">_About</property>
|
||||
<property name="use_underline">True</property>
|
||||
|
||||
@@ -148,6 +148,8 @@ let quit_button_callback = fun gui ac_combo session_combo target_combo () ->
|
||||
| _ -> ()
|
||||
|
||||
|
||||
|
||||
(************************** Main *********************************************)
|
||||
let () =
|
||||
let session = ref ""
|
||||
and fullscreen = ref false in
|
||||
@@ -163,7 +165,8 @@ let () =
|
||||
gui#window#fullscreen ();
|
||||
gui#toplevel#show ();
|
||||
|
||||
gui#window#set_icon (Some (GdkPixbuf.from_file Env.icon_file));
|
||||
let paparazzi_pixbuf = GdkPixbuf.from_file Env.icon_file in
|
||||
gui#window#set_icon (Some paparazzi_pixbuf);
|
||||
|
||||
let s = gui#statusbar#new_context "env" in
|
||||
ignore (s#push (sprintf "HOME=%s SRC=%s" Env.paparazzi_home Env.paparazzi_src));
|
||||
@@ -238,6 +241,7 @@ let () =
|
||||
|
||||
ignore (gui#window#event#connect#delete ~callback:(quit_callback gui ac_combo session_combo target_combo));
|
||||
|
||||
(* Fullscreen menu entry *)
|
||||
let callback = fun () ->
|
||||
fullscreen := not !fullscreen;
|
||||
if !fullscreen then
|
||||
@@ -246,6 +250,11 @@ let () =
|
||||
gui#window#unfullscreen () in
|
||||
ignore (gui#menu_item_fullscreen#connect#activate ~callback);
|
||||
|
||||
(* Help/About menu entry *)
|
||||
let callback = fun () ->
|
||||
ignore (GToolbox.message_box ~title:"About Paparazzi Center" ~icon:(GMisc.image ~pixbuf:paparazzi_pixbuf ())#coerce "Copyright (C) 2007-2008 ENAC, Pascal Brisset\nhttp://paparazzi.enac.fr") in
|
||||
ignore (gui#menu_item_about#connect#activate ~callback);
|
||||
|
||||
(* Read preferences *)
|
||||
if Sys.file_exists Env.gconf_file then begin
|
||||
read_preferences gui Env.gconf_file ac_combo session_combo target_combo
|
||||
|
||||
Reference in New Issue
Block a user