summaryrefslogtreecommitdiff
path: root/data
diff options
context:
space:
mode:
authorJens Georg <mail@jensge.org>2016-06-05 22:30:41 +0200
committerJens Georg <mail@jensge.org>2016-12-17 09:47:40 +0100
commit1bb9f4c01dd3927919e693b3fae3a26cbe0fa87c (patch)
tree3fbb3d96c9641da17a8b9307e05a4f887dcc68b3 /data
parentd5ada7fb1868e74c856240399ee70276cd60af25 (diff)
downloadgupnp-tools-1bb9f4c01dd3927919e693b3fae3a26cbe0fa87c.tar.gz
av-cp: Initial search dialog
Provide basic dialog and hook it up with the TreeView's context menu
Diffstat (limited to 'data')
-rw-r--r--data/Makefile.am2
-rw-r--r--data/gupnp-av-cp.ui.in9
-rw-r--r--data/search-dialog.ui125
3 files changed, 135 insertions, 1 deletions
diff --git a/data/Makefile.am b/data/Makefile.am
index 7d40833..dfe289d 100644
--- a/data/Makefile.am
+++ b/data/Makefile.am
@@ -10,7 +10,7 @@ desktop_in_files = gupnp-universal-cp.desktop.in \
gupnp-network-light.desktop.in
if BUILD_AV
-dist_shared_DATA += gupnp-av-cp.ui
+dist_shared_DATA += gupnp-av-cp.ui search-dialog.ui
desktop_in_files += gupnp-av-cp.desktop.in
endif
diff --git a/data/gupnp-av-cp.ui.in b/data/gupnp-av-cp.ui.in
index 5ac435f..19a21c4 100644
--- a/data/gupnp-av-cp.ui.in
+++ b/data/gupnp-av-cp.ui.in
@@ -35,6 +35,15 @@
<signal name="activate" handler="on_didl_menuitem_activate" swapped="no"/>
</object>
</child>
+ <child>
+ <object class="GtkMenuItem" id="search-menuitem">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="label" translatable="yes">Search…</property>
+ <property name="use_underline">True</property>
+ <signal name="activate" handler="on_search_menu_item_activated" swapped="no"/>
+ </object>
+ </child>
</object>
<object class="GtkTreeStore" id="playlist-tree-store">
<columns>
diff --git a/data/search-dialog.ui b/data/search-dialog.ui
new file mode 100644
index 0000000..12b1415
--- /dev/null
+++ b/data/search-dialog.ui
@@ -0,0 +1,125 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!-- Generated with glade 3.20.0 -->
+<interface>
+ <requires lib="gtk+" version="3.20"/>
+ <object class="GtkListStore" id="search-dialog-listview">
+ <columns>
+ <!-- column-name icon -->
+ <column type="GdkPixbuf"/>
+ <!-- column-name title -->
+ <column type="gchararray"/>
+ </columns>
+ </object>
+ <template class="SearchDialog" parent="GtkDialog">
+ <property name="width_request">-1</property>
+ <property name="height_request">-1</property>
+ <property name="can_focus">False</property>
+ <property name="border_width">6</property>
+ <property name="default_width">400</property>
+ <property name="default_height">300</property>
+ <property name="type_hint">dialog</property>
+ <child internal-child="vbox">
+ <object class="GtkBox">
+ <property name="can_focus">False</property>
+ <property name="orientation">vertical</property>
+ <property name="spacing">2</property>
+ <child internal-child="action_area">
+ <object class="GtkButtonBox">
+ <property name="can_focus">False</property>
+ <property name="layout_style">end</property>
+ <child>
+ <object class="GtkButton">
+ <property name="label" translatable="yes">_Close</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">True</property>
+ <property name="use_underline">True</property>
+ <signal name="clicked" handler="gtk_widget_hide" object="SearchDialog" swapped="yes"/>
+ </object>
+ <packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkBox">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="orientation">vertical</property>
+ <property name="spacing">4</property>
+ <child>
+ <object class="GtkEntry">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="primary_icon_name">edit-find</property>
+ <property name="secondary_icon_name">edit-clear</property>
+ <property name="placeholder_text" translatable="yes">UPnP search expression</property>
+ <signal name="activate" handler="search_dialog_on_search_activate" object="SearchDialog" swapped="yes"/>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">True</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkScrolledWindow">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="shadow_type">in</property>
+ <child>
+ <object class="GtkTreeView" id="search-dialog-treeview">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="model">search-dialog-listview</property>
+ <property name="headers_visible">False</property>
+ <child internal-child="selection">
+ <object class="GtkTreeSelection"/>
+ </child>
+ <child>
+ <object class="GtkTreeViewColumn">
+ <property name="title" translatable="yes">column</property>
+ <child>
+ <object class="GtkCellRendererPixbuf"/>
+ <attributes>
+ <attribute name="pixbuf">0</attribute>
+ </attributes>
+ </child>
+ <child>
+ <object class="GtkCellRendererText">
+ <property name="xpad">6</property>
+ </object>
+ <attributes>
+ <attribute name="text">1</attribute>
+ </attributes>
+ </child>
+ </object>
+ </child>
+ </object>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ </child>
+ </template>
+</interface>