v1ral_ITS

GUI Multisystem USB Maker

Sep 29th, 2018
911
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Bash 63.28 KB | None | 0 0
  1. #! /bin/bash --posix
  2. chemin="$(cd "$(dirname "$0")";pwd)/$(basename "$0")";
  3. dossier="$(dirname "$chemin")"
  4. export chemin dossier
  5. cd "${dossier}"
  6.  
  7. ###Pour exporter la librairie de gettext.
  8. set -a
  9. source gettext.sh
  10. set +a
  11. export -p TEXTDOMAIN=multisystem
  12. export -p TEXTDOMAINDIR=${dossier}/locale
  13. . gettext.sh
  14. multisystem=$0
  15.  
  16. #stop si root!
  17. if [ "$(id -u)" == "0" ]; then
  18. zenity --error --text "$(eval_gettext "Erreur: pas en root!")"
  19. nohup "$dossier"/kill.sh&
  20. exit 0
  21. fi
  22.  
  23. #gtkrc perso
  24. #bonne adresse pour les styles gtkrc ==> http://orford.org/gtk/
  25. # Example pour modifier style des boutons nommés stylebt
  26. #style "styleBorderless" {
  27. #   GtkButton::inner-border = {10, 0, 0, 10}
  28. #   xthickness = 0
  29. #   ythickness = 0
  30. #}
  31. #widget "*stylebt" style "styleBorderless"
  32. #
  33. #Exemple pour changer police d'un widget nommé GtkEditFontMonospace
  34. #style "styleGtkEditFontMonospace" {
  35. #   text[NORMAL] = "#ffffff"
  36. #   base[NORMAL] = "#000000"
  37. #   font_name = "monospace 16"
  38. #}
  39. #widget "*GtkEditFontMonospace" style "styleGtkEditFontMonospace"
  40. #
  41. if [ -f "$HOME/.multisystem/gtkrc" ]; then
  42. export GTK2_RC_FILES=$HOME/.multisystem/gtkrc:~/.gtkrc-2.0
  43. fi
  44.  
  45. #Test les path et ajout à .profile de user si path existe et non present dans $PATH
  46. #pour fonctionnement de which en user non sudo sur les bases Debian
  47. function FCT_CHECKPATH()
  48. {
  49. [ ! -f "$HOME/.profile" ] && >"$HOME/.profile"
  50. . $HOME/.profile
  51. export PATH=$PATH
  52. path_curents="/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games"
  53. path_actuels="$(echo $PATH | tr ":" "\n")"
  54. path_add=""
  55. I=$IFS; IFS=":"
  56. for test_path in $path_curents; do
  57. if [[ ! "$(grep "^${test_path}$" <<<"${path_actuels}")" ]]; then
  58. path_add="${path_add}${test_path}:"
  59. echo Ajouter PATH: ${test_path}
  60. fi
  61. done
  62. IFS=$I
  63. if [ "${path_add}" ]; then
  64. echo "PATH=\"${path_add}\$PATH\"" | tee -a "$HOME/.profile"
  65. export PATH="${path_add}$PATH"
  66. fi
  67. }
  68. FCT_CHECKPATH
  69.  
  70. #Path gtkdialog
  71. GTKDIALOG=gtkdialog
  72. export GTKDIALOG
  73.  
  74. #Check version gtkdialog
  75. function funcGTKDVGet() {
  76. GTKVMINI="0.8.3"
  77. GTKDV=( $($GTKDIALOG -v) )
  78. GTKDV=${GTKDV[2]}
  79. echo "Gtkdialog version: $GTKDV"
  80. if [[ $GTKDV < $GTKVMINI ]]; then
  81. GTKVADV="This application requires at least gtkdialog-$GTKVMINI,\nPlease updrade your version.\nWebsite: http://code.google.com/p/gtkdialog/"
  82. echo -e "\033[1;47;31m $GTKVADV \033[0m"
  83. zenity --info --text  "$GTKVADV"&
  84. exit 0
  85. fi
  86. }
  87. funcGTKDVGet
  88.  
  89. #Créer dossier pref
  90. if [ ! -d "$HOME/.multisystem/" ]; then
  91. mkdir "$HOME/.multisystem/" 2>/dev/null
  92. fi
  93.  
  94. #Mettre à jour les icones GTK ! à revoir ...
  95. #http://developer.gimp.org/api/2.0/gtk/gtk-update-icon-cache.html
  96. #gtk-update-icon-cache -t "$HOME"/.local/share/icons/hicolor/
  97. #manque ==> index.theme voir ==> /usr/share/icons/hicolor/index.theme
  98.  
  99. #Caler lang si user n'a pas réglé dans gui de multisystem
  100. if [ ! -f "$HOME/.multisystem/lang_sel.txt" ]; then
  101. echo
  102. >"$HOME/.multisystem/lang_sel.txt"
  103. while read line
  104. do
  105. if [ "$(grep -i "$(echo $line | awk -F'|' '{print $3}'| sed "s/\..*//")" <<<"${LANG}")" ]; then
  106. echo $line | awk -F'|' '{print $3}'| sed "s/\..*//"
  107. echo $line >"$HOME/.multisystem/lang_sel.txt"
  108. break
  109. fi
  110. done <<<"$(cat "${dossier}/lang_list.txt" | sed "/^$/d")"
  111.  
  112. #Si ne trouve pas de traduction passer en Anglais.
  113. if [ ! "$(cat "$HOME/.multisystem/lang_sel.txt")" ]; then
  114. echo "English|en|en_US.UTF-8" >"$HOME/.multisystem/lang_sel.txt"
  115. fi
  116. cat "$HOME/.multisystem/lang_sel.txt"
  117. fi
  118.  
  119. #pour slitaz
  120. if [ "$(which tazpkg 2>/dev/null)" ]; then
  121. export LANG="$(awk -F\| '{print $3}' "$HOME/.multisystem/lang_sel.txt")"
  122. else
  123. #declare -x LANG="$(awk -F\| '{print $3}' "$HOME/.multisystem/lang_sel.txt")"
  124. declare -x LANGUAGE="$(awk -F\| '{print $3}' "$HOME/.multisystem/lang_sel.txt")"
  125. fi
  126.  
  127. echo LANG:$LANG
  128. echo LANGUAGE:$LANGUAGE
  129. echo LANGSEL:$(cat "$HOME/.multisystem/lang_sel.txt")
  130.  
  131. #zenity --info --text "$(export)"
  132. #locale -a
  133. #cat /etc/default/locale
  134. #/etc/environment or ~/.gtkrc
  135. #sudo locale-gen --purge fr_FR.UTF-8
  136. #locale-gen
  137. #dpkg-reconfigure locales
  138. #dpkg-reconfigure console-data
  139. #dpkg-reconfigure console-setup
  140. #id
  141.  
  142. #if [ ! "$(ps ax | grep -v grep | grep "hal-lock --interface org.freedesktop.Hal.Device.Volume --exclusive --run ${chemin}")" ]; then
  143. #hal-lock --interface org.freedesktop.Hal.Device.Volume --exclusive --run "${chemin}"
  144. #exit 0
  145. #fi
  146.  
  147. #Thème
  148. . ./theme.sh
  149.  
  150. #Gui logo
  151. # font-family=\"purisa\" weight=\"bold\"
  152. if [ "$(grep "fr_FR" <<<"${LANG}")" ]; then
  153. export MOD_WAIT='<window title="MultiSystem-logo" window_position="0" decorated="false">
  154. <vbox>
  155. <text sensitive="false" use-markup="true" wrap="false" angle="10">
  156. <variable>MESSAGES</variable>
  157. <input>echo "\<b>\<span color=\"#EB2C00\" size=\"larger\">○ NOUVEAU !\nLa première clé USB MultiSystem du marché\nest disponible sur liveusb.info.\</span>\</b>" | sed "s%\\\%%g" | sed "s%\\\\n\\\\n\\\\n%%g"</input>
  158. </text>
  159. <pixmap>
  160. <input file>./logo_pub.jpg</input>
  161. </pixmap>
  162. <pixmap>
  163. <input file>./pixmaps/multisystem-wait.gif</input>
  164. </pixmap>
  165. </vbox>
  166. </window>'
  167. else
  168. export MOD_WAIT='<window title="MultiSystem-logo" window_position="0" decorated="false">
  169. <vbox>
  170. <pixmap>
  171. <input file>./logo.png</input>
  172. </pixmap>
  173. <pixmap>
  174. <input file>./pixmaps/multisystem-wait.gif</input>
  175. </pixmap>
  176. </vbox>
  177. </window>'
  178. fi
  179.  
  180. #Lancer logo
  181. gtkdialog --program=MOD_WAIT &
  182. sleep .5
  183.  
  184. function FCT_DETECT_PROCESS()
  185. {
  186. #detect process
  187. #zenity --info --text "$(pgrep -xlc multisystem) $(pgrep -xlc gui_multisystem)"
  188. if [[ "$(pgrep -xlc multisystem)" -gt "1" || "$(pgrep -xlc gui_multisystem)" -gt "1" ]]; then
  189. wmctrl -c "MultiSystem-logo"
  190. #Activer fenetre
  191. xdotool windowactivate $(wmctrl -l | grep 'MultiSystem' | awk '{print $1}')
  192. exit 0
  193. fi
  194. }
  195. FCT_DETECT_PROCESS
  196.  
  197. #Verif dépendances...
  198. errorlist=()
  199. testlist="$(cat "${dossier}/dependances.txt")"
  200. for i in $(grep -v "^#" <<<"${testlist}" | xargs)
  201. do
  202. if [ ! "$(which $i 2>/dev/null)" ]; then
  203. errorlist=(${errorlist[@]} $i)
  204. fi
  205. done
  206. #Stop si
  207. if [ "$(echo "${errorlist[@]}")" ]; then
  208. echo -e "\033[1;47;31m $(eval_gettext 'Erreur il manque: ')${errorlist[@]} \033[0m"
  209. exit 0
  210. fi
  211. #dpkg -L grub-pc
  212.  
  213. #mettre en place les icon pour lancement si pas installé!
  214. mkdir -p "$HOME"/.local/share/icons/hicolor/48x48/apps/ 2>/dev/null
  215. #comparer nombre icon et maj si diff
  216. if [ "$(ls -A "${dossier}"/pixmaps/multisystem-* 2>/dev/null | wc -l)" != "$(ls -A "$HOME"/.local/share/icons/hicolor/48x48/apps/multisystem-* 2>/dev/null | wc -l)" ]; then
  217. cp -f "${dossier}/pixmaps/"* "$HOME"/.local/share/icons/hicolor/48x48/apps/
  218. fi
  219.  
  220. #Vérifier que GParted n'est pas open!
  221. if [ "$(ps aux | grep -v grep | grep 'hal-lock.*interface org.freedesktop.Hal.Device.Storage.*exclusive')" ]; then
  222. zenity --error --text "$(eval_gettext "Erreur: un logiciel bloque l\'utilisation des disques, veuillez le fermer.")"
  223. nohup "$dossier"/kill.sh&
  224. exit 0
  225. fi
  226.  
  227. #Vérifier que user est bien administrateur
  228. if [ "$(cat /etc/group | grep ^adm)" ]; then
  229. echo
  230. if [ ! "$(cat /etc/group | grep ^adm | grep $USER)" ]; then
  231. zenity --error --text "$(eval_gettext "Erreur:") USER:$USER is not admin!"
  232. nohup "$dossier"/kill.sh&
  233. exit 0
  234. fi
  235. fi
  236.  
  237. #Fermer logo
  238. #zenity --info --text "logo3"
  239. #wmctrl -c "MultiSystem-logo"
  240.  
  241. #Système de détection
  242. source ./gui-detect.sh
  243. sleep .1
  244.  
  245. #Thème (laisser en doublon ici !)
  246. . ./theme.sh
  247.  
  248. #mettre en place autorun.inf/multisystem.bat/icon.ico
  249. if [ ! -f "$(cat /tmp/multisystem/multisystem-mountpoint-usb)/autorun.inf" ]; then
  250. #echo -e '[AutoRun]\r\nShellexecute=multisystem.bat\r\nICON=icon.ico\r\nLabel=MultiSystem' | tee "$(cat /tmp/multisystem/multisystem-mountpoint-usb)/autorun.inf"
  251. echo -e '[AutoRun]\r\nICON=icon.ico\r\nLabel=MultiSystem\r\n\r\n[Content]\r\nMusicFiles=false\r\nPictureFiles=false\r\nVideoFiles=false' | tee "$(cat /tmp/multisystem/multisystem-mountpoint-usb)/autorun.inf"
  252. #copier .ico
  253. cp -f "${dossier}/icon.ico" "$(cat /tmp/multisystem/multisystem-mountpoint-usb)/icon.ico"
  254. fi
  255.  
  256. #par securité verifier multisystem.bat
  257. #7295356a95fc3e312ec342f57b944662  .../multisystem.bat
  258. #if [ "7295356a95fc3e312ec342f57b944662" != "$(md5sum "$(cat /tmp/multisystem/multisystem-mountpoint-usb)/multisystem.bat" | awk '{print $1}')" ]; then
  259. #zenity --info --text "$(eval_gettext "ATTENTION!\nle fichier multisystem.bat à été modifié, Virus?")"
  260. #fi
  261.  
  262. #Vérifier les mise à jour! / uniquement si installé!
  263. if [[ "${dossier}" == "/usr/local/share/multisystem" && "$(cat "$HOME/.multisystem/checkupdate")" = "true" ]]; then
  264. wget -t1 -T1 http://liveusb.info/multisystem/version-multisystem.txt -O "/tmp/multisystem/version-multisystem.txt"
  265. if [ "$(cat /tmp/multisystem/version-multisystem.txt 2>/dev/null)" ]; then
  266. echo ok
  267. if [ "$(cat /tmp/multisystem/version-multisystem.txt)" != "$(cat /usr/local/share/multisystem/version-multisystem.txt)" ]; then
  268. zenity --info --text "$(eval_gettext "Une mise à jour de multisystem est disponible")"&
  269. fi
  270. fi
  271. fi
  272.  
  273. #Avertissement si user supprime OS dans gui de multisystem
  274. [ ! "$(cat "$HOME/.multisystem/check_rem" 2>/dev/null)" ] && echo "true" >"$HOME/.multisystem/check_rem"
  275. check_rem="$(cat "$HOME/.multisystem/check_rem")"
  276.  
  277. #Activer icon dans menu gnome
  278. if [[ ! "$(cat /proc/cmdline | grep casper)" && "$(which gconf-editor)" && "$(gconftool-2  --get "/desktop/gnome/interface/menus_have_icons" 2>/dev/null)" = "false" ]]; then
  279. echo
  280. if [ ! -f "$HOME/.multisystem/active_icon" ]; then
  281. zenity --question --text="$(eval_gettext "Activer les icones dans les menus de gnome ?")"
  282. if [ $? = "0" ]; then
  283. echo ok >"$HOME/.multisystem/active_icon"
  284. gconftool-2 --set "/desktop/gnome/interface/menus_have_icons" --type bool "true"
  285. fi
  286. fi
  287. fi
  288.  
  289. #mettre à jour le menu du tree
  290. #relever icone|iso|date
  291. gtkdialog --program=MOD_WAIT &
  292. sleep .1
  293. ./fonctions.sh
  294. #wmctrl -c "MultiSystem-logo"
  295.  
  296. #Corriger bug 1.96 de mon grub.cfg
  297. if [ "$(grub-install -V | grep 1.96)" ]; then
  298. sed -i "s/linux16/linux/g" "$(cat /tmp/multisystem/multisystem-mountpoint-usb)/boot/grub/grub.cfg"
  299. sed -i "s/initrd16/initrd/g" "$(cat /tmp/multisystem/multisystem-mountpoint-usb)/boot/grub/grub.cfg"
  300. sed -i "s/--config-file=\/boot\/grub\/menu.lst//g" "$(cat /tmp/multisystem/multisystem-mountpoint-usb)/boot/grub/grub.cfg"
  301. sed -i "s/(\${root})//g" "$(cat /tmp/multisystem/multisystem-mountpoint-usb)/boot/grub/grub.cfg"
  302. sed -i "s/^set root=${root}/#set root=${root}/g" "$(cat /tmp/multisystem/multisystem-mountpoint-usb)/boot/grub/grub.cfg"
  303. sed -i "s/\#set root=(hd0,1)/set root=(hd0,1)/g" "$(cat /tmp/multisystem/multisystem-mountpoint-usb)/boot/grub/grub.cfg"
  304. fi
  305.  
  306. #Onglet À propos
  307. >/tmp/multisystem/multisystem-about
  308. while read line
  309. do
  310. echo "multisystem-$(echo ${line} | awk -F'|' '{print $2}')|$(eval_gettext 'Traducteur') $(echo ${line} | awk -F'|' '{print $1}'), $(echo ${line} | awk -F'|' '{print $4}')|$(echo ${line} | awk -F'|' '{print $5}')" >>/tmp/multisystem/multisystem-about
  311. done <<<"$(cat "${dossier}/lang_list.txt" | sed "/^$/d")"
  312. #check .deb
  313. verify_update="$(dpkg -l "multisystem" | grep "^ii  multisystem" 2>/dev/null | awk '{print $3}')"
  314. #Si .deb est installé
  315. if [ "${verify_update}" ]; then
  316. echo "<span color='"'#4CB23F'"'>Version:${verify_update} $(cat ./version-multisystem.txt)</span>" >/tmp/multisystem/multisystem-inputversion
  317. #Si .deb n'est pas installé
  318. elif [ ! "${verify_update}" ]; then
  319. echo "<span color='"'#4CB23F'"'>Version:$(cat ./version-multisystem.txt)</span>" >/tmp/multisystem/multisystem-inputversion
  320. fi
  321.  
  322. #Onglet Non-Libre
  323. #Créer dossier nonfree
  324. mkdir -p "$HOME"/.multisystem/nonfree 2>/dev/null
  325. #Check les files
  326. >/tmp/multisystem/multisystem-nonfree
  327. if [ -f "$HOME"/.multisystem/nonfree/plpbt.bin ]; then
  328. echo 'gtk-ok|plpbt.bin' >>/tmp/multisystem/multisystem-nonfree
  329. else
  330. echo 'gtk-no|plpbt.bin' >>/tmp/multisystem/multisystem-nonfree
  331. fi
  332. if [ -f "$HOME"/.multisystem/nonfree/plpcfgbt ]; then
  333. echo 'gtk-ok|plpcfgbt' >>/tmp/multisystem/multisystem-nonfree
  334. else
  335. echo 'gtk-no|plpcfgbt' >>/tmp/multisystem/multisystem-nonfree
  336. fi
  337. if [ -f "$HOME"/.multisystem/nonfree/NTDETECT.COM ]; then
  338. echo 'gtk-ok|NTDETECT.COM' >>/tmp/multisystem/multisystem-nonfree
  339. else
  340. echo 'gtk-no|NTDETECT.COM' >>/tmp/multisystem/multisystem-nonfree
  341. fi
  342. if [ -f "$HOME"/.multisystem/nonfree/SETUPLDR.BIN ]; then
  343. echo 'gtk-ok|SETUPLDR.BIN' >>/tmp/multisystem/multisystem-nonfree
  344. else
  345. echo 'gtk-no|SETUPLDR.BIN' >>/tmp/multisystem/multisystem-nonfree
  346. fi
  347. if [ -f "$HOME"/.multisystem/nonfree/RAMDISK.SY_ ]; then
  348. echo 'gtk-ok|RAMDISK.SY_' >>/tmp/multisystem/multisystem-nonfree
  349. else
  350. echo 'gtk-no|RAMDISK.SY_' >>/tmp/multisystem/multisystem-nonfree
  351. fi
  352. if [ -f "$HOME"/.multisystem/nonfree/RAMDISK.SYS ]; then
  353. echo 'gtk-ok|RAMDISK.SYS' >>/tmp/multisystem/multisystem-nonfree
  354. else
  355. echo 'gtk-no|RAMDISK.SYS' >>/tmp/multisystem/multisystem-nonfree
  356. fi
  357. if [ -f "$HOME"/.multisystem/nonfree/BOOTSECT.BIN ]; then
  358. echo 'gtk-ok|BOOTSECT.BIN' >>/tmp/multisystem/multisystem-nonfree
  359. else
  360. echo 'gtk-no|BOOTSECT.BIN' >>/tmp/multisystem/multisystem-nonfree
  361. fi
  362. if [ -f "$HOME"/.multisystem/nonfree/firadisk.ima ]; then
  363. echo 'gtk-ok|firadisk.ima' >>/tmp/multisystem/multisystem-nonfree
  364. else
  365. echo 'gtk-no|firadisk.ima' >>/tmp/multisystem/multisystem-nonfree
  366. fi
  367. #Détreminer éditeur text
  368. if [  "$(which nautilus)" ]; then
  369. navuse="nautilus"
  370. elif [ "$(which dolphin)" ]; then
  371. navuse="dolphin"
  372. elif [ "$(which rox-filer)" ]; then
  373. navuse="rox-filer"
  374. elif [ "$(which thunar)" ]; then
  375. navuse="thunar"
  376. elif [ "$(which pcmanfm)" ]; then
  377. navuse="pcmanfm"
  378. fi
  379.  
  380. #forcer à true par defaut
  381. echo 'true' >/tmp/multisystem/multisystem-update-bootloader
  382.  
  383. #Onglet par defaut
  384. echo 0 >/tmp/multisystem/multisystem-inputtab1
  385. echo 0 >/tmp/multisystem/multisystem-inputtab2
  386. echo 0 >/tmp/multisystem/multisystem-inputtab3
  387.  
  388. #Bas de pages commun des onglets secondaires
  389. function FCT_HOME()
  390. {
  391. echo '<pixmap>
  392. <input file>'${theme_bdo}'</input>
  393. </pixmap>
  394. <hbox spacing="0">
  395. <button name="stylebt" height_request="30" image-position="0" relief="2" xalign="0" yalign="0">
  396. <height>16</height>
  397. <input file icon="multisystem-home"></input>
  398. <label>'$(eval_gettext 'Retour Accueil')'</label>
  399. <action>echo 0 > /tmp/multisystem/multisystem-inputtab1</action>
  400. <action>echo 0 > /tmp/multisystem/multisystem-inputtab2</action>
  401. <action>refresh:tab1</action>
  402. <action>refresh:tab2</action>
  403. <action>refresh:tree</action>
  404. <action>refresh:MESSAGES</action>
  405. </button>
  406. <button name="stylebt" height_request="30" image-position="0" relief="2" xalign="0" yalign="0">
  407. <height>16</height>
  408. <input file stock="gtk-quit"></input>
  409. <label>'$(eval_gettext 'Quitter')'</label>
  410. <action>wmctrl -c "MultiSystem-logo"</action>
  411. <action>wmctrl -c "MultiSystem-logo2"</action>
  412. <action>wmctrl -c "VBox"</action>
  413. <action>exit:exit</action>
  414. </button>
  415. </hbox>'
  416. }
  417.  
  418.  
  419. #sortie des fonctions pour Ubuntu 16.04 !!!
  420. source "${dossier}/gtkdialog-function.sh"
  421. #Nom de le fonction à exécuter dans FCT_vte
  422. echo "" >/tmp/multisystem/multisystem-function_name
  423. #Fichier bash a executer dans widget vte
  424. echo "" >"/tmp/multisystem/multisystem-vte"
  425. chmod +x "/tmp/multisystem/multisystem-vte"
  426. #Déclenchement du widget timer
  427. echo "false" >"/tmp/multisystem/multisystem-timer"
  428. #Sélection fihier iso
  429. echo "" >/tmp/multisystem/multisystem-fileselect
  430. echo All | tee /tmp/multisystem/multisystem-output-list
  431. #Onglet Déboguer
  432. echo "" >/tmp/multisystem/multisystem-test-usb
  433. export message_debug="$(eval_gettext "Patience test en cours...")"
  434. #Onglet N°5 Formater votre clé USB
  435. export format_text="$(parted -s $(cat /tmp/multisystem/multisystem-selection-usb | sed 's/[0-9]//') unit MB print)"
  436. echo -e "${format_text}" >/tmp/multisystem/multisystem-format-text
  437. FCT_hidden_update_tree
  438. export texte_annonce="MultiSystem recherche des traducteurs,\nMerci de nous contacter\nsi vous souhaitez participer\nContact:liveusb@gmail.com\n\nMultiSystem looking for translators,\nThank you contact us\nif you want to participate\nContact:liveusb@gmail.com"
  439. FCT_vte
  440.  
  441.  
  442.  
  443.  
  444. #image-name="multisystem-icon"
  445. #image-name="multisystem-liveusb"
  446. #border-width="5"
  447. MULTISYSTEM='<window width_request="600" height_request="420" spacing="0" window_position="0" title="MultiSystem" icon-name="multisystem-icon" decorated="true" resizable="false">
  448. <vbox spacing="0">
  449.  
  450. <timer milliseconds="true" interval="250" visible="false">
  451. <variable>TIMER</variable>
  452. <sensitive>false</sensitive>
  453. <input file>/tmp/multisystem/multisystem-timer</input>
  454. <action>refresh:TIMER</action>
  455. <action>echo TIMER refresh $(cat /tmp/multisystem/multisystem-timer)</action>
  456. <action>refresh:tab1</action>
  457. <action>refresh:tab2</action>
  458. <action>refresh:tab3</action>
  459. <action>refresh:DAG</action>
  460. <action>refresh:MESSAGES</action>
  461. <action>refresh:tree</action>
  462. </timer>
  463. <notebook page="0" space-expand="false" space-fill="false" tab-border="0" tab-hborder="0" tab-vborder="0" show-border="false" show_tabs="false" labels="0|1">
  464.  
  465. '$(comment Onglet masqué primaire 0)'
  466. <vbox spacing="0">
  467. <notebook page="0" space-expand="false" space-fill="false" tab-border="0" tab-hborder="0" tab-vborder="0" show-border="false" tab-pos="2" scrollable="true" show-tabs="true" enable-popup="true" homogeneous="true" labels="MS|'$(eval_gettext 'Menus')'|'$(eval_gettext 'Démarrage')'|'$(eval_gettext 'Non-Libre')'|'$(eval_gettext 'À propos')'">
  468. '$(comment Onglet N°0 MultiSystem)'
  469. <vbox spacing="0" width_request="380">
  470. <pixmap>
  471. <input file>'${theme_bdo}'</input>
  472. <variable>line1</variable>
  473. </pixmap>
  474. <hbox height_request="200" spacing="0">
  475.  
  476. <vbox spacing="0">
  477.  
  478. <button name="stylebt" width_request="64" height_request="200" tooltip-text="'$(eval_gettext 'Afficher le menu Avancé')'">
  479. <input file icon="multisystem-show"></input>
  480. <variable>show</variable>
  481. <action>hide:show</action>
  482. <action>show:hide</action>
  483. <action>show:qemu</action>
  484. <action>show:vbox</action>
  485. <action>show:btup</action>
  486. <action>show:btmove</action>
  487. <action>show:btdown</action>
  488. <action>show:btclear</action>
  489. <action>show:ckeckrem</action>
  490. <action>show:showhihe</action>
  491. <action>show:btcmdline</action>
  492. <action>show:btpersistent1</action>
  493. <action>show:btcdamorce2</action>
  494. <action>show:btlang1</action>
  495. <action>show:btpref2</action>
  496. <action>show:btgrub</action>
  497. <action>show:update_bootloader</action>
  498. <action>show:btdownload1</action>
  499. <action>show:btmaj1</action>
  500. <action>show:checkupdate2</action>
  501. </button>
  502. <button name="stylebt" width_request="32" height_request="200" tooltip-text="'$(eval_gettext 'Masquer le menu Avancé')'">
  503. <input file icon="multisystem-hide"></input>
  504. <variable>hide</variable>
  505. <action>show:show</action>
  506. <action>hide:hide</action>
  507. <action>hide:qemu</action>
  508. <action>hide:vbox</action>
  509. <action>hide:btup</action>
  510. <action>hide:btmove</action>
  511. <action>hide:btdown</action>
  512. <action>hide:btclear</action>
  513. <action>hide:ckeckrem</action>
  514. <action>hide:showhihe</action>
  515. <action>hide:btcmdline</action>
  516. <action>hide:btpersistent1</action>
  517. <action>hide:btcdamorce2</action>
  518. <action>hide:btlang1</action>
  519. <action>hide:btpref2</action>
  520. <action>hide:btgrub</action>
  521. <action>hide:update_bootloader</action>
  522. <action>hide:btdownload1</action>
  523. <action>hide:btmaj1</action>
  524. <action>hide:checkupdate2</action>
  525. </button>
  526. </vbox>
  527.  
  528. <vbox spacing="0">
  529. <button name="stylebt" width_request="32" height_request="100" tooltip-text="'$(eval_gettext 'Tester dans Qemu')'">
  530. <input file icon="multisystem-qemu"></input>
  531. <variable>qemu</variable>
  532. <action>./fonctions.sh qemu</action>
  533. <action>refresh:MESSAGES</action>
  534. </button>
  535. <button name="stylebt" width_request="32" height_request="100" tooltip-text="'$(eval_gettext 'Tester dans VirtualBox')'">
  536. <input file icon="multisystem-vbox"></input>
  537. <variable>vbox</variable>
  538. <action>./fonctions.sh vbox</action>
  539. <action>refresh:MESSAGES</action>
  540. </button>
  541. </vbox>
  542.  
  543. <tree icon="multisystem-tux" tooltip-text="'$(eval_gettext "Double clic pour modifier les noms dans le menu du bootloader.")'" rules_hint="true" headers_visible="false" hover_expand="false" hover_selection="false" exported_column="1">
  544. <label>1|2|3|4|5</label>
  545. <variable>tree</variable>
  546. <input icon_column="0">if [ "$(cat /tmp/multisystem/multisystem-laisserpasser-usb)" = "ok" ];then cat /tmp/multisystem/multisystem-mise-en-forme;else echo "multisystem-logo|||||||";fi</input>
  547. <action>./fonctions.sh menu\|$tree</action>
  548. <action>refresh:tree</action>
  549. <action>refresh:MESSAGES</action>
  550. </tree>
  551.  
  552. <vbox spacing="0">
  553.  
  554. <button name="stylebt" width_request="32" height_request="40" tooltip-text="Menu up">
  555. <input file stock="gtk-go-up"></input>
  556. <variable>btup</variable>
  557. <input file stock="gtk-delete"></input>
  558. <variable>btclear</variable>
  559. <!-- Masquer les boutons sur terminal VTE -->
  560. <action>hide:btvte2</action>
  561. <action>hide:debugvte</action>
  562. <!-- clear:vte0 -->
  563. <action>clear:vte0</action>
  564. <!-- Changer onglet -->
  565. <action>echo 1 > /tmp/multisystem/multisystem-inputtab1</action>
  566. <action>echo 0 > /tmp/multisystem/multisystem-inputtab3</action>
  567. <action>refresh:tab1</action>
  568. <action>refresh:tab3</action>
  569. <!-- Démarrer le timer -->
  570. <action>echo true >/tmp/multisystem/multisystem-timer</action>
  571. <!-- Fonction à executer -->
  572. <action>test "$tree" && echo selup >/tmp/multisystem/multisystem-function_name</action>
  573. <action>test "$tree" && echo "${tree}">/tmp/multisystem/multisystem-fileselect</action>
  574. <!-- Start Timer -->
  575. <action>echo true >/tmp/multisystem/multisystem-timer</action>
  576. <action>refresh:TIMER</action>
  577. <!-- On raffraichit le terminal -->
  578. <action>refresh:vte0</action>
  579. </button>
  580.  
  581. <button name="stylebt" width_request="32" height_request="40" tooltip-text="Menu move">
  582. <input file stock="gtk-jump-to"></input>
  583. <variable>btmove</variable>
  584. <!-- Masquer les boutons sur terminal VTE -->
  585. <action>hide:btvte2</action>
  586. <action>hide:debugvte</action>
  587. <!-- clear:vte0 -->
  588. <action>clear:vte0</action>
  589. <!-- Changer onglet -->
  590. <action>echo 1 > /tmp/multisystem/multisystem-inputtab1</action>
  591. <action>echo 0 > /tmp/multisystem/multisystem-inputtab3</action>
  592. <action>refresh:tab1</action>
  593. <action>refresh:tab3</action>
  594. <!-- Démarrer le timer -->
  595. <action>echo true >/tmp/multisystem/multisystem-timer</action>
  596. <!-- Fonction à executer -->
  597. <action>test "$tree" && echo move >/tmp/multisystem/multisystem-function_name</action>
  598. <action>test "$tree" && echo "${tree}">/tmp/multisystem/multisystem-fileselect</action>
  599. <!-- Start Timer -->
  600. <action>echo true >/tmp/multisystem/multisystem-timer</action>
  601. <action>refresh:TIMER</action>
  602. <!-- On raffraichit le terminal -->
  603. <action>refresh:vte0</action>
  604. </button>
  605.  
  606. <button name="stylebt" width_request="32" height_request="40" tooltip-text="Menu down">
  607. <input file stock="gtk-go-down"></input>
  608. <variable>btdown</variable>
  609. <!-- Masquer les boutons sur terminal VTE -->
  610. <action>hide:btvte2</action>
  611. <action>hide:debugvte</action>
  612. <!-- clear:vte0 -->
  613. <action>clear:vte0</action>
  614. <!-- Changer onglet -->
  615. <action>echo 1 > /tmp/multisystem/multisystem-inputtab1</action>
  616. <action>echo 0 > /tmp/multisystem/multisystem-inputtab3</action>
  617. <action>refresh:tab1</action>
  618. <action>refresh:tab3</action>
  619. <!-- Démarrer le timer -->
  620. <action>echo true >/tmp/multisystem/multisystem-timer</action>
  621. <!-- Fonction à executer -->
  622. <action>test "$tree" && echo seldown >/tmp/multisystem/multisystem-function_name</action>
  623. <action>test "$tree" && echo "${tree}">/tmp/multisystem/multisystem-fileselect</action>
  624. <!-- Start Timer -->
  625. <action>echo true >/tmp/multisystem/multisystem-timer</action>
  626. <action>refresh:TIMER</action>
  627. <!-- On raffraichit le terminal -->
  628. <action>refresh:vte0</action>
  629. </button>
  630.  
  631. <button name="stylebt" width_request="32" height_request="40" tooltip-text="'$(eval_gettext "Supprimer un système d'exploitation")'">
  632. <input file stock="gtk-delete"></input>
  633. <variable>btclear</variable>
  634. <!-- Masquer les boutons sur terminal VTE -->
  635. <action>hide:btvte2</action>
  636. <action>hide:debugvte</action>
  637. <!-- clear:vte0 -->
  638. <action>clear:vte0</action>
  639. <!-- Changer onglet -->
  640. <action>echo 1 > /tmp/multisystem/multisystem-inputtab1</action>
  641. <action>echo 0 > /tmp/multisystem/multisystem-inputtab3</action>
  642. <action>refresh:tab1</action>
  643. <action>refresh:tab3</action>
  644. <!-- Démarrer le timer -->
  645. <action>echo true >/tmp/multisystem/multisystem-timer</action>
  646. <!-- Fonction à executer -->
  647. <action>test "$tree" && echo selclear >/tmp/multisystem/multisystem-function_name</action>
  648. <action>test "$tree" && echo "${tree}">/tmp/multisystem/multisystem-fileselect</action>
  649. <!-- Start Timer -->
  650. <action>echo true >/tmp/multisystem/multisystem-timer</action>
  651. <action>refresh:TIMER</action>
  652. <!-- On raffraichit le terminal -->
  653. <action>refresh:vte0</action>
  654. </button>
  655.  
  656. <checkbox width_request="32" height_request="40" use-underline="true" active="'$check_rem'" tooltip-text="'$(eval_gettext "Prévenir avant de supprimer")'">
  657. <label>_</label>
  658. <variable>ckeckrem</variable>
  659. <action>if true echo "true" >"$HOME/.multisystem/check_rem"</action>
  660. <action>if false echo "false" >"$HOME/.multisystem/check_rem"</action>
  661. </checkbox>
  662. </vbox>
  663.  
  664. <vbox spacing="0">
  665. <button name="stylebt" width_request="32" height_request="40" tooltip-text="'$(eval_gettext "Afficher/Masquer des fichiers/dossiers dans votre clé usb")'">
  666. <input file icon="multisystem-hidden"></input>
  667. <variable>showhihe</variable>
  668. <action>echo 1 > /tmp/multisystem/multisystem-inputtab1</action>
  669. <action>echo 6 > /tmp/multisystem/multisystem-inputtab3</action>
  670. <action>refresh:tab1</action>
  671. <action>refresh:tab3</action>
  672. <action>refresh:MESSAGES</action>
  673. </button>
  674.  
  675. <button name="stylebt" width_request="32" height_request="40" tooltip-text="'$(eval_gettext "Ajouter une option de démarrage (cmdline)")'">
  676. <input file stock="gtk-edit"></input>
  677. <variable>btcmdline</variable>
  678. <action>test $tree && ./fonctions.sh cmdline\|$tree</action>
  679. <action>refresh:tree</action>
  680. <action>refresh:MESSAGES</action>
  681. </button>
  682.  
  683. <button name="stylebt" width_request="32" height_request="40" tooltip-text="'$(eval_gettext "Ajouter mode persistent")'">
  684. <input file icon="multisystem-save"></input>
  685. <variable>btpersistent1</variable>
  686. <action>./fonctions.sh persistent\|$tree</action>
  687. <action>refresh:tree</action>
  688. <action>refresh:MESSAGES</action>
  689. </button>
  690.  
  691. <button name="stylebt" width_request="32" height_request="40" tooltip-text="'$(eval_gettext 'Créer CD pour lancer USB')'">
  692. <input file icon="multisystem-cdrom"></input>
  693. <variable>btcdamorce2</variable>
  694. <!-- Masquer les boutons sur terminal VTE -->
  695. <action>hide:btvte2</action>
  696. <action>hide:debugvte</action>
  697. <!-- clear:vte0 -->
  698. <action>clear:vte0</action>
  699. <!-- Changer onglet -->
  700. <action>echo 1 > /tmp/multisystem/multisystem-inputtab1</action>
  701. <action>echo 0 > /tmp/multisystem/multisystem-inputtab3</action>
  702. <action>refresh:tab1</action>
  703. <action>refresh:tab3</action>
  704. <!-- Démarrer le timer -->
  705. <action>echo true >/tmp/multisystem/multisystem-timer</action>
  706. <!-- Fonction à executer -->
  707. <action>echo cdamorce >/tmp/multisystem/multisystem-function_name</action>
  708. <!-- Start Timer -->
  709. <action>echo true >/tmp/multisystem/multisystem-timer</action>
  710. <action>refresh:TIMER</action>
  711. <!-- On raffraichit le terminal -->
  712. <action>refresh:vte0</action>
  713. </button>
  714.  
  715. <button name="stylebt" width_request="32" height_request="40" tooltip-text="'$(eval_gettext "Internationalisation")'">
  716. <input file icon="multisystem-language"></input>
  717. <variable>btlang1</variable>
  718. <action>echo 1 > /tmp/multisystem/multisystem-inputtab1</action>
  719. <action>echo 1 > /tmp/multisystem/multisystem-inputtab3</action>
  720. <action>refresh:tab1</action>
  721. <action>refresh:tab3</action>
  722. <action>refresh:MESSAGES</action>
  723. </button>
  724. </vbox>
  725.  
  726. <vbox spacing="0">
  727. <button name="stylebt" width_request="32" height_request="80" tooltip-text="'$(eval_gettext "Réglages Grub")'">
  728. <input file stock="gtk-preferences"></input>
  729. <variable>btpref2</variable>
  730. <action>./fonctions.sh pref</action>
  731. <action>refresh:MESSAGES</action>
  732. </button>
  733. <button name="stylebt" width_request="32" height_request="80" tooltip-text="'$(eval_gettext "Mettre à jour Grub2")'">
  734. <input file icon="multisystem-grub48"></input>
  735. <variable>btgrub</variable>
  736. <!-- Masquer les boutons sur terminal VTE -->
  737. <action>hide:btvte2</action>
  738. <action>hide:debugvte</action>
  739. <!-- clear:vte0 -->
  740. <action>clear:vte0</action>
  741. <!-- Changer onglet -->
  742. <action>echo 1 > /tmp/multisystem/multisystem-inputtab1</action>
  743. <action>echo 0 > /tmp/multisystem/multisystem-inputtab3</action>
  744. <action>refresh:tab1</action>
  745. <action>refresh:tab3</action>
  746. <!-- Démarrer le timer -->
  747. <action>echo true >/tmp/multisystem/multisystem-timer</action>
  748. <!-- Fonction à executer -->
  749. <action>echo grub >/tmp/multisystem/multisystem-function_name</action>
  750. <!-- Start Timer -->
  751. <action>echo true >/tmp/multisystem/multisystem-timer</action>
  752. <action>refresh:TIMER</action>
  753. <!-- On raffraichit le terminal -->
  754. <action>refresh:vte0</action>
  755. </button>
  756.  
  757. <checkbox width_request="32" height_request="40" use-underline="true" active="true" tooltip-text="'$(eval_gettext "Décochez pour déplacer rapidement les menus, ne pas mettre à jour les bootloader, ATTENTION! cochez lors du dernier déplacement pour mettre à jour les bootloader.")'">
  758. <label>_</label>
  759. <variable>update_bootloader</variable>
  760. <action>if true echo true >/tmp/multisystem/multisystem-update-bootloader</action>
  761. <action>if false echo false >/tmp/multisystem/multisystem-update-bootloader</action>
  762. </checkbox>
  763. </vbox>
  764.  
  765. <vbox spacing="0">
  766. <button name="stylebt" width_request="32" height_request="80" tooltip-text="'$(eval_gettext "Télécharger des LiveCD")'">
  767. <input file icon="multisystem-download"></input>
  768. <variable>btdownload1</variable>
  769. <action>echo All | tee /tmp/multisystem/multisystem-output-list</action>
  770. <action>refresh:tree_list</action>
  771. <action>clear:QUOI</action>
  772. <action>echo 1 > /tmp/multisystem/multisystem-inputtab1</action>
  773. <action>echo 2 > /tmp/multisystem/multisystem-inputtab3</action>
  774. <action>refresh:tab1</action>
  775. <action>refresh:tab3</action>
  776. <action>refresh:tree</action>
  777. <action>refresh:MESSAGES</action>
  778. </button>
  779. <button name="stylebt" width_request="32" height_request="80" tooltip-text="'$(eval_gettext "Mise à jour")'">
  780. <input file icon="multisystem-update"></input>
  781. <variable>btmaj1</variable>
  782. <action>echo 1 > /tmp/multisystem/multisystem-inputtab1</action>
  783. <action>echo 3 > /tmp/multisystem/multisystem-inputtab3</action>
  784. <action>refresh:tab1</action>
  785. <action>refresh:tab3</action>
  786. <action>refresh:MESSAGES</action>
  787. </button>
  788.  
  789. <checkbox width_request="32" height_request="40" use-underline="true" tooltip-text="'$(eval_gettext 'Vérifier les mise à jour à chaque lancement')'">
  790. <label>_</label>
  791. <variable>checkupdate2</variable>
  792. <default>true</default>
  793. <action>if true echo true >"'$HOME'/.multisystem/checkupdate"</action>
  794. <action>if false echo false >"'$HOME'/.multisystem/checkupdate"</action>
  795. <input>cat "'$HOME'/.multisystem/checkupdate"</input>
  796. <action>refresh:checkupdate</action>
  797. <action>refresh:checkupdate2</action>
  798. </checkbox>
  799.  
  800. </vbox>
  801.  
  802. </hbox>
  803.  
  804. <pixmap>
  805. <input file>'${theme_bdo}'</input>
  806. <variable>line2</variable>
  807. </pixmap>
  808. <vbox height_request="70" spacing="0">
  809. <text sensitive="false">
  810. <variable>MESSAGES</variable>
  811. <input>echo "'$(eval_gettext "Volume USB:")'$(cat /tmp/multisystem/multisystem-selection-usb) UUID:$(cat /tmp/multisystem/multisystem-selection-uuid-usb)\n'$(eval_gettext 'Point de montage:')'$(cat /tmp/multisystem/multisystem-mountpoint-usb)\n'$(eval_gettext 'Taille:')'$(($(df 2>/dev/null | grep ^$(cat /tmp/multisystem/multisystem-selection-usb) | awk '\''{print $2}'\'')/1024))Mio '$(eval_gettext 'Occupé:')'$(($(df 2>/dev/null | grep ^$(cat /tmp/multisystem/multisystem-selection-usb) | awk '\''{print $3}'\'')/1024))Mio '$(eval_gettext 'Libre:')'$(($(df 2>/dev/null | grep ^$(cat /tmp/multisystem/multisystem-selection-usb) | awk '\''{print $4}'\'')/1024))Mio\n'$(eval_gettext 'Nombre de LiveCD:')'$(cat /tmp/multisystem/multisystem-nombreiso-usb)"</input>
  812. </text>
  813. </vbox>
  814. <pixmap>
  815. <input file>'${theme_bdo}'</input>
  816. <variable>line3</variable>
  817. </pixmap>
  818.  
  819. <hbox spacing="0">
  820. <button name="stylebt" relief="2" tooltip-text="'$(eval_gettext 'Sauvegarde/Restauration')'">
  821. <input file icon="multisystem-save2"></input>
  822. <action>./fonctions.sh save</action>
  823. </button>
  824.  
  825. <frame '$(eval_gettext "Glisser/Déposer iso/img")'>
  826. <hbox spacing="0">
  827. <entry primary-icon-name="multisystem-seliso" secondary-icon-name="'${theme_btn}'" accept="filename" activates-default="false" fs-folder="'$HOME/'" fs-action="file" fs-filters="*.iso|*.img" show-hidden="false" fs-title="Select an iso file" tooltip-text="'$(eval_gettext "Glisser/Déposer iso/img")'" primary-icon-tooltip-text="'$(eval_gettext 'Utilisez ce bouton si le Glisser/Déposer ne fonctionne pas.')'" secondary-icon-tooltip-text="'$(eval_gettext "Ajouter un liveCD")'">
  828. <variable>DAG</variable>
  829. <width>50</width><height>50</height>
  830. <action signal="changed">hide:btvte2</action>
  831. <action signal="primary-icon-press">hide:btvte2</action>
  832. <action signal="secondary-icon-press">hide:btvte2</action>
  833.  
  834. <action signal="changed">hide:debugvte</action>
  835. <action signal="primary-icon-press">hide:debugvte</action>
  836. <action signal="secondary-icon-press">hide:debugvte</action>
  837.  
  838. <!-- primary-icon-press -->
  839. <action signal="primary-icon-press">fileselect:DAG</action>
  840.  
  841. <action signal="changed">test "$DAG" && echo "DAG:$DAG"</action>
  842. <action signal="changed">test "$DAG" && echo "${DAG}">/tmp/multisystem/multisystem-fileselect</action>
  843.  
  844. <!-- clear:vte0 -->
  845. <action signal="changed">clear:vte0</action>
  846.  
  847. <!-- Changer onglet -->
  848. <action signal="changed">echo 1 > /tmp/multisystem/multisystem-inputtab1</action>
  849. <action signal="changed">echo 0 > /tmp/multisystem/multisystem-inputtab3</action>
  850. <action signal="changed">refresh:tab1</action>
  851. <action signal="changed">refresh:tab3</action>
  852.  
  853. <!-- Démarrer le timer -->
  854. <action signal="changed">echo true >/tmp/multisystem/multisystem-timer</action>
  855. <!-- Fonction à executer -->
  856. <action signal="changed">test "$DAG" && echo addvte >/tmp/multisystem/multisystem-function_name</action>
  857.  
  858. <!-- Start Timer -->
  859. <action signal="changed">echo true >/tmp/multisystem/multisystem-timer</action>
  860. <action signal="changed">refresh:TIMER</action>
  861.  
  862. <!-- On raffraichit le terminal -->
  863. <action signal="changed">refresh:vte0</action>
  864.  
  865. <!-- !!! -->
  866. <action signal="changed">clear:DAG</action>
  867.  
  868. <!-- secondary-icon-press -->
  869. <!-- Changer onglet -->
  870. <action signal="secondary-icon-press">echo 1 > /tmp/multisystem/multisystem-inputtab1</action>
  871. <action signal="secondary-icon-press">echo 0 > /tmp/multisystem/multisystem-inputtab3</action>
  872. <action signal="secondary-icon-press">refresh:tab1</action>
  873. <action signal="secondary-icon-press">refresh:tab3</action>
  874. <!-- Start Timer -->
  875. <action signal="secondary-icon-press">echo true >/tmp/multisystem/multisystem-timer</action>
  876. <action signal="secondary-icon-press">refresh:TIMER</action>
  877. <action signal="secondary-icon-press">echo addvtemulti</action>
  878. <action signal="secondary-icon-press">echo addvtemulti >/tmp/multisystem/multisystem-function_name</action>
  879.  
  880. <action signal="secondary-icon-press">clear:vte0</action>
  881.  
  882. <!-- On raffraichit le terminal -->
  883. <action signal="secondary-icon-press">refresh:vte0</action>
  884. </entry>
  885. </hbox>
  886. </frame>
  887.  
  888. <button name="stylebt" relief="2" tooltip-text="'$(eval_gettext "Quitter")'">
  889. <input file icon="multisystem-exit"></input>
  890. <action>wmctrl -c "MultiSystem-logo"</action>
  891. <action>wmctrl -c "MultiSystem-logo2"</action>
  892. <action>wmctrl -c "VBox"</action>
  893. <action type="exit">exit</action>
  894. </button>
  895.  
  896. </hbox>
  897. </vbox>
  898.  
  899.  
  900.  
  901.  
  902. '$(comment Onglet N°1 Menus)'
  903. <vbox spacing="0" height_request="380">
  904.  
  905. <hbox spacing="0" homogeneous="true" space-expand="true" space-fill="false">
  906.  
  907. <vbox spacing="0" space-expand="true" space-fill="false">
  908.  
  909. <button name="stylebt" image-position="2">
  910. <input file stock="gtk-preferences"></input>
  911. <variable>btpref</variable>
  912. <label>'$(eval_gettext 'Réglages Grub')'</label>
  913. <action>./fonctions.sh pref</action>
  914. <action>refresh:MESSAGES</action>
  915. </button>
  916.  
  917. <button name="stylebt" image-position="2">
  918. <input file icon="multisystem-grub48"></input>
  919. <variable>btgrub2</variable>
  920. <label>'$(eval_gettext 'Mettre à jour Grub2')'</label>
  921. <!-- Masquer les boutons sur terminal VTE -->
  922. <action>hide:btvte2</action>
  923. <action>hide:debugvte</action>
  924. <!-- clear:vte0 -->
  925. <action>clear:vte0</action>
  926. <!-- Changer onglet -->
  927. <action>echo 1 > /tmp/multisystem/multisystem-inputtab1</action>
  928. <action>echo 0 > /tmp/multisystem/multisystem-inputtab3</action>
  929. <action>refresh:tab1</action>
  930. <action>refresh:tab3</action>
  931. <!-- Démarrer le timer -->
  932. <action>echo true >/tmp/multisystem/multisystem-timer</action>
  933. <!-- Fonction à executer -->
  934. <action>echo grub >/tmp/multisystem/multisystem-function_name</action>
  935. <!-- Start Timer -->
  936. <action>echo true >/tmp/multisystem/multisystem-timer</action>
  937. <action>refresh:TIMER</action>
  938. <!-- On raffraichit le terminal -->
  939. <action>refresh:vte0</action>
  940. </button>
  941.  
  942. <button name="stylebt" image-position="2">
  943. <input file icon="multisystem-grub48"></input>
  944. <variable>btburg</variable>
  945. <label>'$(eval_gettext 'Mettre à jour Burg')'</label>
  946. <action>./fonctions.sh burg</action>
  947. <action>refresh:MESSAGES</action>
  948. </button>
  949.  
  950. <button name="stylebt" image-position="2">
  951. <input file stock="gtk-save"></input>
  952. <variable>btsave</variable>
  953. <label>'$(eval_gettext 'Sauvegarde/Restauration')'</label>
  954. <action>./fonctions.sh save</action>
  955. <action>refresh:MESSAGES</action>
  956. </button>
  957.  
  958. <button name="stylebt" image-position="2">
  959. <input file icon="multisystem-save"></input>
  960. <variable>btpersistent2</variable>
  961. <label>'$(eval_gettext 'Ajouter mode persistent')'</label>
  962. <action>./fonctions.sh persistent\|$tree</action>
  963. <action>refresh:MESSAGES</action>
  964. <action>refresh:tree</action>
  965. </button>
  966.  
  967. <button name="stylebt" image-position="2">
  968. <input file icon="multisystem-resize"></input>
  969. <variable>btpersistent3</variable>
  970. <label>'$(eval_gettext 'Redimensionner persistent')'</label>
  971. <action>./fonctions.sh persistent-resize</action>
  972. <action>refresh:MESSAGES</action>
  973. <action>refresh:tree</action>
  974. </button>
  975.  
  976. <button name="stylebt" image-position="2">
  977. <input file icon="multisystem-download"></input>
  978. <variable>btdownload2</variable>
  979. <label>'$(eval_gettext 'Télécharger des LiveCD')'</label>
  980. <action>echo All | tee /tmp/multisystem/multisystem-output-list</action>
  981. <action>refresh:tree_list</action>
  982. <action>clear:QUOI</action>
  983. <action>echo 1 > /tmp/multisystem/multisystem-inputtab1</action>
  984. <action>echo 2 > /tmp/multisystem/multisystem-inputtab3</action>
  985. <action>refresh:tab1</action>
  986. <action>refresh:tab3</action>
  987. <action>refresh:tree</action>
  988. <action>refresh:MESSAGES</action>
  989. </button>
  990.  
  991. </vbox>
  992. <vbox spacing="0" space-expand="true" space-fill="false">
  993.  
  994. <button name="stylebt" image-position="2">
  995. <input file icon="multisystem-language"></input>
  996. <variable>btlang2</variable>
  997. <label>'$(eval_gettext 'Internationalisation')'</label>
  998. <action>echo 1 > /tmp/multisystem/multisystem-inputtab1</action>
  999. <action>echo 1 > /tmp/multisystem/multisystem-inputtab3</action>
  1000. <action>refresh:tab1</action>
  1001. <action>refresh:tab3</action>
  1002. <action>refresh:MESSAGES</action>
  1003. </button>
  1004.  
  1005. <button name="stylebt" image-position="2">
  1006. <input file icon="display"></input>
  1007. <variable>btvte</variable>
  1008. <label>'$(eval_gettext 'Terminal')'</label>
  1009. <action>echo 1 > /tmp/multisystem/multisystem-inputtab1</action>
  1010. <action>echo 0 > /tmp/multisystem/multisystem-inputtab3</action>
  1011. <action>refresh:tab1</action>
  1012. <action>refresh:tab3</action>
  1013. <action signal="changed">echo true >/tmp/multisystem/multisystem-timer</action>
  1014. <action>clear:vte0</action>
  1015. <action>show:btvte2</action>
  1016. <action>show:debugvte</action>
  1017. <action signal="changed">refresh:TIMER</action>
  1018. </button>
  1019.  
  1020. <button name="stylebt" image-position="2">
  1021. <input file icon="multisystem-gparted64"></input>
  1022. <variable>btformat</variable>
  1023. <label>'$(eval_gettext 'Formater votre clé USB')'</label>
  1024. <action>echo 1 > /tmp/multisystem/multisystem-inputtab1</action>
  1025. <action>echo 5 > /tmp/multisystem/multisystem-inputtab3</action>
  1026. <action>refresh:tab1</action>
  1027. <action>refresh:tab3</action>
  1028. <action>refresh:MESSAGES</action>
  1029. </button>
  1030.  
  1031. <button name="stylebt" image-position="2">
  1032. <input file stock="gtk-execute"></input>
  1033. <variable>btdebug</variable>
  1034. <label>'$(eval_gettext 'Déboguer')'</label>
  1035. <action>echo "" >/tmp/multisystem/multisystem-test-usb</action>
  1036. <action>refresh:debug_edit</action>
  1037. <action>echo 1 > /tmp/multisystem/multisystem-inputtab1</action>
  1038. <action>echo 4 > /tmp/multisystem/multisystem-inputtab3</action>
  1039. <action>refresh:tab1</action>
  1040. <action>refresh:tab3</action>
  1041. <action>refresh:MESSAGES</action>
  1042. </button>
  1043.  
  1044. <button name="stylebt" image-position="2">
  1045. <input file icon="multisystem-vbox"></input>
  1046. <variable>btinstallvbox</variable>
  1047. <label>'$(eval_gettext 'Installer VirtualBox')'</label>
  1048. <action>./fonctions.sh installvbox</action>
  1049. <action>refresh:MESSAGES</action>
  1050. </button>
  1051.  
  1052. <button name="stylebt" image-position="2">
  1053. <input file icon="multisystem-update"></input>
  1054. <variable>btmaj2</variable>
  1055. <label>'$(eval_gettext 'Mise à jour')'</label>
  1056. <action>echo 1 > /tmp/multisystem/multisystem-inputtab1</action>
  1057. <action>echo 3 > /tmp/multisystem/multisystem-inputtab3</action>
  1058. <action>refresh:tab1</action>
  1059. <action>refresh:tab3</action>
  1060. <action>refresh:MESSAGES</action>
  1061. </button>
  1062.  
  1063. <button name="stylebt" image-position="2">
  1064. <input file stock="gtk-delete"></input>
  1065. <variable>btuninstall</variable>
  1066. <label>'$(eval_gettext 'Désinstaller')'</label>
  1067. <action>nohup xterm -title 'Uninstall' -e "sudo ./uninstall.sh" &</action>
  1068. <action>wmctrl -c "MultiSystem-logo"</action>
  1069. <action>wmctrl -c "MultiSystem-logo2"</action>
  1070. <action>wmctrl -c "VBox"</action>
  1071. <action type="exit">exit</action>
  1072. </button>
  1073.  
  1074. </vbox>
  1075.  
  1076. </hbox>
  1077. </vbox>
  1078.  
  1079.  
  1080.  
  1081.  
  1082.  
  1083.  
  1084. '$(comment Onglet N°2 Démarrage)'
  1085. <vbox spacing="0" height_request="380">
  1086. <hbox>
  1087. <button name="stylebt" width_request="36" height_request="36">
  1088. <input file icon="multisystem-cdrom"></input>
  1089. <variable>btcdamorce</variable>
  1090. <!-- Masquer les boutons sur terminal VTE -->
  1091. <action>hide:btvte2</action>
  1092. <action>hide:debugvte</action>
  1093. <!-- clear:vte0 -->
  1094. <action>clear:vte0</action>
  1095. <!-- Changer onglet -->
  1096. <action>echo 1 > /tmp/multisystem/multisystem-inputtab1</action>
  1097. <action>echo 0 > /tmp/multisystem/multisystem-inputtab3</action>
  1098. <action>refresh:tab1</action>
  1099. <action>refresh:tab3</action>
  1100. <!-- Démarrer le timer -->
  1101. <action>echo true >/tmp/multisystem/multisystem-timer</action>
  1102. <!-- Fonction à executer -->
  1103. <action>echo cdamorce >/tmp/multisystem/multisystem-function_name</action>
  1104. <!-- Start Timer -->
  1105. <action>echo true >/tmp/multisystem/multisystem-timer</action>
  1106. <action>refresh:TIMER</action>
  1107. <!-- On raffraichit le terminal -->
  1108. <action>refresh:vte0</action>
  1109. </button>
  1110.  
  1111. <text width_request="345" use-markup="true">
  1112. <label>"<b>'$(eval_gettext 'Créer CD pour lancer USB')'</b>"</label>
  1113. </text>
  1114. </hbox>
  1115. <pixmap>
  1116. <input file>'${theme_bdo}'</input>
  1117. </pixmap>
  1118. <hbox>
  1119. <button name="stylebt" width_request="36" height_request="36">
  1120. <input file icon="multisystem-grub48"></input>
  1121. <variable>btinfoboot</variable>
  1122. <action>./fonctions.sh infoboot\|grub</action>
  1123. <action>refresh:MESSAGES</action>
  1124. </button>
  1125. <text width_request="345" use-markup="true">
  1126. <label>"<b>'$(eval_gettext 'Boot depuis Grub/Grub2')'</b>"</label>
  1127. </text>
  1128. </hbox>
  1129. <hbox>
  1130. <button name="stylebt" width_request="36" height_request="36">
  1131. <input file icon="multisystem-windows48"></input>
  1132. <variable>btinfoboot</variable>
  1133. <action>./fonctions.sh infoboot\|xp</action>
  1134. <action>refresh:MESSAGES</action>
  1135. </button>
  1136. <text width_request="345" use-markup="true">
  1137. <label>"<b>'$(eval_gettext 'Boot depuis Windows XP')'</b>"</label>
  1138. </text>
  1139. </hbox>
  1140. <hbox>
  1141. <button name="stylebt" width_request="36" height_request="36">
  1142. <input file icon="multisystem-windows48"></input>
  1143. <variable>btinfoboot</variable>
  1144. <action>./fonctions.sh infoboot\|vista</action>
  1145. <action>refresh:MESSAGES</action>
  1146. </button>
  1147. <text width_request="345" use-markup="true">
  1148. <label>"<b>'$(eval_gettext 'Boot depuis Windows Vista')'</b>"</label>
  1149. </text>
  1150. </hbox>
  1151. <hbox>
  1152. <button name="stylebt" width_request="36" height_request="36">
  1153. <input file icon="multisystem-apple48"></input>
  1154. <variable>btinfoboot</variable>
  1155. <action>./fonctions.sh infoboot\|macintel</action>
  1156. <action>refresh:MESSAGES</action>
  1157. </button>
  1158. <text width_request="345" use-markup="true">
  1159. <label>"<b>'$(eval_gettext 'Boot depuis MacIntel')'</b>"</label>
  1160. </text>
  1161. </hbox>
  1162. <pixmap>
  1163. <input file>'${theme_bdo}'</input>
  1164. </pixmap>
  1165. <hbox>
  1166. <button name="stylebt" width_request="36" height_request="36">
  1167. <input file icon="multisystem-qemu"></input>
  1168. <variable>btqemu</variable>
  1169. <action>./fonctions.sh qemu</action>
  1170. <action>refresh:MESSAGES</action>
  1171. </button>
  1172. <text width_request="345" use-markup="true">
  1173. <label>"<b>'$(eval_gettext 'Tester votre liveUSB dans Qemu')'</b>"</label>
  1174. </text>
  1175. </hbox>
  1176. <hbox>
  1177. <button name="stylebt" width_request="36" height_request="36">
  1178. <input file icon="multisystem-vbox"></input>
  1179. <variable>btvbox1</variable>
  1180. <action>./fonctions.sh vbox</action>
  1181. <action>refresh:MESSAGES</action>
  1182. </button>
  1183. <text width_request="345" use-markup="true">
  1184. <label>"<b>'$(eval_gettext 'Tester votre liveUSB dans VirtualBox')'</b>"</label>
  1185. </text>
  1186. </hbox>
  1187. <hbox>
  1188. <button name="stylebt" width_request="36" height_request="36">
  1189. <input file icon="multisystem-vbox"></input>
  1190. <variable>btvbox2</variable>
  1191. <action>wmctrl -c "VBox"</action>
  1192. <action>./VBox_livecd_gui.sh &</action>
  1193. <action>refresh:MESSAGES</action>
  1194. </button>
  1195. <text width_request="345" use-markup="true">
  1196. <label>"<b>'$(eval_gettext 'Tester un LiveCD dans VirtualBox')'</b>"</label>
  1197. </text>
  1198. </hbox>
  1199. </vbox>
  1200.  
  1201.  
  1202.  
  1203. '$(comment Onglet N°3 Non-Libre)'
  1204. <vbox spacing="0" height_request="380">
  1205. <text use-markup="true" wrap="true" width-chars="70" sensitive="false">
  1206. <input>echo "\<b>\<big>'$(eval_gettext "Partie Non Libre de MultiSystem")'\</big>\</b>" | sed "s%\\\%%g"</input>
  1207. </text>
  1208.  
  1209. <pixmap>
  1210. <input file>'${theme_bdo}'</input>
  1211. </pixmap>
  1212.  
  1213. <hbox>
  1214. <button name="stylebt" tooltip-text="'$(eval_gettext 'PLoP Boot Manager est un freeware.')'">
  1215. <input file icon="multisystem-plop-logo"></input>
  1216. <label>"'$(eval_gettext 'Télécharger PLoP Boot Manager')'"</label>
  1217. <action>./fonctions-nonfree.sh plop</action>
  1218. <action>refresh:tree2</action>
  1219. </button>
  1220. </hbox>
  1221.  
  1222. <pixmap>
  1223. <input file>'${theme_bdo}'</input>
  1224. </pixmap>
  1225.  
  1226. <hbox>
  1227. <button name="stylebt" tooltip-text="'$(eval_gettext 'Utilisé pour démarrer les iso de Windows XP')'">
  1228. <input file icon="multisystem-windows48"></input>
  1229. <label>'$(eval_gettext 'Télécharger firadisk.ima')'</label>
  1230. <action>./fonctions-nonfree.sh firadisk</action>
  1231. <action>refresh:tree2</action>
  1232. </button>
  1233. </hbox>
  1234.  
  1235. <pixmap>
  1236. <input file>'${theme_bdo}'</input>
  1237. </pixmap>
  1238.  
  1239. <vbox homogeneous="true">
  1240. <hbox>
  1241. <button name="stylebt" tooltip-text="'$(eval_gettext 'Utilisé pour les iso BartPE')'">
  1242. <input file icon="multisystem-windows48"></input>
  1243. <label>'$(eval_gettext 'Télécharger Microsoft Windows Server 2003 SP1')'</label>
  1244. <action>./fonctions-nonfree.sh bartpe</action>
  1245. <action>refresh:tree2</action>
  1246. </button>
  1247. </hbox>
  1248. </vbox>
  1249.  
  1250. <pixmap>
  1251. <input file>'${theme_bdo}'</input>
  1252. </pixmap>
  1253.  
  1254. <hbox height_request="200">
  1255. <tree hover_selection="true" headers_visible="false" exported_column="0">
  1256. <label>files</label>
  1257. <input icon_column="0">cat /tmp/multisystem/multisystem-nonfree</input>
  1258. <variable>tree2</variable>
  1259. <action signal="button-press-event">nohup '${navuse}' "$HOME"/.multisystem/nonfree&</action>
  1260. </tree>
  1261. </hbox>
  1262.  
  1263. <pixmap>
  1264. <input file>'${theme_bdo}'</input>
  1265. </pixmap>
  1266.  
  1267. </vbox>
  1268.  
  1269.  
  1270.  
  1271.  
  1272. '$(comment Onglet N°4 À propos)'
  1273. <vbox spacing="0" height_request="380">
  1274. <text use-markup="true" wrap="true" sensitive="false">
  1275. <input>echo "\<b>'$(eval_gettext 'MultiSystem recherche des traducteurs,\nSi vous souhaitez participer,\nMerci de nous contacter.\nContact:')'liveusb@gmail.com\</b>" | sed "s%\\\%%g"</input>
  1276. </text>
  1277. <pixmap>
  1278. <input file>'${theme_bdo}'</input>
  1279. </pixmap>
  1280. <vbox height_request="32" homogeneous="true">
  1281. <text use-underline="true"><label>_</label></text>
  1282. <text use-markup="true">
  1283. <input file>/tmp/multisystem/multisystem-inputversion</input>
  1284. </text>
  1285. </vbox>
  1286. <pixmap>
  1287. <input file>'${theme_bdo}'</input>
  1288. </pixmap>
  1289. <hbox>
  1290. <pixmap>
  1291. <input file>"'${dossier}'/pixmaps/multisystem-map-flags.png"</input>
  1292. </pixmap>
  1293. </hbox>
  1294. <pixmap>
  1295. <input file>'${theme_bdo}'</input>
  1296. </pixmap>
  1297. <hbox height_request="160">
  1298. <tree headers_visible="false" exported_column="1">
  1299. <label>1|2|3</label>
  1300. <input icon_column="0">cat /tmp/multisystem/multisystem-about</input>
  1301. <variable>tree3</variable>
  1302. <action>xdg-email --utf8 --subject "MultiSystem translation" --body "message" "${tree3}" &</action>
  1303. </tree>
  1304. </hbox>
  1305. <pixmap>
  1306. <input file>'${theme_bdo}'</input>
  1307. </pixmap>
  1308. </vbox>
  1309.  
  1310.  
  1311. <variable>tab2</variable>
  1312. <input file>/tmp/multisystem/multisystem-inputtab2</input>
  1313. <action signal="show">refresh:tree</action>
  1314. </notebook>
  1315. </vbox>
  1316.  
  1317.  
  1318.  
  1319.  
  1320. '$(comment Onglet masqué secondaire 1)'
  1321. <vbox spacing="0">
  1322. <notebook page="0" space-expand="false" space-fill="false" tab-border="0" tab-hborder="0" tab-vborder="0" show-border="false" show_tabs="false" labels="0|1|2|3|4|5|6|7|8|9|10|11">
  1323.  
  1324.  
  1325. '$(comment Onglet N°0 Terminal VTE)'
  1326. <vbox spacing="0">
  1327. <hbox spacing="0" height_request="410">
  1328.  
  1329. <vbox spacing="0">
  1330. <!-- Retour Home -->
  1331. <button name="returnhome" height_request="205" tooltip-text="'$(eval_gettext 'Retour Accueil')'">
  1332. <input file stock="gtk-home"></input>
  1333. <variable>btvte2</variable>
  1334. <action>echo 0 >/tmp/multisystem/multisystem-inputtab1</action>
  1335. <action>echo 0 >/tmp/multisystem/multisystem-inputtab2</action>
  1336. <action>echo 0 >/tmp/multisystem/multisystem-inputtab3</action>
  1337. <action>echo "" >/tmp/multisystem/multisystem-fileselect</action>
  1338. <action>echo false >/tmp/multisystem/multisystem-timer</action>
  1339. <action>refresh:tab1</action>
  1340. <action>refresh:tab2</action>
  1341. <action>refresh:tab3</action>
  1342. <action>refresh:DAG</action>
  1343. <action>refresh:MESSAGES</action>
  1344. <action>refresh:tree</action>
  1345. <action>refresh:TIMER</action>
  1346. </button>
  1347. <button name="debugvte" height_request="205" tooltip-text="Executer debug.sh">
  1348. <input file stock="gtk-execute"></input>
  1349. <variable>debugvte</variable>
  1350. <action>echo "debugvte" >/tmp/multisystem/multisystem-function_name</action>
  1351. <action>clear:vte0</action>
  1352. <action>refresh:vte0</action>
  1353. </button>
  1354. </vbox>
  1355.  
  1356. <terminal has-focus="true" argv0="/bin/bash">
  1357. <variable>vte0</variable>
  1358. <input>bash -c "source ${dossier}/gtkdialog-function.sh;FCT_vte $(cat /tmp/multisystem/multisystem-function_name)"</input>
  1359. <height>0</height>
  1360. <width>0</width>
  1361. </terminal>
  1362. </hbox>
  1363. </vbox>
  1364.  
  1365.  
  1366. '$(comment Onglet N°1 Internationalisation)'
  1367. <vbox spacing="0">
  1368. <vbox height_request="370">
  1369. <frame '$(eval_gettext 'Changer de language')'>
  1370. <hbox spacing="0" height_request="32">
  1371. <pixmap>
  1372. <input file icon="config-language"></input>
  1373. <height>32</height>
  1374. <width>32</width>
  1375. </pixmap>
  1376. <text width_request="5" use-underline="true"><label>_</label></text>
  1377. <comboboxtext allow-empty="false" value-in-list="true" tooltip-text="'$(eval_gettext 'Changer de language')'">
  1378. <variable>lister_lang</variable>
  1379. <input>bash -c "source ${dossier}/gtkdialog-function.sh;FCT_lister_lang"</input>
  1380. <action signal="changed">echo "$(grep "^$lister_lang" "'${dossier}'/lang_list.txt")" >"$HOME/.multisystem/lang_sel.txt"</action>
  1381. <action signal="changed">nohup "${dossier}/gui_multisystem.sh" &</action>
  1382. <action signal="changed">wmctrl -c "MultiSystem-logo"</action>
  1383. <action signal="changed">wmctrl -c "MultiSystem-logo2"</action>
  1384. <action signal="changed">wmctrl -c "VBox"</action>
  1385. <action signal="changed">exit:selang</action>
  1386. </comboboxtext>
  1387. </hbox>
  1388. </frame>
  1389.  
  1390. <pixmap>
  1391. <input file>'${theme_bdo}'</input>
  1392. </pixmap>
  1393.  
  1394. <frame>
  1395. <text use-markup="true" wrap="true" sensitive="false">
  1396. <input>echo "\<b>\<big>'$texte_annonce'\</big>\</b>" | sed "s%\\\%%g"</input>
  1397. </text>
  1398. </frame>
  1399. </vbox>
  1400. '$(FCT_HOME)'
  1401. </vbox>
  1402.  
  1403.  
  1404.  
  1405.  
  1406.  
  1407.  
  1408. '$(comment Onglet N°2 Télécharger des LiveCD)'
  1409. <vbox spacing="0">
  1410. <vbox height_request="370">
  1411.  
  1412. <hbox>
  1413. <entry activates_default="true">
  1414. <variable>QUOI</variable>
  1415. </entry>
  1416. <button name="stylebt">
  1417. <input file stock="gtk-find"></input>
  1418. <variable>RECHERCHER</variable>
  1419. <action>echo "$QUOI" >/tmp/multisystem/multisystem-output-list</action>
  1420. <action>refresh:tree_list</action>
  1421. </button>
  1422. </hbox>
  1423.  
  1424. <hbox>
  1425. <button name="stylebt">
  1426. <label>All</label>
  1427. <input file stock="gtk-find"></input>
  1428. <action>clear:QUOI</action>
  1429. <action>echo All | tee /tmp/multisystem/multisystem-output-list</action>
  1430. <action>refresh:tree_list</action>
  1431. </button>
  1432.  
  1433. <button name="stylebt">
  1434. <label>Audio</label>
  1435. <input file stock="gtk-find"></input>
  1436. <action>clear:QUOI</action>
  1437. <action>echo Audio | tee /tmp/multisystem/multisystem-output-list</action>
  1438. <action>refresh:tree_list</action>
  1439. </button>
  1440.  
  1441. <button name="stylebt">
  1442. <label>Utility</label>
  1443. <input file stock="gtk-find"></input>
  1444. <action>clear:QUOI</action>
  1445. <action>echo Utility | tee /tmp/multisystem/multisystem-output-list</action>
  1446. <action>refresh:tree_list</action>
  1447. </button>
  1448.  
  1449. <button name="stylebt">
  1450. <label>Antivirus</label>
  1451. <input file stock="gtk-find"></input>
  1452. <action>clear:QUOI</action>
  1453. <action>echo Antivirus | tee /tmp/multisystem/multisystem-output-list</action>
  1454. <action>refresh:tree_list</action>
  1455. </button>
  1456.  
  1457. <button name="stylebt">
  1458. <label>Gamer</label>
  1459. <input file stock="gtk-find"></input>
  1460. <action>clear:QUOI</action>
  1461. <action>echo Gamer | tee /tmp/multisystem/multisystem-output-list</action>
  1462. <action>refresh:tree_list</action>
  1463. </button>
  1464. </hbox>
  1465.  
  1466. <tree  headers_visible="true" exported_column="3" rules_hint="true">
  1467. <label>Name|Bootloader|Category|URL Download</label>
  1468. <variable>tree_list</variable>
  1469. <input icon_column="0">bash -c "source ${dossier}/gtkdialog-function.sh;FCT_download_livecd"</input>
  1470. <action>test ${tree_list} && xdg-open ${tree_list} &</action>
  1471. </tree>
  1472. </vbox>
  1473. '$(FCT_HOME)'
  1474. </vbox>
  1475.  
  1476.  
  1477.  
  1478.  
  1479.  
  1480. '$(comment Onglet N°3 Mise à jour)'
  1481. <vbox spacing="0">
  1482. <vbox height_request="370">
  1483. <pixmap>
  1484. <input file>'${theme_bdo}'</input>
  1485. </pixmap>
  1486. <vbox width_request="400" width_request="50" scrollable="true">
  1487. <text use-markup="true" wrap="true" width-chars="70">
  1488. <input>echo "\<b>\<span color=\"red\">'$(eval_gettext "A ce jour MultiSystem est gratuit\nmais son développement n\\047est pas sans frais!\nSi vous l\\047utilisez régulièrement\net que vous souhaitez qu\\047il continue à évoluer,\nmerci de faire un geste de soutien via paypal.\n\npar avance MERCI!\nFrançois Fabre @frafa")'\</span>\</b>" | sed "s%\\\%%g" | sed "s%\\\\n\\\\n\\\\n%%g"</input>
  1489. </text>
  1490. </vbox>
  1491. <pixmap>
  1492. <input file>'${theme_bdo}'</input>
  1493. </pixmap>
  1494.  
  1495. <checkbox>
  1496. <label>"'$(eval_gettext 'Vérifier les mise à jour à chaque lancement')'"</label>
  1497. <variable>checkupdate</variable>
  1498. <default>true</default>
  1499. <action>if true echo true >"'$HOME'/.multisystem/checkupdate"</action>
  1500. <action>if false echo false >"'$HOME'/.multisystem/checkupdate"</action>
  1501. <input>cat "'$HOME'/.multisystem/checkupdate"</input>
  1502. <action>refresh:checkupdate</action>
  1503. <action>refresh:checkupdate2</action>
  1504. </checkbox>
  1505.  
  1506. <pixmap>
  1507. <input file>'${theme_bdo}'</input>
  1508. </pixmap>
  1509. <vbox spacing="0">
  1510. <radiobutton active="true">
  1511. <label>"'$(eval_gettext "Faire une donation")'"</label>
  1512. <variable>radio1</variable>
  1513. </radiobutton>
  1514. <radiobutton>
  1515. <label>"'$(eval_gettext "Ne pas faire de donation")'"</label>
  1516. <variable>radio2</variable>
  1517. </radiobutton>
  1518. </vbox>
  1519. <pixmap>
  1520. <input file>'${theme_bdo}'</input>
  1521. </pixmap>
  1522. <vbox spacing="0">
  1523. <radiobutton active="true">
  1524. <label>"'$(eval_gettext "Mise à jour")'"</label>
  1525. <variable>radio3</variable>
  1526. </radiobutton>
  1527. <radiobutton>
  1528. <label>"'$(eval_gettext "Mise à jour partielle")'"</label>
  1529. <variable>radio4</variable>
  1530. </radiobutton>
  1531. </vbox>
  1532. <pixmap>
  1533. <input file>'${theme_bdo}'</input>
  1534. </pixmap>
  1535. <hbox>
  1536. <button name="stylebt">
  1537. <input file icon="multisystem-update"></input>
  1538. <label>'$(eval_gettext 'Mise à jour')'</label>
  1539. <action>bash -c "source ${dossier}/gtkdialog-function.sh;FCT_update" &</action>
  1540. <action>wmctrl -c "MultiSystem-logo"</action>
  1541. <action>wmctrl -c "MultiSystem-logo2"</action>
  1542. <action>wmctrl -c "VBox"</action>
  1543. <action type="exit">exit</action>
  1544. </button>
  1545. </hbox>
  1546. </vbox>
  1547. '$(FCT_HOME)'
  1548. </vbox>
  1549.  
  1550.  
  1551.  
  1552.  
  1553.  
  1554. '$(comment Onglet N°4 Déboguer)'
  1555. <vbox spacing="0">
  1556. <vbox height_request="370">
  1557.  
  1558. <frame Debug>
  1559. <vbox scrollable="true">
  1560. <edit>
  1561. <variable>debug_edit</variable>
  1562. <input file>/tmp/multisystem/multisystem-test-usb</input>
  1563. </edit>
  1564. </vbox>
  1565. </frame>
  1566.  
  1567. <hbox homogeneous="true">
  1568. <button name="stylebt" width_request="180">
  1569. <input file icon="gtk-execute"></input>
  1570. <label>"'$(eval_gettext "fdisk -l")'"</label>
  1571. <action>fdisk -l $(cat /tmp/multisystem/multisystem-selection-usb | sed '\''s/[0-9]//'\'')>/tmp/multisystem/multisystem-test-usb</action>
  1572. <action>refresh:debug_edit</action>
  1573. </button>
  1574. <button name="stylebt" width_request="180">
  1575. <input file icon="gtk-execute"></input>
  1576. <label>"'$(eval_gettext "parted print")'"</label>
  1577. <action>parted -s $(cat /tmp/multisystem/multisystem-selection-usb | sed '\''s/[0-9]//'\'') unit MB print >/tmp/multisystem/multisystem-test-usb</action>
  1578. <action>refresh:debug_edit</action>
  1579. </button>
  1580. </hbox>
  1581.  
  1582. <hbox homogeneous="true">
  1583. <hbox spacing="0">
  1584. <button name="stylebt" width_request="115">
  1585. <input file icon="gtk-execute"></input>
  1586. <label>"'$(eval_gettext "Afficher mbr")'"</label>
  1587. <action>dd if="$(cat /tmp/multisystem/multisystem-selection-usb | sed '\''s/[0-9]//'\'')" bs=512 count=1 | xxd >/tmp/multisystem/multisystem-test-usb</action>
  1588. <action>refresh:debug_edit</action>
  1589. </button>
  1590. <button name="stylebt" width_request="65">
  1591. <input file icon="gtk-execute"></input>
  1592. <label>"'$(cat /tmp/multisystem/multisystem-selection-usb | sed 's@/dev/@@')'"</label>
  1593. <action>dd if="$(cat /tmp/multisystem/multisystem-selection-usb)" bs=512 count=1 | xxd >/tmp/multisystem/multisystem-test-usb</action>
  1594. <action>refresh:debug_edit</action>
  1595. </button>
  1596. </hbox>
  1597.  
  1598. <button name="stylebt" width_request="180">
  1599. <input file icon="gtk-execute"></input>
  1600. <label>"'$(eval_gettext "udevadm info")'"</label>
  1601. <action>udevadm info -q all -n $(cat /tmp/multisystem/multisystem-selection-usb | sed '\''s/[0-9]//'\'') >/tmp/multisystem/multisystem-test-usb</action>
  1602. <action>refresh:debug_edit</action>
  1603. </button>
  1604. </hbox>
  1605.  
  1606. <hbox homogeneous="true">
  1607. <button name="stylebt" width_request="180">
  1608. <input file icon="gtk-execute"></input>
  1609. <label>"'$(eval_gettext "Version Grub2")'"</label>
  1610. <action>grub-install --version >/tmp/multisystem/multisystem-test-usb</action>
  1611. <action>refresh:debug_edit</action>
  1612. </button>
  1613. <button name="stylebt" width_request="180">
  1614. <input file icon="gtk-execute"></input>
  1615. <label>"'$(eval_gettext "Réparer fat32")'"</label>
  1616. <action signal="button-press-event">echo '${message_debug}' >/tmp/multisystem/multisystem-test-usb</action>
  1617. <action signal="button-press-event">refresh:debug_edit</action>
  1618. <action signal="button-release-event">bash -c "source ${dossier}/gtkdialog-function.sh;xterm -e FCT_debug_repair"</action>
  1619. <action signal="button-release-event">echo >/tmp/multisystem/multisystem-test-usb</action>
  1620. <action signal="button-release-event">refresh:debug_edit</action>
  1621. </button>
  1622. </hbox>
  1623.  
  1624. <hbox homogeneous="true">
  1625. <button name="stylebt" width_request="180">
  1626. <input file icon="gtk-execute"></input>
  1627. <label>"'$(eval_gettext "Benchmark écriture")'"</label>
  1628. <action signal="button-press-event">echo '${message_debug}' >/tmp/multisystem/multisystem-test-usb</action>
  1629. <action signal="button-press-event">refresh:debug_edit</action>
  1630. <action signal="button-release-event">bash -c "source ${dossier}/gtkdialog-function.sh;xterm -e FCT_debug_write"</action>
  1631. <action signal="button-release-event">refresh:debug_edit</action>
  1632. </button>
  1633. <button name="stylebt" width_request="180">
  1634. <input file icon="gtk-execute"></input>
  1635. <label>"'$(eval_gettext "Benchmark lecture")'"</label>
  1636. <action signal="button-press-event">echo '${message_debug}' >/tmp/multisystem/multisystem-test-usb</action>
  1637. <action signal="button-press-event">refresh:debug_edit</action>
  1638. <action signal="button-release-event">bash -c "source ${dossier}/gtkdialog-function.sh;xterm -e FCT_debug_read"</action>
  1639. <action signal="button-release-event">echo >/tmp/multisystem/multisystem-test-usb</action>
  1640. <action signal="button-release-event">refresh:debug_edit</action>
  1641. </button>
  1642. </hbox>
  1643. </vbox>
  1644. '$(FCT_HOME)'
  1645. </vbox>
  1646.  
  1647.  
  1648.  
  1649.  
  1650.  
  1651. '$(comment Onglet N°5 Formater votre clé USB)'
  1652. <vbox spacing="0">
  1653. <vbox height_request="370">
  1654. <frame '$(eval_gettext 'Informations')'>
  1655. <vbox scrollable="true">
  1656. <text use-markup="true" sensitive="false">
  1657. <input>echo "\<b>\<big>'$(eval_gettext "ATTENTION!\nVous allez formater\nle volume amovible:")' $(cat /tmp/multisystem/multisystem-selection-usb | sed 's/[0-9]//')'$(eval_gettext "\nTout son contenu\nsera définitivement éffacé.")'\</big>\</b>" | sed "s%\\\%%g"</input>
  1658. </text>
  1659. </vbox>
  1660. </frame>
  1661. <edit editable="true" cursor-visible="true" accepts-tab="true" left-margin="2" right-margin="2" indent="2">
  1662. <input file>/tmp/multisystem/multisystem-format-text</input>
  1663. </edit>
  1664. <pixmap>
  1665. <input file>./pixmaps/multisystem-usbpendrive.png</input>
  1666. </pixmap>
  1667. <hbox>
  1668. <button name="stylebt" relief="2" tooltip-text="'$(eval_gettext 'Valider')'">
  1669. <input file stock="gtk-apply"></input>
  1670. <label>"'$(eval_gettext 'Valider')'"</label>
  1671. <action>bash -c "source ${dossier}/gtkdialog-function.sh;xterm -e FCT_format" &</action>
  1672. <action>wmctrl -c "MultiSystem-logo"</action>
  1673. <action>wmctrl -c "MultiSystem-logo2"</action>
  1674. <action>wmctrl -c "VBox"</action>
  1675. <action type="exit">format</action>
  1676. </button>
  1677. </hbox>
  1678. </vbox>
  1679. '$(FCT_HOME)'
  1680. </vbox>
  1681.  
  1682.  
  1683.  
  1684.  
  1685.  
  1686. '$(comment Onglet N°6 Afficher/Masquer des fichiers/dossiers dans votre clé usb)'
  1687. <vbox spacing="0">
  1688. <vbox height_request="370">
  1689.  
  1690. <frame>
  1691. <text use-markup="true" wrap="true" width-chars="70" sensitive="false">
  1692. <input>echo "\<b>\<big>'$(eval_gettext "Afficher/Masquer des fichiers/dossiers\nFonctionne uniquement avec Nautilus.")'\</big>\</b>" | sed "s%\\\%%g"</input>
  1693. </text>
  1694. </frame>
  1695.  
  1696. <hbox homogeneous="true">
  1697. <button name="stylebt" tooltip-text="'$(eval_gettext 'Afficher tous')'">
  1698. <input file icon="multisystem-green"></input>
  1699. <label>'$(eval_gettext 'Afficher tous')'</label>
  1700. <action>bash -c "source ${dossier}/gtkdialog-function.sh;FCT_hidden_showall"</action>
  1701. <action>refresh:hidden_tree</action>
  1702. </button>
  1703. <button name="stylebt" tooltip-text="'$(eval_gettext 'Masquer tous')'">
  1704. <input file icon="multisystem-red"></input>
  1705. <label>'$(eval_gettext 'Masquer tous')'</label>
  1706. <action>bash -c "source ${dossier}/gtkdialog-function.sh;FCT_hidden_hiddenall"</action>
  1707. <action>refresh:hidden_tree</action>
  1708. </button>
  1709. </hbox>
  1710.  
  1711. <frame '$(eval_gettext 'Contenu de votre clé USB')'>
  1712. <hbox height_request="210">
  1713. <tree hover_selection="true" headers_visible="false" exported_column="0">
  1714. <label>files</label>
  1715. <input icon_column="0">cat /tmp/multisystem/multisystem-hidden</input>
  1716. <variable>hidden_tree</variable>
  1717. <action signal="button-press-event">bash -c "source ${dossier}/gtkdialog-function.sh;FCT_hidden_modify $hidden_tree"</action>
  1718. <action signal="button-press-event">refresh:hidden_tree</action>
  1719. </tree>
  1720. </hbox>
  1721. </frame>
  1722.  
  1723. </vbox>
  1724. '$(FCT_HOME)'
  1725. </vbox>
  1726.  
  1727.  
  1728.  
  1729.  
  1730.  
  1731. '$(comment Onglet N°7 N/A)'
  1732. <vbox spacing="0">
  1733. <vbox height_request="370">
  1734. <pixmap>
  1735. <input file>'${theme_bdo}'</input>
  1736. </pixmap>
  1737. <text><label>N/A 7</label></text>
  1738. </vbox>
  1739. '$(FCT_HOME)'
  1740. </vbox>
  1741.  
  1742.  
  1743.  
  1744.  
  1745.  
  1746.  
  1747. '$(comment Onglet N°8 N/A)'
  1748. <vbox spacing="0">
  1749. <vbox height_request="370">
  1750. <pixmap>
  1751. <input file>'${theme_bdo}'</input>
  1752. </pixmap>
  1753. <text><label>N/A 8</label></text>
  1754. </vbox>
  1755. '$(FCT_HOME)'
  1756. </vbox>
  1757.  
  1758.  
  1759.  
  1760.  
  1761.  
  1762. '$(comment Onglet N°9 N/A)'
  1763. <vbox spacing="0">
  1764. <vbox height_request="370">
  1765. <pixmap>
  1766. <input file>'${theme_bdo}'</input>
  1767. </pixmap>
  1768. <text><label>N/A 9</label></text>
  1769. </vbox>
  1770. '$(FCT_HOME)'
  1771. </vbox>
  1772.  
  1773.  
  1774.  
  1775. <variable>tab3</variable>
  1776. <input file>/tmp/multisystem/multisystem-inputtab3</input>
  1777. <action signal="show">refresh:tree</action>
  1778. </notebook>
  1779. </vbox>
  1780. <variable>tab1</variable>
  1781. <input file>/tmp/multisystem/multisystem-inputtab1</input>
  1782. <action signal="show">refresh:tree</action>
  1783. </notebook>
  1784. </vbox>
  1785. <action signal="delete-event">wmctrl -c "MultiSystem-logo"</action>
  1786. <action signal="delete-event">wmctrl -c "MultiSystem-logo"2</action>
  1787. <action signal="delete-event">wmctrl -c "VBox"</action>
  1788. <action signal="focus-in-event">clear:DAG</action>
  1789. <action signal="focus-in-event">refresh:DAG</action>
  1790. <action signal="focus-in-event">refresh:MESSAGES</action>
  1791. <action signal="focus-in-event">refresh:tree</action>
  1792. <action signal="show">wmctrl -c "MultiSystem-logo"</action>
  1793. <action signal="show">refresh:MESSAGES</action>
  1794. <action signal="show">refresh:tree</action>
  1795. <action signal="hide">refresh:DAG</action>
  1796. <action signal="show">hide:hide</action>
  1797. <action signal="show">hide:qemu</action>
  1798. <action signal="show">hide:vbox</action>
  1799. <action signal="show">hide:btup</action>
  1800. <action signal="show">hide:btmove</action>
  1801. <action signal="show">hide:btdown</action>
  1802. <action signal="show">hide:btclear</action>
  1803. <action signal="show">hide:ckeckrem</action>
  1804. <action signal="show">hide:showhihe</action>
  1805. <action signal="show">hide:btcmdline</action>
  1806. <action signal="show">hide:btpersistent1</action>
  1807. <action signal="show">hide:btcdamorce2</action>
  1808. <action signal="show">hide:btlang1</action>
  1809. <action signal="show">hide:btpref2</action>
  1810. <action signal="show">hide:btgrub</action>
  1811. <action signal="show">hide:update_bootloader</action>
  1812. <action signal="show">hide:btdownload1</action>
  1813. <action signal="show">hide:btmaj1</action>
  1814. <action signal="show">hide:checkupdate2</action>
  1815. <variable>window</variable>
  1816. </window>'
  1817. export MULTISYSTEM="$(sed 's@<!--.*-->@@g' <<<"$MULTISYSTEM")"
  1818. export MULTISYSTEM
  1819. $GTKDIALOG --program=MULTISYSTEM
  1820.  
  1821. #echo -e "$MULTISYSTEM" >/tmp/multisystem/multisystem.xml
  1822. #$GTKDIALOG -f /tmp/multisystem/multisystem.xml
  1823. exit 0
Add Comment
Please, Sign In to add comment