[tuxdroid-svn] r748 - in software/gadgets/tux_controller/trunk: . TuxController TuxController/Pictu
Status: Beta
Brought to you by:
ks156
From: Paul_R <c2m...@c2...> - 2007-12-03 16:31:48
|
Author: Paul_R Date: 2007-12-03 17:31:43 +0100 (Mon, 03 Dec 2007) New Revision: 748 Added: software/gadgets/tux_controller/trunk/TuxController/Pictures/Icons/beak_closed.png software/gadgets/tux_controller/trunk/TuxController/Pictures/Icons/beak_open.png software/gadgets/tux_controller/trunk/TuxController/Pictures/Icons/eyes_closed.png software/gadgets/tux_controller/trunk/TuxController/Pictures/Icons/led_off.png software/gadgets/tux_controller/trunk/TuxController/Pictures/Icons/led_on.png software/gadgets/tux_controller/trunk/TuxController/Pictures/Icons/spin_left.png software/gadgets/tux_controller/trunk/TuxController/Pictures/Icons/spin_off.png software/gadgets/tux_controller/trunk/TuxController/Pictures/Icons/spin_right.png software/gadgets/tux_controller/trunk/TuxController/Pictures/Icons/wings_down.png software/gadgets/tux_controller/trunk/TuxController/Pictures/Icons/wings_up.png Modified: software/gadgets/tux_controller/trunk/TuxController.tgf software/gadgets/tux_controller/trunk/TuxController/Pictures/Icons/down.png software/gadgets/tux_controller/trunk/TuxController/Pictures/Icons/left.png software/gadgets/tux_controller/trunk/TuxController/Pictures/Icons/right.png software/gadgets/tux_controller/trunk/TuxController/Pictures/Icons/run.png software/gadgets/tux_controller/trunk/TuxController/Pictures/Icons/up.png software/gadgets/tux_controller/trunk/TuxController/Scripts/Python/GUI/widget/other.glade software/gadgets/tux_controller/trunk/TuxController/Scripts/Python/GUI/widget/other.pyp software/gadgets/tux_controller/trunk/TuxController/settings.xml software/gadgets/tux_controller/trunk/TuxDroidController.tgf Log: * Added the images Added: software/gadgets/tux_controller/trunk/TuxController/Pictures/Icons/beak_closed.png =================================================================== (Binary files differ) Property changes on: software/gadgets/tux_controller/trunk/TuxController/Pictures/Icons/beak_closed.png ___________________________________________________________________ Name: svn:mime-type + application/octet-stream Added: software/gadgets/tux_controller/trunk/TuxController/Pictures/Icons/beak_open.png =================================================================== (Binary files differ) Property changes on: software/gadgets/tux_controller/trunk/TuxController/Pictures/Icons/beak_open.png ___________________________________________________________________ Name: svn:mime-type + application/octet-stream Modified: software/gadgets/tux_controller/trunk/TuxController/Pictures/Icons/down.png =================================================================== (Binary files differ) Added: software/gadgets/tux_controller/trunk/TuxController/Pictures/Icons/eyes_closed.png =================================================================== (Binary files differ) Property changes on: software/gadgets/tux_controller/trunk/TuxController/Pictures/Icons/eyes_closed.png ___________________________________________________________________ Name: svn:mime-type + application/octet-stream Added: software/gadgets/tux_controller/trunk/TuxController/Pictures/Icons/led_off.png =================================================================== (Binary files differ) Property changes on: software/gadgets/tux_controller/trunk/TuxController/Pictures/Icons/led_off.png ___________________________________________________________________ Name: svn:mime-type + application/octet-stream Added: software/gadgets/tux_controller/trunk/TuxController/Pictures/Icons/led_on.png =================================================================== (Binary files differ) Property changes on: software/gadgets/tux_controller/trunk/TuxController/Pictures/Icons/led_on.png ___________________________________________________________________ Name: svn:mime-type + application/octet-stream Modified: software/gadgets/tux_controller/trunk/TuxController/Pictures/Icons/left.png =================================================================== (Binary files differ) Modified: software/gadgets/tux_controller/trunk/TuxController/Pictures/Icons/right.png =================================================================== (Binary files differ) Modified: software/gadgets/tux_controller/trunk/TuxController/Pictures/Icons/run.png =================================================================== (Binary files differ) Added: software/gadgets/tux_controller/trunk/TuxController/Pictures/Icons/spin_left.png =================================================================== (Binary files differ) Property changes on: software/gadgets/tux_controller/trunk/TuxController/Pictures/Icons/spin_left.png ___________________________________________________________________ Name: svn:mime-type + application/octet-stream Added: software/gadgets/tux_controller/trunk/TuxController/Pictures/Icons/spin_off.png =================================================================== (Binary files differ) Property changes on: software/gadgets/tux_controller/trunk/TuxController/Pictures/Icons/spin_off.png ___________________________________________________________________ Name: svn:mime-type + application/octet-stream Added: software/gadgets/tux_controller/trunk/TuxController/Pictures/Icons/spin_right.png =================================================================== (Binary files differ) Property changes on: software/gadgets/tux_controller/trunk/TuxController/Pictures/Icons/spin_right.png ___________________________________________________________________ Name: svn:mime-type + application/octet-stream Modified: software/gadgets/tux_controller/trunk/TuxController/Pictures/Icons/up.png =================================================================== (Binary files differ) Added: software/gadgets/tux_controller/trunk/TuxController/Pictures/Icons/wings_down.png =================================================================== (Binary files differ) Property changes on: software/gadgets/tux_controller/trunk/TuxController/Pictures/Icons/wings_down.png ___________________________________________________________________ Name: svn:mime-type + application/octet-stream Added: software/gadgets/tux_controller/trunk/TuxController/Pictures/Icons/wings_up.png =================================================================== (Binary files differ) Property changes on: software/gadgets/tux_controller/trunk/TuxController/Pictures/Icons/wings_up.png ___________________________________________________________________ Name: svn:mime-type + application/octet-stream Modified: software/gadgets/tux_controller/trunk/TuxController/Scripts/Python/GUI/widget/other.glade =================================================================== --- software/gadgets/tux_controller/trunk/TuxController/Scripts/Python/GUI/widget/other.glade 2007-12-03 15:05:36 UTC (rev 747) +++ software/gadgets/tux_controller/trunk/TuxController/Scripts/Python/GUI/widget/other.glade 2007-12-03 16:31:43 UTC (rev 748) @@ -41,7 +41,7 @@ <property name="border_width">2</property> <property name="visible">True</property> <property name="n_rows">5</property> - <property name="n_columns">2</property> + <property name="n_columns">3</property> <property name="homogeneous">False</property> <property name="row_spacing">0</property> <property name="column_spacing">0</property> @@ -281,18 +281,6 @@ <property name="y">16</property> </packing> </child> - - <child> - <widget class="GtkHSeparator" id="hseparator16"> - <property name="width_request">518</property> - <property name="height_request">5</property> - <property name="visible">True</property> - </widget> - <packing> - <property name="x">0</property> - <property name="y">60</property> - </packing> - </child> </widget> <packing> <property name="left_attach">1</property> @@ -305,18 +293,6 @@ <child> <widget class="GtkFixed" id="fixed13"> <property name="visible">True</property> - - <child> - <widget class="GtkHSeparator" id="hseparator17"> - <property name="width_request">288</property> - <property name="height_request">5</property> - <property name="visible">True</property> - </widget> - <packing> - <property name="x">0</property> - <property name="y">60</property> - </packing> - </child> </widget> <packing> <property name="left_attach">0</property> @@ -328,106 +304,6 @@ </child> <child> - <widget class="GtkFixed" id="fixed22"> - <property name="visible">True</property> - - <child> - <widget class="GtkHSeparator" id="hseparator21"> - <property name="width_request">288</property> - <property name="height_request">5</property> - <property name="visible">True</property> - </widget> - <packing> - <property name="x">0</property> - <property name="y">60</property> - </packing> - </child> - </widget> - <packing> - <property name="left_attach">0</property> - <property name="right_attach">1</property> - <property name="top_attach">1</property> - <property name="bottom_attach">2</property> - <property name="x_options">fill</property> - </packing> - </child> - - <child> - <widget class="GtkFixed" id="fixed23"> - <property name="visible">True</property> - - <child> - <widget class="GtkHSeparator" id="hseparator22"> - <property name="width_request">288</property> - <property name="height_request">5</property> - <property name="visible">True</property> - </widget> - <packing> - <property name="x">0</property> - <property name="y">60</property> - </packing> - </child> - </widget> - <packing> - <property name="left_attach">0</property> - <property name="right_attach">1</property> - <property name="top_attach">2</property> - <property name="bottom_attach">3</property> - <property name="x_options">fill</property> - </packing> - </child> - - <child> - <widget class="GtkFixed" id="fixed24"> - <property name="visible">True</property> - - <child> - <widget class="GtkHSeparator" id="hseparator23"> - <property name="width_request">288</property> - <property name="height_request">5</property> - <property name="visible">True</property> - </widget> - <packing> - <property name="x">0</property> - <property name="y">60</property> - </packing> - </child> - </widget> - <packing> - <property name="left_attach">0</property> - <property name="right_attach">1</property> - <property name="top_attach">3</property> - <property name="bottom_attach">4</property> - <property name="x_options">fill</property> - </packing> - </child> - - <child> - <widget class="GtkFixed" id="fixed25"> - <property name="visible">True</property> - - <child> - <widget class="GtkHSeparator" id="hseparator24"> - <property name="width_request">288</property> - <property name="height_request">5</property> - <property name="visible">True</property> - </widget> - <packing> - <property name="x">0</property> - <property name="y">77</property> - </packing> - </child> - </widget> - <packing> - <property name="left_attach">0</property> - <property name="right_attach">1</property> - <property name="top_attach">4</property> - <property name="bottom_attach">5</property> - <property name="x_options">fill</property> - </packing> - </child> - - <child> <widget class="GtkFixed" id="fixed26"> <property name="visible">True</property> @@ -452,18 +328,6 @@ </child> <child> - <widget class="GtkHSeparator" id="hseparator25"> - <property name="width_request">518</property> - <property name="height_request">5</property> - <property name="visible">True</property> - </widget> - <packing> - <property name="x">0</property> - <property name="y">60</property> - </packing> - </child> - - <child> <widget class="GtkVSeparator" id="vseparator11"> <property name="width_request">16</property> <property name="height_request">50</property> @@ -612,18 +476,18 @@ </child> <child> - <widget class="GtkButton" id="btnEyesOpen"> + <widget class="GtkButton" id="btnEyesClose"> <property name="width_request">32</property> <property name="height_request">32</property> <property name="visible">True</property> <property name="can_focus">True</property> <property name="relief">GTK_RELIEF_NONE</property> <property name="focus_on_click">False</property> - <signal name="pressed" handler="on_btnEyesOpen_pressed" last_modification_time="Fri, 16 Nov 2007 07:47:02 GMT"/> - <signal name="released" handler="on_btnEyesOpen_released" last_modification_time="Fri, 16 Nov 2007 07:47:05 GMT"/> + <signal name="pressed" handler="on_btnEyesClose_pressed" last_modification_time="Fri, 16 Nov 2007 07:47:14 GMT"/> + <signal name="released" handler="on_btnEyesClose_released" last_modification_time="Fri, 16 Nov 2007 07:47:18 GMT"/> <child> - <widget class="GtkAlignment" id="alignment1"> + <widget class="GtkAlignment" id="alignment3"> <property name="visible">True</property> <property name="xalign">0.5</property> <property name="yalign">0.5</property> @@ -635,13 +499,13 @@ <property name="right_padding">0</property> <child> - <widget class="GtkHBox" id="hbox1"> + <widget class="GtkHBox" id="hbox3"> <property name="visible">True</property> <property name="homogeneous">False</property> <property name="spacing">2</property> <child> - <widget class="GtkImage" id="imgEyesOpen"> + <widget class="GtkImage" id="imgEyesClose"> <property name="visible">True</property> <property name="can_focus">True</property> <property name="has_focus">True</property> @@ -660,7 +524,7 @@ </child> <child> - <widget class="GtkLabel" id="label1"> + <widget class="GtkLabel" id="label3"> <property name="visible">True</property> <property name="label" translatable="yes"> </property> @@ -691,23 +555,23 @@ </widget> <packing> <property name="x">16</property> - <property name="y">0</property> + <property name="y">32</property> </packing> </child> <child> - <widget class="GtkButton" id="btnEyesClose"> + <widget class="GtkButton" id="btnEyesOpen"> <property name="width_request">32</property> <property name="height_request">32</property> <property name="visible">True</property> <property name="can_focus">True</property> <property name="relief">GTK_RELIEF_NONE</property> <property name="focus_on_click">False</property> - <signal name="pressed" handler="on_btnEyesClose_pressed" last_modification_time="Fri, 16 Nov 2007 07:47:14 GMT"/> - <signal name="released" handler="on_btnEyesClose_released" last_modification_time="Fri, 16 Nov 2007 07:47:18 GMT"/> + <signal name="pressed" handler="on_btnEyesOpen_pressed" last_modification_time="Fri, 16 Nov 2007 07:47:02 GMT"/> + <signal name="released" handler="on_btnEyesOpen_released" last_modification_time="Fri, 16 Nov 2007 07:47:05 GMT"/> <child> - <widget class="GtkAlignment" id="alignment3"> + <widget class="GtkAlignment" id="alignment1"> <property name="visible">True</property> <property name="xalign">0.5</property> <property name="yalign">0.5</property> @@ -719,13 +583,13 @@ <property name="right_padding">0</property> <child> - <widget class="GtkHBox" id="hbox3"> + <widget class="GtkHBox" id="hbox1"> <property name="visible">True</property> <property name="homogeneous">False</property> <property name="spacing">2</property> <child> - <widget class="GtkImage" id="imgEyesClose"> + <widget class="GtkImage" id="imgEyesOpen"> <property name="visible">True</property> <property name="can_focus">True</property> <property name="has_focus">True</property> @@ -744,7 +608,7 @@ </child> <child> - <widget class="GtkLabel" id="label3"> + <widget class="GtkLabel" id="label1"> <property name="visible">True</property> <property name="label" translatable="yes"> </property> @@ -775,7 +639,7 @@ </widget> <packing> <property name="x">16</property> - <property name="y">32</property> + <property name="y">16</property> </packing> </child> </widget> @@ -814,18 +678,6 @@ </child> <child> - <widget class="GtkHSeparator" id="hseparator26"> - <property name="width_request">518</property> - <property name="height_request">5</property> - <property name="visible">True</property> - </widget> - <packing> - <property name="x">0</property> - <property name="y">60</property> - </packing> - </child> - - <child> <widget class="GtkVSeparator" id="vseparator13"> <property name="width_request">16</property> <property name="height_request">50</property> @@ -850,88 +702,6 @@ </child> <child> - <widget class="GtkButton" id="button4"> - <property name="width_request">32</property> - <property name="height_request">32</property> - <property name="visible">True</property> - <property name="can_focus">True</property> - <property name="relief">GTK_RELIEF_NONE</property> - <property name="focus_on_click">False</property> - - <child> - <widget class="GtkAlignment" id="alignment4"> - <property name="visible">True</property> - <property name="xalign">0.5</property> - <property name="yalign">0.5</property> - <property name="xscale">0</property> - <property name="yscale">0</property> - <property name="top_padding">0</property> - <property name="bottom_padding">0</property> - <property name="left_padding">0</property> - <property name="right_padding">0</property> - - <child> - <widget class="GtkHBox" id="hbox4"> - <property name="visible">True</property> - <property name="homogeneous">False</property> - <property name="spacing">2</property> - - <child> - <widget class="GtkImage" id="image4"> - <property name="visible">True</property> - <property name="can_focus">True</property> - <property name="has_focus">True</property> - <property name="stock">gtk-go-up</property> - <property name="icon_size">4</property> - <property name="xalign">0</property> - <property name="yalign">0</property> - <property name="xpad">0</property> - <property name="ypad">0</property> - </widget> - <packing> - <property name="padding">0</property> - <property name="expand">False</property> - <property name="fill">False</property> - </packing> - </child> - - <child> - <widget class="GtkLabel" id="label4"> - <property name="visible">True</property> - <property name="label" translatable="yes"> -</property> - <property name="use_underline">True</property> - <property name="use_markup">False</property> - <property name="justify">GTK_JUSTIFY_LEFT</property> - <property name="wrap">False</property> - <property name="selectable">False</property> - <property name="xalign">0.5</property> - <property name="yalign">0.5</property> - <property name="xpad">0</property> - <property name="ypad">0</property> - <property name="ellipsize">PANGO_ELLIPSIZE_NONE</property> - <property name="width_chars">-1</property> - <property name="single_line_mode">False</property> - <property name="angle">0</property> - </widget> - <packing> - <property name="padding">0</property> - <property name="expand">False</property> - <property name="fill">False</property> - </packing> - </child> - </widget> - </child> - </widget> - </child> - </widget> - <packing> - <property name="x">16</property> - <property name="y">0</property> - </packing> - </child> - - <child> <widget class="GtkRadioButton" id="radMouthsec"> <property name="width_request">114</property> <property name="height_request">22</property> @@ -1219,7 +989,7 @@ </widget> <packing> <property name="x">16</property> - <property name="y">32</property> + <property name="y">24</property> </packing> </child> </widget> @@ -1258,18 +1028,6 @@ </child> <child> - <widget class="GtkHSeparator" id="hseparator27"> - <property name="width_request">518</property> - <property name="height_request">5</property> - <property name="visible">True</property> - </widget> - <packing> - <property name="x">0</property> - <property name="y">60</property> - </packing> - </child> - - <child> <widget class="GtkVSeparator" id="vseparator15"> <property name="width_request">16</property> <property name="height_request">50</property> @@ -1282,18 +1040,6 @@ </child> <child> - <widget class="GtkVSeparator" id="vseparator14"> - <property name="width_request">16</property> - <property name="height_request">50</property> - <property name="visible">True</property> - </widget> - <packing> - <property name="x">65</property> - <property name="y">7</property> - </packing> - </child> - - <child> <widget class="GtkRadioButton" id="radWingssec"> <property name="width_request">114</property> <property name="height_request">22</property> @@ -1438,18 +1184,18 @@ </child> <child> - <widget class="GtkButton" id="btnWingsUp"> + <widget class="GtkButton" id="btnWingsDown"> <property name="width_request">32</property> <property name="height_request">32</property> <property name="visible">True</property> <property name="can_focus">True</property> <property name="relief">GTK_RELIEF_NONE</property> <property name="focus_on_click">False</property> - <signal name="pressed" handler="on_btnWingsUp_pressed" last_modification_time="Fri, 16 Nov 2007 07:47:48 GMT"/> - <signal name="released" handler="on_btnWingsUp_released" last_modification_time="Fri, 16 Nov 2007 07:47:50 GMT"/> + <signal name="pressed" handler="on_btnWingsDown_pressed" last_modification_time="Fri, 16 Nov 2007 07:47:58 GMT"/> + <signal name="released" handler="on_btnWingsDown_released" last_modification_time="Fri, 16 Nov 2007 07:48:01 GMT"/> <child> - <widget class="GtkAlignment" id="alignment6"> + <widget class="GtkAlignment" id="alignment7"> <property name="visible">True</property> <property name="xalign">0.5</property> <property name="yalign">0.5</property> @@ -1461,13 +1207,13 @@ <property name="right_padding">0</property> <child> - <widget class="GtkHBox" id="hbox6"> + <widget class="GtkHBox" id="hbox7"> <property name="visible">True</property> <property name="homogeneous">False</property> <property name="spacing">2</property> <child> - <widget class="GtkImage" id="imgWingsUp"> + <widget class="GtkImage" id="imgWingsDown"> <property name="visible">True</property> <property name="can_focus">True</property> <property name="has_focus">True</property> @@ -1486,7 +1232,7 @@ </child> <child> - <widget class="GtkLabel" id="label6"> + <widget class="GtkLabel" id="label7"> <property name="visible">True</property> <property name="label" translatable="yes"> </property> @@ -1517,23 +1263,23 @@ </widget> <packing> <property name="x">16</property> - <property name="y">0</property> + <property name="y">40</property> </packing> </child> <child> - <widget class="GtkButton" id="btnWingsDown"> + <widget class="GtkButton" id="btnWingsUp"> <property name="width_request">32</property> <property name="height_request">32</property> <property name="visible">True</property> <property name="can_focus">True</property> <property name="relief">GTK_RELIEF_NONE</property> <property name="focus_on_click">False</property> - <signal name="pressed" handler="on_btnWingsDown_pressed" last_modification_time="Fri, 16 Nov 2007 07:47:58 GMT"/> - <signal name="released" handler="on_btnWingsDown_released" last_modification_time="Fri, 16 Nov 2007 07:48:01 GMT"/> + <signal name="pressed" handler="on_btnWingsUp_pressed" last_modification_time="Fri, 16 Nov 2007 07:47:48 GMT"/> + <signal name="released" handler="on_btnWingsUp_released" last_modification_time="Fri, 16 Nov 2007 07:47:50 GMT"/> <child> - <widget class="GtkAlignment" id="alignment7"> + <widget class="GtkAlignment" id="alignment6"> <property name="visible">True</property> <property name="xalign">0.5</property> <property name="yalign">0.5</property> @@ -1545,13 +1291,13 @@ <property name="right_padding">0</property> <child> - <widget class="GtkHBox" id="hbox7"> + <widget class="GtkHBox" id="hbox6"> <property name="visible">True</property> <property name="homogeneous">False</property> <property name="spacing">2</property> <child> - <widget class="GtkImage" id="imgWingsDown"> + <widget class="GtkImage" id="imgWingsUp"> <property name="visible">True</property> <property name="can_focus">True</property> <property name="has_focus">True</property> @@ -1570,7 +1316,7 @@ </child> <child> - <widget class="GtkLabel" id="label7"> + <widget class="GtkLabel" id="label6"> <property name="visible">True</property> <property name="label" translatable="yes"> </property> @@ -1601,9 +1347,21 @@ </widget> <packing> <property name="x">16</property> - <property name="y">32</property> + <property name="y">8</property> </packing> </child> + + <child> + <widget class="GtkVSeparator" id="vseparator14"> + <property name="width_request">16</property> + <property name="height_request">50</property> + <property name="visible">True</property> + </widget> + <packing> + <property name="x">65</property> + <property name="y">7</property> + </packing> + </child> </widget> <packing> <property name="left_attach">1</property> @@ -2005,18 +1763,6 @@ </child> <child> - <widget class="GtkHSeparator" id="hseparator28"> - <property name="width_request">518</property> - <property name="height_request">5</property> - <property name="visible">True</property> - </widget> - <packing> - <property name="x">0</property> - <property name="y">77</property> - </packing> - </child> - - <child> <widget class="GtkVSeparator" id="vseparator17"> <property name="width_request">16</property> <property name="height_request">70</property> @@ -2037,6 +1783,128 @@ <property name="y_options">fill</property> </packing> </child> + + <child> + <widget class="GtkFixed" id="fixed25"> + <property name="visible">True</property> + + <child> + <widget class="GtkImage" id="imgSpin"> + <property name="width_request">367</property> + <property name="height_request">83</property> + <property name="visible">True</property> + <property name="xalign">0.5</property> + <property name="yalign">0.5</property> + <property name="xpad">0</property> + <property name="ypad">0</property> + </widget> + <packing> + <property name="x">0</property> + <property name="y">0</property> + </packing> + </child> + </widget> + <packing> + <property name="left_attach">0</property> + <property name="right_attach">1</property> + <property name="top_attach">4</property> + <property name="bottom_attach">5</property> + <property name="x_options">fill</property> + <property name="y_options">fill</property> + </packing> + </child> + + <child> + <widget class="GtkFixed" id="fixed24"> + <property name="width_request">372</property> + <property name="height_request">0</property> + <property name="visible">True</property> + + <child> + <widget class="GtkImage" id="imgWings"> + <property name="width_request">367</property> + <property name="height_request">142</property> + <property name="visible">True</property> + <property name="xalign">0.5</property> + <property name="yalign">0.5</property> + <property name="xpad">0</property> + <property name="ypad">0</property> + </widget> + <packing> + <property name="x">0</property> + <property name="y">0</property> + </packing> + </child> + </widget> + <packing> + <property name="left_attach">0</property> + <property name="right_attach">1</property> + <property name="top_attach">3</property> + <property name="bottom_attach">4</property> + <property name="x_options">fill</property> + <property name="y_options">fill</property> + </packing> + </child> + + <child> + <widget class="GtkFixed" id="fixed23"> + <property name="visible">True</property> + + <child> + <widget class="GtkImage" id="imgMouth"> + <property name="width_request">367</property> + <property name="height_request">62</property> + <property name="visible">True</property> + <property name="xalign">0.5</property> + <property name="yalign">0.5</property> + <property name="xpad">0</property> + <property name="ypad">0</property> + </widget> + <packing> + <property name="x">0</property> + <property name="y">0</property> + </packing> + </child> + </widget> + <packing> + <property name="left_attach">0</property> + <property name="right_attach">1</property> + <property name="top_attach">2</property> + <property name="bottom_attach">3</property> + <property name="x_options">fill</property> + <property name="y_options">fill</property> + </packing> + </child> + + <child> + <widget class="GtkFixed" id="fixed22"> + <property name="visible">True</property> + + <child> + <widget class="GtkImage" id="imgEyes"> + <property name="width_request">367</property> + <property name="height_request">79</property> + <property name="visible">True</property> + <property name="xalign">0.5</property> + <property name="yalign">0.5</property> + <property name="xpad">0</property> + <property name="ypad">0</property> + </widget> + <packing> + <property name="x">0</property> + <property name="y">16</property> + </packing> + </child> + </widget> + <packing> + <property name="left_attach">0</property> + <property name="right_attach">1</property> + <property name="top_attach">1</property> + <property name="bottom_attach">2</property> + <property name="x_options">fill</property> + <property name="y_options">fill</property> + </packing> + </child> </widget> <packing> <property name="padding">0</property> @@ -2104,15 +1972,15 @@ </child> <child> - <widget class="GtkLabel" id="lblSoundL"> - <property name="width_request">138</property> - <property name="height_request">16</property> + <widget class="GtkLabel" id="lblSound"> + <property name="width_request">46</property> + <property name="height_request">17</property> <property name="visible">True</property> <property name="label" translatable="yes"> </property> <property name="use_underline">False</property> <property name="use_markup">False</property> - <property name="justify">GTK_JUSTIFY_RIGHT</property> - <property name="wrap">True</property> + <property name="justify">GTK_JUSTIFY_LEFT</property> + <property name="wrap">False</property> <property name="selectable">False</property> <property name="xalign">0.5</property> <property name="yalign">0.5</property> @@ -2124,13 +1992,13 @@ <property name="angle">0</property> </widget> <packing> - <property name="x">0</property> + <property name="x">312</property> <property name="y">56</property> </packing> </child> <child> - <widget class="GtkLabel" id="lblLight"> + <widget class="GtkLabel" id="lblBattery"> <property name="width_request">46</property> <property name="height_request">17</property> <property name="visible">True</property> @@ -2151,20 +2019,20 @@ </widget> <packing> <property name="x">312</property> - <property name="y">8</property> + <property name="y">32</property> </packing> </child> <child> - <widget class="GtkLabel" id="lblBattery"> - <property name="width_request">46</property> - <property name="height_request">17</property> + <widget class="GtkLabel" id="lblLightL"> + <property name="width_request">138</property> + <property name="height_request">16</property> <property name="visible">True</property> - <property name="label" translatable="yes"> </property> + <property name="label" translatable="yes"></property> <property name="use_underline">False</property> <property name="use_markup">False</property> - <property name="justify">GTK_JUSTIFY_LEFT</property> - <property name="wrap">False</property> + <property name="justify">GTK_JUSTIFY_RIGHT</property> + <property name="wrap">True</property> <property name="selectable">False</property> <property name="xalign">0.5</property> <property name="yalign">0.5</property> @@ -2177,20 +2045,20 @@ </widget> <packing> <property name="x">312</property> - <property name="y">32</property> + <property name="y">0</property> </packing> </child> <child> - <widget class="GtkLabel" id="lblSound"> - <property name="width_request">46</property> - <property name="height_request">17</property> + <widget class="GtkLabel" id="lblBatteryL"> + <property name="width_request">138</property> + <property name="height_request">16</property> <property name="visible">True</property> <property name="label" translatable="yes"> </property> <property name="use_underline">False</property> <property name="use_markup">False</property> - <property name="justify">GTK_JUSTIFY_LEFT</property> - <property name="wrap">False</property> + <property name="justify">GTK_JUSTIFY_RIGHT</property> + <property name="wrap">True</property> <property name="selectable">False</property> <property name="xalign">0.5</property> <property name="yalign">0.5</property> @@ -2202,17 +2070,17 @@ <property name="angle">0</property> </widget> <packing> - <property name="x">312</property> - <property name="y">56</property> + <property name="x">0</property> + <property name="y">32</property> </packing> </child> <child> - <widget class="GtkLabel" id="lblLightL"> + <widget class="GtkLabel" id="lblSoundL"> <property name="width_request">138</property> <property name="height_request">16</property> <property name="visible">True</property> - <property name="label" translatable="yes"></property> + <property name="label" translatable="yes"> </property> <property name="use_underline">False</property> <property name="use_markup">False</property> <property name="justify">GTK_JUSTIFY_RIGHT</property> @@ -2228,33 +2096,21 @@ <property name="angle">0</property> </widget> <packing> - <property name="x">312</property> - <property name="y">0</property> + <property name="x">0</property> + <property name="y">56</property> </packing> </child> <child> - <widget class="GtkVSeparator" id="vseparator20"> - <property name="width_request">16</property> - <property name="height_request">70</property> + <widget class="GtkLabel" id="lblLight"> + <property name="width_request">46</property> + <property name="height_request">17</property> <property name="visible">True</property> - </widget> - <packing> - <property name="x">356</property> - <property name="y">0</property> - </packing> - </child> - - <child> - <widget class="GtkLabel" id="lblBatteryL"> - <property name="width_request">138</property> - <property name="height_request">16</property> - <property name="visible">True</property> <property name="label" translatable="yes"> </property> <property name="use_underline">False</property> <property name="use_markup">False</property> - <property name="justify">GTK_JUSTIFY_RIGHT</property> - <property name="wrap">True</property> + <property name="justify">GTK_JUSTIFY_LEFT</property> + <property name="wrap">False</property> <property name="selectable">False</property> <property name="xalign">0.5</property> <property name="yalign">0.5</property> @@ -2266,8 +2122,8 @@ <property name="angle">0</property> </widget> <packing> - <property name="x">0</property> - <property name="y">32</property> + <property name="x">312</property> + <property name="y">8</property> </packing> </child> Modified: software/gadgets/tux_controller/trunk/TuxController/Scripts/Python/GUI/widget/other.pyp =================================================================== --- software/gadgets/tux_controller/trunk/TuxController/Scripts/Python/GUI/widget/other.pyp 2007-12-03 15:05:36 UTC (rev 747) +++ software/gadgets/tux_controller/trunk/TuxController/Scripts/Python/GUI/widget/other.pyp 2007-12-03 16:31:43 UTC (rev 748) @@ -34,6 +34,9 @@ self.status_table() def on_window1_destroy(self, widget, *args): + ''' + When the window is destroyed, don't forget to remove the monitoring vectors + ''' tux.monitoring.remove(self.light_idx) tux.monitoring.remove(self.sound_idx) tux.monitoring.remove(self.battery_idx) @@ -41,12 +44,29 @@ tux.event.on_left_blue_led_off = None tux.event.on_right_blue_led_on = None tux.event.on_right_blue_led_off = None + tux.event.on_eyes_open = None + tux.event.on_eyes_closed = None + tux.event.on_mouth_open = None + tux.event.on_mouth_close = None + tux.event.on_spin_stop = None def binding(self): + ''' + This function 'connect' some Tux's events with local functions. + See the tux.event help for more informations. + + The light, battery and audio monitoring are also initialized here. + ''' tux.event.on_left_blue_led_on = self.on_left_led_on tux.event.on_left_blue_led_off = self.on_left_led_off tux.event.on_right_blue_led_on = self.on_right_led_on tux.event.on_right_blue_led_off = self.on_right_led_off + tux.event.on_eyes_open = self.on_eyes_open + tux.event.on_eyes_close = self.on_eyes_close + tux.event.on_mouth_open = self.on_mouth_open + tux.event.on_mouth_close = self.on_mouth_close + tux.event.on_spin_stop = self.on_spin_stop + self.light_idx = tux.monitoring.insert(0x1B, self.on_light_level) self.battery_idx = tux.monitoring.insert(0x25, self.on_battery_level) tux.micro.on() @@ -54,6 +74,9 @@ tux.sys.wait(0.1) def update_status(self): + ''' + This function update the status when the gadget is starting. + ''' if tux.status.lled(): self.get_widget('chkLEDLeft').set_active(True) else: @@ -65,27 +88,72 @@ self.get_widget('chkLEDRight').set_active(False) def update_pix(self): - path = _me.get_path('pictures')+'/Icons/' - self.get_widget('imgLEDRun').set_from_file(path+'run.png') + ''' + It's necessary to update the pictures. + The first step is to determine the path where the pictures are stored. + To do this, the instruction _me.get_path('pictures') return the path + of the 'picture' folder of the TGF. + ''' + self.path = _me.get_path('pictures')+'/Icons/' - self.get_widget('imgEyesOpen').set_from_file(path+'up.png') - self.get_widget('imgEyesClose').set_from_file(path+'down.png') - self.get_widget('imgEyesRun').set_from_file(path+'run.png') + ### Update the buttons icons + self.get_widget('imgLEDRun').set_from_file(self.path+'run.png') - self.get_widget('imgMouthClose').set_from_file(path+'up.png') - self.get_widget('imgMouthOpen').set_from_file(path+'down.png') - self.get_widget('imgMouthRun').set_from_file(path+'run.png') + self.get_widget('imgEyesOpen').set_from_file(self.path+'up.png') + self.get_widget('imgEyesClose').set_from_file(self.path+'down.png') + self.get_widget('imgEyesRun').set_from_file(self.path+'run.png') - self.get_widget('imgWingsUp').set_from_file(path+'up.png') - self.get_widget('imgWingsDown').set_from_file(path+'down.png') - self.get_widget('imgWingsRun').set_from_file(path+'run.png') + self.get_widget('imgMouthClose').set_from_file(self.path+'up.png') + self.get_widget('imgMouthOpen').set_from_file(self.path+'down.png') + self.get_widget('imgMouthRun').set_from_file(self.path+'run.png') - self.get_widget('imgSpinLeft').set_from_file(path+'left.png') - self.get_widget('imgSpinRight').set_from_file(path+'right.png') - self.get_widget('imgSpinRun').set_from_file(path+'run.png') + self.get_widget('imgWingsUp').set_from_file(self.path+'up.png') + self.get_widget('imgWingsDown').set_from_file(self.path+'down.png') + self.get_widget('imgWingsRun').set_from_file(self.path+'run.png') + + self.get_widget('imgSpinLeft').set_from_file(self.path+'left.png') + self.get_widget('imgSpinRight').set_from_file(self.path+'right.png') + self.get_widget('imgSpinRun').set_from_file(self.path+'run.png') + + ### Update the Tux pictures + if tux.status.rled() == 0: + self.get_widget('imgEyes').set_from_file(self.path+'led_off.png') + else: + self.get_widget('imgEyes').set_from_file(self.path+'led_on.png') + ## Do the same for the second led... + #if tux.status.rlled() == 0: + # self.get_widget('imgEyes').set_from_file(path+'led_off.png') + #else: + # self.get_widget('imgEyes').set_from_file(path+'led_on.png') + + if tux.status.eyes_closed() == 0: + self.get_widget('imgEyes').set_from_file(self.path+'eyes_closed.png') + + if tux.status.mouth_closed() == 0: + self.get_widget('imgMouth').set_from_file(self.path+'beak_closed.png') + else: + self.get_widget('imgMouth').set_from_file(self.path+'beak_open.png') + ## I'm waiting for an absolute wings position status + #if tux.status.wings_up() == 0: + self.get_widget('imgWings').set_from_file(self.path+'wings_down.png') + + ## I'm waiting for a spinning status + #if tux.status.spinning() + self.get_widget('imgSpin').set_from_file(self.path+'spin_off.png') + + def update_labels(self): + ''' + Update the GUI labels. + + To enable the gadget to be translated, all the strings are configured on the + Tux Gadget Maker strings section. + + To load a string, just use _me.get_string('my_string') + ''' + ## Update the TAB labels self.get_widget('tabControl').set_label(_me.string('tabControl')) self.get_widget('tabStatus').set_label(_me.string('tabStatus')) @@ -104,14 +172,23 @@ self.get_widget('radSpinDirLeft').set_label(_me.string('radSpinDirLeft')) self.get_widget('radSpinDirRight').set_label(_me.string('radSpinDirRight')) - self.get_widget('lblLightL').set_text(_me.string('lblLightL')) + self.get_widget('lblBatteryL').set_text(_me.string('lblBatteryL')) self.get_widget('lblSoundL').set_text(_me.string('lblSoundL')) + self.get_widget('lblLightL').set_text(_me.string('lblLightL')) def status_table(self): + ''' + This function create a custom Treeview. + + The treeviews can't be created directly with glade, so we need to define it + directly in software + ''' + ### Define a new gtk.Treeview self.status_tree = gtk.TreeStore(str, str, str, str) self.status_view = gtk.TreeView(self.status_tree) + ### Create the columns self.name1_renderer = gtk.CellRendererText() self.name1_column = gtk.TreeViewColumn(_me.string('colStatus'), self.name1_renderer, text=0) self.name1_column.set_min_width(300) @@ -132,6 +209,7 @@ self.value2_column.set_min_width(85) self.value2_column.add_attribute(self.value2_renderer, 'text', 3) + ### Add the columns to the treeview self.status_view.append_column(self.name1_column) self.status_view.append_column(self.value1_column) self.status_view.append_column(self.name2_column) @@ -139,9 +217,15 @@ self.status_view.set_rules_hint(True) + ### Add the treeview to the scrolledwindow1 self.get_widget("scrolledwindow1").add(self.status_view) + + ### And show all ! self.get_widget("scrolledwindow1").show_all() + + ### tux.sys.looped_function allow to execute a function periodically. + ## Here, this function is used to refresh the status treeview. tux.sys.looped_function(self.refresh_treeview, 0.5) @@ -149,6 +233,9 @@ # # Widget items events # +# This section contains all the functions connected to the widgets +# signals. +# #################################################################### ## btnLEDrun def on_btnLEDRun_clicked(self, widget, *args): @@ -264,6 +351,9 @@ def on_btnSpinLeft_pressed(self, widget, *args): tux.cmd.spinl_on_free(0) +### I'm waiting for an event function... + self.get_widget('imgSpin').set_from_file(self.path+'spin_left.png') + def on_btnSpinLeft_released(self, widget, *args): tux.cmd.spinl_on_free(1) @@ -271,6 +361,9 @@ def on_btnSpinRight_pressed(self, widget, *args): tux.cmd.spinr_on_free(0) +### I'm waiting for an event function... + self.get_widget('imgSpin').set_from_file(self.path+'spin_right.png') + def on_btnSpinRight_released(self, widget, *args): tux.cmd.spinr_on_free(1) @@ -286,12 +379,26 @@ else: if self.get_widget('radSpinDirLeft').get_active(): tux.cmd.spinl_on_free(int(value), int(freq)) + +### I'm waiting for an event function... + self.get_widget('imgSpin').set_from_file(self.path+'spin_left.png') else: tux.cmd.spinr_on_free(int(value), int(freq)) + +### I'm waiting for an event function... + self.get_widget('imgSpin').set_from_file(self.path+'spin_right.png') - + ## chkLEDRight def on_chkLEDRight_toggled(self, widget, *args): + ''' + When the check box is toggled, the LED will be switched off/on. + This trig a LED event, which will toggle the checkbox, which + will trig a LED event, etc ... + + To prevent this bug, a global flag is used to indicate that the + LED has been toggled by an event, and not by the user. + ''' global __led_toggled_by_event if __led_toggled_by_event: return if widget.get_active(): @@ -330,32 +437,64 @@ # # Tux events functions # +# These functions are trigged when an Tux event occurs. +# All of these functions are declared in the 'binding' function. +# #################################################################### def on_right_led_on(self): global __led_toggled_by_event __led_toggled_by_event = True self.get_widget('chkLEDRight').set_active(True) + self.get_widget('imgEyes').set_from_file(self.path+'led_on.png') __led_toggled_by_event = False def on_right_led_off(self): global __led_toggled_by_event __led_toggled_by_event = True self.get_widget('chkLEDRight').set_active(False) + self.get_widget('imgEyes').set_from_file(self.path+'led_off.png') __led_toggled_by_event = False def on_left_led_on(self): global __led_toggled_by_event __led_toggled_by_event = True self.get_widget('chkLEDLeft').set_active(True) + self.get_widget('imgEyes').set_from_file(self.path+'led_on.png') __led_toggled_by_event = False def on_left_led_off(self): global __led_toggled_by_event __led_toggled_by_event = True self.get_widget('chkLEDLeft').set_active(False) + self.get_widget('imgEyes').set_from_file(self.path+'led_off.png') __led_toggled_by_event = False + def on_eyes_close(self): + self.get_widget('imgEyes').set_from_file(self.path+'eyes_closed.png') + + def on_eyes_open(self): + if tux.status.lled() == 0 or tux.status.rled() == 0: + self.get_widget('imgEyes').set_from_file(self.path+'led_off.png') + else: + self.get_widget('imgEyes').set_from_file(self.path+'led_on.png') + + ### Specify the behavior of each leds + + #if tux.status.lled() == 0: + # self.get_widget('imgEyes').set_from_file(self.path+'led_off.png') + #else: + # self.get_widget('imgEyes').set_from_file(self.path+'led_on.png') + + def on_mouth_open(self): + self.get_widget('imgMouth').set_from_file(self.path+'beak_open.png') + + def on_mouth_close(self): + self.get_widget('imgMouth').set_from_file(self.path+'beak_closed.png') + + def on_spin_stop(self): + self.get_widget('imgSpin').set_from_file(self.path+'spin_off.png') + def on_light_level(self, args): level = args[0]*256 + args[1] level = level / 1124.0 * 100.0 @@ -384,17 +523,27 @@ val = float(val / 127.0) self.get_widget('lblSound').set_text('%.1f%s'%(val*100, '%')) self.get_widget('SoundLevel').set_fraction(val) - + +#################################################################### +# +# Refresh the statuses treeview +# +#################################################################### def refresh_treeview(self): + ''' + All statuses must be requested. This operation require a lot of time. + So, to not block the gadget when the treeview is refreshed, the function + is launched on a thread. + ''' thread.start_new_thread(self.refresh, ()) return True def refresh(self): ## Buttons status - lwing_pushed = tux.status.lwing_bt() rwing_pushed = tux.status.rwing_bt() head_pushed = tux.status.head_bt() + #print (lwing_pushed,rwing_pushed,head_pushed) self.status_tree.clear() self.status_tree.append(None, ['lwing_pushed', str(lwing_pushed), 'test', 'test']) Modified: software/gadgets/tux_controller/trunk/TuxController/settings.xml =================================================================== --- software/gadgets/tux_controller/trunk/TuxController/settings.xml 2007-12-03 15:05:36 UTC (rev 747) +++ software/gadgets/tux_controller/trunk/TuxController/settings.xml 2007-12-03 16:31:43 UTC (rev 748) @@ -7,9 +7,9 @@ <have_settings_part type='bool'>True</have_settings_part> <gui_state> <widget> - <y type='int'>25</y> + <y type='int'>64</y> <visible type='bool'>True</visible> - <x type='int'>0</x> + <x type='int'>210</x> </widget> <conf> <visible type='bool'>False</visible> Modified: software/gadgets/tux_controller/trunk/TuxController.tgf =================================================================== (Binary files differ) Modified: software/gadgets/tux_controller/trunk/TuxDroidController.tgf =================================================================== (Binary files differ) |