[farsight2/master] Show recv codecs in fs2-gui
Olivier Crête
olivier.crete at collabora.co.uk
Tue Dec 23 15:23:34 PST 2008
---
tests/gui/fs2-gui.glade | 304 ++++++++++++++++++++++++-----------------------
tests/gui/fs2-gui.py | 37 ++++++-
2 files changed, 187 insertions(+), 154 deletions(-)
diff --git a/tests/gui/fs2-gui.glade b/tests/gui/fs2-gui.glade
index 00f4611..d3005ba 100644
--- a/tests/gui/fs2-gui.glade
+++ b/tests/gui/fs2-gui.glade
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!DOCTYPE glade-interface SYSTEM "glade-2.0.dtd">
-<!--Generated with glade3 3.4.0 on Tue Jun 17 13:36:51 2008 -->
+<!--Generated with glade3 3.4.0 on Tue Jun 17 16:01:07 2008 -->
<glade-interface>
<widget class="GtkWindow" id="main_window">
<property name="events">GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK</property>
@@ -35,48 +35,30 @@
<property name="column_spacing">6</property>
<property name="row_spacing">6</property>
<child>
- <widget class="GtkAspectFrame" id="preview_aspectframe">
+ <widget class="GtkLabel" id="label4">
<property name="visible">True</property>
<property name="events">GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK</property>
- <property name="border_width">6</property>
- <property name="label_xalign">0</property>
- <property name="ratio">1.3300000429153442</property>
- <child>
- <widget class="GtkDrawingArea" id="preview_drawingarea">
- <property name="width_request">160</property>
- <property name="height_request">120</property>
- <property name="visible">True</property>
- <property name="events">GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK</property>
- <signal name="expose_event" handler="exposed"/>
- </widget>
- </child>
- <child>
- <widget class="GtkLabel" id="frame_label">
- <property name="visible">True</property>
- <property name="events">GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK</property>
- <property name="label" translatable="yes"><b>User</b></property>
- <property name="use_markup">True</property>
- </widget>
- <packing>
- <property name="type">label_item</property>
- </packing>
- </child>
+ <property name="label" translatable="yes">Video:</property>
</widget>
<packing>
- <property name="right_attach">2</property>
+ <property name="top_attach">2</property>
+ <property name="bottom_attach">3</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="x_padding">6</property>
</packing>
</child>
<child>
- <widget class="GtkLabel" id="label3">
+ <widget class="GtkComboBox" id="video_combobox">
<property name="visible">True</property>
<property name="events">GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK</property>
- <property name="label" translatable="yes">Audio:</property>
+ <signal name="changed" handler="video_combobox_changed_cb"/>
</widget>
<packing>
- <property name="top_attach">1</property>
- <property name="bottom_attach">2</property>
- <property name="x_options">GTK_FILL</property>
- <property name="x_padding">6</property>
+ <property name="left_attach">1</property>
+ <property name="right_attach">2</property>
+ <property name="top_attach">2</property>
+ <property name="bottom_attach">3</property>
+ <property name="y_options">GTK_EXPAND</property>
</packing>
</child>
<child>
@@ -90,32 +72,52 @@
<property name="right_attach">2</property>
<property name="top_attach">1</property>
<property name="bottom_attach">2</property>
+ <property name="y_options">GTK_EXPAND</property>
</packing>
</child>
<child>
- <widget class="GtkComboBox" id="video_combobox">
+ <widget class="GtkLabel" id="label3">
<property name="visible">True</property>
<property name="events">GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK</property>
- <signal name="changed" handler="video_combobox_changed_cb"/>
+ <property name="label" translatable="yes">Audio:</property>
</widget>
<packing>
- <property name="left_attach">1</property>
- <property name="right_attach">2</property>
- <property name="top_attach">2</property>
- <property name="bottom_attach">3</property>
+ <property name="top_attach">1</property>
+ <property name="bottom_attach">2</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="x_padding">6</property>
</packing>
</child>
<child>
- <widget class="GtkLabel" id="label4">
+ <widget class="GtkAspectFrame" id="preview_aspectframe">
<property name="visible">True</property>
<property name="events">GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK</property>
- <property name="label" translatable="yes">Video:</property>
+ <property name="border_width">6</property>
+ <property name="label_xalign">0</property>
+ <property name="ratio">1.3300000429153442</property>
+ <child>
+ <widget class="GtkDrawingArea" id="preview_drawingarea">
+ <property name="width_request">160</property>
+ <property name="height_request">120</property>
+ <property name="visible">True</property>
+ <property name="events">GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK</property>
+ <signal name="expose_event" handler="exposed"/>
+ </widget>
+ </child>
+ <child>
+ <widget class="GtkLabel" id="frame_label">
+ <property name="visible">True</property>
+ <property name="events">GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK</property>
+ <property name="label" translatable="yes"><b>User</b></property>
+ <property name="use_markup">True</property>
+ </widget>
+ <packing>
+ <property name="type">label_item</property>
+ </packing>
+ </child>
</widget>
<packing>
- <property name="top_attach">2</property>
- <property name="bottom_attach">3</property>
- <property name="x_options">GTK_FILL</property>
- <property name="x_padding">6</property>
+ <property name="right_attach">2</property>
</packing>
</child>
</widget>
@@ -224,43 +226,36 @@
<property name="column_spacing">12</property>
<property name="row_spacing">12</property>
<child>
- <widget class="GtkSpinButton" id="newport_spinbutton">
+ <widget class="GtkLabel" id="label1">
<property name="visible">True</property>
- <property name="can_focus">True</property>
<property name="events">GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK</property>
- <property name="max_length">5</property>
- <property name="width_chars">5</property>
- <property name="adjustment">9392 1 65535 1 10 10</property>
- <property name="snap_to_ticks">True</property>
- <property name="numeric">True</property>
</widget>
<packing>
- <property name="left_attach">1</property>
- <property name="right_attach">2</property>
+ <property name="left_attach">2</property>
+ <property name="right_attach">3</property>
<property name="top_attach">2</property>
<property name="bottom_attach">3</property>
- <property name="x_options">GTK_SHRINK</property>
</packing>
</child>
<child>
- <widget class="GtkLabel" id="label11">
+ <widget class="GtkImage" id="image5">
<property name="visible">True</property>
<property name="events">GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK</property>
- <property name="label" translatable="yes">Enter the IP address and the port of the server to connect to, or only the port if you want to start a new server</property>
- <property name="wrap">True</property>
+ <property name="yalign">0</property>
+ <property name="icon_size">6</property>
+ <property name="icon_name">start-here</property>
</widget>
- <packing>
- <property name="left_attach">1</property>
- <property name="right_attach">3</property>
- </packing>
</child>
<child>
- <widget class="GtkLabel" id="label10">
+ <widget class="GtkEntry" id="newip_entry">
<property name="visible">True</property>
+ <property name="can_focus">True</property>
<property name="events">GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK</property>
- <property name="label" translatable="yes">IP address: </property>
+ <property name="text" translatable="yes">127.0.0.1</property>
</widget>
<packing>
+ <property name="left_attach">1</property>
+ <property name="right_attach">3</property>
<property name="top_attach">1</property>
<property name="bottom_attach">2</property>
<property name="y_options">GTK_FILL</property>
@@ -279,39 +274,46 @@
</packing>
</child>
<child>
- <widget class="GtkEntry" id="newip_entry">
+ <widget class="GtkLabel" id="label10">
<property name="visible">True</property>
- <property name="can_focus">True</property>
<property name="events">GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK</property>
- <property name="text" translatable="yes">127.0.0.1</property>
+ <property name="label" translatable="yes">IP address: </property>
</widget>
<packing>
- <property name="left_attach">1</property>
- <property name="right_attach">3</property>
<property name="top_attach">1</property>
<property name="bottom_attach">2</property>
<property name="y_options">GTK_FILL</property>
</packing>
</child>
<child>
- <widget class="GtkImage" id="image5">
+ <widget class="GtkLabel" id="label11">
<property name="visible">True</property>
<property name="events">GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK</property>
- <property name="yalign">0</property>
- <property name="icon_size">6</property>
- <property name="icon_name">start-here</property>
+ <property name="label" translatable="yes">Enter the IP address and the port of the server to connect to, or only the port if you want to start a new server</property>
+ <property name="wrap">True</property>
</widget>
+ <packing>
+ <property name="left_attach">1</property>
+ <property name="right_attach">3</property>
+ </packing>
</child>
<child>
- <widget class="GtkLabel" id="label1">
+ <widget class="GtkSpinButton" id="newport_spinbutton">
<property name="visible">True</property>
+ <property name="can_focus">True</property>
<property name="events">GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK</property>
+ <property name="max_length">5</property>
+ <property name="width_chars">5</property>
+ <property name="adjustment">9392 1 65535 1 10 10</property>
+ <property name="snap_to_ticks">True</property>
+ <property name="numeric">True</property>
</widget>
<packing>
- <property name="left_attach">2</property>
- <property name="right_attach">3</property>
+ <property name="left_attach">1</property>
+ <property name="right_attach">2</property>
<property name="top_attach">2</property>
<property name="bottom_attach">3</property>
+ <property name="x_options">GTK_SHRINK</property>
</packing>
</child>
</widget>
@@ -462,204 +464,204 @@
<property name="column_spacing">6</property>
<property name="row_spacing">6</property>
<child>
- <widget class="GtkButton" id="dtmf_1">
+ <widget class="GtkButton" id="dtmf_pound">
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="receives_default">True</property>
<property name="events">GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK</property>
- <property name="label" translatable="yes">1</property>
+ <property name="label" translatable="yes">#</property>
<property name="response_id">0</property>
- <signal name="pressed" handler="dtmf_start" object="1"/>
- <signal name="released" handler="dtmf_stop" object="1"/>
+ <signal name="pressed" handler="dtmf_start" object="#"/>
+ <signal name="released" handler="dtmf_stop" object="#"/>
</widget>
+ <packing>
+ <property name="left_attach">2</property>
+ <property name="right_attach">3</property>
+ <property name="top_attach">3</property>
+ <property name="bottom_attach">4</property>
+ </packing>
</child>
<child>
- <widget class="GtkButton" id="dtmf_2">
+ <widget class="GtkButton" id="dtmf_0">
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="receives_default">True</property>
<property name="events">GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK</property>
- <property name="label" translatable="yes">2</property>
+ <property name="label" translatable="yes">0</property>
<property name="response_id">0</property>
- <signal name="pressed" handler="dtmf_start" object="2"/>
- <signal name="released" handler="dtmf_stop" object="2"/>
+ <signal name="pressed" handler="dtmf_start" object="0"/>
+ <signal name="released" handler="dtmf_stop" object="0"/>
</widget>
<packing>
<property name="left_attach">1</property>
<property name="right_attach">2</property>
+ <property name="top_attach">3</property>
+ <property name="bottom_attach">4</property>
</packing>
</child>
<child>
- <widget class="GtkButton" id="dtmf_3">
+ <widget class="GtkButton" id="dtmf_star">
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="receives_default">True</property>
<property name="events">GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK</property>
- <property name="label" translatable="yes">3</property>
+ <property name="label" translatable="yes">*</property>
<property name="response_id">0</property>
- <signal name="pressed" handler="dtmf_start" object="3"/>
- <signal name="released" handler="dtmf_stop" object="3"/>
+ <signal name="pressed" handler="dtmf_start" object="*"/>
+ <signal name="released" handler="dtmf_stop" object="*"/>
</widget>
<packing>
- <property name="left_attach">2</property>
- <property name="right_attach">3</property>
+ <property name="top_attach">3</property>
+ <property name="bottom_attach">4</property>
</packing>
</child>
<child>
- <widget class="GtkButton" id="dtmf_4">
+ <widget class="GtkButton" id="dtmf_9">
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="receives_default">True</property>
<property name="events">GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK</property>
- <property name="label" translatable="yes">4</property>
+ <property name="label" translatable="yes">9</property>
<property name="response_id">0</property>
- <signal name="pressed" handler="dtmf_start" object="4"/>
- <signal name="released" handler="dtmf_stop" object="4"/>
+ <signal name="pressed" handler="dtmf_start" object="9"/>
+ <signal name="released" handler="dtmf_stop" object="9"/>
</widget>
<packing>
- <property name="top_attach">1</property>
- <property name="bottom_attach">2</property>
+ <property name="left_attach">2</property>
+ <property name="right_attach">3</property>
+ <property name="top_attach">2</property>
+ <property name="bottom_attach">3</property>
</packing>
</child>
<child>
- <widget class="GtkButton" id="dtmf_5">
+ <widget class="GtkButton" id="dtmf_8">
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="receives_default">True</property>
<property name="events">GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK</property>
- <property name="label" translatable="yes">5</property>
+ <property name="label" translatable="yes">8</property>
<property name="response_id">0</property>
- <signal name="pressed" handler="dtmf_start" object="5"/>
- <signal name="released" handler="dtmf_stop" object="5"/>
+ <signal name="pressed" handler="dtmf_start" object="8"/>
+ <signal name="released" handler="dtmf_stop" object="8"/>
</widget>
<packing>
<property name="left_attach">1</property>
<property name="right_attach">2</property>
- <property name="top_attach">1</property>
- <property name="bottom_attach">2</property>
+ <property name="top_attach">2</property>
+ <property name="bottom_attach">3</property>
</packing>
</child>
<child>
- <widget class="GtkButton" id="dtmf_6">
+ <widget class="GtkButton" id="dtmf_7">
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="receives_default">True</property>
<property name="events">GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK</property>
- <property name="label" translatable="yes">6</property>
+ <property name="label" translatable="yes">7</property>
<property name="response_id">0</property>
- <signal name="pressed" handler="dtmf_start" object="6"/>
- <signal name="released" handler="dtmf_stop" object="6"/>
+ <signal name="pressed" handler="dtmf_start" object="7"/>
+ <signal name="released" handler="dtmf_stop" object="7"/>
</widget>
<packing>
- <property name="left_attach">2</property>
- <property name="right_attach">3</property>
- <property name="top_attach">1</property>
- <property name="bottom_attach">2</property>
+ <property name="top_attach">2</property>
+ <property name="bottom_attach">3</property>
</packing>
</child>
<child>
- <widget class="GtkButton" id="dtmf_7">
+ <widget class="GtkButton" id="dtmf_6">
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="receives_default">True</property>
<property name="events">GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK</property>
- <property name="label" translatable="yes">7</property>
+ <property name="label" translatable="yes">6</property>
<property name="response_id">0</property>
- <signal name="pressed" handler="dtmf_start" object="7"/>
- <signal name="released" handler="dtmf_stop" object="7"/>
+ <signal name="pressed" handler="dtmf_start" object="6"/>
+ <signal name="released" handler="dtmf_stop" object="6"/>
</widget>
<packing>
- <property name="top_attach">2</property>
- <property name="bottom_attach">3</property>
+ <property name="left_attach">2</property>
+ <property name="right_attach">3</property>
+ <property name="top_attach">1</property>
+ <property name="bottom_attach">2</property>
</packing>
</child>
<child>
- <widget class="GtkButton" id="dtmf_8">
+ <widget class="GtkButton" id="dtmf_5">
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="receives_default">True</property>
<property name="events">GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK</property>
- <property name="label" translatable="yes">8</property>
+ <property name="label" translatable="yes">5</property>
<property name="response_id">0</property>
- <signal name="pressed" handler="dtmf_start" object="8"/>
- <signal name="released" handler="dtmf_stop" object="8"/>
+ <signal name="pressed" handler="dtmf_start" object="5"/>
+ <signal name="released" handler="dtmf_stop" object="5"/>
</widget>
<packing>
<property name="left_attach">1</property>
<property name="right_attach">2</property>
- <property name="top_attach">2</property>
- <property name="bottom_attach">3</property>
+ <property name="top_attach">1</property>
+ <property name="bottom_attach">2</property>
</packing>
</child>
<child>
- <widget class="GtkButton" id="dtmf_9">
+ <widget class="GtkButton" id="dtmf_4">
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="receives_default">True</property>
<property name="events">GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK</property>
- <property name="label" translatable="yes">9</property>
+ <property name="label" translatable="yes">4</property>
<property name="response_id">0</property>
- <signal name="pressed" handler="dtmf_start" object="9"/>
- <signal name="released" handler="dtmf_stop" object="9"/>
+ <signal name="pressed" handler="dtmf_start" object="4"/>
+ <signal name="released" handler="dtmf_stop" object="4"/>
</widget>
<packing>
- <property name="left_attach">2</property>
- <property name="right_attach">3</property>
- <property name="top_attach">2</property>
- <property name="bottom_attach">3</property>
+ <property name="top_attach">1</property>
+ <property name="bottom_attach">2</property>
</packing>
</child>
<child>
- <widget class="GtkButton" id="dtmf_star">
+ <widget class="GtkButton" id="dtmf_3">
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="receives_default">True</property>
<property name="events">GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK</property>
- <property name="label" translatable="yes">*</property>
+ <property name="label" translatable="yes">3</property>
<property name="response_id">0</property>
- <signal name="pressed" handler="dtmf_start" object="*"/>
- <signal name="released" handler="dtmf_stop" object="*"/>
+ <signal name="pressed" handler="dtmf_start" object="3"/>
+ <signal name="released" handler="dtmf_stop" object="3"/>
</widget>
<packing>
- <property name="top_attach">3</property>
- <property name="bottom_attach">4</property>
+ <property name="left_attach">2</property>
+ <property name="right_attach">3</property>
</packing>
</child>
<child>
- <widget class="GtkButton" id="dtmf_0">
+ <widget class="GtkButton" id="dtmf_2">
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="receives_default">True</property>
<property name="events">GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK</property>
- <property name="label" translatable="yes">0</property>
+ <property name="label" translatable="yes">2</property>
<property name="response_id">0</property>
- <signal name="pressed" handler="dtmf_start" object="0"/>
- <signal name="released" handler="dtmf_stop" object="0"/>
+ <signal name="pressed" handler="dtmf_start" object="2"/>
+ <signal name="released" handler="dtmf_stop" object="2"/>
</widget>
<packing>
<property name="left_attach">1</property>
<property name="right_attach">2</property>
- <property name="top_attach">3</property>
- <property name="bottom_attach">4</property>
</packing>
</child>
<child>
- <widget class="GtkButton" id="dtmf_pound">
+ <widget class="GtkButton" id="dtmf_1">
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="receives_default">True</property>
<property name="events">GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK</property>
- <property name="label" translatable="yes">#</property>
+ <property name="label" translatable="yes">1</property>
<property name="response_id">0</property>
- <signal name="pressed" handler="dtmf_start" object="#"/>
- <signal name="released" handler="dtmf_stop" object="#"/>
+ <signal name="pressed" handler="dtmf_start" object="1"/>
+ <signal name="released" handler="dtmf_stop" object="1"/>
</widget>
- <packing>
- <property name="left_attach">2</property>
- <property name="right_attach">3</property>
- <property name="top_attach">3</property>
- <property name="bottom_attach">4</property>
- </packing>
</child>
</widget>
<packing>
diff --git a/tests/gui/fs2-gui.py b/tests/gui/fs2-gui.py
index 635bbf1..eb1a3d4 100644
--- a/tests/gui/fs2-gui.py
+++ b/tests/gui/fs2-gui.py
@@ -163,7 +163,12 @@ class FsUIPipeline:
self.codecs_changed_audio()
if message.structure["session"] == self.videosession.fssession:
self.codecs_changed_video()
-
+ elif message.structure.has_name("farsight-recv-codecs-changed"):
+ print message.src.get_name(), ": ", message.structure.get_name()
+ message.structure["stream"].uistream.recv_codecs_changed( \
+ message.structure["codecs"])
+
+
elif message.structure.has_name("farsight-error"):
print "Async error ("+ str(message.structure["error-no"]) +"): " + message.structure["error-msg"] +" --- "+ message.structure["debug-msg"]
else:
@@ -504,6 +509,9 @@ class FsUIStream:
self.connect.send_codec(self.participant.id, self.id, codec)
self.connect.send_codecs_done(self.participant.id, self.id)
+ def recv_codecs_changed(self, codecs):
+ self.participant.recv_codecs_changed()
+
class FsUIParticipant:
"Wraps one FsParticipant, is one user remote contact"
@@ -552,7 +560,10 @@ class FsUIParticipant:
self.userframe = self.glade.get_widget("user_frame")
self.glade.get_widget("frame_label").set_text(self.cname)
self.glade.signal_autoconnect(self)
- self.mainui.hbox_add(self.userframe)
+ self.label = gtk.Label()
+ self.label.set_alignment(0,0)
+ self.label.show()
+ self.mainui.hbox_add(self.userframe, self.label)
gtk.gdk.threads_leave()
def exposed(self, widget, *args):
@@ -641,6 +652,25 @@ class FsUIParticipant:
else:
print "ERROR ON %d" % (self.id)
+ def recv_codecs_changed(self):
+ codecs = {}
+ for s in self.streams:
+ codec = self.streams[s].fsstream.get_property("current-recv-codecs")
+ mediatype = self.streams[s].session.fssession.get_property("media-type")
+ if len(codec):
+ if mediatype in codecs:
+ codecs[mediatype] += codec
+ else:
+ codecs[mediatype] = codec
+ str = ""
+ for mt in codecs:
+ str += "<big>" +mt.value_nick.title() + "</big>:\n"
+ for c in codecs[mt]:
+ str += " <b>%s</b>: %s %s\n" % (c.id,
+ c.encoding_name,
+ c.clock_rate)
+ self.label.set_markup(str)
+
class FsMainUI:
@@ -736,10 +766,11 @@ class FsMainUI:
def shutdown(self, widget=None):
gtk.main_quit()
- def hbox_add(self, widget):
+ def hbox_add(self, widget, label):
table = self.glade.get_widget("users_table")
x = table.get_properties("n-columns")[0]
table.attach(widget, x, x+1, 0, 1)
+ table.attach(label, x, x+1, 1, 3, xpadding=6)
def __del__(self):
self.mainwindow.destroy()
--
1.5.6.5
More information about the farsight-commits
mailing list