Hi, Here's a patch that simplifies the layout of the crossfade settings. BTW, couldn't the network buffer size be set automatically based on the crossfade duration? Eskil
Index: shell/rb-shell-preferences.c =================================================================== --- shell/rb-shell-preferences.c (revision 5463) +++ shell/rb-shell-preferences.c (arbetskopia) @@ -98,6 +98,7 @@ #ifdef HAVE_GSTREAMER_0_10_XFADE GtkWidget *xfade_backend_check; + GtkWidget *crossfading_box; GtkWidget *album_crossfade_check; GtkWidget *transition_duration; GtkWidget *network_buffer_size; @@ -246,13 +247,12 @@ "playback_prefs_box", shell_preferences); - rb_glade_boldify_label (xml, "backend_label"); - rb_glade_boldify_label (xml, "crossfade_type_label"); - rb_glade_boldify_label (xml, "duration_label"); - rb_glade_boldify_label (xml, "buffer_size_label"); + rb_glade_boldify_label (xml, "crossfading_label"); shell_preferences->priv->xfade_backend_check = glade_xml_get_widget (xml, "use_xfade_backend"); + shell_preferences->priv->crossfading_box = + glade_xml_get_widget (xml, "crossfading_box"); shell_preferences->priv->album_crossfade_check = glade_xml_get_widget (xml, "album_check"); shell_preferences->priv->transition_duration = @@ -605,9 +605,7 @@ backend = gtk_toggle_button_get_active (GTK_TOGGLE_BUTTON (preferences->priv->xfade_backend_check)); - gtk_widget_set_sensitive (preferences->priv->album_crossfade_check, backend); - gtk_widget_set_sensitive (preferences->priv->network_buffer_size, backend); - gtk_widget_set_sensitive (preferences->priv->transition_duration, backend); + gtk_widget_set_sensitive (preferences->priv->crossfading_box, backend); } static void Index: data/glade/playback-prefs.glade =================================================================== --- data/glade/playback-prefs.glade (revision 5463) +++ data/glade/playback-prefs.glade (arbetskopia) @@ -40,92 +40,16 @@ <property name="spacing">18</property> <child> - <widget class="GtkVBox" id="vbox3"> + <widget class="GtkCheckButton" id="use_xfade_backend"> <property name="visible">True</property> - <property name="homogeneous">False</property> - <property name="spacing">6</property> - - <child> - <widget class="GtkLabel" id="backend_label"> - <property name="visible">True</property> - <property name="label" translatable="yes">Player Backend</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="selectable">False</property> - <property name="xalign">0</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> - - <child> - <widget class="GtkHBox" id="hbox1"> - <property name="visible">True</property> - <property name="homogeneous">False</property> - <property name="spacing">0</property> - - <child> - <widget class="GtkLabel" id="label1"> - <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="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> - - <child> - <widget class="GtkCheckButton" id="use_xfade_backend"> - <property name="visible">True</property> - <property name="can_focus">True</property> - <property name="label" translatable="yes">_Use crossfading backend (requires restart)</property> - <property name="use_underline">True</property> - <property name="relief">GTK_RELIEF_NORMAL</property> - <property name="focus_on_click">True</property> - <property name="active">False</property> - <property name="inconsistent">False</property> - <property name="draw_indicator">True</property> - </widget> - <packing> - <property name="padding">0</property> - <property name="expand">False</property> - <property name="fill">False</property> - </packing> - </child> - </widget> - <packing> - <property name="padding">0</property> - <property name="expand">True</property> - <property name="fill">True</property> - </packing> - </child> + <property name="can_focus">True</property> + <property name="label" translatable="yes">_Use crossfading (requires restart)</property> + <property name="use_underline">True</property> + <property name="relief">GTK_RELIEF_NORMAL</property> + <property name="focus_on_click">True</property> + <property name="active">False</property> + <property name="inconsistent">False</property> + <property name="draw_indicator">True</property> </widget> <packing> <property name="padding">0</property> @@ -135,15 +59,15 @@ </child> <child> - <widget class="GtkVBox" id="vbox5"> + <widget class="GtkVBox" id="crossfading_box"> <property name="visible">True</property> <property name="homogeneous">False</property> <property name="spacing">6</property> <child> - <widget class="GtkLabel" id="duration_label"> + <widget class="GtkLabel" id="crossfading_label"> <property name="visible">True</property> - <property name="label" translatable="yes">Crossfade Duration (Seconds)</property> + <property name="label" translatable="yes">Crossfading</property> <property name="use_underline">False</property> <property name="use_markup">False</property> <property name="justify">GTK_JUSTIFY_LEFT</property> @@ -166,15 +90,15 @@ </child> <child> - <widget class="GtkHBox" id="hbox4"> + <widget class="GtkHBox" id="hbox6"> <property name="visible">True</property> <property name="homogeneous">False</property> <property name="spacing">0</property> <child> - <widget class="GtkLabel" id="label5"> + <widget class="GtkLabel" id="label4"> <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> @@ -182,7 +106,7 @@ <property name="selectable">False</property> <property name="xalign">0.5</property> <property name="yalign">0.5</property> - <property name="xpad">0</property> + <property name="xpad">8</property> <property name="ypad">0</property> <property name="ellipsize">PANGO_ELLIPSIZE_NONE</property> <property name="width_chars">-1</property> @@ -197,122 +121,146 @@ </child> <child> - <widget class="GtkHScale" id="duration"> + <widget class="GtkTable" id="table1"> <property name="visible">True</property> - <property name="can_focus">True</property> - <property name="draw_value">True</property> - <property name="value_pos">GTK_POS_TOP</property> - <property name="digits">1</property> - <property name="update_policy">GTK_UPDATE_CONTINUOUS</property> - <property name="inverted">False</property> - <property name="adjustment">0 0 60 0.1 1 0</property> - </widget> - <packing> - <property name="padding">0</property> - <property name="expand">True</property> - <property name="fill">True</property> - </packing> - </child> - </widget> - <packing> - <property name="padding">0</property> - <property name="expand">True</property> - <property name="fill">True</property> - </packing> - </child> - </widget> - <packing> - <property name="padding">0</property> - <property name="expand">False</property> - <property name="fill">False</property> - </packing> - </child> + <property name="n_rows">3</property> + <property name="n_columns">2</property> + <property name="homogeneous">False</property> + <property name="row_spacing">6</property> + <property name="column_spacing">12</property> - <child> - <widget class="GtkVBox" id="vbox7"> - <property name="visible">True</property> - <property name="homogeneous">False</property> - <property name="spacing">6</property> + <child> + <widget class="GtkLabel" id="label8"> + <property name="visible">True</property> + <property name="label" translatable="yes">_Duration (seconds):</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</property> + <property name="yalign">0.5</property> + <property name="xpad">0</property> + <property name="ypad">0</property> + <property name="mnemonic_widget">duration</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="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"></property> + </packing> + </child> - <child> - <widget class="GtkLabel" id="crossfade_type_label"> - <property name="visible">True</property> - <property name="label" translatable="yes">Crossfade Type</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="selectable">False</property> - <property name="xalign">0</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> + <child> + <widget class="GtkHScale" id="duration"> + <property name="visible">True</property> + <property name="can_focus">True</property> + <property name="draw_value">True</property> + <property name="value_pos">GTK_POS_TOP</property> + <property name="digits">1</property> + <property name="update_policy">GTK_UPDATE_CONTINUOUS</property> + <property name="inverted">False</property> + <property name="adjustment">0 0 60 1 10 0</property> + </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="y_options">fill</property> + </packing> + </child> - <child> - <widget class="GtkHBox" id="hbox5"> - <property name="visible">True</property> - <property name="homogeneous">False</property> - <property name="spacing">0</property> + <child> + <widget class="GtkCheckButton" id="album_check"> + <property name="visible">True</property> + <property name="can_focus">True</property> + <property name="label" translatable="yes">C_rossfade between songs on the same album</property> + <property name="use_underline">True</property> + <property name="relief">GTK_RELIEF_NORMAL</property> + <property name="focus_on_click">True</property> + <property name="active">False</property> + <property name="inconsistent">False</property> + <property name="draw_indicator">True</property> + </widget> + <packing> + <property name="left_attach">0</property> + <property name="right_attach">2</property> + <property name="top_attach">0</property> + <property name="bottom_attach">1</property> + <property name="x_options">fill</property> + <property name="y_options"></property> + </packing> + </child> - <child> - <widget class="GtkLabel" id="label7"> - <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="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> + <child> + <widget class="GtkLabel" id="buffer_size_label"> + <property name="visible">True</property> + <property name="label" translatable="yes">_Network buffer size (kB):</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</property> + <property name="yalign">0.5</property> + <property name="xpad">0</property> + <property name="ypad">0</property> + <property name="mnemonic_widget">network_buffer_size</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="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"></property> + </packing> + </child> - <child> - <widget class="GtkCheckButton" id="album_check"> - <property name="visible">True</property> - <property name="can_focus">True</property> - <property name="label" translatable="yes">C_rossfade between songs on the same album</property> - <property name="use_underline">True</property> - <property name="relief">GTK_RELIEF_NORMAL</property> - <property name="focus_on_click">True</property> - <property name="active">False</property> - <property name="inconsistent">False</property> - <property name="draw_indicator">True</property> + <child> + <widget class="GtkHScale" id="network_buffer_size"> + <property name="visible">True</property> + <property name="can_focus">True</property> + <property name="draw_value">True</property> + <property name="value_pos">GTK_POS_TOP</property> + <property name="digits">0</property> + <property name="update_policy">GTK_UPDATE_CONTINUOUS</property> + <property name="inverted">False</property> + <property name="adjustment">32 32 1024 32 128 0</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="x_options">fill</property> + <property name="y_options">fill</property> + </packing> + </child> </widget> <packing> <property name="padding">0</property> - <property name="expand">False</property> - <property name="fill">False</property> + <property name="expand">True</property> + <property name="fill">True</property> </packing> </child> </widget> <packing> <property name="padding">0</property> - <property name="expand">False</property> - <property name="fill">False</property> + <property name="expand">True</property> + <property name="fill">True</property> </packing> </child> </widget> @@ -322,100 +270,6 @@ <property name="fill">False</property> </packing> </child> - - <child> - <widget class="GtkVBox" id="vbox6"> - <property name="visible">True</property> - <property name="homogeneous">False</property> - <property name="spacing">6</property> - - <child> - <widget class="GtkLabel" id="buffer_size_label"> - <property name="visible">True</property> - <property name="label" translatable="yes">Network Buffer Size (kB)</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="selectable">False</property> - <property name="xalign">0</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> - - <child> - <widget class="GtkHBox" id="hbox3"> - <property name="visible">True</property> - <property name="homogeneous">False</property> - <property name="spacing">0</property> - - <child> - <widget class="GtkLabel" id="label4"> - <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="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> - - <child> - <widget class="GtkHScale" id="network_buffer_size"> - <property name="visible">True</property> - <property name="can_focus">True</property> - <property name="draw_value">True</property> - <property name="value_pos">GTK_POS_TOP</property> - <property name="digits">0</property> - <property name="update_policy">GTK_UPDATE_CONTINUOUS</property> - <property name="inverted">False</property> - <property name="adjustment">32 32 1024 32 128 0</property> - </widget> - <packing> - <property name="padding">0</property> - <property name="expand">True</property> - <property name="fill">True</property> - </packing> - </child> - </widget> - <packing> - <property name="padding">0</property> - <property name="expand">False</property> - <property name="fill">False</property> - </packing> - </child> - </widget> - <packing> - <property name="padding">0</property> - <property name="expand">True</property> - <property name="fill">True</property> - </packing> - </child> </widget> </child> </widget>
Attachment:
screenshot.png
Description: PNG image