[rygel] data,ui: Remove MediaExport's title widgets
- From: Zeeshan Ali Khattak <zeeshanak src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [rygel] data,ui: Remove MediaExport's title widgets
- Date: Thu, 17 Feb 2011 23:48:27 +0000 (UTC)
commit ba5f257e994414591224380bf961a21c0f202056
Author: Zeeshan Ali (Khattak) <zeeshanak gnome org>
Date: Wed Feb 16 02:55:23 2011 +0200
data,ui: Remove MediaExport's title widgets
data/rygel-preferences.ui | 37 +--------------------------
src/ui/rygel-media-export-pref-section.vala | 28 --------------------
2 files changed, 1 insertions(+), 64 deletions(-)
---
diff --git a/data/rygel-preferences.ui b/data/rygel-preferences.ui
index 99e596f..1c06807 100644
--- a/data/rygel-preferences.ui
+++ b/data/rygel-preferences.ui
@@ -83,7 +83,7 @@
<object class="GtkTable" id="table4">
<property name="visible">True</property>
<property name="can_focus">False</property>
- <property name="n_rows">3</property>
+ <property name="n_rows">2</property>
<property name="n_columns">2</property>
<property name="column_spacing">6</property>
<property name="row_spacing">6</property>
@@ -104,41 +104,6 @@
</packing>
</child>
<child>
- <object class="GtkLabel" id="mediaexport-title-label">
- <property name="visible">True</property>
- <property name="can_focus">False</property>
- <property name="xalign">0</property>
- <property name="xpad">12</property>
- <property name="label" translatable="yes">Ti_tle</property>
- <property name="use_underline">True</property>
- </object>
- <packing>
- <property name="top_attach">1</property>
- <property name="bottom_attach">2</property>
- <property name="x_options">GTK_FILL</property>
- <property name="y_options">GTK_FILL</property>
- </packing>
- </child>
- <child>
- <object class="GtkEntry" id="mediaexport-title-entry">
- <property name="visible">True</property>
- <property name="can_focus">True</property>
- <property name="has_tooltip">True</property>
- <property name="tooltip_markup" translatable="yes">Write %u for username, %n for real name of the user and %h for host name</property>
- <property name="tooltip_text" translatable="yes">Write %u for username, %n for real name of the user and %h for host name</property>
- <property name="invisible_char">â??</property>
- <property name="width_chars">30</property>
- <property name="invisible_char_set">True</property>
- </object>
- <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">GTK_FILL</property>
- </packing>
- </child>
- <child>
<object class="GtkLabel" id="uris-label">
<property name="visible">True</property>
<property name="can_focus">False</property>
diff --git a/src/ui/rygel-media-export-pref-section.vala b/src/ui/rygel-media-export-pref-section.vala
index ba32731..8902a3c 100644
--- a/src/ui/rygel-media-export-pref-section.vala
+++ b/src/ui/rygel-media-export-pref-section.vala
@@ -25,8 +25,6 @@ using Gee;
public class Rygel.MediaExportPrefSection : PreferencesSection {
const string ENABLED_CHECK = "-enabled-checkbutton";
- const string TITLE_LABEL = "-title-label";
- const string TITLE_ENTRY = "-title-entry";
const string NAME = "MediaExport";
const string URIS_KEY = "uris";
const string URIS_LABEL = URIS_KEY + "-label";
@@ -38,8 +36,6 @@ public class Rygel.MediaExportPrefSection : PreferencesSection {
const string CLEAR_BUTTON = "clear-button";
private CheckButton enabled_check;
- private Entry title_entry;
-
private ArrayList<Widget> widgets; // All widgets in this section
private TreeView treeview;
@@ -55,13 +51,6 @@ public class Rygel.MediaExportPrefSection : PreferencesSection {
this.enabled_check = (CheckButton) builder.get_object (name.down () +
ENABLED_CHECK);
assert (this.enabled_check != null);
- this.title_entry = (Entry) builder.get_object (name.down () +
- TITLE_ENTRY);
- assert (this.title_entry != null);
- var title_label = (Label) builder.get_object (name.down () +
- TITLE_LABEL);
- assert (title_label != null);
- this.widgets.add (title_label);
try {
this.enabled_check.active = config.get_enabled (name);
@@ -69,18 +58,6 @@ public class Rygel.MediaExportPrefSection : PreferencesSection {
this.enabled_check.active = false;
}
- string title;
- try {
- title = config.get_title (name);
- } catch (GLib.Error err) {
- title = name;
- }
-
- title = title.replace ("@REALNAME@", "%n");
- title = title.replace ("@USERNAME@", "%u");
- title = title.replace ("@HOSTNAME@", "%h");
- this.title_entry.set_text (title);
-
this.enabled_check.toggled.connect (this.on_enabled_check_toggled);
this.treeview = (TreeView) builder.get_object (URIS_TEXTVIEW);
@@ -136,11 +113,6 @@ public class Rygel.MediaExportPrefSection : PreferencesSection {
UserConfig.ENABLED_KEY,
this.enabled_check.active);
- var title = this.title_entry.get_text ().replace ("%n", "@REALNAME@");
- title = title.replace ("%u", "@USERNAME@");
- title = title.replace ("%h", "@HOSTNAME@");
- this.config.set_string (this.name, UserConfig.TITLE_KEY, title);
-
TreeIter iter;
var uri_list = new ArrayList<string> ();
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]