Sophie

Sophie

distrib > Fedora > 14 > x86_64 > by-pkgid > dc9b9eb224888fd532330fad8ee0ffc5 > files > 559

audacious-devel-2.4.5-1.fc14.x86_64.rpm

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<title>Audacious: ui_preferences.c Source File</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<link href="doxygen.css" rel="stylesheet" type="text/css"/>
</head>
<body>
<!-- Generated by Doxygen 1.7.3 -->
<div id="top">
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr style="height: 56px;">
  <td style="padding-left: 0.5em;">
   <div id="projectname">Audacious&#160;<span id="projectnumber">$Id:Doxyfile42802007-03-2104:39:00Znenolod$</span></div>
  </td>
 </tr>
 </tbody>
</table>
</div>
  <div id="navrow1" class="tabs">
    <ul class="tablist">
      <li><a href="index.html"><span>Main&#160;Page</span></a></li>
      <li><a href="pages.html"><span>Related&#160;Pages</span></a></li>
      <li><a href="annotated.html"><span>Classes</span></a></li>
      <li class="current"><a href="files.html"><span>Files</span></a></li>
    </ul>
  </div>
  <div id="navrow2" class="tabs2">
    <ul class="tablist">
      <li><a href="files.html"><span>File&#160;List</span></a></li>
      <li><a href="globals.html"><span>File&#160;Members</span></a></li>
    </ul>
  </div>
<div class="header">
  <div class="headertitle">
<h1>ui_preferences.c</h1>  </div>
</div>
<div class="contents">
<a href="ui__preferences_8c.html">Go to the documentation of this file.</a><div class="fragment"><pre class="fragment"><a name="l00001"></a>00001 <span class="comment">/*  Audacious - Cross-platform multimedia player</span>
<a name="l00002"></a>00002 <span class="comment"> *  Copyright (C) 2005-2007  Audacious development team.</span>
<a name="l00003"></a>00003 <span class="comment"> *</span>
<a name="l00004"></a>00004 <span class="comment"> *  This program is free software; you can redistribute it and/or modify</span>
<a name="l00005"></a>00005 <span class="comment"> *  it under the terms of the GNU General Public License as published by</span>
<a name="l00006"></a>00006 <span class="comment"> *  the Free Software Foundation; under version 3 of the License.</span>
<a name="l00007"></a>00007 <span class="comment"> *</span>
<a name="l00008"></a>00008 <span class="comment"> *  This program is distributed in the hope that it will be useful,</span>
<a name="l00009"></a>00009 <span class="comment"> *  but WITHOUT ANY WARRANTY; without even the implied warranty of</span>
<a name="l00010"></a>00010 <span class="comment"> *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the</span>
<a name="l00011"></a>00011 <span class="comment"> *  GNU General Public License for more details.</span>
<a name="l00012"></a>00012 <span class="comment"> *</span>
<a name="l00013"></a>00013 <span class="comment"> *  You should have received a copy of the GNU General Public License</span>
<a name="l00014"></a>00014 <span class="comment"> *  along with this program.  If not, see &lt;http://www.gnu.org/licenses&gt;.</span>
<a name="l00015"></a>00015 <span class="comment"> *</span>
<a name="l00016"></a>00016 <span class="comment"> *  The Audacious team does not consider modular code linking to</span>
<a name="l00017"></a>00017 <span class="comment"> *  Audacious or using our public API to be a derived work.</span>
<a name="l00018"></a>00018 <span class="comment"> */</span>
<a name="l00019"></a>00019 
<a name="l00020"></a>00020 <span class="preprocessor">#ifdef HAVE_CONFIG_H</span>
<a name="l00021"></a>00021 <span class="preprocessor"></span><span class="preprocessor">#  include &quot;config.h&quot;</span>
<a name="l00022"></a>00022 <span class="preprocessor">#endif</span>
<a name="l00023"></a>00023 <span class="preprocessor"></span>
<a name="l00024"></a>00024 <span class="preprocessor">#include &lt;glib.h&gt;</span>
<a name="l00025"></a>00025 <span class="preprocessor">#include &lt;gtk/gtk.h&gt;</span>
<a name="l00026"></a>00026 <span class="preprocessor">#include &lt;string.h&gt;</span>
<a name="l00027"></a>00027 <span class="preprocessor">#include &lt;stddef.h&gt;</span>
<a name="l00028"></a>00028 <span class="preprocessor">#include &lt;stdio.h&gt;</span>
<a name="l00029"></a>00029 <span class="preprocessor">#include &lt;sys/types.h&gt;</span>
<a name="l00030"></a>00030 <span class="preprocessor">#include &lt;dirent.h&gt;</span>
<a name="l00031"></a>00031 <span class="preprocessor">#include &lt;unistd.h&gt;</span>
<a name="l00032"></a>00032 <span class="preprocessor">#include &lt;errno.h&gt;</span>
<a name="l00033"></a>00033 <span class="preprocessor">#include &lt;sys/types.h&gt;</span>
<a name="l00034"></a>00034 <span class="preprocessor">#include &lt;sys/stat.h&gt;</span>
<a name="l00035"></a>00035 <span class="preprocessor">#include &lt;gdk/gdkkeysyms.h&gt;</span>
<a name="l00036"></a>00036 
<a name="l00037"></a>00037 <span class="preprocessor">#include &lt;libaudcore/hook.h&gt;</span>
<a name="l00038"></a>00038 
<a name="l00039"></a>00039 <span class="preprocessor">#include &quot;<a class="code" href="audconfig_8h.html">audconfig.h</a>&quot;</span>
<a name="l00040"></a>00040 <span class="preprocessor">#include &quot;<a class="code" href="compatibility_8h.html">compatibility.h</a>&quot;</span>
<a name="l00041"></a>00041 <span class="preprocessor">#include &quot;<a class="code" href="debug_8h.html">debug.h</a>&quot;</span>
<a name="l00042"></a>00042 <span class="preprocessor">#include &quot;<a class="code" href="i18n_8h.html">i18n.h</a>&quot;</span>
<a name="l00043"></a>00043 <span class="preprocessor">#include &quot;<a class="code" href="misc_8h.html">misc.h</a>&quot;</span>
<a name="l00044"></a>00044 <span class="preprocessor">#include &quot;<a class="code" href="playback_8h.html">playback.h</a>&quot;</span>
<a name="l00045"></a>00045 <span class="preprocessor">#include &quot;<a class="code" href="plugin_8h.html" title="Main Audacious plugin API header file.">plugin.h</a>&quot;</span>
<a name="l00046"></a>00046 <span class="preprocessor">#include &quot;<a class="code" href="pluginenum_8h.html">pluginenum.h</a>&quot;</span>
<a name="l00047"></a>00047 <span class="preprocessor">#include &quot;<a class="code" href="plugins_8h.html">plugins.h</a>&quot;</span>
<a name="l00048"></a>00048 <span class="preprocessor">#include &quot;<a class="code" href="effect_8h.html">effect.h</a>&quot;</span>
<a name="l00049"></a>00049 <span class="preprocessor">#include &quot;<a class="code" href="general_8h.html">general.h</a>&quot;</span>
<a name="l00050"></a>00050 <span class="preprocessor">#include &quot;<a class="code" href="output_8h.html">output.h</a>&quot;</span>
<a name="l00051"></a>00051 <span class="preprocessor">#include &quot;<a class="code" href="playlist_8h.html">playlist.h</a>&quot;</span>
<a name="l00052"></a>00052 <span class="preprocessor">#include &quot;<a class="code" href="playlist-utils_8h.html">playlist-utils.h</a>&quot;</span>
<a name="l00053"></a>00053 <span class="preprocessor">#include &quot;<a class="code" href="visualization_8h.html">visualization.h</a>&quot;</span>
<a name="l00054"></a>00054 <span class="preprocessor">#include &quot;<a class="code" href="util_8h.html">util.h</a>&quot;</span>
<a name="l00055"></a>00055 <span class="preprocessor">#include &quot;<a class="code" href="configdb_8h.html">configdb.h</a>&quot;</span>
<a name="l00056"></a>00056 <span class="preprocessor">#include &quot;<a class="code" href="preferences_8h.html">preferences.h</a>&quot;</span>
<a name="l00057"></a>00057 
<a name="l00058"></a>00058 <span class="preprocessor">#include &quot;<a class="code" href="ui__preferences_8h.html">ui_preferences.h</a>&quot;</span>
<a name="l00059"></a>00059 
<a name="l00060"></a><a class="code" href="ui__preferences_8c.html#a65dbec50671b69564a37363d2bc5a3d8">00060</a> <span class="preprocessor">#define TITLESTRING_UPDATE_TIMEOUT 3</span>
<a name="l00061"></a>00061 <span class="preprocessor"></span>
<a name="l00062"></a>00062 <span class="keyword">static</span> <span class="keywordtype">void</span> <a class="code" href="ui__preferences_8c.html#a162e0c2f851d5a3f8b1b0d9fd68b679f">sw_volume_toggled</a> (<span class="keywordtype">void</span>);
<a name="l00063"></a>00063 
<a name="l00064"></a><a class="code" href="ui__preferences_8c.html#ab327bcf652522bc3ff67a66149322eca">00064</a> <span class="keyword">enum</span> <a class="code" href="ui__preferences_8c.html#ab327bcf652522bc3ff67a66149322eca">CategoryViewCols</a> {
<a name="l00065"></a><a class="code" href="ui__preferences_8c.html#ab327bcf652522bc3ff67a66149322ecaa9f029b74c630e374d42d3487fcb2024b">00065</a>     <a class="code" href="ui__preferences_8c.html#ab327bcf652522bc3ff67a66149322ecaa9f029b74c630e374d42d3487fcb2024b">CATEGORY_VIEW_COL_ICON</a>,
<a name="l00066"></a><a class="code" href="ui__preferences_8c.html#ab327bcf652522bc3ff67a66149322ecaa2ad7e3c813c7a4c25ec39518ed944b97">00066</a>     <a class="code" href="ui__preferences_8c.html#ab327bcf652522bc3ff67a66149322ecaa2ad7e3c813c7a4c25ec39518ed944b97">CATEGORY_VIEW_COL_NAME</a>,
<a name="l00067"></a><a class="code" href="ui__preferences_8c.html#ab327bcf652522bc3ff67a66149322ecaa807e88ae3818317d7cb3025cac995a52">00067</a>     <a class="code" href="ui__preferences_8c.html#ab327bcf652522bc3ff67a66149322ecaa807e88ae3818317d7cb3025cac995a52">CATEGORY_VIEW_COL_ID</a>,
<a name="l00068"></a><a class="code" href="ui__preferences_8c.html#ab327bcf652522bc3ff67a66149322ecaaa5e981b84e9ff40e106e2fd68eeaae77">00068</a>     <a class="code" href="ui__preferences_8c.html#ab327bcf652522bc3ff67a66149322ecaaa5e981b84e9ff40e106e2fd68eeaae77">CATEGORY_VIEW_N_COLS</a>
<a name="l00069"></a>00069 };
<a name="l00070"></a>00070 
<a name="l00071"></a><a class="code" href="ui__preferences_8c.html#ace28870b3187dd2ac8e8f218e8c590d4">00071</a> <span class="keyword">enum</span> <a class="code" href="ui__preferences_8c.html#ace28870b3187dd2ac8e8f218e8c590d4">PluginViewCols</a> {
<a name="l00072"></a><a class="code" href="ui__preferences_8c.html#ace28870b3187dd2ac8e8f218e8c590d4a0c9c6f27b4307deed535637690600b72">00072</a>     <a class="code" href="ui__preferences_8c.html#ace28870b3187dd2ac8e8f218e8c590d4a0c9c6f27b4307deed535637690600b72">PLUGIN_VIEW_COL_ACTIVE</a>,
<a name="l00073"></a><a class="code" href="ui__preferences_8c.html#ace28870b3187dd2ac8e8f218e8c590d4a838e9673d18906f8105fa1d13c052cf3">00073</a>     <a class="code" href="ui__preferences_8c.html#ace28870b3187dd2ac8e8f218e8c590d4a838e9673d18906f8105fa1d13c052cf3">PLUGIN_VIEW_COL_DESC</a>,
<a name="l00074"></a><a class="code" href="ui__preferences_8c.html#ace28870b3187dd2ac8e8f218e8c590d4a327b60fd26e1b343a926bf9a9125100c">00074</a>     <a class="code" href="ui__preferences_8c.html#ace28870b3187dd2ac8e8f218e8c590d4a327b60fd26e1b343a926bf9a9125100c">PLUGIN_VIEW_COL_FILENAME</a>,
<a name="l00075"></a><a class="code" href="ui__preferences_8c.html#ace28870b3187dd2ac8e8f218e8c590d4a9863793d2e83dab994f12dd91a443320">00075</a>     <a class="code" href="ui__preferences_8c.html#ace28870b3187dd2ac8e8f218e8c590d4a9863793d2e83dab994f12dd91a443320">PLUGIN_VIEW_COL_ID</a>,
<a name="l00076"></a><a class="code" href="ui__preferences_8c.html#ace28870b3187dd2ac8e8f218e8c590d4a5ed42aa040a6ec3d2ba084f3c72cd57e">00076</a>     <a class="code" href="ui__preferences_8c.html#ace28870b3187dd2ac8e8f218e8c590d4a5ed42aa040a6ec3d2ba084f3c72cd57e">PLUGIN_VIEW_COL_PLUGIN_PTR</a>,
<a name="l00077"></a><a class="code" href="ui__preferences_8c.html#ace28870b3187dd2ac8e8f218e8c590d4abe51f5d764f6163dc1d30a845be154d7">00077</a>     <a class="code" href="ui__preferences_8c.html#ace28870b3187dd2ac8e8f218e8c590d4abe51f5d764f6163dc1d30a845be154d7">PLUGIN_VIEW_N_COLS</a>
<a name="l00078"></a>00078 };
<a name="l00079"></a>00079 
<a name="l00080"></a><a class="code" href="ui__preferences_8c.html#a5644eb3f790d5e6ba29119a7d4e6e3d3">00080</a> <span class="keyword">enum</span> <a class="code" href="ui__preferences_8c.html#a5644eb3f790d5e6ba29119a7d4e6e3d3">PluginViewType</a> {
<a name="l00081"></a><a class="code" href="ui__preferences_8c.html#a5644eb3f790d5e6ba29119a7d4e6e3d3ab5031417c44d1f05c26c8379ec6bbe3d">00081</a>     <a class="code" href="ui__preferences_8c.html#a5644eb3f790d5e6ba29119a7d4e6e3d3ab5031417c44d1f05c26c8379ec6bbe3d">PLUGIN_VIEW_TYPE_INPUT</a>,
<a name="l00082"></a><a class="code" href="ui__preferences_8c.html#a5644eb3f790d5e6ba29119a7d4e6e3d3a224907d964592908c703588c3bde1bcd">00082</a>     <a class="code" href="ui__preferences_8c.html#a5644eb3f790d5e6ba29119a7d4e6e3d3a224907d964592908c703588c3bde1bcd">PLUGIN_VIEW_TYPE_GENERAL</a>,
<a name="l00083"></a><a class="code" href="ui__preferences_8c.html#a5644eb3f790d5e6ba29119a7d4e6e3d3a0c16e7265127af9a2346972168951bad">00083</a>     <a class="code" href="ui__preferences_8c.html#a5644eb3f790d5e6ba29119a7d4e6e3d3a0c16e7265127af9a2346972168951bad">PLUGIN_VIEW_TYPE_VIS</a>,
<a name="l00084"></a><a class="code" href="ui__preferences_8c.html#a5644eb3f790d5e6ba29119a7d4e6e3d3afd0d22de728112565df5c88ed82f3c06">00084</a>     <a class="code" href="ui__preferences_8c.html#a5644eb3f790d5e6ba29119a7d4e6e3d3afd0d22de728112565df5c88ed82f3c06">PLUGIN_VIEW_TYPE_EFFECT</a>
<a name="l00085"></a>00085 };
<a name="l00086"></a>00086 
<a name="l00087"></a><a class="code" href="structCategory.html">00087</a> <span class="keyword">typedef</span> <span class="keyword">struct </span>{
<a name="l00088"></a><a class="code" href="structCategory.html#a4717f5fa6a854b0e11cb0184bbddefb6">00088</a>     <span class="keyword">const</span> gchar *<a class="code" href="structCategory.html#a4717f5fa6a854b0e11cb0184bbddefb6">icon_path</a>;
<a name="l00089"></a><a class="code" href="structCategory.html#a15a442550a35802ac6a73eb5fbe8c3c1">00089</a>     <span class="keyword">const</span> gchar *<a class="code" href="structCategory.html#a15a442550a35802ac6a73eb5fbe8c3c1">name</a>;
<a name="l00090"></a>00090 } <a class="code" href="structCategory.html">Category</a>;
<a name="l00091"></a>00091 
<a name="l00092"></a><a class="code" href="structTitleFieldTag.html">00092</a> <span class="keyword">typedef</span> <span class="keyword">struct </span>{
<a name="l00093"></a><a class="code" href="structTitleFieldTag.html#a3e2fa4ac079dc7692238689d3749d1d6">00093</a>     <span class="keyword">const</span> gchar *<a class="code" href="structTitleFieldTag.html#a3e2fa4ac079dc7692238689d3749d1d6">name</a>;
<a name="l00094"></a><a class="code" href="structTitleFieldTag.html#aafaff2926dc2cf96f21c559ce2290867">00094</a>     <span class="keyword">const</span> gchar *<a class="code" href="structTitleFieldTag.html#aafaff2926dc2cf96f21c559ce2290867">tag</a>;
<a name="l00095"></a>00095 } <a class="code" href="structTitleFieldTag.html">TitleFieldTag</a>;
<a name="l00096"></a>00096 
<a name="l00097"></a><a class="code" href="structMenuPos.html">00097</a> <span class="keyword">typedef</span> <span class="keyword">struct </span>{
<a name="l00098"></a><a class="code" href="structMenuPos.html#a50edc68e640424b58d32f2e40620809f">00098</a>     <a class="code" href="misc-api_8h.html#acf599c059f43e0cca83145eb6b0c93cd">gint</a> <a class="code" href="structMenuPos.html#a50edc68e640424b58d32f2e40620809f">x</a>;
<a name="l00099"></a><a class="code" href="structMenuPos.html#ac736ed415d574b86ff7a3c98d5831c0e">00099</a>     <a class="code" href="misc-api_8h.html#acf599c059f43e0cca83145eb6b0c93cd">gint</a> <a class="code" href="structMenuPos.html#ac736ed415d574b86ff7a3c98d5831c0e">y</a>;
<a name="l00100"></a>00100 } <a class="code" href="structMenuPos.html">MenuPos</a>;
<a name="l00101"></a>00101 
<a name="l00102"></a><a class="code" href="ui__preferences_8c.html#a68dc3d5b54e6e977aedc3ca6a96e92b1">00102</a> <span class="keyword">static</span> <span class="comment">/* GtkWidget * */</span> <span class="keywordtype">void</span> * <a class="code" href="ui__preferences_8c.html#a68dc3d5b54e6e977aedc3ca6a96e92b1">prefswin</a> = NULL;
<a name="l00103"></a><a class="code" href="ui__preferences_8c.html#a6af62902a201b816a4038fd2f97481a2">00103</a> <span class="keyword">static</span> GtkWidget *<a class="code" href="ui__preferences_8c.html#a6af62902a201b816a4038fd2f97481a2">filepopup_settings</a> = NULL;
<a name="l00104"></a><a class="code" href="ui__preferences_8c.html#a2d9f22af30312bfb508faf3d100d1a43">00104</a> <span class="keyword">static</span> GtkWidget *<a class="code" href="ui__preferences_8c.html#a2d9f22af30312bfb508faf3d100d1a43">category_treeview</a> = NULL;
<a name="l00105"></a><a class="code" href="ui__preferences_8c.html#a5c1d2afa8759c0f574e9ac02dcd695f8">00105</a> <span class="keyword">static</span> GtkWidget *<a class="code" href="ui__preferences_8c.html#a5c1d2afa8759c0f574e9ac02dcd695f8">category_notebook</a> = NULL;
<a name="l00106"></a><a class="code" href="ui__preferences_8c.html#a7967067f4ebb6dfe6b7061ed452ee7e8">00106</a> GtkWidget *<a class="code" href="ui__preferences_8c.html#a7967067f4ebb6dfe6b7061ed452ee7e8">filepopupbutton</a> = NULL;
<a name="l00107"></a>00107 
<a name="l00108"></a>00108 <span class="comment">/* filepopup settings widgets */</span>
<a name="l00109"></a><a class="code" href="ui__preferences_8c.html#aeffefe5b1341092d2bcea93eeb54e6e7">00109</a> GtkWidget *<a class="code" href="ui__preferences_8c.html#aeffefe5b1341092d2bcea93eeb54e6e7">filepopup_settings_cover_name_include</a>;
<a name="l00110"></a><a class="code" href="ui__preferences_8c.html#a4916123a9b3c4cd69579f6e2ab05f392">00110</a> GtkWidget *<a class="code" href="ui__preferences_8c.html#a4916123a9b3c4cd69579f6e2ab05f392">filepopup_settings_cover_name_exclude</a>;
<a name="l00111"></a><a class="code" href="ui__preferences_8c.html#a131837372172af9db3fc5d91a5f2aa9b">00111</a> GtkWidget *<a class="code" href="ui__preferences_8c.html#a131837372172af9db3fc5d91a5f2aa9b">filepopup_settings_recurse_for_cover</a>;
<a name="l00112"></a><a class="code" href="ui__preferences_8c.html#ace3440a4371ba3dd0d53bcc054bb483a">00112</a> GtkWidget *<a class="code" href="ui__preferences_8c.html#ace3440a4371ba3dd0d53bcc054bb483a">filepopup_settings_recurse_for_cover_depth</a>;
<a name="l00113"></a><a class="code" href="ui__preferences_8c.html#a95e4e396181962faab937bb13309a48b">00113</a> GtkWidget *<a class="code" href="ui__preferences_8c.html#a95e4e396181962faab937bb13309a48b">filepopup_settings_recurse_for_cover_depth_box</a>;
<a name="l00114"></a><a class="code" href="ui__preferences_8c.html#a346148c7cc9fc7f3d713fd1280a6a349">00114</a> GtkWidget *<a class="code" href="ui__preferences_8c.html#a346148c7cc9fc7f3d713fd1280a6a349">filepopup_settings_use_file_cover</a>;
<a name="l00115"></a><a class="code" href="ui__preferences_8c.html#afd8b57e120943e674216fc2854ca1edb">00115</a> GtkWidget *<a class="code" href="ui__preferences_8c.html#afd8b57e120943e674216fc2854ca1edb">filepopup_settings_showprogressbar</a>;
<a name="l00116"></a><a class="code" href="ui__preferences_8c.html#a557d900b62cb289e400d6c124f34a3e4">00116</a> GtkWidget *<a class="code" href="ui__preferences_8c.html#a557d900b62cb289e400d6c124f34a3e4">filepopup_settings_delay</a>;
<a name="l00117"></a>00117 
<a name="l00118"></a>00118 <span class="comment">/* prefswin widgets */</span>
<a name="l00119"></a><a class="code" href="ui__preferences_8c.html#a653d9510fccddd6017f30dab79d0f355">00119</a> GtkWidget *<a class="code" href="ui__preferences_8c.html#a653d9510fccddd6017f30dab79d0f355">titlestring_entry</a>;
<a name="l00120"></a><a class="code" href="ui__preferences_8c.html#ac603916ed5e941130399cbf62c64e46f">00120</a> GtkWidget *<a class="code" href="ui__preferences_8c.html#ac603916ed5e941130399cbf62c64e46f">filepopup_for_tuple_settings_button</a>;
<a name="l00121"></a><a class="code" href="ui__preferences_8c.html#ab6cf8123c3f99607c2c27af09aa18aa6">00121</a> <span class="keyword">static</span> <a class="code" href="misc-api_8h.html#acf599c059f43e0cca83145eb6b0c93cd">gint</a> <a class="code" href="ui__preferences_8c.html#ab6cf8123c3f99607c2c27af09aa18aa6">titlestring_timeout_counter</a> = 0;
<a name="l00122"></a>00122 
<a name="l00123"></a><a class="code" href="ui__preferences_8c.html#a6fe696cc8598814a9079c942d06df5ea">00123</a> <span class="keyword">static</span> <a class="code" href="structCategory.html">Category</a> <a class="code" href="ui__preferences_8c.html#a6fe696cc8598814a9079c942d06df5ea">categories</a>[] = {
<a name="l00124"></a>00124     {DATA_DIR <span class="stringliteral">&quot;/images/audio.png&quot;</span>,        <a class="code" href="i18n_8h.html#a75278405e7f034d2b1af80bfd94675fe">N_</a>(<span class="stringliteral">&quot;Audio&quot;</span>)},
<a name="l00125"></a>00125     {DATA_DIR <span class="stringliteral">&quot;/images/replay_gain.png&quot;</span>,  <a class="code" href="i18n_8h.html#a75278405e7f034d2b1af80bfd94675fe">N_</a>(<span class="stringliteral">&quot;Replay Gain&quot;</span>)},
<a name="l00126"></a>00126     {DATA_DIR <span class="stringliteral">&quot;/images/connectivity.png&quot;</span>, <a class="code" href="i18n_8h.html#a75278405e7f034d2b1af80bfd94675fe">N_</a>(<span class="stringliteral">&quot;Network&quot;</span>)},
<a name="l00127"></a>00127     {DATA_DIR <span class="stringliteral">&quot;/images/playback.png&quot;</span>,     <a class="code" href="i18n_8h.html#a75278405e7f034d2b1af80bfd94675fe">N_</a>(<span class="stringliteral">&quot;Playback&quot;</span>)},
<a name="l00128"></a>00128     {DATA_DIR <span class="stringliteral">&quot;/images/playlist.png&quot;</span>,     <a class="code" href="i18n_8h.html#a75278405e7f034d2b1af80bfd94675fe">N_</a>(<span class="stringliteral">&quot;Playlist&quot;</span>)},
<a name="l00129"></a>00129     {DATA_DIR <span class="stringliteral">&quot;/images/plugins.png&quot;</span>,      <a class="code" href="i18n_8h.html#a75278405e7f034d2b1af80bfd94675fe">N_</a>(<span class="stringliteral">&quot;Plugins&quot;</span>)},
<a name="l00130"></a>00130 };
<a name="l00131"></a>00131 
<a name="l00132"></a><a class="code" href="ui__preferences_8c.html#ab17d8310433b2104fda0b9d19e73b3a3">00132</a> <span class="keyword">static</span> <a class="code" href="misc-api_8h.html#acf599c059f43e0cca83145eb6b0c93cd">gint</a> <a class="code" href="ui__preferences_8c.html#ab17d8310433b2104fda0b9d19e73b3a3">n_categories</a> = G_N_ELEMENTS(categories);
<a name="l00133"></a>00133 
<a name="l00134"></a><a class="code" href="ui__preferences_8c.html#af5dc5e9ede295febcd9c52af94ae76ea">00134</a> <span class="keyword">static</span> <a class="code" href="structTitleFieldTag.html">TitleFieldTag</a> <a class="code" href="ui__preferences_8c.html#af5dc5e9ede295febcd9c52af94ae76ea">title_field_tags</a>[] = {
<a name="l00135"></a>00135     { <a class="code" href="i18n_8h.html#a75278405e7f034d2b1af80bfd94675fe">N_</a>(<span class="stringliteral">&quot;Artist&quot;</span>)     , <span class="stringliteral">&quot;${artist}&quot;</span> },
<a name="l00136"></a>00136     { <a class="code" href="i18n_8h.html#a75278405e7f034d2b1af80bfd94675fe">N_</a>(<span class="stringliteral">&quot;Album&quot;</span>)      , <span class="stringliteral">&quot;${album}&quot;</span> },
<a name="l00137"></a>00137     { <a class="code" href="i18n_8h.html#a75278405e7f034d2b1af80bfd94675fe">N_</a>(<span class="stringliteral">&quot;Title&quot;</span>)      , <span class="stringliteral">&quot;${title}&quot;</span> },
<a name="l00138"></a>00138     { <a class="code" href="i18n_8h.html#a75278405e7f034d2b1af80bfd94675fe">N_</a>(<span class="stringliteral">&quot;Tracknumber&quot;</span>), <span class="stringliteral">&quot;${track-number}&quot;</span> },
<a name="l00139"></a>00139     { <a class="code" href="i18n_8h.html#a75278405e7f034d2b1af80bfd94675fe">N_</a>(<span class="stringliteral">&quot;Genre&quot;</span>)      , <span class="stringliteral">&quot;${genre}&quot;</span> },
<a name="l00140"></a>00140     { <a class="code" href="i18n_8h.html#a75278405e7f034d2b1af80bfd94675fe">N_</a>(<span class="stringliteral">&quot;Filename&quot;</span>)   , <span class="stringliteral">&quot;${file-name}&quot;</span> },
<a name="l00141"></a>00141     { <a class="code" href="i18n_8h.html#a75278405e7f034d2b1af80bfd94675fe">N_</a>(<span class="stringliteral">&quot;Filepath&quot;</span>)   , <span class="stringliteral">&quot;${file-path}&quot;</span> },
<a name="l00142"></a>00142     { <a class="code" href="i18n_8h.html#a75278405e7f034d2b1af80bfd94675fe">N_</a>(<span class="stringliteral">&quot;Date&quot;</span>)       , <span class="stringliteral">&quot;${date}&quot;</span> },
<a name="l00143"></a>00143     { <a class="code" href="i18n_8h.html#a75278405e7f034d2b1af80bfd94675fe">N_</a>(<span class="stringliteral">&quot;Year&quot;</span>)       , <span class="stringliteral">&quot;${year}&quot;</span> },
<a name="l00144"></a>00144     { <a class="code" href="i18n_8h.html#a75278405e7f034d2b1af80bfd94675fe">N_</a>(<span class="stringliteral">&quot;Comment&quot;</span>)    , <span class="stringliteral">&quot;${comment}&quot;</span> },
<a name="l00145"></a>00145     { <a class="code" href="i18n_8h.html#a75278405e7f034d2b1af80bfd94675fe">N_</a>(<span class="stringliteral">&quot;Codec&quot;</span>)      , <span class="stringliteral">&quot;${codec}&quot;</span> },
<a name="l00146"></a>00146     { <a class="code" href="i18n_8h.html#a75278405e7f034d2b1af80bfd94675fe">N_</a>(<span class="stringliteral">&quot;Quality&quot;</span>)    , <span class="stringliteral">&quot;${quality}&quot;</span> },
<a name="l00147"></a>00147 };
<a name="l00148"></a><a class="code" href="ui__preferences_8c.html#af4fd0a20dbb4a65972bc5f4f51c373a8">00148</a> <span class="keyword">static</span> <span class="keyword">const</span> guint <a class="code" href="ui__preferences_8c.html#af4fd0a20dbb4a65972bc5f4f51c373a8">n_title_field_tags</a> = G_N_ELEMENTS(title_field_tags);
<a name="l00149"></a>00149 
<a name="l00150"></a><a class="code" href="ui__preferences_8c.html#a35f349d7e674dc2f2e859d0e57ff4283">00150</a> <span class="keyword">static</span> <a class="code" href="structComboBoxElements.html">ComboBoxElements</a> <a class="code" href="ui__preferences_8c.html#a35f349d7e674dc2f2e859d0e57ff4283">chardet_detector_presets</a>[] = {
<a name="l00151"></a>00151     { <a class="code" href="i18n_8h.html#a75278405e7f034d2b1af80bfd94675fe">N_</a>(<span class="stringliteral">&quot;None&quot;</span>)     , <a class="code" href="i18n_8h.html#a75278405e7f034d2b1af80bfd94675fe">N_</a>(<span class="stringliteral">&quot;None&quot;</span>) },
<a name="l00152"></a>00152     { <a class="code" href="i18n_8h.html#a75278405e7f034d2b1af80bfd94675fe">N_</a>(<span class="stringliteral">&quot;Japanese&quot;</span>) , <a class="code" href="i18n_8h.html#a75278405e7f034d2b1af80bfd94675fe">N_</a>(<span class="stringliteral">&quot;Japanese&quot;</span>) },
<a name="l00153"></a>00153     { <a class="code" href="i18n_8h.html#a75278405e7f034d2b1af80bfd94675fe">N_</a>(<span class="stringliteral">&quot;Taiwanese&quot;</span>), <a class="code" href="i18n_8h.html#a75278405e7f034d2b1af80bfd94675fe">N_</a>(<span class="stringliteral">&quot;Taiwanese&quot;</span>) },
<a name="l00154"></a>00154     { <a class="code" href="i18n_8h.html#a75278405e7f034d2b1af80bfd94675fe">N_</a>(<span class="stringliteral">&quot;Chinese&quot;</span>)  , <a class="code" href="i18n_8h.html#a75278405e7f034d2b1af80bfd94675fe">N_</a>(<span class="stringliteral">&quot;Chinese&quot;</span>) },
<a name="l00155"></a>00155     { <a class="code" href="i18n_8h.html#a75278405e7f034d2b1af80bfd94675fe">N_</a>(<span class="stringliteral">&quot;Korean&quot;</span>)   , <a class="code" href="i18n_8h.html#a75278405e7f034d2b1af80bfd94675fe">N_</a>(<span class="stringliteral">&quot;Korean&quot;</span>) },
<a name="l00156"></a>00156     { <a class="code" href="i18n_8h.html#a75278405e7f034d2b1af80bfd94675fe">N_</a>(<span class="stringliteral">&quot;Russian&quot;</span>)  , <a class="code" href="i18n_8h.html#a75278405e7f034d2b1af80bfd94675fe">N_</a>(<span class="stringliteral">&quot;Russian&quot;</span>) },
<a name="l00157"></a>00157     { <a class="code" href="i18n_8h.html#a75278405e7f034d2b1af80bfd94675fe">N_</a>(<span class="stringliteral">&quot;Greek&quot;</span>)    , <a class="code" href="i18n_8h.html#a75278405e7f034d2b1af80bfd94675fe">N_</a>(<span class="stringliteral">&quot;Greek&quot;</span>) },
<a name="l00158"></a>00158     { <a class="code" href="i18n_8h.html#a75278405e7f034d2b1af80bfd94675fe">N_</a>(<span class="stringliteral">&quot;Hebrew&quot;</span>)   , <a class="code" href="i18n_8h.html#a75278405e7f034d2b1af80bfd94675fe">N_</a>(<span class="stringliteral">&quot;Hebrew&quot;</span>) },
<a name="l00159"></a>00159     { <a class="code" href="i18n_8h.html#a75278405e7f034d2b1af80bfd94675fe">N_</a>(<span class="stringliteral">&quot;Turkish&quot;</span>)  , <a class="code" href="i18n_8h.html#a75278405e7f034d2b1af80bfd94675fe">N_</a>(<span class="stringliteral">&quot;Turkish&quot;</span>) },
<a name="l00160"></a>00160     { <a class="code" href="i18n_8h.html#a75278405e7f034d2b1af80bfd94675fe">N_</a>(<span class="stringliteral">&quot;Arabic&quot;</span>)   , <a class="code" href="i18n_8h.html#a75278405e7f034d2b1af80bfd94675fe">N_</a>(<span class="stringliteral">&quot;Arabic&quot;</span>) },
<a name="l00161"></a>00161     { <a class="code" href="i18n_8h.html#a75278405e7f034d2b1af80bfd94675fe">N_</a>(<span class="stringliteral">&quot;Polish&quot;</span>)   , <a class="code" href="i18n_8h.html#a75278405e7f034d2b1af80bfd94675fe">N_</a>(<span class="stringliteral">&quot;Polish&quot;</span>) },
<a name="l00162"></a>00162     { <a class="code" href="i18n_8h.html#a75278405e7f034d2b1af80bfd94675fe">N_</a>(<span class="stringliteral">&quot;Baltic&quot;</span>)   , <a class="code" href="i18n_8h.html#a75278405e7f034d2b1af80bfd94675fe">N_</a>(<span class="stringliteral">&quot;Baltic&quot;</span>) },
<a name="l00163"></a>00163     { <a class="code" href="i18n_8h.html#a75278405e7f034d2b1af80bfd94675fe">N_</a>(<span class="stringliteral">&quot;Universal&quot;</span>), <a class="code" href="i18n_8h.html#a75278405e7f034d2b1af80bfd94675fe">N_</a>(<span class="stringliteral">&quot;Universal&quot;</span>) }
<a name="l00164"></a>00164 };
<a name="l00165"></a>00165 
<a name="l00166"></a><a class="code" href="ui__preferences_8c.html#aad0d14f2924a50e081f278b1f660b6bb">00166</a> <span class="keyword">static</span> <a class="code" href="structComboBoxElements.html">ComboBoxElements</a> <a class="code" href="ui__preferences_8c.html#aad0d14f2924a50e081f278b1f660b6bb">bitdepth_elements</a>[] = {
<a name="l00167"></a>00167     { GINT_TO_POINTER(16), <span class="stringliteral">&quot;16&quot;</span> },
<a name="l00168"></a>00168     { GINT_TO_POINTER(24), <span class="stringliteral">&quot;24&quot;</span> },
<a name="l00169"></a>00169     { GINT_TO_POINTER(32), <span class="stringliteral">&quot;32&quot;</span> },
<a name="l00170"></a>00170     {GINT_TO_POINTER (0), <span class="stringliteral">&quot;Floating point&quot;</span>},
<a name="l00171"></a>00171 };
<a name="l00172"></a>00172 
<a name="l00173"></a><a class="code" href="structCategoryQueueEntry.html">00173</a> <span class="keyword">typedef</span> <span class="keyword">struct </span>{
<a name="l00174"></a><a class="code" href="structCategoryQueueEntry.html#ab0ee73d4643c3aedb3ba15b8e680d4e8">00174</a>     <span class="keywordtype">void</span> *<a class="code" href="structCategoryQueueEntry.html#ab0ee73d4643c3aedb3ba15b8e680d4e8">next</a>;
<a name="l00175"></a><a class="code" href="structCategoryQueueEntry.html#a921bd11623d976bdc29eda94ecc3090f">00175</a>     GtkWidget *<a class="code" href="structCategoryQueueEntry.html#a921bd11623d976bdc29eda94ecc3090f">container</a>;
<a name="l00176"></a><a class="code" href="structCategoryQueueEntry.html#a88dc3ce0f0e92236d14c64fc4d6577e0">00176</a>     <span class="keyword">const</span> gchar * <a class="code" href="structCategoryQueueEntry.html#a88dc3ce0f0e92236d14c64fc4d6577e0">pg_name</a>;
<a name="l00177"></a><a class="code" href="structCategoryQueueEntry.html#a4989ec930e5f97de96277f718de0fb15">00177</a>     <span class="keyword">const</span> gchar * <a class="code" href="structCategoryQueueEntry.html#a4989ec930e5f97de96277f718de0fb15">img_url</a>;
<a name="l00178"></a>00178 } <a class="code" href="structCategoryQueueEntry.html">CategoryQueueEntry</a>;
<a name="l00179"></a>00179 
<a name="l00180"></a><a class="code" href="ui__preferences_8c.html#a4ec3c92c0498e384e9b4986b093f2cec">00180</a> <a class="code" href="structCategoryQueueEntry.html">CategoryQueueEntry</a> *<a class="code" href="ui__preferences_8c.html#a4ec3c92c0498e384e9b4986b093f2cec">category_queue</a> = NULL;
<a name="l00181"></a>00181 
<a name="l00182"></a><a class="code" href="ui__preferences_8c.html#a96e8471242cd6bc75fff174d77d6e262">00182</a> <span class="keyword">static</span> PreferencesWidget <a class="code" href="ui__preferences_8c.html#a96e8471242cd6bc75fff174d77d6e262">audio_page_widgets</a>[] = {
<a name="l00183"></a>00183     {<a class="code" href="preferences_8h.html#a7b98518122eb2e94554d2b99d29d1452a546d7ca530397014266faf6f554e3061">WIDGET_LABEL</a>, <a class="code" href="i18n_8h.html#a75278405e7f034d2b1af80bfd94675fe">N_</a>(<span class="stringliteral">&quot;&lt;b&gt;Bit Depth&lt;/b&gt;&quot;</span>), NULL, NULL, NULL, FALSE},
<a name="l00184"></a>00184     {<a class="code" href="preferences_8h.html#a7b98518122eb2e94554d2b99d29d1452af92f2abad2182229bda2ad5ed80ec9c4">WIDGET_COMBO_BOX</a>, <a class="code" href="i18n_8h.html#a75278405e7f034d2b1af80bfd94675fe">N_</a>(<span class="stringliteral">&quot;Output bit depth:&quot;</span>), &amp;<a class="code" href="audconfig_8c.html#a98bd56a064259046a6cc6b1a620badf8">cfg</a>.output_bit_depth, NULL,
<a name="l00185"></a>00185                        <a class="code" href="i18n_8h.html#a75278405e7f034d2b1af80bfd94675fe">N_</a>(<span class="stringliteral">&quot;All streams will be converted to this bit depth.\n&quot;</span>
<a name="l00186"></a>00186                           <span class="stringliteral">&quot;This should be the max supported bit depth of\nthe sound card or output plugin.&quot;</span>), FALSE,
<a name="l00187"></a>00187                        {.combo = {<a class="code" href="ui__preferences_8c.html#aad0d14f2924a50e081f278b1f660b6bb">bitdepth_elements</a>, G_N_ELEMENTS(bitdepth_elements), TRUE}}, <a class="code" href="preferences_8h.html#ad9971b6ef33e02ba2c75d19c1d2518a1aba052e3feaa532e0d8beeb68a3aa6c83">VALUE_INT</a>},
<a name="l00188"></a>00188     {<a class="code" href="preferences_8h.html#a7b98518122eb2e94554d2b99d29d1452a546d7ca530397014266faf6f554e3061">WIDGET_LABEL</a>, <a class="code" href="i18n_8h.html#a75278405e7f034d2b1af80bfd94675fe">N_</a>(<span class="stringliteral">&quot;&lt;b&gt;Volume Control&lt;/b&gt;&quot;</span>), NULL, NULL, NULL, FALSE},
<a name="l00189"></a>00189     {<a class="code" href="preferences_8h.html#a7b98518122eb2e94554d2b99d29d1452a1500c50c7cba34aac0d3e542f716d658">WIDGET_CHK_BTN</a>, <a class="code" href="i18n_8h.html#a75278405e7f034d2b1af80bfd94675fe">N_</a>(<span class="stringliteral">&quot;Use software volume control&quot;</span>),
<a name="l00190"></a>00190      &amp; <a class="code" href="audconfig_8c.html#a98bd56a064259046a6cc6b1a620badf8">cfg</a>.software_volume_control, <a class="code" href="ui__preferences_8c.html#a162e0c2f851d5a3f8b1b0d9fd68b679f">sw_volume_toggled</a>,
<a name="l00191"></a>00191                      <a class="code" href="i18n_8h.html#a75278405e7f034d2b1af80bfd94675fe">N_</a>(<span class="stringliteral">&quot;Use software volume control. This may be useful for situations where your audio system does not support controlling the playback volume.&quot;</span>), FALSE},
<a name="l00192"></a>00192 };
<a name="l00193"></a>00193 
<a name="l00194"></a><a class="code" href="ui__preferences_8c.html#a668fa51313bf026938f653846a837fc6">00194</a> <span class="keyword">static</span> PreferencesWidget <a class="code" href="ui__preferences_8c.html#a668fa51313bf026938f653846a837fc6">rg_params_elements</a>[] = {
<a name="l00195"></a>00195     {<a class="code" href="preferences_8h.html#a7b98518122eb2e94554d2b99d29d1452a507a22559fb8f5293dbe10051781e64f">WIDGET_SPIN_BTN</a>, <a class="code" href="i18n_8h.html#a75278405e7f034d2b1af80bfd94675fe">N_</a>(<span class="stringliteral">&quot;Preamp:&quot;</span>), &amp;<a class="code" href="audconfig_8c.html#a98bd56a064259046a6cc6b1a620badf8">cfg</a>.replay_gain_preamp, NULL, NULL, FALSE, {.spin_btn = {-15, 15, 0.01, <a class="code" href="i18n_8h.html#a75278405e7f034d2b1af80bfd94675fe">N_</a>(<span class="stringliteral">&quot;dB&quot;</span>)}}, <a class="code" href="preferences_8h.html#ad9971b6ef33e02ba2c75d19c1d2518a1a636cea292b122aac7b4c4e193c4cb92f">VALUE_FLOAT</a>},
<a name="l00196"></a>00196     {<a class="code" href="preferences_8h.html#a7b98518122eb2e94554d2b99d29d1452a507a22559fb8f5293dbe10051781e64f">WIDGET_SPIN_BTN</a>, <a class="code" href="i18n_8h.html#a75278405e7f034d2b1af80bfd94675fe">N_</a>(<span class="stringliteral">&quot;Default gain:&quot;</span>), &amp;<a class="code" href="audconfig_8c.html#a98bd56a064259046a6cc6b1a620badf8">cfg</a>.default_gain, NULL, <a class="code" href="i18n_8h.html#a75278405e7f034d2b1af80bfd94675fe">N_</a>(<span class="stringliteral">&quot;This gain will be used if file doesn&#39;t contain Replay Gain metadata.&quot;</span>), FALSE, {.spin_btn = {-15, 15, 0.01, <a class="code" href="i18n_8h.html#a75278405e7f034d2b1af80bfd94675fe">N_</a>(<span class="stringliteral">&quot;dB&quot;</span>)}}, <a class="code" href="preferences_8h.html#ad9971b6ef33e02ba2c75d19c1d2518a1a636cea292b122aac7b4c4e193c4cb92f">VALUE_FLOAT</a>},
<a name="l00197"></a>00197     {<a class="code" href="preferences_8h.html#a7b98518122eb2e94554d2b99d29d1452a546d7ca530397014266faf6f554e3061">WIDGET_LABEL</a>, <a class="code" href="i18n_8h.html#a75278405e7f034d2b1af80bfd94675fe">N_</a>(<span class="stringliteral">&quot;&lt;span size=\&quot;small\&quot;&gt;Please remember that the most efficient way to prevent signal clipping is not to use positive values above.&lt;/span&gt;&quot;</span>), NULL, NULL, NULL, FALSE, {.label = {<span class="stringliteral">&quot;gtk-info&quot;</span>}}},
<a name="l00198"></a>00198 };
<a name="l00199"></a>00199 
<a name="l00200"></a><a class="code" href="ui__preferences_8c.html#aee27d4fb743ba829f98fa99911391dba">00200</a> <span class="keyword">static</span> PreferencesWidget <a class="code" href="ui__preferences_8c.html#aee27d4fb743ba829f98fa99911391dba">replay_gain_page_widgets</a>[] = {
<a name="l00201"></a>00201     {<a class="code" href="preferences_8h.html#a7b98518122eb2e94554d2b99d29d1452a546d7ca530397014266faf6f554e3061">WIDGET_LABEL</a>, <a class="code" href="i18n_8h.html#a75278405e7f034d2b1af80bfd94675fe">N_</a>(<span class="stringliteral">&quot;&lt;b&gt;Replay Gain configuration&lt;/b&gt;&quot;</span>), NULL, NULL, NULL, FALSE},
<a name="l00202"></a>00202     {<a class="code" href="preferences_8h.html#a7b98518122eb2e94554d2b99d29d1452a1500c50c7cba34aac0d3e542f716d658">WIDGET_CHK_BTN</a>, <a class="code" href="i18n_8h.html#a75278405e7f034d2b1af80bfd94675fe">N_</a>(<span class="stringliteral">&quot;Enable Replay Gain&quot;</span>), &amp;<a class="code" href="audconfig_8c.html#a98bd56a064259046a6cc6b1a620badf8">cfg</a>.enable_replay_gain, NULL, NULL, FALSE},
<a name="l00203"></a>00203     {<a class="code" href="preferences_8h.html#a7b98518122eb2e94554d2b99d29d1452a546d7ca530397014266faf6f554e3061">WIDGET_LABEL</a>, <a class="code" href="i18n_8h.html#a75278405e7f034d2b1af80bfd94675fe">N_</a>(<span class="stringliteral">&quot;&lt;b&gt;Replay Gain mode&lt;/b&gt;&quot;</span>), NULL, NULL, NULL, TRUE},
<a name="l00204"></a>00204     {<a class="code" href="preferences_8h.html#a7b98518122eb2e94554d2b99d29d1452ab9de9db8d433704ff7b8babe9b892352">WIDGET_RADIO_BTN</a>, <a class="code" href="i18n_8h.html#a75278405e7f034d2b1af80bfd94675fe">N_</a>(<span class="stringliteral">&quot;Track gain/peak&quot;</span>), &amp;<a class="code" href="audconfig_8c.html#a98bd56a064259046a6cc6b1a620badf8">cfg</a>.replay_gain_track, NULL, NULL, TRUE},
<a name="l00205"></a>00205     {<a class="code" href="preferences_8h.html#a7b98518122eb2e94554d2b99d29d1452ab9de9db8d433704ff7b8babe9b892352">WIDGET_RADIO_BTN</a>, <a class="code" href="i18n_8h.html#a75278405e7f034d2b1af80bfd94675fe">N_</a>(<span class="stringliteral">&quot;Album gain/peak&quot;</span>), &amp;<a class="code" href="audconfig_8c.html#a98bd56a064259046a6cc6b1a620badf8">cfg</a>.replay_gain_album, NULL, NULL, TRUE},
<a name="l00206"></a>00206     {<a class="code" href="preferences_8h.html#a7b98518122eb2e94554d2b99d29d1452a546d7ca530397014266faf6f554e3061">WIDGET_LABEL</a>, <a class="code" href="i18n_8h.html#a75278405e7f034d2b1af80bfd94675fe">N_</a>(<span class="stringliteral">&quot;&lt;b&gt;Miscellaneous&lt;/b&gt;&quot;</span>), NULL, NULL, NULL, TRUE},
<a name="l00207"></a>00207     {<a class="code" href="preferences_8h.html#a7b98518122eb2e94554d2b99d29d1452a1500c50c7cba34aac0d3e542f716d658">WIDGET_CHK_BTN</a>, <a class="code" href="i18n_8h.html#a75278405e7f034d2b1af80bfd94675fe">N_</a>(<span class="stringliteral">&quot;Enable peak info clipping prevention&quot;</span>), &amp;<a class="code" href="audconfig_8c.html#a98bd56a064259046a6cc6b1a620badf8">cfg</a>.enable_clipping_prevention, NULL,
<a name="l00208"></a>00208                      <a class="code" href="i18n_8h.html#a75278405e7f034d2b1af80bfd94675fe">N_</a>(<span class="stringliteral">&quot;Use peak value from Replay Gain info for clipping prevention&quot;</span>), TRUE},
<a name="l00209"></a>00209     {<a class="code" href="preferences_8h.html#a7b98518122eb2e94554d2b99d29d1452ac9de46f3888daabbe74a9dbd477861ab">WIDGET_TABLE</a>, NULL, NULL, NULL, NULL, TRUE, {.table = {<a class="code" href="ui__preferences_8c.html#a668fa51313bf026938f653846a837fc6">rg_params_elements</a>, G_N_ELEMENTS(<a class="code" href="ui__preferences_8c.html#a668fa51313bf026938f653846a837fc6">rg_params_elements</a>)}}},
<a name="l00210"></a>00210 };
<a name="l00211"></a>00211 
<a name="l00212"></a><a class="code" href="ui__preferences_8c.html#afe988db4bdd96dcbbfe694b6434ec8d5">00212</a> <span class="keyword">static</span> PreferencesWidget <a class="code" href="ui__preferences_8c.html#afe988db4bdd96dcbbfe694b6434ec8d5">proxy_host_port_elements</a>[] = {
<a name="l00213"></a>00213     {<a class="code" href="preferences_8h.html#a7b98518122eb2e94554d2b99d29d1452a494c57d571e067e24c2db77b86ff7e48">WIDGET_ENTRY</a>, <a class="code" href="i18n_8h.html#a75278405e7f034d2b1af80bfd94675fe">N_</a>(<span class="stringliteral">&quot;Proxy hostname:&quot;</span>), <span class="stringliteral">&quot;proxy_host&quot;</span>, NULL, NULL, FALSE, {.entry = {FALSE}}, <a class="code" href="preferences_8h.html#ad9971b6ef33e02ba2c75d19c1d2518a1aa2654bf717a1ea21127a2fd0d5c68f93">VALUE_CFG_STRING</a>},
<a name="l00214"></a>00214     {<a class="code" href="preferences_8h.html#a7b98518122eb2e94554d2b99d29d1452a494c57d571e067e24c2db77b86ff7e48">WIDGET_ENTRY</a>, <a class="code" href="i18n_8h.html#a75278405e7f034d2b1af80bfd94675fe">N_</a>(<span class="stringliteral">&quot;Proxy port:&quot;</span>), <span class="stringliteral">&quot;proxy_port&quot;</span>, NULL, NULL, FALSE, {.entry = {FALSE}}, <a class="code" href="preferences_8h.html#ad9971b6ef33e02ba2c75d19c1d2518a1aa2654bf717a1ea21127a2fd0d5c68f93">VALUE_CFG_STRING</a>},
<a name="l00215"></a>00215 };
<a name="l00216"></a>00216 
<a name="l00217"></a><a class="code" href="ui__preferences_8c.html#a232974d897d8a83c05e5a45b94d17975">00217</a> <span class="keyword">static</span> PreferencesWidget <a class="code" href="ui__preferences_8c.html#a232974d897d8a83c05e5a45b94d17975">proxy_auth_elements</a>[] = {
<a name="l00218"></a>00218     {<a class="code" href="preferences_8h.html#a7b98518122eb2e94554d2b99d29d1452a494c57d571e067e24c2db77b86ff7e48">WIDGET_ENTRY</a>, <a class="code" href="i18n_8h.html#a75278405e7f034d2b1af80bfd94675fe">N_</a>(<span class="stringliteral">&quot;Proxy username:&quot;</span>), <span class="stringliteral">&quot;proxy_user&quot;</span>, NULL, NULL, FALSE, {.entry = {FALSE}}, <a class="code" href="preferences_8h.html#ad9971b6ef33e02ba2c75d19c1d2518a1aa2654bf717a1ea21127a2fd0d5c68f93">VALUE_CFG_STRING</a>},
<a name="l00219"></a>00219     {<a class="code" href="preferences_8h.html#a7b98518122eb2e94554d2b99d29d1452a494c57d571e067e24c2db77b86ff7e48">WIDGET_ENTRY</a>, <a class="code" href="i18n_8h.html#a75278405e7f034d2b1af80bfd94675fe">N_</a>(<span class="stringliteral">&quot;Proxy password:&quot;</span>), <span class="stringliteral">&quot;proxy_pass&quot;</span>, NULL, NULL, FALSE, {.entry = {TRUE}}, <a class="code" href="preferences_8h.html#ad9971b6ef33e02ba2c75d19c1d2518a1aa2654bf717a1ea21127a2fd0d5c68f93">VALUE_CFG_STRING</a>},
<a name="l00220"></a>00220 };
<a name="l00221"></a>00221 
<a name="l00222"></a><a class="code" href="ui__preferences_8c.html#a41d34000229bbb38c16ada9e5e79f97d">00222</a> <span class="keyword">static</span> PreferencesWidget <a class="code" href="ui__preferences_8c.html#a41d34000229bbb38c16ada9e5e79f97d">connectivity_page_widgets</a>[] = {
<a name="l00223"></a>00223     {<a class="code" href="preferences_8h.html#a7b98518122eb2e94554d2b99d29d1452a546d7ca530397014266faf6f554e3061">WIDGET_LABEL</a>, <a class="code" href="i18n_8h.html#a75278405e7f034d2b1af80bfd94675fe">N_</a>(<span class="stringliteral">&quot;&lt;b&gt;Proxy Configuration&lt;/b&gt;&quot;</span>), NULL, NULL, NULL, FALSE},
<a name="l00224"></a>00224     {<a class="code" href="preferences_8h.html#a7b98518122eb2e94554d2b99d29d1452a1500c50c7cba34aac0d3e542f716d658">WIDGET_CHK_BTN</a>, <a class="code" href="i18n_8h.html#a75278405e7f034d2b1af80bfd94675fe">N_</a>(<span class="stringliteral">&quot;Enable proxy usage&quot;</span>), <span class="stringliteral">&quot;use_proxy&quot;</span>, NULL, NULL, FALSE,
<a name="l00225"></a>00225      .cfg_type = <a class="code" href="preferences_8h.html#ad9971b6ef33e02ba2c75d19c1d2518a1af66df06f8eda912b1e7f44a27ac33f19">VALUE_CFG_BOOLEAN</a>},
<a name="l00226"></a>00226     {<a class="code" href="preferences_8h.html#a7b98518122eb2e94554d2b99d29d1452ac9de46f3888daabbe74a9dbd477861ab">WIDGET_TABLE</a>, NULL, NULL, NULL, NULL, TRUE, {.table = {<a class="code" href="ui__preferences_8c.html#afe988db4bdd96dcbbfe694b6434ec8d5">proxy_host_port_elements</a>, G_N_ELEMENTS(<a class="code" href="ui__preferences_8c.html#afe988db4bdd96dcbbfe694b6434ec8d5">proxy_host_port_elements</a>)}}},
<a name="l00227"></a>00227     {<a class="code" href="preferences_8h.html#a7b98518122eb2e94554d2b99d29d1452a1500c50c7cba34aac0d3e542f716d658">WIDGET_CHK_BTN</a>, <a class="code" href="i18n_8h.html#a75278405e7f034d2b1af80bfd94675fe">N_</a>(<span class="stringliteral">&quot;Use authentication with proxy&quot;</span>), <span class="stringliteral">&quot;proxy_use_auth&quot;</span>,
<a name="l00228"></a>00228      NULL, NULL, FALSE, .cfg_type = <a class="code" href="preferences_8h.html#ad9971b6ef33e02ba2c75d19c1d2518a1af66df06f8eda912b1e7f44a27ac33f19">VALUE_CFG_BOOLEAN</a>},
<a name="l00229"></a>00229     {<a class="code" href="preferences_8h.html#a7b98518122eb2e94554d2b99d29d1452ac9de46f3888daabbe74a9dbd477861ab">WIDGET_TABLE</a>, NULL, NULL, NULL, NULL, TRUE, {.table = {<a class="code" href="ui__preferences_8c.html#a232974d897d8a83c05e5a45b94d17975">proxy_auth_elements</a>, G_N_ELEMENTS(<a class="code" href="ui__preferences_8c.html#a232974d897d8a83c05e5a45b94d17975">proxy_auth_elements</a>)}}},
<a name="l00230"></a>00230     {<a class="code" href="preferences_8h.html#a7b98518122eb2e94554d2b99d29d1452a546d7ca530397014266faf6f554e3061">WIDGET_LABEL</a>, <a class="code" href="i18n_8h.html#a75278405e7f034d2b1af80bfd94675fe">N_</a>(<span class="stringliteral">&quot;&lt;span size=\&quot;small\&quot;&gt;Changing these settings will require a restart of Audacious.&lt;/span&gt;&quot;</span>), NULL, NULL, NULL, FALSE, {.label = {<span class="stringliteral">&quot;gtk-dialog-warning&quot;</span>}}},
<a name="l00231"></a>00231 };
<a name="l00232"></a>00232 
<a name="l00233"></a><a class="code" href="ui__preferences_8c.html#a3aec073b5ab620c9688852feb5069538">00233</a> <span class="keyword">static</span> PreferencesWidget <a class="code" href="ui__preferences_8c.html#a3aec073b5ab620c9688852feb5069538">playback_page_widgets</a>[] = {
<a name="l00234"></a>00234     {<a class="code" href="preferences_8h.html#a7b98518122eb2e94554d2b99d29d1452a546d7ca530397014266faf6f554e3061">WIDGET_LABEL</a>, <a class="code" href="i18n_8h.html#a75278405e7f034d2b1af80bfd94675fe">N_</a>(<span class="stringliteral">&quot;&lt;b&gt;Playback&lt;/b&gt;&quot;</span>), NULL, NULL, NULL, FALSE},
<a name="l00235"></a>00235     {<a class="code" href="preferences_8h.html#a7b98518122eb2e94554d2b99d29d1452a1500c50c7cba34aac0d3e542f716d658">WIDGET_CHK_BTN</a>, <a class="code" href="i18n_8h.html#a75278405e7f034d2b1af80bfd94675fe">N_</a>(<span class="stringliteral">&quot;Continue playback on startup&quot;</span>), &amp;<a class="code" href="audconfig_8c.html#a98bd56a064259046a6cc6b1a620badf8">cfg</a>.resume_playback_on_startup, NULL,
<a name="l00236"></a>00236         <a class="code" href="i18n_8h.html#a75278405e7f034d2b1af80bfd94675fe">N_</a>(<span class="stringliteral">&quot;When Audacious starts, automatically begin playing from the point where we stopped before.&quot;</span>), FALSE},
<a name="l00237"></a>00237     {<a class="code" href="preferences_8h.html#a7b98518122eb2e94554d2b99d29d1452a1500c50c7cba34aac0d3e542f716d658">WIDGET_CHK_BTN</a>, <a class="code" href="i18n_8h.html#a75278405e7f034d2b1af80bfd94675fe">N_</a>(<span class="stringliteral">&quot;Don&#39;t advance in the playlist&quot;</span>), &amp;<a class="code" href="audconfig_8c.html#a98bd56a064259046a6cc6b1a620badf8">cfg</a>.no_playlist_advance, NULL,
<a name="l00238"></a>00238         <a class="code" href="i18n_8h.html#a75278405e7f034d2b1af80bfd94675fe">N_</a>(<span class="stringliteral">&quot;When finished playing a song, don&#39;t automatically advance to the next.&quot;</span>), FALSE},
<a name="l00239"></a>00239     {<a class="code" href="preferences_8h.html#a7b98518122eb2e94554d2b99d29d1452a1500c50c7cba34aac0d3e542f716d658">WIDGET_CHK_BTN</a>, <a class="code" href="i18n_8h.html#a75278405e7f034d2b1af80bfd94675fe">N_</a>(<span class="stringliteral">&quot;Clear current playlist when opening new files&quot;</span>),
<a name="l00240"></a>00240      &amp; <a class="code" href="audconfig_8c.html#a98bd56a064259046a6cc6b1a620badf8">cfg</a>.clear_playlist, NULL, NULL, FALSE},
<a name="l00241"></a>00241 };
<a name="l00242"></a>00242 
<a name="l00243"></a><a class="code" href="ui__preferences_8c.html#a7d14ae6c999a530a0abed4563fea45a9">00243</a> <span class="keyword">static</span> PreferencesWidget <a class="code" href="ui__preferences_8c.html#a7d14ae6c999a530a0abed4563fea45a9">chardet_elements</a>[] = {
<a name="l00244"></a>00244     {<a class="code" href="preferences_8h.html#a7b98518122eb2e94554d2b99d29d1452af92f2abad2182229bda2ad5ed80ec9c4">WIDGET_COMBO_BOX</a>, <a class="code" href="i18n_8h.html#a75278405e7f034d2b1af80bfd94675fe">N_</a>(<span class="stringliteral">&quot;Auto character encoding detector for:&quot;</span>), &amp;<a class="code" href="audconfig_8c.html#a98bd56a064259046a6cc6b1a620badf8">cfg</a>.chardet_detector, NULL, NULL, TRUE,
<a name="l00245"></a>00245         {.combo = {<a class="code" href="ui__preferences_8c.html#a35f349d7e674dc2f2e859d0e57ff4283">chardet_detector_presets</a>, G_N_ELEMENTS(chardet_detector_presets),
<a name="l00246"></a>00246 <span class="preprocessor">                   #ifdef USE_CHARDET</span>
<a name="l00247"></a>00247 <span class="preprocessor"></span>                   TRUE
<a name="l00248"></a>00248 <span class="preprocessor">                   #else</span>
<a name="l00249"></a>00249 <span class="preprocessor"></span>                   FALSE
<a name="l00250"></a>00250 <span class="preprocessor">                   #endif</span>
<a name="l00251"></a>00251 <span class="preprocessor"></span>                   }}, <a class="code" href="preferences_8h.html#ad9971b6ef33e02ba2c75d19c1d2518a1a35da8b8ef95fd9827e1294f400d01c65">VALUE_STRING</a>},
<a name="l00252"></a>00252     {<a class="code" href="preferences_8h.html#a7b98518122eb2e94554d2b99d29d1452a494c57d571e067e24c2db77b86ff7e48">WIDGET_ENTRY</a>, <a class="code" href="i18n_8h.html#a75278405e7f034d2b1af80bfd94675fe">N_</a>(<span class="stringliteral">&quot;Fallback character encodings:&quot;</span>), &amp;<a class="code" href="audconfig_8c.html#a98bd56a064259046a6cc6b1a620badf8">cfg</a>.chardet_fallback, <a class="code" href="audconfig_8c.html#a7511fdd448f1527e86b59dbbcc25f58c">aud_config_chardet_update</a>, <a class="code" href="i18n_8h.html#a75278405e7f034d2b1af80bfd94675fe">N_</a>(<span class="stringliteral">&quot;List of character encodings used for fall back conversion of metadata. If automatic character encoding detector failed or has been disabled, encodings in this list would be treated as candidates of the encoding of metadata, and fall back conversion from these encodings to UTF-8 would be attempted.&quot;</span>), TRUE, {.entry = {FALSE}}, <a class="code" href="preferences_8h.html#ad9971b6ef33e02ba2c75d19c1d2518a1a35da8b8ef95fd9827e1294f400d01c65">VALUE_STRING</a>},
<a name="l00253"></a>00253 };
<a name="l00254"></a>00254 
<a name="l00255"></a><a class="code" href="ui__preferences_8c.html#a79cfe8200657a5a8dee1014f3d033aed">00255</a> <span class="keyword">static</span> PreferencesWidget <a class="code" href="ui__preferences_8c.html#a79cfe8200657a5a8dee1014f3d033aed">playlist_page_widgets</a>[] = {
<a name="l00256"></a>00256     {<a class="code" href="preferences_8h.html#a7b98518122eb2e94554d2b99d29d1452a546d7ca530397014266faf6f554e3061">WIDGET_LABEL</a>, <a class="code" href="i18n_8h.html#a75278405e7f034d2b1af80bfd94675fe">N_</a>(<span class="stringliteral">&quot;&lt;b&gt;Metadata&lt;/b&gt;&quot;</span>), NULL, NULL, NULL, FALSE},
<a name="l00257"></a>00257     {<a class="code" href="preferences_8h.html#a7b98518122eb2e94554d2b99d29d1452ac9de46f3888daabbe74a9dbd477861ab">WIDGET_TABLE</a>, NULL, NULL, NULL, NULL, TRUE, {.table = {<a class="code" href="ui__preferences_8c.html#a7d14ae6c999a530a0abed4563fea45a9">chardet_elements</a>, G_N_ELEMENTS(<a class="code" href="ui__preferences_8c.html#a7d14ae6c999a530a0abed4563fea45a9">chardet_elements</a>)}}},
<a name="l00258"></a>00258 };
<a name="l00259"></a>00259 
<a name="l00260"></a>00260 <span class="keyword">static</span> <span class="keywordtype">void</span> <a class="code" href="ui__preferences_8c.html#a19b121ea803d703ab99cab744e801889">prefswin_page_queue_destroy</a>(<a class="code" href="structCategoryQueueEntry.html">CategoryQueueEntry</a> *ent);
<a name="l00261"></a>00261 <span class="keywordtype">void</span> <a class="code" href="ui__preferences_8c.html#a37055262a6741b11aff36a1c01a5e9a9">create_plugin_preferences_page</a>(PluginPreferences *settings);
<a name="l00262"></a>00262 <span class="keywordtype">void</span> <a class="code" href="ui__preferences_8c.html#a8b479180c3fbf93e7d1477b2bc5059ce">destroy_plugin_preferences_page</a>(PluginPreferences *settings);
<a name="l00263"></a>00263 
<a name="l00264"></a><a class="code" href="ui__preferences_8c.html#a46e3cec7b5fbeafd83618dbe8a5a26e9">00264</a> <span class="keyword">static</span> <span class="keywordtype">void</span> <a class="code" href="ui__preferences_8c.html#a46e3cec7b5fbeafd83618dbe8a5a26e9">output_about</a> (OutputPlugin * plugin)
<a name="l00265"></a>00265 {
<a name="l00266"></a>00266     <span class="keywordflow">if</span> (plugin-&gt;about != NULL)
<a name="l00267"></a>00267         plugin-&gt;about ();
<a name="l00268"></a>00268 }
<a name="l00269"></a>00269 
<a name="l00270"></a><a class="code" href="ui__preferences_8c.html#a65deb7ac6816d7cda0845122f2b96569">00270</a> <span class="keyword">static</span> <span class="keywordtype">void</span> <a class="code" href="ui__preferences_8c.html#a65deb7ac6816d7cda0845122f2b96569">output_configure</a> (OutputPlugin * plugin)
<a name="l00271"></a>00271 {
<a name="l00272"></a>00272     <span class="keywordflow">if</span> (plugin-&gt;configure != NULL)
<a name="l00273"></a>00273         plugin-&gt;configure ();
<a name="l00274"></a>00274 }
<a name="l00275"></a>00275 
<a name="l00276"></a>00276 <span class="keyword">static</span> <span class="keywordtype">void</span>
<a name="l00277"></a><a class="code" href="ui__preferences_8c.html#a7917d20a6e80d0bf1e5715c2b78b17e7">00277</a> <a class="code" href="ui__preferences_8c.html#a7917d20a6e80d0bf1e5715c2b78b17e7">change_category</a>(GtkNotebook * notebook,
<a name="l00278"></a>00278                 GtkTreeSelection * selection)
<a name="l00279"></a>00279 {
<a name="l00280"></a>00280     GtkTreeModel *model;
<a name="l00281"></a>00281     GtkTreeIter iter;
<a name="l00282"></a>00282     <a class="code" href="misc-api_8h.html#acf599c059f43e0cca83145eb6b0c93cd">gint</a> <a class="code" href="structindex.html">index</a>;
<a name="l00283"></a>00283 
<a name="l00284"></a>00284     <span class="keywordflow">if</span> (!gtk_tree_selection_get_selected(selection, &amp;model, &amp;iter))
<a name="l00285"></a>00285         <span class="keywordflow">return</span>;
<a name="l00286"></a>00286 
<a name="l00287"></a>00287     gtk_tree_model_get(model, &amp;iter, <a class="code" href="ui__preferences_8c.html#ab327bcf652522bc3ff67a66149322ecaa807e88ae3818317d7cb3025cac995a52">CATEGORY_VIEW_COL_ID</a>, &amp;index, -1);
<a name="l00288"></a>00288     gtk_notebook_set_current_page(notebook, index);
<a name="l00289"></a>00289 }
<a name="l00290"></a>00290 
<a name="l00291"></a><a class="code" href="ui__preferences_8c.html#a1b84f014b29b9ea443ae51712d0fc0c7">00291</a> <span class="keyword">static</span> <span class="keywordtype">void</span> <a class="code" href="ui__preferences_8c.html#a1b84f014b29b9ea443ae51712d0fc0c7">output_plugin_open_prefs</a> (GtkComboBox * combo, <span class="keywordtype">void</span> * unused)
<a name="l00292"></a>00292 {
<a name="l00293"></a>00293     <a class="code" href="ui__preferences_8c.html#a65deb7ac6816d7cda0845122f2b96569">output_configure</a> (g_list_nth_data (<a class="code" href="output_8c.html#a9c0b095a41c60449bc217651abd25e0c">get_output_list</a> (),
<a name="l00294"></a>00294      gtk_combo_box_get_active (combo)));
<a name="l00295"></a>00295 }
<a name="l00296"></a>00296 
<a name="l00297"></a><a class="code" href="ui__preferences_8c.html#aedebd68ac518ba0633b162bf83f2093a">00297</a> <span class="keyword">static</span> <span class="keywordtype">void</span> <a class="code" href="ui__preferences_8c.html#aedebd68ac518ba0633b162bf83f2093a">output_plugin_open_info</a> (GtkComboBox * combo, <span class="keywordtype">void</span> * unused)
<a name="l00298"></a>00298 {
<a name="l00299"></a>00299     <a class="code" href="ui__preferences_8c.html#a46e3cec7b5fbeafd83618dbe8a5a26e9">output_about</a> (g_list_nth_data (<a class="code" href="output_8c.html#a9c0b095a41c60449bc217651abd25e0c">get_output_list</a> (), gtk_combo_box_get_active
<a name="l00300"></a>00300      (combo)));
<a name="l00301"></a>00301 }
<a name="l00302"></a>00302 
<a name="l00303"></a>00303 <span class="keyword">static</span> <span class="keywordtype">void</span>
<a name="l00304"></a><a class="code" href="ui__preferences_8c.html#a1100328568c2bfe74262b4b2fbfd7a28">00304</a> <a class="code" href="ui__preferences_8c.html#a1100328568c2bfe74262b4b2fbfd7a28">plugin_toggle</a>(GtkCellRendererToggle * cell,
<a name="l00305"></a>00305               <span class="keyword">const</span> gchar * path_str,
<a name="l00306"></a>00306               gpointer <a class="code" href="misc-api_8h.html#a2a40119722f785a93d720b769541a543">data</a>)
<a name="l00307"></a>00307 {
<a name="l00308"></a>00308     GtkTreeModel *model = GTK_TREE_MODEL(data);
<a name="l00309"></a>00309     GtkTreeIter iter;
<a name="l00310"></a>00310     GtkTreePath *<a class="code" href="plugins-api_8h.html#aed23534511ec9dec0630ca4854c4552b">path</a> = gtk_tree_path_new_from_string(path_str);
<a name="l00311"></a>00311     Plugin *plugin = NULL;
<a name="l00312"></a>00312     <a class="code" href="misc-api_8h.html#acf599c059f43e0cca83145eb6b0c93cd">gint</a> plugin_type = GPOINTER_TO_INT(g_object_get_data(G_OBJECT(data), <span class="stringliteral">&quot;plugin_type&quot;</span>));
<a name="l00313"></a>00313     <a class="code" href="configdb-api_8h.html#a3ac4dad7ee7fd2890139bff9a134ee9a">gboolean</a> enabled;
<a name="l00314"></a>00314 
<a name="l00315"></a>00315     <span class="comment">/* get toggled iter */</span>
<a name="l00316"></a>00316     gtk_tree_model_get_iter(model, &amp;iter, path);
<a name="l00317"></a>00317 
<a name="l00318"></a>00318     gtk_tree_model_get (model, &amp; iter, <a class="code" href="ui__preferences_8c.html#ace28870b3187dd2ac8e8f218e8c590d4a0c9c6f27b4307deed535637690600b72">PLUGIN_VIEW_COL_ACTIVE</a>, &amp; enabled,
<a name="l00319"></a>00319      <a class="code" href="ui__preferences_8c.html#ace28870b3187dd2ac8e8f218e8c590d4a5ed42aa040a6ec3d2ba084f3c72cd57e">PLUGIN_VIEW_COL_PLUGIN_PTR</a>, &amp; plugin, -1);
<a name="l00320"></a>00320     enabled = ! enabled;
<a name="l00321"></a>00321 
<a name="l00322"></a>00322     <span class="keywordflow">switch</span> (plugin_type)
<a name="l00323"></a>00323     {
<a name="l00324"></a>00324     <span class="keywordflow">case</span> <a class="code" href="ui__preferences_8c.html#a5644eb3f790d5e6ba29119a7d4e6e3d3ab5031417c44d1f05c26c8379ec6bbe3d">PLUGIN_VIEW_TYPE_INPUT</a>:
<a name="l00325"></a>00325         <a class="code" href="plugin-registry_8c.html#a6d136611a4b887c781d0e77574dc148c">plugin_set_enabled</a> (<a class="code" href="plugin-registry_8c.html#a0b26488a3994b15c19d353f59d51188b">plugin_by_header</a> (plugin), enabled);
<a name="l00326"></a>00326         <span class="keywordflow">break</span>;
<a name="l00327"></a>00327     <span class="keywordflow">case</span> <a class="code" href="ui__preferences_8c.html#a5644eb3f790d5e6ba29119a7d4e6e3d3a224907d964592908c703588c3bde1bcd">PLUGIN_VIEW_TYPE_GENERAL</a>:
<a name="l00328"></a>00328         <a class="code" href="general_8c.html#af67b753f7d59f97239ef93c380ed1f6f">general_plugin_enable</a> (<a class="code" href="plugin-registry_8c.html#a0b26488a3994b15c19d353f59d51188b">plugin_by_header</a> (plugin), enabled);
<a name="l00329"></a>00329         <span class="keywordflow">break</span>;
<a name="l00330"></a>00330     <span class="keywordflow">case</span> <a class="code" href="ui__preferences_8c.html#a5644eb3f790d5e6ba29119a7d4e6e3d3a0c16e7265127af9a2346972168951bad">PLUGIN_VIEW_TYPE_VIS</a>:
<a name="l00331"></a>00331         <a class="code" href="visualization_8c.html#ae07c8d89ee80a7c8c8c2758bbcc16453">vis_plugin_enable</a> (<a class="code" href="plugin-registry_8c.html#a0b26488a3994b15c19d353f59d51188b">plugin_by_header</a> (plugin), enabled);
<a name="l00332"></a>00332         <span class="keywordflow">break</span>;
<a name="l00333"></a>00333     <span class="keywordflow">case</span> <a class="code" href="ui__preferences_8c.html#a5644eb3f790d5e6ba29119a7d4e6e3d3afd0d22de728112565df5c88ed82f3c06">PLUGIN_VIEW_TYPE_EFFECT</a>:
<a name="l00334"></a>00334         <a class="code" href="effect_8c.html#aeddfdf7457fdc6a428d8cc7932b53920">effect_plugin_enable</a> (<a class="code" href="plugin-registry_8c.html#a0b26488a3994b15c19d353f59d51188b">plugin_by_header</a> (plugin), enabled);
<a name="l00335"></a>00335         <span class="keywordflow">break</span>;
<a name="l00336"></a>00336     }
<a name="l00337"></a>00337 
<a name="l00338"></a>00338     gtk_list_store_set ((GtkListStore *) model, &amp; iter, <a class="code" href="ui__preferences_8c.html#ace28870b3187dd2ac8e8f218e8c590d4a0c9c6f27b4307deed535637690600b72">PLUGIN_VIEW_COL_ACTIVE</a>,
<a name="l00339"></a>00339      enabled, -1);
<a name="l00340"></a>00340 
<a name="l00341"></a>00341     <span class="keywordflow">if</span> (plugin &amp;&amp; plugin-&gt;settings &amp;&amp; plugin-&gt;settings-&gt;type == <a class="code" href="preferences_8h.html#ad26b29cbcb76e2b44f77713fa0df0f2ea39d4f4d4b0191e8b49988444fc853ef0">PREFERENCES_PAGE</a>) {
<a name="l00342"></a>00342         <span class="keywordflow">if</span> (enabled)
<a name="l00343"></a>00343             <a class="code" href="ui__preferences_8c.html#a37055262a6741b11aff36a1c01a5e9a9">create_plugin_preferences_page</a>(plugin-&gt;settings);
<a name="l00344"></a>00344         <span class="keywordflow">else</span>
<a name="l00345"></a>00345             <a class="code" href="ui__preferences_8c.html#a8b479180c3fbf93e7d1477b2bc5059ce">destroy_plugin_preferences_page</a>(plugin-&gt;settings);
<a name="l00346"></a>00346     }
<a name="l00347"></a>00347     <span class="comment">/* clean up */</span>
<a name="l00348"></a>00348     gtk_tree_path_free(path);
<a name="l00349"></a>00349 }
<a name="l00350"></a>00350 
<a name="l00351"></a><a class="code" href="ui__preferences_8c.html#a738a604117425e97d80b2a686476a895">00351</a> <span class="keyword">static</span> <span class="keywordtype">void</span> <a class="code" href="ui__preferences_8c.html#a738a604117425e97d80b2a686476a895">on_output_plugin_cbox_changed</a> (GtkComboBox * combo, <span class="keywordtype">void</span> * unused)
<a name="l00352"></a>00352 {
<a name="l00353"></a>00353     <a class="code" href="output_8c.html#a1051896c3875aa6a7d35ba5946c52478">set_current_output_plugin</a> (g_list_nth_data (<a class="code" href="output_8c.html#a9c0b095a41c60449bc217651abd25e0c">get_output_list</a> (),
<a name="l00354"></a>00354      gtk_combo_box_get_active (combo)));
<a name="l00355"></a>00355 }
<a name="l00356"></a>00356 
<a name="l00357"></a>00357 <span class="keyword">static</span> <span class="keywordtype">void</span>
<a name="l00358"></a><a class="code" href="ui__preferences_8c.html#aba5a53bcd699730e12ae8a3c20eabde5">00358</a> <a class="code" href="ui__preferences_8c.html#aba5a53bcd699730e12ae8a3c20eabde5">on_output_plugin_cbox_realize</a>(GtkComboBox * cbox,
<a name="l00359"></a>00359                               gpointer <a class="code" href="misc-api_8h.html#a2a40119722f785a93d720b769541a543">data</a>)
<a name="l00360"></a>00360 {
<a name="l00361"></a>00361     GList *olist = <a class="code" href="output_8c.html#a9c0b095a41c60449bc217651abd25e0c">get_output_list</a>();
<a name="l00362"></a>00362     OutputPlugin * op;
<a name="l00363"></a>00363     <a class="code" href="misc-api_8h.html#acf599c059f43e0cca83145eb6b0c93cd">gint</a> i = 0, selected = 0;
<a name="l00364"></a>00364 
<a name="l00365"></a>00365     <span class="keywordflow">if</span> (olist == NULL) {
<a name="l00366"></a>00366         gtk_widget_set_sensitive(GTK_WIDGET(cbox), FALSE);
<a name="l00367"></a>00367         <span class="keywordflow">return</span>;
<a name="l00368"></a>00368     }
<a name="l00369"></a>00369 
<a name="l00370"></a>00370     <span class="keywordflow">for</span> (i = 0; olist != NULL; i++, olist = g_list_next(olist)) {
<a name="l00371"></a>00371         op = <a class="code" href="types_8h.html#a63f5244c033787d384e4c850b15ee7e5">OUTPUT_PLUGIN</a>(olist-&gt;data);
<a name="l00372"></a>00372 
<a name="l00373"></a>00373         <span class="keywordflow">if</span> (olist-&gt;data == <a class="code" href="output_8c.html#a7c3c0c4d883734b59bd5f9c5d377fd9d">current_output_plugin</a>)
<a name="l00374"></a>00374             selected = i;
<a name="l00375"></a>00375 
<a name="l00376"></a>00376         gtk_combo_box_append_text(cbox, op-&gt;description);
<a name="l00377"></a>00377     }
<a name="l00378"></a>00378 
<a name="l00379"></a>00379     gtk_combo_box_set_active(cbox, selected);
<a name="l00380"></a>00380     g_signal_connect(cbox, <span class="stringliteral">&quot;changed&quot;</span>,
<a name="l00381"></a>00381                      G_CALLBACK(<a class="code" href="ui__preferences_8c.html#a738a604117425e97d80b2a686476a895">on_output_plugin_cbox_changed</a>), NULL);
<a name="l00382"></a>00382 }
<a name="l00383"></a>00383 
<a name="l00384"></a>00384 <span class="keyword">static</span> <span class="keywordtype">void</span>
<a name="l00385"></a><a class="code" href="ui__preferences_8c.html#aa80ebab184d14b6aa701c054485e8307">00385</a> <a class="code" href="ui__preferences_8c.html#aa80ebab184d14b6aa701c054485e8307">on_plugin_view_realize</a>(GtkTreeView * treeview,
<a name="l00386"></a>00386                        GCallback callback,
<a name="l00387"></a>00387                        gpointer <a class="code" href="misc-api_8h.html#a2a40119722f785a93d720b769541a543">data</a>,
<a name="l00388"></a>00388                        <a class="code" href="misc-api_8h.html#acf599c059f43e0cca83145eb6b0c93cd">gint</a> plugin_type)
<a name="l00389"></a>00389 {
<a name="l00390"></a>00390     GtkListStore *store;
<a name="l00391"></a>00391     GtkTreeIter iter;
<a name="l00392"></a>00392 
<a name="l00393"></a>00393     GtkCellRenderer *renderer;
<a name="l00394"></a>00394     GtkTreeViewColumn *column;
<a name="l00395"></a>00395 
<a name="l00396"></a>00396     GList *ilist;
<a name="l00397"></a>00397     gchar *description[2];
<a name="l00398"></a>00398     <a class="code" href="misc-api_8h.html#acf599c059f43e0cca83145eb6b0c93cd">gint</a> <span class="keywordtype">id</span> = 0;
<a name="l00399"></a>00399 
<a name="l00400"></a>00400     GList *<a class="code" href="misc-api_8h.html#a5b3afcdfb4bae9b4dd1b1ba8f2e6e638">list</a> = (GList *) data;
<a name="l00401"></a>00401 
<a name="l00402"></a>00402     store = gtk_list_store_new(<a class="code" href="ui__preferences_8c.html#ace28870b3187dd2ac8e8f218e8c590d4abe51f5d764f6163dc1d30a845be154d7">PLUGIN_VIEW_N_COLS</a>,
<a name="l00403"></a>00403                                G_TYPE_BOOLEAN, G_TYPE_STRING,
<a name="l00404"></a>00404                                G_TYPE_STRING, G_TYPE_INT, G_TYPE_POINTER);
<a name="l00405"></a>00405     g_object_set_data(G_OBJECT(store), <span class="stringliteral">&quot;plugin_type&quot;</span> , GINT_TO_POINTER(plugin_type));
<a name="l00406"></a>00406 
<a name="l00407"></a>00407     column = gtk_tree_view_column_new();
<a name="l00408"></a>00408     gtk_tree_view_column_set_title(column, <a class="code" href="i18n_8h.html#a32a3cf3d9dd914f5aeeca5423c157934">_</a>(<span class="stringliteral">&quot;Enabled&quot;</span>));
<a name="l00409"></a>00409     gtk_tree_view_column_set_sizing(column, GTK_TREE_VIEW_COLUMN_FIXED);
<a name="l00410"></a>00410     gtk_tree_view_column_set_spacing(column, 4);
<a name="l00411"></a>00411     gtk_tree_view_column_set_resizable(column, FALSE);
<a name="l00412"></a>00412     gtk_tree_view_column_set_fixed_width(column, 50);
<a name="l00413"></a>00413 
<a name="l00414"></a>00414     renderer = gtk_cell_renderer_toggle_new();
<a name="l00415"></a>00415     g_signal_connect(renderer, <span class="stringliteral">&quot;toggled&quot;</span>,
<a name="l00416"></a>00416                      G_CALLBACK(callback), store);
<a name="l00417"></a>00417     gtk_tree_view_column_pack_start(column, renderer, TRUE);
<a name="l00418"></a>00418     gtk_tree_view_column_set_attributes(column, renderer, <span class="stringliteral">&quot;active&quot;</span>,
<a name="l00419"></a>00419                                         <a class="code" href="ui__preferences_8c.html#ace28870b3187dd2ac8e8f218e8c590d4a0c9c6f27b4307deed535637690600b72">PLUGIN_VIEW_COL_ACTIVE</a>, NULL);
<a name="l00420"></a>00420 
<a name="l00421"></a>00421     gtk_tree_view_append_column(treeview, column);
<a name="l00422"></a>00422 
<a name="l00423"></a>00423     column = gtk_tree_view_column_new();
<a name="l00424"></a>00424     gtk_tree_view_column_set_title(column, <a class="code" href="i18n_8h.html#a32a3cf3d9dd914f5aeeca5423c157934">_</a>(<span class="stringliteral">&quot;Description&quot;</span>));
<a name="l00425"></a>00425     gtk_tree_view_column_set_sizing(column, GTK_TREE_VIEW_COLUMN_AUTOSIZE);
<a name="l00426"></a>00426     gtk_tree_view_column_set_spacing(column, 4);
<a name="l00427"></a>00427     gtk_tree_view_column_set_resizable(column, TRUE);
<a name="l00428"></a>00428 
<a name="l00429"></a>00429 
<a name="l00430"></a>00430     renderer = gtk_cell_renderer_text_new();
<a name="l00431"></a>00431     gtk_tree_view_column_pack_start(column, renderer, FALSE);
<a name="l00432"></a>00432     gtk_tree_view_column_set_attributes(column, renderer,
<a name="l00433"></a>00433                                         <span class="stringliteral">&quot;text&quot;</span>, <a class="code" href="ui__preferences_8c.html#ace28870b3187dd2ac8e8f218e8c590d4a838e9673d18906f8105fa1d13c052cf3">PLUGIN_VIEW_COL_DESC</a>, NULL);
<a name="l00434"></a>00434     gtk_tree_view_append_column(treeview, column);
<a name="l00435"></a>00435 
<a name="l00436"></a>00436     column = gtk_tree_view_column_new();
<a name="l00437"></a>00437 
<a name="l00438"></a>00438     gtk_tree_view_column_set_title(column, <a class="code" href="i18n_8h.html#a32a3cf3d9dd914f5aeeca5423c157934">_</a>(<span class="stringliteral">&quot;Filename&quot;</span>));
<a name="l00439"></a>00439     gtk_tree_view_column_set_sizing(column, GTK_TREE_VIEW_COLUMN_AUTOSIZE);
<a name="l00440"></a>00440     gtk_tree_view_column_set_spacing(column, 4);
<a name="l00441"></a>00441     gtk_tree_view_column_set_resizable(column, TRUE);
<a name="l00442"></a>00442 
<a name="l00443"></a>00443     renderer = gtk_cell_renderer_text_new();
<a name="l00444"></a>00444     gtk_tree_view_column_pack_start(column, renderer, TRUE);
<a name="l00445"></a>00445     gtk_tree_view_column_set_attributes(column, renderer, <span class="stringliteral">&quot;text&quot;</span>,
<a name="l00446"></a>00446                                         <a class="code" href="ui__preferences_8c.html#ace28870b3187dd2ac8e8f218e8c590d4a327b60fd26e1b343a926bf9a9125100c">PLUGIN_VIEW_COL_FILENAME</a>, NULL);
<a name="l00447"></a>00447 
<a name="l00448"></a>00448     gtk_tree_view_append_column(treeview, column);
<a name="l00449"></a>00449 
<a name="l00450"></a>00450     MOWGLI_ITER_FOREACH(ilist, list)
<a name="l00451"></a>00451     {
<a name="l00452"></a>00452         Plugin *plugin = <a class="code" href="types_8h.html#a3a1f034ad93243bb3812764cb941dff7">PLUGIN</a>(ilist-&gt;data);
<a name="l00453"></a>00453         <a class="code" href="configdb-api_8h.html#a3ac4dad7ee7fd2890139bff9a134ee9a">gboolean</a> enabled = <a class="code" href="plugin-registry_8c.html#ab0d1feee6ff8124ace42e9ddce885162">plugin_get_enabled</a> (<a class="code" href="plugin-registry_8c.html#a0b26488a3994b15c19d353f59d51188b">plugin_by_header</a> (plugin));
<a name="l00454"></a>00454 
<a name="l00455"></a>00455         description[0] = g_strdup(plugin-&gt;description);
<a name="l00456"></a>00456         description[1] = g_strdup(plugin-&gt;filename);
<a name="l00457"></a>00457 
<a name="l00458"></a>00458         gtk_list_store_append(store, &amp;iter);
<a name="l00459"></a>00459         gtk_list_store_set(store, &amp;iter,
<a name="l00460"></a>00460                            <a class="code" href="ui__preferences_8c.html#ace28870b3187dd2ac8e8f218e8c590d4a0c9c6f27b4307deed535637690600b72">PLUGIN_VIEW_COL_ACTIVE</a>, enabled,
<a name="l00461"></a>00461                            <a class="code" href="ui__preferences_8c.html#ace28870b3187dd2ac8e8f218e8c590d4a838e9673d18906f8105fa1d13c052cf3">PLUGIN_VIEW_COL_DESC</a>, description[0],
<a name="l00462"></a>00462                            <a class="code" href="ui__preferences_8c.html#ace28870b3187dd2ac8e8f218e8c590d4a327b60fd26e1b343a926bf9a9125100c">PLUGIN_VIEW_COL_FILENAME</a>, description[1],
<a name="l00463"></a>00463                            <a class="code" href="ui__preferences_8c.html#ace28870b3187dd2ac8e8f218e8c590d4a9863793d2e83dab994f12dd91a443320">PLUGIN_VIEW_COL_ID</a>, <span class="keywordtype">id</span>++,
<a name="l00464"></a>00464                            <a class="code" href="ui__preferences_8c.html#ace28870b3187dd2ac8e8f218e8c590d4a5ed42aa040a6ec3d2ba084f3c72cd57e">PLUGIN_VIEW_COL_PLUGIN_PTR</a>, plugin, -1);
<a name="l00465"></a>00465 
<a name="l00466"></a>00466         g_free(description[1]);
<a name="l00467"></a>00467         g_free(description[0]);
<a name="l00468"></a>00468     }
<a name="l00469"></a>00469 
<a name="l00470"></a>00470     gtk_tree_view_set_model(treeview, GTK_TREE_MODEL(store));
<a name="l00471"></a>00471 }
<a name="l00472"></a>00472 
<a name="l00473"></a>00473 <span class="keyword">static</span> <span class="keywordtype">void</span>
<a name="l00474"></a><a class="code" href="ui__preferences_8c.html#a34b12071bf70d1a86af0e2b03fdd5a7b">00474</a> <a class="code" href="ui__preferences_8c.html#a34b12071bf70d1a86af0e2b03fdd5a7b">on_input_plugin_view_realize</a>(GtkTreeView * treeview,
<a name="l00475"></a>00475                              gpointer <a class="code" href="misc-api_8h.html#a2a40119722f785a93d720b769541a543">data</a>)
<a name="l00476"></a>00476 {
<a name="l00477"></a>00477     <a class="code" href="ui__preferences_8c.html#aa80ebab184d14b6aa701c054485e8307">on_plugin_view_realize</a> (treeview, (GCallback) <a class="code" href="ui__preferences_8c.html#a1100328568c2bfe74262b4b2fbfd7a28">plugin_toggle</a>, <a class="code" href="util_8c.html#ac80b918c3b70c80aaf5107a181731281">plugin_get_list</a>(<a class="code" href="plugins_8h.html#a16af7b253440dadd46a80a4b9fddba4da90ccc132a4f44b46e7b671831fc62359">PLUGIN_TYPE_INPUT</a>), <a class="code" href="ui__preferences_8c.html#a5644eb3f790d5e6ba29119a7d4e6e3d3ab5031417c44d1f05c26c8379ec6bbe3d">PLUGIN_VIEW_TYPE_INPUT</a>);
<a name="l00478"></a>00478 }
<a name="l00479"></a>00479 
<a name="l00480"></a>00480 <span class="keyword">static</span> <span class="keywordtype">void</span>
<a name="l00481"></a><a class="code" href="ui__preferences_8c.html#af7602fba1e83adf11e84d30b08ff5668">00481</a> <a class="code" href="ui__preferences_8c.html#af7602fba1e83adf11e84d30b08ff5668">on_effect_plugin_view_realize</a>(GtkTreeView * treeview,
<a name="l00482"></a>00482                               gpointer <a class="code" href="misc-api_8h.html#a2a40119722f785a93d720b769541a543">data</a>)
<a name="l00483"></a>00483 {
<a name="l00484"></a>00484     <a class="code" href="ui__preferences_8c.html#aa80ebab184d14b6aa701c054485e8307">on_plugin_view_realize</a> (treeview, (GCallback) <a class="code" href="ui__preferences_8c.html#a1100328568c2bfe74262b4b2fbfd7a28">plugin_toggle</a>, <a class="code" href="util_8c.html#ac80b918c3b70c80aaf5107a181731281">plugin_get_list</a>
<a name="l00485"></a>00485      (<a class="code" href="plugins_8h.html#a16af7b253440dadd46a80a4b9fddba4dae9f4cb7a4f78b0bf25be57d1b05cb613">PLUGIN_TYPE_EFFECT</a>), <a class="code" href="ui__preferences_8c.html#a5644eb3f790d5e6ba29119a7d4e6e3d3afd0d22de728112565df5c88ed82f3c06">PLUGIN_VIEW_TYPE_EFFECT</a>);
<a name="l00486"></a>00486 }
<a name="l00487"></a>00487 
<a name="l00488"></a>00488 <span class="keyword">static</span> <span class="keywordtype">void</span>
<a name="l00489"></a><a class="code" href="ui__preferences_8c.html#adf48dea152df8dd783858be8749737d8">00489</a> <a class="code" href="ui__preferences_8c.html#adf48dea152df8dd783858be8749737d8">on_general_plugin_view_realize</a>(GtkTreeView * treeview,
<a name="l00490"></a>00490                                gpointer <a class="code" href="misc-api_8h.html#a2a40119722f785a93d720b769541a543">data</a>)
<a name="l00491"></a>00491 {
<a name="l00492"></a>00492     <a class="code" href="ui__preferences_8c.html#aa80ebab184d14b6aa701c054485e8307">on_plugin_view_realize</a> (treeview, (GCallback) <a class="code" href="ui__preferences_8c.html#a1100328568c2bfe74262b4b2fbfd7a28">plugin_toggle</a>, <a class="code" href="util_8c.html#ac80b918c3b70c80aaf5107a181731281">plugin_get_list</a>
<a name="l00493"></a>00493      (<a class="code" href="plugins_8h.html#a16af7b253440dadd46a80a4b9fddba4da1755e93b8489ab99d93ae2984de17343">PLUGIN_TYPE_GENERAL</a>), <a class="code" href="ui__preferences_8c.html#a5644eb3f790d5e6ba29119a7d4e6e3d3a224907d964592908c703588c3bde1bcd">PLUGIN_VIEW_TYPE_GENERAL</a>);
<a name="l00494"></a>00494 }
<a name="l00495"></a>00495 
<a name="l00496"></a>00496 <span class="keyword">static</span> <span class="keywordtype">void</span>
<a name="l00497"></a><a class="code" href="ui__preferences_8c.html#aa77abe74b362e208f16ad80dcd1caf4b">00497</a> <a class="code" href="ui__preferences_8c.html#aa77abe74b362e208f16ad80dcd1caf4b">on_vis_plugin_view_realize</a>(GtkTreeView * treeview,
<a name="l00498"></a>00498                            gpointer <a class="code" href="misc-api_8h.html#a2a40119722f785a93d720b769541a543">data</a>)
<a name="l00499"></a>00499 {
<a name="l00500"></a>00500     <a class="code" href="ui__preferences_8c.html#aa80ebab184d14b6aa701c054485e8307">on_plugin_view_realize</a>(treeview, G_CALLBACK(<a class="code" href="ui__preferences_8c.html#a1100328568c2bfe74262b4b2fbfd7a28">plugin_toggle</a>), <a class="code" href="util_8c.html#ac80b918c3b70c80aaf5107a181731281">plugin_get_list</a>(<a class="code" href="plugins_8h.html#a16af7b253440dadd46a80a4b9fddba4da542b11c7fdb0b7ff2dd4f315923efccf">PLUGIN_TYPE_VIS</a>), <a class="code" href="ui__preferences_8c.html#a5644eb3f790d5e6ba29119a7d4e6e3d3a0c16e7265127af9a2346972168951bad">PLUGIN_VIEW_TYPE_VIS</a>);
<a name="l00501"></a>00501 }
<a name="l00502"></a>00502 
<a name="l00503"></a>00503 <span class="keyword">static</span> <span class="keywordtype">void</span>
<a name="l00504"></a><a class="code" href="ui__preferences_8c.html#a1b4dc1f8c7d207379e61c05d11d8eada">00504</a> <a class="code" href="ui__preferences_8c.html#a1b4dc1f8c7d207379e61c05d11d8eada">editable_insert_text</a>(GtkEditable * editable,
<a name="l00505"></a>00505                      <span class="keyword">const</span> gchar * text,
<a name="l00506"></a>00506                      <a class="code" href="misc-api_8h.html#acf599c059f43e0cca83145eb6b0c93cd">gint</a> * pos)
<a name="l00507"></a>00507 {
<a name="l00508"></a>00508     gtk_editable_insert_text(editable, text, strlen(text), pos);
<a name="l00509"></a>00509 }
<a name="l00510"></a>00510 
<a name="l00511"></a>00511 <span class="keyword">static</span> <span class="keywordtype">void</span>
<a name="l00512"></a><a class="code" href="ui__preferences_8c.html#a08973cd6329d02bf8bfbad71cfa7de74">00512</a> <a class="code" href="ui__preferences_8c.html#a08973cd6329d02bf8bfbad71cfa7de74">titlestring_tag_menu_callback</a>(GtkMenuItem * menuitem,
<a name="l00513"></a>00513                               gpointer <a class="code" href="misc-api_8h.html#a2a40119722f785a93d720b769541a543">data</a>)
<a name="l00514"></a>00514 {
<a name="l00515"></a>00515     <span class="keyword">const</span> gchar *separator = <span class="stringliteral">&quot; - &quot;</span>;
<a name="l00516"></a>00516     <a class="code" href="misc-api_8h.html#acf599c059f43e0cca83145eb6b0c93cd">gint</a> item = GPOINTER_TO_INT(data);
<a name="l00517"></a>00517     <a class="code" href="misc-api_8h.html#acf599c059f43e0cca83145eb6b0c93cd">gint</a> pos;
<a name="l00518"></a>00518 
<a name="l00519"></a>00519     pos = gtk_editable_get_position(GTK_EDITABLE(<a class="code" href="ui__preferences_8c.html#a653d9510fccddd6017f30dab79d0f355">titlestring_entry</a>));
<a name="l00520"></a>00520 
<a name="l00521"></a>00521     <span class="comment">/* insert separator as needed */</span>
<a name="l00522"></a>00522     <span class="keywordflow">if</span> (g_utf8_strlen(gtk_entry_get_text(GTK_ENTRY(<a class="code" href="ui__preferences_8c.html#a653d9510fccddd6017f30dab79d0f355">titlestring_entry</a>)), -1) &gt; 0)
<a name="l00523"></a>00523         <a class="code" href="ui__preferences_8c.html#a1b4dc1f8c7d207379e61c05d11d8eada">editable_insert_text</a>(GTK_EDITABLE(<a class="code" href="ui__preferences_8c.html#a653d9510fccddd6017f30dab79d0f355">titlestring_entry</a>), separator, &amp;pos);
<a name="l00524"></a>00524 
<a name="l00525"></a>00525     <a class="code" href="ui__preferences_8c.html#a1b4dc1f8c7d207379e61c05d11d8eada">editable_insert_text</a>(GTK_EDITABLE(<a class="code" href="ui__preferences_8c.html#a653d9510fccddd6017f30dab79d0f355">titlestring_entry</a>), <a class="code" href="i18n_8h.html#a32a3cf3d9dd914f5aeeca5423c157934">_</a>(title_field_tags[item].tag),
<a name="l00526"></a>00526                          &amp;pos);
<a name="l00527"></a>00527 
<a name="l00528"></a>00528     gtk_editable_set_position(GTK_EDITABLE(<a class="code" href="ui__preferences_8c.html#a653d9510fccddd6017f30dab79d0f355">titlestring_entry</a>), pos);
<a name="l00529"></a>00529 }
<a name="l00530"></a>00530 
<a name="l00531"></a>00531 <span class="keyword">static</span> <span class="keywordtype">void</span>
<a name="l00532"></a><a class="code" href="ui__preferences_8c.html#aa810f34a1833ef75e7eaeb3689c01993">00532</a> <a class="code" href="ui__preferences_8c.html#aa810f34a1833ef75e7eaeb3689c01993">util_menu_position</a>(GtkMenu * <a class="code" href="misc-api_8h.html#a0db0b8324cdd171bee042ed55c04d3da">menu</a>, <a class="code" href="misc-api_8h.html#acf599c059f43e0cca83145eb6b0c93cd">gint</a> * x, <a class="code" href="misc-api_8h.html#acf599c059f43e0cca83145eb6b0c93cd">gint</a> * y,
<a name="l00533"></a>00533                    <a class="code" href="configdb-api_8h.html#a3ac4dad7ee7fd2890139bff9a134ee9a">gboolean</a> * push_in, gpointer <a class="code" href="misc-api_8h.html#a2a40119722f785a93d720b769541a543">data</a>)
<a name="l00534"></a>00534 {
<a name="l00535"></a>00535     GtkRequisition requisition;
<a name="l00536"></a>00536     <a class="code" href="misc-api_8h.html#acf599c059f43e0cca83145eb6b0c93cd">gint</a> screen_width;
<a name="l00537"></a>00537     <a class="code" href="misc-api_8h.html#acf599c059f43e0cca83145eb6b0c93cd">gint</a> screen_height;
<a name="l00538"></a>00538     <a class="code" href="structMenuPos.html">MenuPos</a> *pos = <a class="code" href="misc-api_8h.html#a2a40119722f785a93d720b769541a543">data</a>;
<a name="l00539"></a>00539 
<a name="l00540"></a>00540     gtk_widget_size_request(GTK_WIDGET(menu), &amp;requisition);
<a name="l00541"></a>00541 
<a name="l00542"></a>00542     screen_width = gdk_screen_width();
<a name="l00543"></a>00543     screen_height = gdk_screen_height();
<a name="l00544"></a>00544 
<a name="l00545"></a>00545     *x = CLAMP(pos-&gt;<a class="code" href="structMenuPos.html#a50edc68e640424b58d32f2e40620809f">x</a> - 2, 0, MAX(0, screen_width - requisition.width));
<a name="l00546"></a>00546     *y = CLAMP(pos-&gt;<a class="code" href="structMenuPos.html#ac736ed415d574b86ff7a3c98d5831c0e">y</a> - 2, 0, MAX(0, screen_height - requisition.height));
<a name="l00547"></a>00547 }
<a name="l00548"></a>00548 
<a name="l00549"></a>00549 <span class="keyword">static</span> <span class="keywordtype">void</span>
<a name="l00550"></a><a class="code" href="ui__preferences_8c.html#adff7a1519c924b3b174b74899afba03a">00550</a> <a class="code" href="ui__preferences_8c.html#adff7a1519c924b3b174b74899afba03a">on_titlestring_help_button_clicked</a>(GtkButton * button,
<a name="l00551"></a>00551                                    gpointer <a class="code" href="misc-api_8h.html#a2a40119722f785a93d720b769541a543">data</a>)
<a name="l00552"></a>00552 {
<a name="l00553"></a>00553     GtkMenu *<a class="code" href="misc-api_8h.html#a0db0b8324cdd171bee042ed55c04d3da">menu</a>;
<a name="l00554"></a>00554     <a class="code" href="structMenuPos.html">MenuPos</a> *pos = g_newa(<a class="code" href="structMenuPos.html">MenuPos</a>, 1);
<a name="l00555"></a>00555     GdkWindow *parent, *window;
<a name="l00556"></a>00556 
<a name="l00557"></a>00557     <a class="code" href="misc-api_8h.html#acf599c059f43e0cca83145eb6b0c93cd">gint</a> x_ro, y_ro;
<a name="l00558"></a>00558     <a class="code" href="misc-api_8h.html#acf599c059f43e0cca83145eb6b0c93cd">gint</a> x_widget, y_widget;
<a name="l00559"></a>00559     <a class="code" href="misc-api_8h.html#acf599c059f43e0cca83145eb6b0c93cd">gint</a> x_size, y_size;
<a name="l00560"></a>00560 
<a name="l00561"></a>00561     g_return_if_fail (button != NULL);
<a name="l00562"></a>00562     g_return_if_fail (GTK_IS_MENU (data));
<a name="l00563"></a>00563 
<a name="l00564"></a>00564     parent = gtk_widget_get_parent_window(GTK_WIDGET(button));
<a name="l00565"></a>00565     window = <a class="code" href="gtk-compat_8h.html#a0de169f2a8f886c064757aa02fa9228e">gtk_widget_get_window</a>(GTK_WIDGET(button));
<a name="l00566"></a>00566 
<a name="l00567"></a>00567     gdk_drawable_get_size(parent, &amp;x_size, &amp;y_size);
<a name="l00568"></a>00568     gdk_window_get_root_origin(window, &amp;x_ro, &amp;y_ro);
<a name="l00569"></a>00569     gdk_window_get_position(window, &amp;x_widget, &amp;y_widget);
<a name="l00570"></a>00570 
<a name="l00571"></a>00571     pos-&gt;<a class="code" href="structMenuPos.html#a50edc68e640424b58d32f2e40620809f">x</a> = x_size + x_ro;
<a name="l00572"></a>00572     pos-&gt;<a class="code" href="structMenuPos.html#ac736ed415d574b86ff7a3c98d5831c0e">y</a> = y_size + y_ro - 100;
<a name="l00573"></a>00573 
<a name="l00574"></a>00574     menu = GTK_MENU(data);
<a name="l00575"></a>00575     gtk_menu_popup (menu, NULL, NULL, <a class="code" href="ui__preferences_8c.html#aa810f34a1833ef75e7eaeb3689c01993">util_menu_position</a>, pos,
<a name="l00576"></a>00576                     0, GDK_CURRENT_TIME);
<a name="l00577"></a>00577 }
<a name="l00578"></a>00578 
<a name="l00579"></a>00579 
<a name="l00580"></a>00580 <span class="keyword">static</span> <span class="keywordtype">void</span>
<a name="l00581"></a><a class="code" href="ui__preferences_8c.html#aeafed25ac59eaea23709b083e9c79ede">00581</a> <a class="code" href="ui__preferences_8c.html#aeafed25ac59eaea23709b083e9c79ede">on_titlestring_entry_realize</a>(GtkWidget * <a class="code" href="structentry.html">entry</a>,
<a name="l00582"></a>00582                              gpointer <a class="code" href="misc-api_8h.html#a2a40119722f785a93d720b769541a543">data</a>)
<a name="l00583"></a>00583 {
<a name="l00584"></a>00584     gtk_entry_set_text(GTK_ENTRY(entry), <a class="code" href="audconfig_8c.html#a98bd56a064259046a6cc6b1a620badf8">cfg</a>.gentitle_format);
<a name="l00585"></a>00585 }
<a name="l00586"></a>00586 
<a name="l00587"></a>00587 <span class="keyword">static</span> <a class="code" href="configdb-api_8h.html#a3ac4dad7ee7fd2890139bff9a134ee9a">gboolean</a>
<a name="l00588"></a><a class="code" href="ui__preferences_8c.html#add93b392d234afaa764350f9452a18ca">00588</a> <a class="code" href="ui__preferences_8c.html#add93b392d234afaa764350f9452a18ca">titlestring_timeout_proc</a> (gpointer <a class="code" href="misc-api_8h.html#a2a40119722f785a93d720b769541a543">data</a>)
<a name="l00589"></a>00589 {
<a name="l00590"></a>00590     <a class="code" href="ui__preferences_8c.html#ab6cf8123c3f99607c2c27af09aa18aa6">titlestring_timeout_counter</a>--;
<a name="l00591"></a>00591 
<a name="l00592"></a>00592     <span class="keywordflow">if</span>(<a class="code" href="ui__preferences_8c.html#ab6cf8123c3f99607c2c27af09aa18aa6">titlestring_timeout_counter</a> &lt;= 0) {
<a name="l00593"></a>00593         <a class="code" href="ui__preferences_8c.html#ab6cf8123c3f99607c2c27af09aa18aa6">titlestring_timeout_counter</a> = 0;
<a name="l00594"></a>00594         <a class="code" href="playlist-new_8c.html#a01d911fe6ab969cba4bc0e5768c8a773">playlist_reformat_titles</a> ();
<a name="l00595"></a>00595         <span class="keywordflow">return</span> FALSE;
<a name="l00596"></a>00596     } <span class="keywordflow">else</span> {
<a name="l00597"></a>00597         <span class="keywordflow">return</span> TRUE;
<a name="l00598"></a>00598     }
<a name="l00599"></a>00599 }
<a name="l00600"></a>00600 
<a name="l00601"></a>00601 <span class="keyword">static</span> <span class="keywordtype">void</span>
<a name="l00602"></a><a class="code" href="ui__preferences_8c.html#a16b79685f33690135533f9e274eeed5f">00602</a> <a class="code" href="ui__preferences_8c.html#a16b79685f33690135533f9e274eeed5f">on_titlestring_entry_changed</a>(GtkWidget * <a class="code" href="structentry.html">entry</a>,
<a name="l00603"></a>00603                              gpointer <a class="code" href="misc-api_8h.html#a2a40119722f785a93d720b769541a543">data</a>)
<a name="l00604"></a>00604 {
<a name="l00605"></a>00605     g_free(<a class="code" href="audconfig_8c.html#a98bd56a064259046a6cc6b1a620badf8">cfg</a>.gentitle_format);
<a name="l00606"></a>00606     <a class="code" href="audconfig_8c.html#a98bd56a064259046a6cc6b1a620badf8">cfg</a>.gentitle_format = g_strdup(gtk_entry_get_text(GTK_ENTRY(entry)));
<a name="l00607"></a>00607 
<a name="l00608"></a>00608     <span class="keywordflow">if</span>(<a class="code" href="ui__preferences_8c.html#ab6cf8123c3f99607c2c27af09aa18aa6">titlestring_timeout_counter</a> == 0) {
<a name="l00609"></a>00609         <a class="code" href="compatibility_8h.html#a528907d130e2d6bddcf218c16946d51e">g_timeout_add_seconds</a> (1, (GSourceFunc) <a class="code" href="ui__preferences_8c.html#add93b392d234afaa764350f9452a18ca">titlestring_timeout_proc</a>, NULL);
<a name="l00610"></a>00610     }
<a name="l00611"></a>00611 
<a name="l00612"></a>00612     <a class="code" href="ui__preferences_8c.html#ab6cf8123c3f99607c2c27af09aa18aa6">titlestring_timeout_counter</a> = <a class="code" href="ui__preferences_8c.html#a65dbec50671b69564a37363d2bc5a3d8">TITLESTRING_UPDATE_TIMEOUT</a>;
<a name="l00613"></a>00613 }
<a name="l00614"></a>00614 
<a name="l00615"></a>00615 <span class="keyword">static</span> <span class="keywordtype">void</span>
<a name="l00616"></a><a class="code" href="ui__preferences_8c.html#a9673f033564e2412b836a4682beefde6">00616</a> <a class="code" href="ui__preferences_8c.html#a9673f033564e2412b836a4682beefde6">on_titlestring_cbox_realize</a>(GtkWidget * cbox,
<a name="l00617"></a>00617                             gpointer <a class="code" href="misc-api_8h.html#a2a40119722f785a93d720b769541a543">data</a>)
<a name="l00618"></a>00618 {
<a name="l00619"></a>00619     gtk_combo_box_set_active(GTK_COMBO_BOX(cbox), <a class="code" href="audconfig_8c.html#a98bd56a064259046a6cc6b1a620badf8">cfg</a>.titlestring_preset);
<a name="l00620"></a>00620     gtk_widget_set_sensitive(GTK_WIDGET(data),
<a name="l00621"></a>00621                              (<a class="code" href="audconfig_8c.html#a98bd56a064259046a6cc6b1a620badf8">cfg</a>.titlestring_preset == (<a class="code" href="misc-api_8h.html#acf599c059f43e0cca83145eb6b0c93cd">gint</a>)<a class="code" href="playlist-utils_8c.html#a21a5a2d0ce4d45474e846e0e6db30baa">n_titlestring_presets</a>));
<a name="l00622"></a>00622 }
<a name="l00623"></a>00623 
<a name="l00624"></a>00624 <span class="keyword">static</span> <span class="keywordtype">void</span>
<a name="l00625"></a><a class="code" href="ui__preferences_8c.html#a1cbdab02f7bef0e10bf27cedd93d5e75">00625</a> <a class="code" href="ui__preferences_8c.html#a1cbdab02f7bef0e10bf27cedd93d5e75">on_titlestring_cbox_changed</a>(GtkWidget * cbox,
<a name="l00626"></a>00626                             gpointer <a class="code" href="misc-api_8h.html#a2a40119722f785a93d720b769541a543">data</a>)
<a name="l00627"></a>00627 {
<a name="l00628"></a>00628     <a class="code" href="misc-api_8h.html#acf599c059f43e0cca83145eb6b0c93cd">gint</a> position = gtk_combo_box_get_active(GTK_COMBO_BOX(cbox));
<a name="l00629"></a>00629 
<a name="l00630"></a>00630     <a class="code" href="audconfig_8c.html#a98bd56a064259046a6cc6b1a620badf8">cfg</a>.titlestring_preset = position;
<a name="l00631"></a>00631     gtk_widget_set_sensitive(GTK_WIDGET(data), (position == 6));
<a name="l00632"></a>00632 
<a name="l00633"></a>00633     <a class="code" href="playlist-new_8c.html#a01d911fe6ab969cba4bc0e5768c8a773">playlist_reformat_titles</a> ();
<a name="l00634"></a>00634 }
<a name="l00635"></a>00635 
<a name="l00636"></a>00636 <span class="keyword">static</span> <span class="keywordtype">void</span>
<a name="l00637"></a><a class="code" href="ui__preferences_8c.html#a1cb540a11dbf0f7a7dda0d24c37f2b7e">00637</a> <a class="code" href="ui__preferences_8c.html#a1cb540a11dbf0f7a7dda0d24c37f2b7e">on_font_btn_realize</a>(GtkFontButton * button, gchar **<a class="code" href="audconfig_8c.html#a98bd56a064259046a6cc6b1a620badf8">cfg</a>)
<a name="l00638"></a>00638 {
<a name="l00639"></a>00639     gtk_font_button_set_font_name(button, *cfg);
<a name="l00640"></a>00640 }
<a name="l00641"></a>00641 
<a name="l00642"></a>00642 <span class="keyword">static</span> <span class="keywordtype">void</span>
<a name="l00643"></a><a class="code" href="ui__preferences_8c.html#aeb2b0f54933b222483f89e87d6691931">00643</a> <a class="code" href="ui__preferences_8c.html#aeb2b0f54933b222483f89e87d6691931">on_font_btn_font_set</a>(GtkFontButton * button, gchar **config)
<a name="l00644"></a>00644 {
<a name="l00645"></a>00645     g_free(*config);
<a name="l00646"></a>00646     *config = g_strdup(gtk_font_button_get_font_name(button));
<a name="l00647"></a>00647     <a class="code" href="log_8h.html#aebed521e655fa60b64f7323bc418c088" title="Debug message macro and transitional aliases.">AUDDBG</a>(<span class="stringliteral">&quot;Returned font name: \&quot;%s\&quot;\n&quot;</span>, *config);
<a name="l00648"></a>00648     void (*callback) (void) = g_object_get_data(G_OBJECT(button), <span class="stringliteral">&quot;callback&quot;</span>);
<a name="l00649"></a>00649     <span class="keywordflow">if</span> (callback != NULL) callback();
<a name="l00650"></a>00650 }
<a name="l00651"></a>00651 
<a name="l00652"></a>00652 <span class="keyword">static</span> <span class="keywordtype">void</span>
<a name="l00653"></a><a class="code" href="ui__preferences_8c.html#a8b479075affa855747a6a741c3a60bf0">00653</a> <a class="code" href="ui__preferences_8c.html#a8b479075affa855747a6a741c3a60bf0">plugin_preferences_ok</a>(GtkWidget *widget, PluginPreferences *settings)
<a name="l00654"></a>00654 {
<a name="l00655"></a>00655     <span class="keywordflow">if</span> (settings-&gt;apply)
<a name="l00656"></a>00656         settings-&gt;apply();
<a name="l00657"></a>00657 
<a name="l00658"></a>00658     gtk_widget_destroy(GTK_WIDGET(settings-&gt;data));
<a name="l00659"></a>00659 }
<a name="l00660"></a>00660 
<a name="l00661"></a>00661 <span class="keyword">static</span> <span class="keywordtype">void</span>
<a name="l00662"></a><a class="code" href="ui__preferences_8c.html#a05fe12a621bcf9bd7ff3245de5a68243">00662</a> <a class="code" href="ui__preferences_8c.html#a05fe12a621bcf9bd7ff3245de5a68243">plugin_preferences_apply</a>(GtkWidget *widget, PluginPreferences *settings)
<a name="l00663"></a>00663 {
<a name="l00664"></a>00664     <span class="keywordflow">if</span> (settings-&gt;apply)
<a name="l00665"></a>00665         settings-&gt;apply();
<a name="l00666"></a>00666 }
<a name="l00667"></a>00667 
<a name="l00668"></a>00668 <span class="keyword">static</span> <span class="keywordtype">void</span>
<a name="l00669"></a><a class="code" href="ui__preferences_8c.html#ac651a266e25f70538e97e7218adb4a48">00669</a> <a class="code" href="ui__preferences_8c.html#ac651a266e25f70538e97e7218adb4a48">plugin_preferences_cancel</a>(GtkWidget *widget, PluginPreferences *settings)
<a name="l00670"></a>00670 {
<a name="l00671"></a>00671     <span class="keywordflow">if</span> (settings-&gt;cancel)
<a name="l00672"></a>00672         settings-&gt;cancel();
<a name="l00673"></a>00673 
<a name="l00674"></a>00674     gtk_widget_destroy(GTK_WIDGET(settings-&gt;data));
<a name="l00675"></a>00675 }
<a name="l00676"></a>00676 
<a name="l00677"></a>00677 <span class="keyword">static</span> <span class="keywordtype">void</span>
<a name="l00678"></a><a class="code" href="ui__preferences_8c.html#ab18e353a5155e8c0a714bacd8bc5e1d9">00678</a> <a class="code" href="ui__preferences_8c.html#ab18e353a5155e8c0a714bacd8bc5e1d9">plugin_preferences_destroy</a>(GtkWidget *widget, PluginPreferences *settings)
<a name="l00679"></a>00679 {
<a name="l00680"></a>00680     gtk_widget_destroy(widget);
<a name="l00681"></a>00681 
<a name="l00682"></a>00682     <span class="keywordflow">if</span> (settings-&gt;cleanup)
<a name="l00683"></a>00683         settings-&gt;cleanup();
<a name="l00684"></a>00684 
<a name="l00685"></a>00685     settings-&gt;data = NULL;
<a name="l00686"></a>00686 }
<a name="l00687"></a>00687 
<a name="l00688"></a>00688 <span class="keyword">static</span> <span class="keywordtype">void</span>
<a name="l00689"></a><a class="code" href="ui__preferences_8c.html#aaff60e8f2a9db57d17e4a9812a2095e1">00689</a> <a class="code" href="ui__preferences_8c.html#aaff60e8f2a9db57d17e4a9812a2095e1">create_plugin_preferences</a>(PluginPreferences *settings)
<a name="l00690"></a>00690 {
<a name="l00691"></a>00691     GtkWidget *window;
<a name="l00692"></a>00692     GtkWidget *vbox, *bbox, *ok, *apply, *cancel;
<a name="l00693"></a>00693 
<a name="l00694"></a>00694     <span class="keywordflow">if</span> (settings-&gt;data != NULL) {
<a name="l00695"></a>00695         gtk_widget_show(GTK_WIDGET(settings-&gt;data));
<a name="l00696"></a>00696         <span class="keywordflow">return</span>;
<a name="l00697"></a>00697     }
<a name="l00698"></a>00698 
<a name="l00699"></a>00699     <span class="keywordflow">if</span> (settings-&gt;init)
<a name="l00700"></a>00700         settings-&gt;init();
<a name="l00701"></a>00701 
<a name="l00702"></a>00702     window = gtk_window_new(GTK_WINDOW_TOPLEVEL);
<a name="l00703"></a>00703     gtk_window_set_type_hint(GTK_WINDOW(window), GDK_WINDOW_TYPE_HINT_DIALOG);
<a name="l00704"></a>00704     gtk_window_set_title(GTK_WINDOW(window), <a class="code" href="i18n_8h.html#a32a3cf3d9dd914f5aeeca5423c157934">_</a>(settings-&gt;title));
<a name="l00705"></a>00705     gtk_container_set_border_width(GTK_CONTAINER(window), 10);
<a name="l00706"></a>00706 
<a name="l00707"></a>00707     g_signal_connect(G_OBJECT(window), <span class="stringliteral">&quot;destroy&quot;</span>,
<a name="l00708"></a>00708                      G_CALLBACK(<a class="code" href="ui__preferences_8c.html#ab18e353a5155e8c0a714bacd8bc5e1d9">plugin_preferences_destroy</a>), settings);
<a name="l00709"></a>00709 
<a name="l00710"></a>00710     vbox = gtk_vbox_new(FALSE, 10);
<a name="l00711"></a>00711     create_widgets(GTK_BOX(vbox), settings-&gt;prefs, settings-&gt;n_prefs);
<a name="l00712"></a>00712     gtk_container_add(GTK_CONTAINER(window), vbox);
<a name="l00713"></a>00713 
<a name="l00714"></a>00714     bbox = gtk_hbutton_box_new();
<a name="l00715"></a>00715     gtk_button_box_set_layout(GTK_BUTTON_BOX(bbox), GTK_BUTTONBOX_END);
<a name="l00716"></a>00716     gtk_box_set_spacing(GTK_BOX(bbox), 5);
<a name="l00717"></a>00717     gtk_box_pack_start(GTK_BOX(vbox), bbox, FALSE, FALSE, 0);
<a name="l00718"></a>00718 
<a name="l00719"></a>00719     ok = gtk_button_new_from_stock(GTK_STOCK_OK);
<a name="l00720"></a>00720     g_signal_connect(G_OBJECT(ok), <span class="stringliteral">&quot;clicked&quot;</span>,
<a name="l00721"></a>00721                      G_CALLBACK(<a class="code" href="ui__preferences_8c.html#a8b479075affa855747a6a741c3a60bf0">plugin_preferences_ok</a>), settings);
<a name="l00722"></a>00722     gtk_box_pack_start(GTK_BOX(bbox), ok, TRUE, TRUE, 0);
<a name="l00723"></a>00723     <a class="code" href="gtk-compat_8h.html#a0b9f0f50ef60efc20b44f8bf8959b13d">gtk_widget_set_can_default</a> (ok, TRUE);
<a name="l00724"></a>00724     gtk_widget_grab_default(ok);
<a name="l00725"></a>00725 
<a name="l00726"></a>00726     apply = gtk_button_new_from_stock(GTK_STOCK_APPLY);
<a name="l00727"></a>00727     g_signal_connect(G_OBJECT(apply), <span class="stringliteral">&quot;clicked&quot;</span>,
<a name="l00728"></a>00728                      G_CALLBACK(<a class="code" href="ui__preferences_8c.html#a05fe12a621bcf9bd7ff3245de5a68243">plugin_preferences_apply</a>), settings);
<a name="l00729"></a>00729     gtk_box_pack_start(GTK_BOX(bbox), apply, TRUE, TRUE, 0);
<a name="l00730"></a>00730 
<a name="l00731"></a>00731     cancel = gtk_button_new_from_stock(GTK_STOCK_CANCEL);
<a name="l00732"></a>00732     g_signal_connect(G_OBJECT(cancel), <span class="stringliteral">&quot;clicked&quot;</span>,
<a name="l00733"></a>00733                      G_CALLBACK(<a class="code" href="ui__preferences_8c.html#ac651a266e25f70538e97e7218adb4a48">plugin_preferences_cancel</a>), settings);
<a name="l00734"></a>00734     gtk_box_pack_start(GTK_BOX(bbox), cancel, TRUE, TRUE, 0);
<a name="l00735"></a>00735 
<a name="l00736"></a>00736     gtk_window_set_transient_for(GTK_WINDOW(window), GTK_WINDOW(<a class="code" href="ui__preferences_8c.html#a68dc3d5b54e6e977aedc3ca6a96e92b1">prefswin</a>));
<a name="l00737"></a>00737     gtk_widget_show_all(window);
<a name="l00738"></a>00738     settings-&gt;data = (gpointer)window;
<a name="l00739"></a>00739 }
<a name="l00740"></a>00740 
<a name="l00741"></a>00741 <span class="keyword">static</span> <span class="keywordtype">void</span>
<a name="l00742"></a><a class="code" href="ui__preferences_8c.html#a82325604635e4fd9b165e14821330041">00742</a> <a class="code" href="ui__preferences_8c.html#a82325604635e4fd9b165e14821330041">plugin_treeview_open_prefs</a>(GtkTreeView *treeview)
<a name="l00743"></a>00743 {
<a name="l00744"></a>00744     GtkTreeSelection *selection;
<a name="l00745"></a>00745     GtkTreeModel *model;
<a name="l00746"></a>00746     GtkTreeIter iter;
<a name="l00747"></a>00747     Plugin *plugin = NULL;
<a name="l00748"></a>00748 
<a name="l00749"></a>00749     selection = gtk_tree_view_get_selection(treeview);
<a name="l00750"></a>00750     <span class="keywordflow">if</span> (!gtk_tree_selection_get_selected(selection, &amp;model, &amp;iter))
<a name="l00751"></a>00751         <span class="keywordflow">return</span>;
<a name="l00752"></a>00752     gtk_tree_model_get(model, &amp;iter, <a class="code" href="ui__preferences_8c.html#ace28870b3187dd2ac8e8f218e8c590d4a5ed42aa040a6ec3d2ba084f3c72cd57e">PLUGIN_VIEW_COL_PLUGIN_PTR</a>, &amp;plugin, -1);
<a name="l00753"></a>00753 
<a name="l00754"></a>00754     g_return_if_fail(plugin != NULL);
<a name="l00755"></a>00755     g_return_if_fail((plugin-&gt;configure != NULL) ||
<a name="l00756"></a>00756                      ((plugin-&gt;settings != NULL) &amp;&amp; (plugin-&gt;settings-&gt;type == <a class="code" href="preferences_8h.html#ad26b29cbcb76e2b44f77713fa0df0f2ea5fa6e4a533ef28b8c1eb88165449ed44">PREFERENCES_WINDOW</a>)));
<a name="l00757"></a>00757 
<a name="l00758"></a>00758     <span class="keywordflow">if</span> (plugin-&gt;configure != NULL)
<a name="l00759"></a>00759         plugin-&gt;configure();
<a name="l00760"></a>00760     <span class="keywordflow">else</span>
<a name="l00761"></a>00761         <a class="code" href="ui__preferences_8c.html#aaff60e8f2a9db57d17e4a9812a2095e1">create_plugin_preferences</a>(plugin-&gt;settings);
<a name="l00762"></a>00762 }
<a name="l00763"></a>00763 
<a name="l00764"></a>00764 <span class="keyword">static</span> <span class="keywordtype">void</span>
<a name="l00765"></a><a class="code" href="ui__preferences_8c.html#a00517c485d9ab1fbf26b85a5fcb825bd">00765</a> <a class="code" href="ui__preferences_8c.html#a00517c485d9ab1fbf26b85a5fcb825bd">plugin_treeview_open_info</a>(GtkTreeView *treeview)
<a name="l00766"></a>00766 {
<a name="l00767"></a>00767     GtkTreeSelection *selection;
<a name="l00768"></a>00768     GtkTreeModel *model;
<a name="l00769"></a>00769     GtkTreeIter iter;
<a name="l00770"></a>00770     Plugin *plugin = NULL;
<a name="l00771"></a>00771 
<a name="l00772"></a>00772     selection = gtk_tree_view_get_selection(treeview);
<a name="l00773"></a>00773     <span class="keywordflow">if</span> (!gtk_tree_selection_get_selected(selection, &amp;model, &amp;iter))
<a name="l00774"></a>00774         <span class="keywordflow">return</span>;
<a name="l00775"></a>00775     gtk_tree_model_get(model, &amp;iter, <a class="code" href="ui__preferences_8c.html#ace28870b3187dd2ac8e8f218e8c590d4a5ed42aa040a6ec3d2ba084f3c72cd57e">PLUGIN_VIEW_COL_PLUGIN_PTR</a>, &amp;plugin, -1);
<a name="l00776"></a>00776 
<a name="l00777"></a>00777     g_return_if_fail(plugin != NULL);
<a name="l00778"></a>00778     plugin-&gt;about();
<a name="l00779"></a>00779 }
<a name="l00780"></a>00780 
<a name="l00781"></a>00781 <span class="keyword">static</span> <span class="keywordtype">void</span>
<a name="l00782"></a><a class="code" href="ui__preferences_8c.html#a9642650849f954a24ea08a068cb2d903">00782</a> <a class="code" href="ui__preferences_8c.html#a9642650849f954a24ea08a068cb2d903">plugin_treeview_enable_prefs</a>(GtkTreeView * treeview, GtkButton * button)
<a name="l00783"></a>00783 {
<a name="l00784"></a>00784     GtkTreeSelection *selection;
<a name="l00785"></a>00785     GtkTreeModel *model;
<a name="l00786"></a>00786     GtkTreeIter iter;
<a name="l00787"></a>00787     Plugin *plugin = NULL;
<a name="l00788"></a>00788 
<a name="l00789"></a>00789     selection = gtk_tree_view_get_selection(treeview);
<a name="l00790"></a>00790     <span class="keywordflow">if</span> (!gtk_tree_selection_get_selected(selection, &amp;model, &amp;iter))
<a name="l00791"></a>00791         <span class="keywordflow">return</span>;
<a name="l00792"></a>00792 
<a name="l00793"></a>00793     gtk_tree_model_get(model, &amp;iter, <a class="code" href="ui__preferences_8c.html#ace28870b3187dd2ac8e8f218e8c590d4a5ed42aa040a6ec3d2ba084f3c72cd57e">PLUGIN_VIEW_COL_PLUGIN_PTR</a>, &amp;plugin, -1);
<a name="l00794"></a>00794 
<a name="l00795"></a>00795     g_return_if_fail(plugin != NULL);
<a name="l00796"></a>00796 
<a name="l00797"></a>00797     gtk_widget_set_sensitive(GTK_WIDGET(button),
<a name="l00798"></a>00798                              ((plugin-&gt;configure != NULL) ||
<a name="l00799"></a>00799                              (plugin-&gt;settings ? (plugin-&gt;settings-&gt;type == <a class="code" href="preferences_8h.html#ad26b29cbcb76e2b44f77713fa0df0f2ea5fa6e4a533ef28b8c1eb88165449ed44">PREFERENCES_WINDOW</a>) : FALSE)));
<a name="l00800"></a>00800 }
<a name="l00801"></a>00801 
<a name="l00802"></a>00802 <span class="keyword">static</span> <span class="keywordtype">void</span>
<a name="l00803"></a><a class="code" href="ui__preferences_8c.html#a5fb1d6f4bb7c6ce6ad5a6950ac24fdb9">00803</a> <a class="code" href="ui__preferences_8c.html#a5fb1d6f4bb7c6ce6ad5a6950ac24fdb9">plugin_treeview_enable_info</a>(GtkTreeView * treeview, GtkButton * button)
<a name="l00804"></a>00804 {
<a name="l00805"></a>00805     GtkTreeSelection *selection;
<a name="l00806"></a>00806     GtkTreeModel *model;
<a name="l00807"></a>00807     GtkTreeIter iter;
<a name="l00808"></a>00808     Plugin *plugin = NULL;
<a name="l00809"></a>00809 
<a name="l00810"></a>00810     selection = gtk_tree_view_get_selection(treeview);
<a name="l00811"></a>00811     <span class="keywordflow">if</span> (!gtk_tree_selection_get_selected(selection, &amp;model, &amp;iter))
<a name="l00812"></a>00812         <span class="keywordflow">return</span>;
<a name="l00813"></a>00813 
<a name="l00814"></a>00814     gtk_tree_model_get(model, &amp;iter, <a class="code" href="ui__preferences_8c.html#ace28870b3187dd2ac8e8f218e8c590d4a5ed42aa040a6ec3d2ba084f3c72cd57e">PLUGIN_VIEW_COL_PLUGIN_PTR</a>, &amp;plugin, -1);
<a name="l00815"></a>00815 
<a name="l00816"></a>00816     g_return_if_fail(plugin != NULL);
<a name="l00817"></a>00817 
<a name="l00818"></a>00818     gtk_widget_set_sensitive(GTK_WIDGET(button), plugin-&gt;about != NULL);
<a name="l00819"></a>00819 }
<a name="l00820"></a>00820 
<a name="l00821"></a>00821 
<a name="l00822"></a>00822 <span class="keyword">static</span> <span class="keywordtype">void</span>
<a name="l00823"></a><a class="code" href="ui__preferences_8c.html#a888b7b1e4b0131d1d961436820e0d749">00823</a> <a class="code" href="ui__preferences_8c.html#a888b7b1e4b0131d1d961436820e0d749">output_plugin_enable_info</a>(GtkComboBox * cbox, GtkButton * button)
<a name="l00824"></a>00824 {
<a name="l00825"></a>00825     GList *plist;
<a name="l00826"></a>00826 
<a name="l00827"></a>00827     <a class="code" href="misc-api_8h.html#acf599c059f43e0cca83145eb6b0c93cd">gint</a> <span class="keywordtype">id</span> = gtk_combo_box_get_active(cbox);
<a name="l00828"></a>00828 
<a name="l00829"></a>00829     plist = <a class="code" href="output_8c.html#a9c0b095a41c60449bc217651abd25e0c">get_output_list</a>();
<a name="l00830"></a>00830     plist = g_list_nth(plist, <span class="keywordtype">id</span>);
<a name="l00831"></a>00831 
<a name="l00832"></a>00832     gtk_widget_set_sensitive(GTK_WIDGET(button),
<a name="l00833"></a>00833                              <a class="code" href="types_8h.html#a63f5244c033787d384e4c850b15ee7e5">OUTPUT_PLUGIN</a>(plist-&gt;data)-&gt;about != NULL);
<a name="l00834"></a>00834 }
<a name="l00835"></a>00835 
<a name="l00836"></a>00836 <span class="keyword">static</span> <span class="keywordtype">void</span>
<a name="l00837"></a><a class="code" href="ui__preferences_8c.html#aedf73cb5b7bfc5230a1e1499bdd8aab5">00837</a> <a class="code" href="ui__preferences_8c.html#aedf73cb5b7bfc5230a1e1499bdd8aab5">output_plugin_enable_prefs</a>(GtkComboBox * cbox, GtkButton * button)
<a name="l00838"></a>00838 {
<a name="l00839"></a>00839     GList *plist;
<a name="l00840"></a>00840     <a class="code" href="misc-api_8h.html#acf599c059f43e0cca83145eb6b0c93cd">gint</a> <span class="keywordtype">id</span> = gtk_combo_box_get_active(cbox);
<a name="l00841"></a>00841 
<a name="l00842"></a>00842     plist = <a class="code" href="output_8c.html#a9c0b095a41c60449bc217651abd25e0c">get_output_list</a>();
<a name="l00843"></a>00843     plist = g_list_nth(plist, <span class="keywordtype">id</span>);
<a name="l00844"></a>00844 
<a name="l00845"></a>00845     gtk_widget_set_sensitive(GTK_WIDGET(button),
<a name="l00846"></a>00846                              <a class="code" href="types_8h.html#a63f5244c033787d384e4c850b15ee7e5">OUTPUT_PLUGIN</a>(plist-&gt;data)-&gt;configure != NULL);
<a name="l00847"></a>00847 }
<a name="l00848"></a>00848 
<a name="l00849"></a>00849 <span class="keyword">static</span> <span class="keywordtype">void</span>
<a name="l00850"></a><a class="code" href="ui__preferences_8c.html#a549c6e7c307f18e0b2f047c5acc01cc9">00850</a> <a class="code" href="ui__preferences_8c.html#a549c6e7c307f18e0b2f047c5acc01cc9">on_output_plugin_bufsize_realize</a>(GtkSpinButton *button,
<a name="l00851"></a>00851                                  gpointer <a class="code" href="misc-api_8h.html#a2a40119722f785a93d720b769541a543">data</a>)
<a name="l00852"></a>00852 {
<a name="l00853"></a>00853     gtk_spin_button_set_value(button, <a class="code" href="audconfig_8c.html#a98bd56a064259046a6cc6b1a620badf8">cfg</a>.output_buffer_size);
<a name="l00854"></a>00854 }
<a name="l00855"></a>00855 
<a name="l00856"></a>00856 <span class="keyword">static</span> <span class="keywordtype">void</span>
<a name="l00857"></a><a class="code" href="ui__preferences_8c.html#a62d0958807fbd2286d03dc4a49180037">00857</a> <a class="code" href="ui__preferences_8c.html#a62d0958807fbd2286d03dc4a49180037">on_output_plugin_bufsize_value_changed</a>(GtkSpinButton *button,
<a name="l00858"></a>00858                                        gpointer <a class="code" href="misc-api_8h.html#a2a40119722f785a93d720b769541a543">data</a>)
<a name="l00859"></a>00859 {
<a name="l00860"></a>00860     <a class="code" href="audconfig_8c.html#a98bd56a064259046a6cc6b1a620badf8">cfg</a>.output_buffer_size = gtk_spin_button_get_value_as_int(button);
<a name="l00861"></a>00861 }
<a name="l00862"></a>00862 
<a name="l00863"></a>00863 <span class="keyword">static</span> <span class="keywordtype">void</span>
<a name="l00864"></a><a class="code" href="ui__preferences_8c.html#aa5eae5e861ac69be718ec37aadbe68b0">00864</a> <a class="code" href="ui__preferences_8c.html#aa5eae5e861ac69be718ec37aadbe68b0">on_spin_btn_realize_gint</a>(GtkSpinButton *button, <a class="code" href="misc-api_8h.html#acf599c059f43e0cca83145eb6b0c93cd">gint</a> *<a class="code" href="audconfig_8c.html#a98bd56a064259046a6cc6b1a620badf8">cfg</a>)
<a name="l00865"></a>00865 {
<a name="l00866"></a>00866     gtk_spin_button_set_value(button, *cfg);
<a name="l00867"></a>00867 }
<a name="l00868"></a>00868 
<a name="l00869"></a>00869 <span class="keyword">static</span> <span class="keywordtype">void</span>
<a name="l00870"></a><a class="code" href="ui__preferences_8c.html#abff6a22c3da39455a35100f3ee276484">00870</a> <a class="code" href="ui__preferences_8c.html#abff6a22c3da39455a35100f3ee276484">on_spin_btn_changed_gint</a>(GtkSpinButton *button, <a class="code" href="misc-api_8h.html#acf599c059f43e0cca83145eb6b0c93cd">gint</a> *<a class="code" href="audconfig_8c.html#a98bd56a064259046a6cc6b1a620badf8">cfg</a>)
<a name="l00871"></a>00871 {
<a name="l00872"></a>00872     *cfg = gtk_spin_button_get_value_as_int(button);
<a name="l00873"></a>00873 }
<a name="l00874"></a>00874 
<a name="l00875"></a>00875 <span class="keyword">static</span> <span class="keywordtype">void</span>
<a name="l00876"></a><a class="code" href="ui__preferences_8c.html#a62e4ae92e2841cfc228d7b83038f797f">00876</a> <a class="code" href="ui__preferences_8c.html#a62e4ae92e2841cfc228d7b83038f797f">on_spin_btn_realize_gfloat</a>(GtkSpinButton *button, gfloat *<a class="code" href="audconfig_8c.html#a98bd56a064259046a6cc6b1a620badf8">cfg</a>)
<a name="l00877"></a>00877 {
<a name="l00878"></a>00878      gtk_spin_button_set_value(button, (<a class="code" href="configdb-api_8h.html#a7f7966c2bfc9d8a9debaa4e9f62a6a5f">gdouble</a>) *cfg);
<a name="l00879"></a>00879 }
<a name="l00880"></a>00880 
<a name="l00881"></a>00881 <span class="keyword">static</span> <span class="keywordtype">void</span>
<a name="l00882"></a><a class="code" href="ui__preferences_8c.html#adae54771d3b742bac8ffc913ef388e5b">00882</a> <a class="code" href="ui__preferences_8c.html#adae54771d3b742bac8ffc913ef388e5b">on_spin_btn_changed_gfloat</a>(GtkSpinButton *button, gfloat *<a class="code" href="audconfig_8c.html#a98bd56a064259046a6cc6b1a620badf8">cfg</a>)
<a name="l00883"></a>00883 {
<a name="l00884"></a>00884     *cfg = (gfloat) gtk_spin_button_get_value(button);
<a name="l00885"></a>00885 }
<a name="l00886"></a>00886 
<a name="l00887"></a>00887 
<a name="l00888"></a>00888 <span class="keyword">static</span> <span class="keywordtype">void</span>
<a name="l00889"></a><a class="code" href="ui__preferences_8c.html#a73348c5c67f24886ad23e189a33db1a2">00889</a> <a class="code" href="ui__preferences_8c.html#a73348c5c67f24886ad23e189a33db1a2">on_category_treeview_realize</a>(GtkTreeView * treeview,
<a name="l00890"></a>00890                              GtkNotebook * notebook)
<a name="l00891"></a>00891 {
<a name="l00892"></a>00892     GtkListStore *store;
<a name="l00893"></a>00893     GtkCellRenderer *renderer;
<a name="l00894"></a>00894     GtkTreeViewColumn *column;
<a name="l00895"></a>00895     GtkTreeSelection *selection;
<a name="l00896"></a>00896     GtkTreeIter iter;
<a name="l00897"></a>00897     GdkPixbuf *img;
<a name="l00898"></a>00898     <a class="code" href="structCategoryQueueEntry.html">CategoryQueueEntry</a> *qlist;
<a name="l00899"></a>00899     <a class="code" href="misc-api_8h.html#acf599c059f43e0cca83145eb6b0c93cd">gint</a> i;
<a name="l00900"></a>00900 
<a name="l00901"></a>00901     column = gtk_tree_view_column_new();
<a name="l00902"></a>00902     gtk_tree_view_column_set_title(column, <a class="code" href="i18n_8h.html#a32a3cf3d9dd914f5aeeca5423c157934">_</a>(<span class="stringliteral">&quot;Category&quot;</span>));
<a name="l00903"></a>00903     gtk_tree_view_append_column(treeview, column);
<a name="l00904"></a>00904     gtk_tree_view_column_set_spacing(column, 2);
<a name="l00905"></a>00905 
<a name="l00906"></a>00906     renderer = gtk_cell_renderer_pixbuf_new();
<a name="l00907"></a>00907     gtk_tree_view_column_pack_start(column, renderer, FALSE);
<a name="l00908"></a>00908     gtk_tree_view_column_set_attributes(column, renderer, <span class="stringliteral">&quot;pixbuf&quot;</span>, 0, NULL);
<a name="l00909"></a>00909 
<a name="l00910"></a>00910     renderer = gtk_cell_renderer_text_new();
<a name="l00911"></a>00911     gtk_tree_view_column_pack_start(column, renderer, FALSE);
<a name="l00912"></a>00912     gtk_tree_view_column_set_attributes(column, renderer, <span class="stringliteral">&quot;text&quot;</span>, 1, NULL);
<a name="l00913"></a>00913 
<a name="l00914"></a>00914     <a class="code" href="misc-api_8h.html#acf599c059f43e0cca83145eb6b0c93cd">gint</a> width, height;
<a name="l00915"></a>00915     gtk_widget_get_size_request(GTK_WIDGET(treeview), &amp;width, &amp;height);
<a name="l00916"></a>00916     g_object_set(G_OBJECT(renderer), <span class="stringliteral">&quot;wrap-width&quot;</span>, width - 64 - 24, <span class="stringliteral">&quot;wrap-mode&quot;</span>,
<a name="l00917"></a>00917      PANGO_WRAP_WORD_CHAR, NULL);
<a name="l00918"></a>00918 
<a name="l00919"></a>00919     store = gtk_list_store_new(<a class="code" href="ui__preferences_8c.html#ab327bcf652522bc3ff67a66149322ecaaa5e981b84e9ff40e106e2fd68eeaae77">CATEGORY_VIEW_N_COLS</a>,
<a name="l00920"></a>00920                                GDK_TYPE_PIXBUF, G_TYPE_STRING, G_TYPE_INT);
<a name="l00921"></a>00921     gtk_tree_view_set_model(treeview, GTK_TREE_MODEL(store));
<a name="l00922"></a>00922 
<a name="l00923"></a>00923     <span class="keywordflow">for</span> (i = 0; i &lt; <a class="code" href="ui__preferences_8c.html#ab17d8310433b2104fda0b9d19e73b3a3">n_categories</a>; i++) {
<a name="l00924"></a>00924         img = gdk_pixbuf_new_from_file(categories[i].icon_path, NULL);
<a name="l00925"></a>00925         gtk_list_store_append(store, &amp;iter);
<a name="l00926"></a>00926         gtk_list_store_set(store, &amp;iter,
<a name="l00927"></a>00927                            <a class="code" href="ui__preferences_8c.html#ab327bcf652522bc3ff67a66149322ecaa9f029b74c630e374d42d3487fcb2024b">CATEGORY_VIEW_COL_ICON</a>, img,
<a name="l00928"></a>00928                            <a class="code" href="ui__preferences_8c.html#ab327bcf652522bc3ff67a66149322ecaa2ad7e3c813c7a4c25ec39518ed944b97">CATEGORY_VIEW_COL_NAME</a>,
<a name="l00929"></a>00929                            gettext(categories[i].name), <a class="code" href="ui__preferences_8c.html#ab327bcf652522bc3ff67a66149322ecaa807e88ae3818317d7cb3025cac995a52">CATEGORY_VIEW_COL_ID</a>,
<a name="l00930"></a>00930                            i, -1);
<a name="l00931"></a>00931         g_object_unref(img);
<a name="l00932"></a>00932     }
<a name="l00933"></a>00933 
<a name="l00934"></a>00934     selection = gtk_tree_view_get_selection(treeview);
<a name="l00935"></a>00935 
<a name="l00936"></a>00936     g_signal_connect_swapped(selection, <span class="stringliteral">&quot;changed&quot;</span>,
<a name="l00937"></a>00937                              G_CALLBACK(<a class="code" href="ui__preferences_8c.html#a7917d20a6e80d0bf1e5715c2b78b17e7">change_category</a>), notebook);
<a name="l00938"></a>00938 
<a name="l00939"></a>00939     <span class="comment">/* mark the treeview widget as available to third party plugins */</span>
<a name="l00940"></a>00940     <a class="code" href="ui__preferences_8c.html#a2d9f22af30312bfb508faf3d100d1a43">category_treeview</a> = GTK_WIDGET(treeview);
<a name="l00941"></a>00941 
<a name="l00942"></a>00942     <span class="comment">/* prefswin_page_queue_destroy already pops the queue forward for us. */</span>
<a name="l00943"></a>00943     <span class="keywordflow">for</span> (qlist = category_queue; qlist != NULL; qlist = <a class="code" href="ui__preferences_8c.html#a4ec3c92c0498e384e9b4986b093f2cec">category_queue</a>)
<a name="l00944"></a>00944     {
<a name="l00945"></a>00945         <a class="code" href="structCategoryQueueEntry.html">CategoryQueueEntry</a> *ent = (<a class="code" href="structCategoryQueueEntry.html">CategoryQueueEntry</a> *) qlist;
<a name="l00946"></a>00946 
<a name="l00947"></a>00947         <a class="code" href="ui__preferences_8c.html#a6ec6b38ff87a139b46b05db5c8cff100">prefswin_page_new</a>(ent-&gt;<a class="code" href="structCategoryQueueEntry.html#a921bd11623d976bdc29eda94ecc3090f">container</a>, ent-&gt;<a class="code" href="structCategoryQueueEntry.html#a88dc3ce0f0e92236d14c64fc4d6577e0">pg_name</a>, ent-&gt;<a class="code" href="structCategoryQueueEntry.html#a4989ec930e5f97de96277f718de0fb15">img_url</a>);
<a name="l00948"></a>00948         <a class="code" href="ui__preferences_8c.html#a19b121ea803d703ab99cab744e801889">prefswin_page_queue_destroy</a>(ent);
<a name="l00949"></a>00949     }
<a name="l00950"></a>00950 }
<a name="l00951"></a>00951 
<a name="l00952"></a>00952 <span class="keyword">static</span> <span class="keywordtype">void</span>
<a name="l00953"></a><a class="code" href="ui__preferences_8c.html#a8012debecd1036bfae0ab249efa8a5fe">00953</a> <a class="code" href="ui__preferences_8c.html#a8012debecd1036bfae0ab249efa8a5fe">on_show_filepopup_for_tuple_realize</a>(GtkToggleButton * button, gpointer <a class="code" href="misc-api_8h.html#a2a40119722f785a93d720b769541a543">data</a>)
<a name="l00954"></a>00954 {
<a name="l00955"></a>00955     gtk_toggle_button_set_active(button, <a class="code" href="audconfig_8c.html#a98bd56a064259046a6cc6b1a620badf8">cfg</a>.show_filepopup_for_tuple);
<a name="l00956"></a>00956     <a class="code" href="ui__preferences_8c.html#a7967067f4ebb6dfe6b7061ed452ee7e8">filepopupbutton</a> = GTK_WIDGET(button);
<a name="l00957"></a>00957 
<a name="l00958"></a>00958     gtk_widget_set_sensitive(<a class="code" href="ui__preferences_8c.html#ac603916ed5e941130399cbf62c64e46f">filepopup_for_tuple_settings_button</a>, <a class="code" href="audconfig_8c.html#a98bd56a064259046a6cc6b1a620badf8">cfg</a>.show_filepopup_for_tuple);
<a name="l00959"></a>00959 }
<a name="l00960"></a>00960 
<a name="l00961"></a>00961 <span class="keyword">static</span> <span class="keywordtype">void</span>
<a name="l00962"></a><a class="code" href="ui__preferences_8c.html#a8061d28defce7facf5f92ad05b663353">00962</a> <a class="code" href="ui__preferences_8c.html#a8061d28defce7facf5f92ad05b663353">on_show_filepopup_for_tuple_toggled</a>(GtkToggleButton * button, gpointer <a class="code" href="misc-api_8h.html#a2a40119722f785a93d720b769541a543">data</a>)
<a name="l00963"></a>00963 {
<a name="l00964"></a>00964     <a class="code" href="audconfig_8c.html#a98bd56a064259046a6cc6b1a620badf8">cfg</a>.show_filepopup_for_tuple = gtk_toggle_button_get_active(button);
<a name="l00965"></a>00965 
<a name="l00966"></a>00966     gtk_widget_set_sensitive(<a class="code" href="ui__preferences_8c.html#ac603916ed5e941130399cbf62c64e46f">filepopup_for_tuple_settings_button</a>, <a class="code" href="audconfig_8c.html#a98bd56a064259046a6cc6b1a620badf8">cfg</a>.show_filepopup_for_tuple);
<a name="l00967"></a>00967 }
<a name="l00968"></a>00968 
<a name="l00969"></a>00969 <span class="keyword">static</span> <span class="keywordtype">void</span>
<a name="l00970"></a><a class="code" href="ui__preferences_8c.html#af73b7a114e444a037308dfc567aea660">00970</a> <a class="code" href="ui__preferences_8c.html#af73b7a114e444a037308dfc567aea660">on_recurse_for_cover_toggled</a>(GtkToggleButton *button, gpointer <a class="code" href="misc-api_8h.html#a2a40119722f785a93d720b769541a543">data</a>)
<a name="l00971"></a>00971 {
<a name="l00972"></a>00972     gtk_widget_set_sensitive(GTK_WIDGET(data),
<a name="l00973"></a>00973                              gtk_toggle_button_get_active(button));
<a name="l00974"></a>00974 }
<a name="l00975"></a>00975 
<a name="l00976"></a>00976 <span class="keyword">static</span> <span class="keywordtype">void</span>
<a name="l00977"></a><a class="code" href="ui__preferences_8c.html#af57329a78cd8de1556129e4852bb3e8c">00977</a> <a class="code" href="ui__preferences_8c.html#af57329a78cd8de1556129e4852bb3e8c">on_filepopup_for_tuple_settings_clicked</a>(GtkButton *button, gpointer <a class="code" href="misc-api_8h.html#a2a40119722f785a93d720b769541a543">data</a>)
<a name="l00978"></a>00978 {
<a name="l00979"></a>00979     gtk_entry_set_text(GTK_ENTRY(<a class="code" href="ui__preferences_8c.html#aeffefe5b1341092d2bcea93eeb54e6e7">filepopup_settings_cover_name_include</a>), <a class="code" href="audconfig_8c.html#a98bd56a064259046a6cc6b1a620badf8">cfg</a>.cover_name_include);
<a name="l00980"></a>00980     gtk_entry_set_text(GTK_ENTRY(<a class="code" href="ui__preferences_8c.html#a4916123a9b3c4cd69579f6e2ab05f392">filepopup_settings_cover_name_exclude</a>), <a class="code" href="audconfig_8c.html#a98bd56a064259046a6cc6b1a620badf8">cfg</a>.cover_name_exclude);
<a name="l00981"></a>00981     gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON(<a class="code" href="ui__preferences_8c.html#a131837372172af9db3fc5d91a5f2aa9b">filepopup_settings_recurse_for_cover</a>), <a class="code" href="audconfig_8c.html#a98bd56a064259046a6cc6b1a620badf8">cfg</a>.recurse_for_cover);
<a name="l00982"></a>00982     gtk_spin_button_set_value(GTK_SPIN_BUTTON(<a class="code" href="ui__preferences_8c.html#ace3440a4371ba3dd0d53bcc054bb483a">filepopup_settings_recurse_for_cover_depth</a>), <a class="code" href="audconfig_8c.html#a98bd56a064259046a6cc6b1a620badf8">cfg</a>.recurse_for_cover_depth);
<a name="l00983"></a>00983     <a class="code" href="ui__preferences_8c.html#af73b7a114e444a037308dfc567aea660">on_recurse_for_cover_toggled</a>(GTK_TOGGLE_BUTTON(<a class="code" href="ui__preferences_8c.html#a131837372172af9db3fc5d91a5f2aa9b">filepopup_settings_recurse_for_cover</a>), <a class="code" href="ui__preferences_8c.html#a95e4e396181962faab937bb13309a48b">filepopup_settings_recurse_for_cover_depth_box</a>);
<a name="l00984"></a>00984     gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON(<a class="code" href="ui__preferences_8c.html#a346148c7cc9fc7f3d713fd1280a6a349">filepopup_settings_use_file_cover</a>), <a class="code" href="audconfig_8c.html#a98bd56a064259046a6cc6b1a620badf8">cfg</a>.use_file_cover);
<a name="l00985"></a>00985     gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON(<a class="code" href="ui__preferences_8c.html#afd8b57e120943e674216fc2854ca1edb">filepopup_settings_showprogressbar</a>), <a class="code" href="audconfig_8c.html#a98bd56a064259046a6cc6b1a620badf8">cfg</a>.filepopup_showprogressbar);
<a name="l00986"></a>00986     gtk_spin_button_set_value(GTK_SPIN_BUTTON(<a class="code" href="ui__preferences_8c.html#a557d900b62cb289e400d6c124f34a3e4">filepopup_settings_delay</a>), <a class="code" href="audconfig_8c.html#a98bd56a064259046a6cc6b1a620badf8">cfg</a>.filepopup_delay);
<a name="l00987"></a>00987 
<a name="l00988"></a>00988     gtk_widget_show(<a class="code" href="ui__preferences_8c.html#a6af62902a201b816a4038fd2f97481a2">filepopup_settings</a>);
<a name="l00989"></a>00989 }
<a name="l00990"></a>00990 
<a name="l00991"></a>00991 <span class="keyword">static</span> <span class="keywordtype">void</span>
<a name="l00992"></a><a class="code" href="ui__preferences_8c.html#a049f8fcd8c932908dc9aab7e1e50d299">00992</a> <a class="code" href="ui__preferences_8c.html#a049f8fcd8c932908dc9aab7e1e50d299">on_filepopup_settings_ok_clicked</a>(GtkButton *button, gpointer <a class="code" href="misc-api_8h.html#a2a40119722f785a93d720b769541a543">data</a>)
<a name="l00993"></a>00993 {
<a name="l00994"></a>00994     g_free(<a class="code" href="audconfig_8c.html#a98bd56a064259046a6cc6b1a620badf8">cfg</a>.cover_name_include);
<a name="l00995"></a>00995     <a class="code" href="audconfig_8c.html#a98bd56a064259046a6cc6b1a620badf8">cfg</a>.cover_name_include = g_strdup(gtk_entry_get_text(GTK_ENTRY(<a class="code" href="ui__preferences_8c.html#aeffefe5b1341092d2bcea93eeb54e6e7">filepopup_settings_cover_name_include</a>)));
<a name="l00996"></a>00996 
<a name="l00997"></a>00997     g_free(<a class="code" href="audconfig_8c.html#a98bd56a064259046a6cc6b1a620badf8">cfg</a>.cover_name_exclude);
<a name="l00998"></a>00998     <a class="code" href="audconfig_8c.html#a98bd56a064259046a6cc6b1a620badf8">cfg</a>.cover_name_exclude = g_strdup(gtk_entry_get_text(GTK_ENTRY(<a class="code" href="ui__preferences_8c.html#a4916123a9b3c4cd69579f6e2ab05f392">filepopup_settings_cover_name_exclude</a>)));
<a name="l00999"></a>00999 
<a name="l01000"></a>01000     <a class="code" href="audconfig_8c.html#a98bd56a064259046a6cc6b1a620badf8">cfg</a>.recurse_for_cover = gtk_toggle_button_get_active(GTK_TOGGLE_BUTTON(<a class="code" href="ui__preferences_8c.html#a131837372172af9db3fc5d91a5f2aa9b">filepopup_settings_recurse_for_cover</a>));
<a name="l01001"></a>01001     <a class="code" href="audconfig_8c.html#a98bd56a064259046a6cc6b1a620badf8">cfg</a>.recurse_for_cover_depth = gtk_spin_button_get_value_as_int(GTK_SPIN_BUTTON(<a class="code" href="ui__preferences_8c.html#ace3440a4371ba3dd0d53bcc054bb483a">filepopup_settings_recurse_for_cover_depth</a>));
<a name="l01002"></a>01002     <a class="code" href="audconfig_8c.html#a98bd56a064259046a6cc6b1a620badf8">cfg</a>.use_file_cover = gtk_toggle_button_get_active(GTK_TOGGLE_BUTTON(<a class="code" href="ui__preferences_8c.html#a346148c7cc9fc7f3d713fd1280a6a349">filepopup_settings_use_file_cover</a>));
<a name="l01003"></a>01003     <a class="code" href="audconfig_8c.html#a98bd56a064259046a6cc6b1a620badf8">cfg</a>.filepopup_showprogressbar = gtk_toggle_button_get_active(GTK_TOGGLE_BUTTON(<a class="code" href="ui__preferences_8c.html#afd8b57e120943e674216fc2854ca1edb">filepopup_settings_showprogressbar</a>));
<a name="l01004"></a>01004     <a class="code" href="audconfig_8c.html#a98bd56a064259046a6cc6b1a620badf8">cfg</a>.filepopup_delay = gtk_spin_button_get_value_as_int(GTK_SPIN_BUTTON(<a class="code" href="ui__preferences_8c.html#a557d900b62cb289e400d6c124f34a3e4">filepopup_settings_delay</a>));
<a name="l01005"></a>01005 
<a name="l01006"></a>01006     gtk_widget_hide(<a class="code" href="ui__preferences_8c.html#a6af62902a201b816a4038fd2f97481a2">filepopup_settings</a>);
<a name="l01007"></a>01007 }
<a name="l01008"></a>01008 
<a name="l01009"></a>01009 <span class="keyword">static</span> <span class="keywordtype">void</span>
<a name="l01010"></a><a class="code" href="ui__preferences_8c.html#a3b6d36d1a01a13d92936188e549bf558">01010</a> <a class="code" href="ui__preferences_8c.html#a3b6d36d1a01a13d92936188e549bf558">on_filepopup_settings_cancel_clicked</a>(GtkButton *button, gpointer <a class="code" href="misc-api_8h.html#a2a40119722f785a93d720b769541a543">data</a>)
<a name="l01011"></a>01011 {
<a name="l01012"></a>01012     gtk_widget_hide(<a class="code" href="ui__preferences_8c.html#a6af62902a201b816a4038fd2f97481a2">filepopup_settings</a>);
<a name="l01013"></a>01013 }
<a name="l01014"></a>01014 
<a name="l01015"></a>01015 <span class="keyword">static</span> <span class="keywordtype">void</span>
<a name="l01016"></a><a class="code" href="ui__preferences_8c.html#a95e7218024259e4cc8cf004f2e8d6447">01016</a> <a class="code" href="ui__preferences_8c.html#a95e7218024259e4cc8cf004f2e8d6447">on_toggle_button_toggled</a>(GtkToggleButton * button, <a class="code" href="configdb-api_8h.html#a3ac4dad7ee7fd2890139bff9a134ee9a">gboolean</a> *<a class="code" href="audconfig_8c.html#a98bd56a064259046a6cc6b1a620badf8">cfg</a>)
<a name="l01017"></a>01017 {
<a name="l01018"></a>01018     *cfg = gtk_toggle_button_get_active(button);
<a name="l01019"></a>01019     void (*callback) (void) = g_object_get_data(G_OBJECT(button), <span class="stringliteral">&quot;callback&quot;</span>);
<a name="l01020"></a>01020     <span class="keywordflow">if</span> (callback != NULL) callback();
<a name="l01021"></a>01021     GtkWidget *child = g_object_get_data(G_OBJECT(button), <span class="stringliteral">&quot;child&quot;</span>);
<a name="l01022"></a>01022     <span class="keywordflow">if</span> (child) gtk_widget_set_sensitive(GTK_WIDGET(child), *cfg);
<a name="l01023"></a>01023 }
<a name="l01024"></a>01024 
<a name="l01025"></a>01025 <span class="keyword">static</span> <span class="keywordtype">void</span>
<a name="l01026"></a><a class="code" href="ui__preferences_8c.html#ad86421e267a4c8a3ccd390cf41ee14d9">01026</a> <a class="code" href="ui__preferences_8c.html#ad86421e267a4c8a3ccd390cf41ee14d9">on_toggle_button_realize</a>(GtkToggleButton * button, <a class="code" href="configdb-api_8h.html#a3ac4dad7ee7fd2890139bff9a134ee9a">gboolean</a> *<a class="code" href="audconfig_8c.html#a98bd56a064259046a6cc6b1a620badf8">cfg</a>)
<a name="l01027"></a>01027 {
<a name="l01028"></a>01028     gtk_toggle_button_set_active(button, cfg ? *cfg : FALSE);
<a name="l01029"></a>01029     GtkWidget *child = g_object_get_data(G_OBJECT(button), <span class="stringliteral">&quot;child&quot;</span>);
<a name="l01030"></a>01030     <span class="keywordflow">if</span> (child) gtk_widget_set_sensitive(GTK_WIDGET(child), cfg ? *cfg : FALSE);
<a name="l01031"></a>01031 }
<a name="l01032"></a>01032 
<a name="l01033"></a>01033 <span class="keyword">static</span> <span class="keywordtype">void</span>
<a name="l01034"></a><a class="code" href="ui__preferences_8c.html#ac74285e56522f2b36a0db57fbbc02829">01034</a> <a class="code" href="ui__preferences_8c.html#ac74285e56522f2b36a0db57fbbc02829">on_toggle_button_cfg_toggled</a>(GtkToggleButton *button, gchar *<a class="code" href="audconfig_8c.html#a98bd56a064259046a6cc6b1a620badf8">cfg</a>)
<a name="l01035"></a>01035 {
<a name="l01036"></a>01036     g_return_if_fail(cfg != NULL);
<a name="l01037"></a>01037 
<a name="l01038"></a>01038     mcs_handle_t *<a class="code" href="configdb-api_8h.html#a111075202a831737470faf04df888f59">db</a>;
<a name="l01039"></a>01039     <a class="code" href="configdb-api_8h.html#a3ac4dad7ee7fd2890139bff9a134ee9a">gboolean</a> ret = gtk_toggle_button_get_active(button);
<a name="l01040"></a>01040 
<a name="l01041"></a>01041     db = <a class="code" href="configdb_8c.html#a2bf0784e3c27f6dcf806712382f4093d" title="Opens the configuration database.">cfg_db_open</a>();
<a name="l01042"></a>01042     <a class="code" href="configdb-api_8h.html#a5d87c9bc2262204ab4c5effa7aa49d45">cfg_db_set_bool</a>(db, NULL, cfg, ret);
<a name="l01043"></a>01043     <a class="code" href="configdb_8c.html#a28a8cbf4f7ed7314513ae6922a84d746" title="Closes the configuration database.">cfg_db_close</a>(db);
<a name="l01044"></a>01044 }
<a name="l01045"></a>01045 
<a name="l01046"></a>01046 <span class="keyword">static</span> <span class="keywordtype">void</span>
<a name="l01047"></a><a class="code" href="ui__preferences_8c.html#a34bdf3f3820a480c11e78b059d54b23c">01047</a> <a class="code" href="ui__preferences_8c.html#a34bdf3f3820a480c11e78b059d54b23c">on_toggle_button_cfg_realize</a>(GtkToggleButton *button, gchar *<a class="code" href="audconfig_8c.html#a98bd56a064259046a6cc6b1a620badf8">cfg</a>)
<a name="l01048"></a>01048 {
<a name="l01049"></a>01049     mcs_handle_t *<a class="code" href="configdb-api_8h.html#a111075202a831737470faf04df888f59">db</a>;
<a name="l01050"></a>01050     <a class="code" href="configdb-api_8h.html#a3ac4dad7ee7fd2890139bff9a134ee9a">gboolean</a> ret;
<a name="l01051"></a>01051 
<a name="l01052"></a>01052     g_return_if_fail(cfg != NULL);
<a name="l01053"></a>01053 
<a name="l01054"></a>01054     db = <a class="code" href="configdb_8c.html#a2bf0784e3c27f6dcf806712382f4093d" title="Opens the configuration database.">cfg_db_open</a>();
<a name="l01055"></a>01055 
<a name="l01056"></a>01056     <span class="keywordflow">if</span> (<a class="code" href="configdb_8c.html#a818ee486a9e7d240e8a4074ad91370d4" title="Fetches a boolean value from the configuration database.">cfg_db_get_bool</a>(db, NULL, cfg, &amp;ret) != FALSE)
<a name="l01057"></a>01057         gtk_toggle_button_set_active(button, ret);
<a name="l01058"></a>01058 
<a name="l01059"></a>01059     <a class="code" href="configdb_8c.html#a28a8cbf4f7ed7314513ae6922a84d746" title="Closes the configuration database.">cfg_db_close</a>(db);
<a name="l01060"></a>01060 }
<a name="l01061"></a>01061 
<a name="l01062"></a>01062 <span class="keyword">static</span> <span class="keywordtype">void</span>
<a name="l01063"></a><a class="code" href="ui__preferences_8c.html#a86586275cbfacf5d92fc1fb6a04e40ee">01063</a> <a class="code" href="ui__preferences_8c.html#a86586275cbfacf5d92fc1fb6a04e40ee">on_entry_realize</a>(GtkEntry *<a class="code" href="structentry.html">entry</a>, gchar **<a class="code" href="audconfig_8c.html#a98bd56a064259046a6cc6b1a620badf8">cfg</a>)
<a name="l01064"></a>01064 {
<a name="l01065"></a>01065     g_return_if_fail(cfg != NULL);
<a name="l01066"></a>01066 
<a name="l01067"></a>01067     <span class="keywordflow">if</span> (*cfg)
<a name="l01068"></a>01068         gtk_entry_set_text(entry, *cfg);
<a name="l01069"></a>01069 }
<a name="l01070"></a>01070 
<a name="l01071"></a>01071 <span class="keyword">static</span> <span class="keywordtype">void</span>
<a name="l01072"></a><a class="code" href="ui__preferences_8c.html#ade0080a8259000ae1b4ff102d0864724">01072</a> <a class="code" href="ui__preferences_8c.html#ade0080a8259000ae1b4ff102d0864724">on_entry_changed</a>(GtkEntry *<a class="code" href="structentry.html">entry</a>, gchar **<a class="code" href="audconfig_8c.html#a98bd56a064259046a6cc6b1a620badf8">cfg</a>)
<a name="l01073"></a>01073 {
<a name="l01074"></a>01074     void (*callback) (void) = g_object_get_data(G_OBJECT(entry), <span class="stringliteral">&quot;callback&quot;</span>);
<a name="l01075"></a>01075     <span class="keyword">const</span> gchar *ret;
<a name="l01076"></a>01076 
<a name="l01077"></a>01077     g_return_if_fail(cfg != NULL);
<a name="l01078"></a>01078 
<a name="l01079"></a>01079     g_free(*cfg);
<a name="l01080"></a>01080 
<a name="l01081"></a>01081     ret = gtk_entry_get_text(entry);
<a name="l01082"></a>01082 
<a name="l01083"></a>01083     <span class="keywordflow">if</span> (ret == NULL)
<a name="l01084"></a>01084         *cfg = g_strdup(<span class="stringliteral">&quot;&quot;</span>);
<a name="l01085"></a>01085     <span class="keywordflow">else</span>
<a name="l01086"></a>01086         *cfg = g_strdup(ret);
<a name="l01087"></a>01087 
<a name="l01088"></a>01088     <span class="keywordflow">if</span> (callback != NULL) callback();
<a name="l01089"></a>01089 }
<a name="l01090"></a>01090 
<a name="l01091"></a>01091 <span class="keyword">static</span> <span class="keywordtype">void</span>
<a name="l01092"></a><a class="code" href="ui__preferences_8c.html#ac2e5f65556a97a5716a900fdc0f56b59">01092</a> <a class="code" href="ui__preferences_8c.html#ac2e5f65556a97a5716a900fdc0f56b59">on_entry_cfg_realize</a>(GtkEntry *<a class="code" href="structentry.html">entry</a>, gchar *<a class="code" href="audconfig_8c.html#a98bd56a064259046a6cc6b1a620badf8">cfg</a>)
<a name="l01093"></a>01093 {
<a name="l01094"></a>01094     mcs_handle_t *<a class="code" href="configdb-api_8h.html#a111075202a831737470faf04df888f59">db</a>;
<a name="l01095"></a>01095     gchar *ret;
<a name="l01096"></a>01096 
<a name="l01097"></a>01097     g_return_if_fail(cfg != NULL);
<a name="l01098"></a>01098 
<a name="l01099"></a>01099     db = <a class="code" href="configdb_8c.html#a2bf0784e3c27f6dcf806712382f4093d" title="Opens the configuration database.">cfg_db_open</a>();
<a name="l01100"></a>01100 
<a name="l01101"></a>01101     <span class="keywordflow">if</span> (<a class="code" href="configdb_8c.html#a5e953f9747e3f21a50f56eb98e5595fb" title="Fetches a string from the configuration database.">cfg_db_get_string</a>(db, NULL, cfg, &amp;ret) != FALSE)
<a name="l01102"></a>01102         gtk_entry_set_text(entry, ret);
<a name="l01103"></a>01103 
<a name="l01104"></a>01104     <a class="code" href="configdb_8c.html#a28a8cbf4f7ed7314513ae6922a84d746" title="Closes the configuration database.">cfg_db_close</a>(db);
<a name="l01105"></a>01105 }
<a name="l01106"></a>01106 
<a name="l01107"></a>01107 <span class="keyword">static</span> <span class="keywordtype">void</span>
<a name="l01108"></a><a class="code" href="ui__preferences_8c.html#a3ac1a8c39cba9ec1fda53b692ac8a1a1">01108</a> <a class="code" href="ui__preferences_8c.html#a3ac1a8c39cba9ec1fda53b692ac8a1a1">on_entry_cfg_changed</a>(GtkEntry *<a class="code" href="structentry.html">entry</a>, gchar *<a class="code" href="audconfig_8c.html#a98bd56a064259046a6cc6b1a620badf8">cfg</a>)
<a name="l01109"></a>01109 {
<a name="l01110"></a>01110     mcs_handle_t *<a class="code" href="configdb-api_8h.html#a111075202a831737470faf04df888f59">db</a>;
<a name="l01111"></a>01111     gchar *ret = g_strdup(gtk_entry_get_text(entry));
<a name="l01112"></a>01112 
<a name="l01113"></a>01113     g_return_if_fail(cfg != NULL);
<a name="l01114"></a>01114 
<a name="l01115"></a>01115     db = <a class="code" href="configdb_8c.html#a2bf0784e3c27f6dcf806712382f4093d" title="Opens the configuration database.">cfg_db_open</a>();
<a name="l01116"></a>01116     <a class="code" href="configdb-api_8h.html#a8d56867014d5e405878c52cff1f3a570">cfg_db_set_string</a>(db, NULL, cfg, ret);
<a name="l01117"></a>01117     <a class="code" href="configdb_8c.html#a28a8cbf4f7ed7314513ae6922a84d746" title="Closes the configuration database.">cfg_db_close</a>(db);
<a name="l01118"></a>01118 
<a name="l01119"></a>01119     g_free(ret);
<a name="l01120"></a>01120 }
<a name="l01121"></a>01121 
<a name="l01122"></a>01122 <span class="keyword">static</span> <span class="keywordtype">void</span>
<a name="l01123"></a><a class="code" href="ui__preferences_8c.html#a835ed6302ddd3d75ebf48c4d6eb2b6a2">01123</a> <a class="code" href="ui__preferences_8c.html#a835ed6302ddd3d75ebf48c4d6eb2b6a2">on_cbox_changed_int</a>(GtkComboBox * combobox, PreferencesWidget *widget)
<a name="l01124"></a>01124 {
<a name="l01125"></a>01125     <a class="code" href="misc-api_8h.html#acf599c059f43e0cca83145eb6b0c93cd">gint</a> position = 0;
<a name="l01126"></a>01126 
<a name="l01127"></a>01127     position = gtk_combo_box_get_active(GTK_COMBO_BOX(combobox));
<a name="l01128"></a>01128     *((<a class="code" href="misc-api_8h.html#acf599c059f43e0cca83145eb6b0c93cd">gint</a> *)widget-&gt;cfg) = GPOINTER_TO_INT(widget-&gt;data.combo.elements[position].value);
<a name="l01129"></a>01129 }
<a name="l01130"></a>01130 
<a name="l01131"></a>01131 <span class="keyword">static</span> <span class="keywordtype">void</span>
<a name="l01132"></a><a class="code" href="ui__preferences_8c.html#a83d34c7424ac25af37bf80a0bcdb66bf">01132</a> <a class="code" href="ui__preferences_8c.html#a83d34c7424ac25af37bf80a0bcdb66bf">on_cbox_changed_string</a>(GtkComboBox * combobox, PreferencesWidget *widget)
<a name="l01133"></a>01133 {
<a name="l01134"></a>01134     <a class="code" href="misc-api_8h.html#acf599c059f43e0cca83145eb6b0c93cd">gint</a> position = 0;
<a name="l01135"></a>01135 
<a name="l01136"></a>01136     position = gtk_combo_box_get_active(GTK_COMBO_BOX(combobox));
<a name="l01137"></a>01137     
<a name="l01138"></a>01138     g_free(*((gchar **)widget-&gt;cfg));
<a name="l01139"></a>01139     
<a name="l01140"></a>01140     *((gchar **)widget-&gt;cfg) = g_strdup(widget-&gt;data.combo.elements[position].value);
<a name="l01141"></a>01141 }
<a name="l01142"></a>01142 
<a name="l01143"></a>01143 <span class="keyword">static</span> <span class="keywordtype">void</span>
<a name="l01144"></a><a class="code" href="ui__preferences_8c.html#a22b8e3f9491d3e7fd755f7eeb0bf2b33">01144</a> <a class="code" href="ui__preferences_8c.html#a22b8e3f9491d3e7fd755f7eeb0bf2b33">on_cbox_realize</a>(GtkComboBox *combobox, PreferencesWidget * widget)
<a name="l01145"></a>01145 {
<a name="l01146"></a>01146     guint i=0,<a class="code" href="structindex.html">index</a>=0;
<a name="l01147"></a>01147 
<a name="l01148"></a>01148     <span class="keywordflow">for</span>(i=0; i&lt;widget-&gt;data.combo.n_elements; i++) {
<a name="l01149"></a>01149         gtk_combo_box_append_text(combobox, <a class="code" href="i18n_8h.html#a32a3cf3d9dd914f5aeeca5423c157934">_</a>(widget-&gt;data.combo.elements[i].label));
<a name="l01150"></a>01150     }
<a name="l01151"></a>01151 
<a name="l01152"></a>01152     <span class="keywordflow">if</span> (widget-&gt;data.combo.enabled) {
<a name="l01153"></a>01153         <span class="keywordflow">switch</span> (widget-&gt;cfg_type) {
<a name="l01154"></a>01154             <span class="keywordflow">case</span> <a class="code" href="preferences_8h.html#ad9971b6ef33e02ba2c75d19c1d2518a1aba052e3feaa532e0d8beeb68a3aa6c83">VALUE_INT</a>:
<a name="l01155"></a>01155                 g_signal_connect(combobox, <span class="stringliteral">&quot;changed&quot;</span>,
<a name="l01156"></a>01156                                  G_CALLBACK(<a class="code" href="ui__preferences_8c.html#a835ed6302ddd3d75ebf48c4d6eb2b6a2">on_cbox_changed_int</a>), widget);
<a name="l01157"></a>01157                 <span class="keywordflow">for</span>(i=0; i&lt;widget-&gt;data.combo.n_elements; i++) {
<a name="l01158"></a>01158                     <span class="keywordflow">if</span> (GPOINTER_TO_INT(widget-&gt;data.combo.elements[i].value) == *((<a class="code" href="misc-api_8h.html#acf599c059f43e0cca83145eb6b0c93cd">gint</a> *) widget-&gt;cfg)) {
<a name="l01159"></a>01159                         <a class="code" href="structindex.html">index</a> = i;
<a name="l01160"></a>01160                         <span class="keywordflow">break</span>;
<a name="l01161"></a>01161                     }
<a name="l01162"></a>01162                 }
<a name="l01163"></a>01163                 <span class="keywordflow">break</span>;
<a name="l01164"></a>01164             <span class="keywordflow">case</span> <a class="code" href="preferences_8h.html#ad9971b6ef33e02ba2c75d19c1d2518a1a35da8b8ef95fd9827e1294f400d01c65">VALUE_STRING</a>:
<a name="l01165"></a>01165                 g_signal_connect(combobox, <span class="stringliteral">&quot;changed&quot;</span>,
<a name="l01166"></a>01166                                  G_CALLBACK(<a class="code" href="ui__preferences_8c.html#a83d34c7424ac25af37bf80a0bcdb66bf">on_cbox_changed_string</a>), widget);
<a name="l01167"></a>01167                 <span class="keywordflow">for</span>(i=0; i&lt;widget-&gt;data.combo.n_elements; i++) {
<a name="l01168"></a>01168                     <span class="keywordflow">if</span>(!strcmp((gchar *)widget-&gt;data.combo.elements[i].value, *((gchar **)widget-&gt;cfg))) {
<a name="l01169"></a>01169                         <a class="code" href="structindex.html">index</a> = i;
<a name="l01170"></a>01170                         <span class="keywordflow">break</span>;
<a name="l01171"></a>01171                     }
<a name="l01172"></a>01172                 }
<a name="l01173"></a>01173                 <span class="keywordflow">break</span>;
<a name="l01174"></a>01174             <span class="keywordflow">case</span> <a class="code" href="preferences_8h.html#ad9971b6ef33e02ba2c75d19c1d2518a1a1d95631efa74ba82adcf8eb25caeaacf">VALUE_NULL</a>:
<a name="l01175"></a>01175                 <span class="keywordflow">break</span>;
<a name="l01176"></a>01176             <span class="keywordflow">default</span>:
<a name="l01177"></a>01177                 g_warning(<span class="stringliteral">&quot;Unhandled cbox value type&quot;</span>);
<a name="l01178"></a>01178                 <span class="keywordflow">break</span>;
<a name="l01179"></a>01179         }
<a name="l01180"></a>01180         gtk_combo_box_set_active(GTK_COMBO_BOX(combobox), <a class="code" href="structindex.html">index</a>);
<a name="l01181"></a>01181     } <span class="keywordflow">else</span> {
<a name="l01182"></a>01182         gtk_combo_box_set_active(GTK_COMBO_BOX(combobox), -1);
<a name="l01183"></a>01183         gtk_widget_set_sensitive(GTK_WIDGET(combobox), 0);
<a name="l01184"></a>01184     }
<a name="l01185"></a>01185 }
<a name="l01186"></a>01186 
<a name="l01187"></a>01187 <span class="keywordtype">void</span>
<a name="l01188"></a><a class="code" href="ui__preferences_8c.html#a703cc756e60f4799257eb2d2cf5183ee">01188</a> <a class="code" href="ui__preferences_8c.html#a703cc756e60f4799257eb2d2cf5183ee">create_filepopup_settings</a>(<span class="keywordtype">void</span>)
<a name="l01189"></a>01189 {
<a name="l01190"></a>01190     GtkWidget *vbox;
<a name="l01191"></a>01191     GtkWidget *table;
<a name="l01192"></a>01192 
<a name="l01193"></a>01193     GtkWidget *label_cover_retrieve;
<a name="l01194"></a>01194     GtkWidget *label_cover_search;
<a name="l01195"></a>01195     GtkWidget *label_exclude;
<a name="l01196"></a>01196     GtkWidget *label_include;
<a name="l01197"></a>01197     GtkWidget *label_search_depth;
<a name="l01198"></a>01198     GtkWidget *label_misc;
<a name="l01199"></a>01199     GtkWidget *label_delay;
<a name="l01200"></a>01200 
<a name="l01201"></a>01201     GtkObject *recurse_for_cover_depth_adj;
<a name="l01202"></a>01202     GtkObject *delay_adj;
<a name="l01203"></a>01203     GtkWidget *alignment;
<a name="l01204"></a>01204 
<a name="l01205"></a>01205     GtkWidget *hbox;
<a name="l01206"></a>01206     GtkWidget *hbuttonbox;
<a name="l01207"></a>01207     GtkWidget *btn_cancel;
<a name="l01208"></a>01208     GtkWidget *btn_ok;
<a name="l01209"></a>01209 
<a name="l01210"></a>01210     <a class="code" href="ui__preferences_8c.html#a6af62902a201b816a4038fd2f97481a2">filepopup_settings</a> = gtk_window_new(GTK_WINDOW_TOPLEVEL);
<a name="l01211"></a>01211     gtk_container_set_border_width(GTK_CONTAINER(<a class="code" href="ui__preferences_8c.html#a6af62902a201b816a4038fd2f97481a2">filepopup_settings</a>), 12);
<a name="l01212"></a>01212     gtk_window_set_title(GTK_WINDOW(<a class="code" href="ui__preferences_8c.html#a6af62902a201b816a4038fd2f97481a2">filepopup_settings</a>), <a class="code" href="i18n_8h.html#a32a3cf3d9dd914f5aeeca5423c157934">_</a>(<span class="stringliteral">&quot;Popup Information Settings&quot;</span>));
<a name="l01213"></a>01213     gtk_window_set_position(GTK_WINDOW(<a class="code" href="ui__preferences_8c.html#a6af62902a201b816a4038fd2f97481a2">filepopup_settings</a>), GTK_WIN_POS_CENTER_ON_PARENT);
<a name="l01214"></a>01214     gtk_window_set_skip_taskbar_hint(GTK_WINDOW(<a class="code" href="ui__preferences_8c.html#a6af62902a201b816a4038fd2f97481a2">filepopup_settings</a>), TRUE);
<a name="l01215"></a>01215     gtk_window_set_type_hint(GTK_WINDOW(<a class="code" href="ui__preferences_8c.html#a6af62902a201b816a4038fd2f97481a2">filepopup_settings</a>), GDK_WINDOW_TYPE_HINT_DIALOG);
<a name="l01216"></a>01216     gtk_window_set_transient_for(GTK_WINDOW(<a class="code" href="ui__preferences_8c.html#a6af62902a201b816a4038fd2f97481a2">filepopup_settings</a>), GTK_WINDOW(<a class="code" href="ui__preferences_8c.html#a68dc3d5b54e6e977aedc3ca6a96e92b1">prefswin</a>));
<a name="l01217"></a>01217 
<a name="l01218"></a>01218     vbox = gtk_vbox_new(FALSE, 12);
<a name="l01219"></a>01219     gtk_container_add(GTK_CONTAINER(<a class="code" href="ui__preferences_8c.html#a6af62902a201b816a4038fd2f97481a2">filepopup_settings</a>), vbox);
<a name="l01220"></a>01220 
<a name="l01221"></a>01221     label_cover_retrieve = gtk_label_new(<a class="code" href="i18n_8h.html#a32a3cf3d9dd914f5aeeca5423c157934">_</a>(<span class="stringliteral">&quot;&lt;b&gt;Cover image retrieve&lt;/b&gt;&quot;</span>));
<a name="l01222"></a>01222     gtk_box_pack_start(GTK_BOX(vbox), label_cover_retrieve, FALSE, FALSE, 0);
<a name="l01223"></a>01223     gtk_label_set_use_markup(GTK_LABEL(label_cover_retrieve), TRUE);
<a name="l01224"></a>01224     gtk_misc_set_alignment(GTK_MISC(label_cover_retrieve), 0, 0.5);
<a name="l01225"></a>01225 
<a name="l01226"></a>01226     label_cover_search = gtk_label_new(<a class="code" href="i18n_8h.html#a32a3cf3d9dd914f5aeeca5423c157934">_</a>(<span class="stringliteral">&quot;While searching for the album&#39;s cover, Audacious looks for certain words in the filename. You can specify those words in the lists below, separated using commas.&quot;</span>));
<a name="l01227"></a>01227     gtk_box_pack_start(GTK_BOX(vbox), label_cover_search, FALSE, FALSE, 0);
<a name="l01228"></a>01228     gtk_label_set_line_wrap(GTK_LABEL(label_cover_search), TRUE);
<a name="l01229"></a>01229     gtk_misc_set_alignment(GTK_MISC(label_cover_search), 0, 0);
<a name="l01230"></a>01230     gtk_misc_set_padding(GTK_MISC(label_cover_search), 12, 0);
<a name="l01231"></a>01231 
<a name="l01232"></a>01232     table = gtk_table_new(2, 2, FALSE);
<a name="l01233"></a>01233     gtk_box_pack_start(GTK_BOX(vbox), table, FALSE, FALSE, 0);
<a name="l01234"></a>01234     gtk_table_set_row_spacings(GTK_TABLE(table), 4);
<a name="l01235"></a>01235     gtk_table_set_col_spacings(GTK_TABLE(table), 4);
<a name="l01236"></a>01236 
<a name="l01237"></a>01237     <a class="code" href="ui__preferences_8c.html#aeffefe5b1341092d2bcea93eeb54e6e7">filepopup_settings_cover_name_include</a> = gtk_entry_new();
<a name="l01238"></a>01238     gtk_table_attach(GTK_TABLE(table), <a class="code" href="ui__preferences_8c.html#aeffefe5b1341092d2bcea93eeb54e6e7">filepopup_settings_cover_name_include</a>, 1, 2, 0, 1,
<a name="l01239"></a>01239                      (GtkAttachOptions) (GTK_EXPAND | GTK_FILL),
<a name="l01240"></a>01240                      (GtkAttachOptions) (0), 0, 0);
<a name="l01241"></a>01241     gtk_entry_set_activates_default(GTK_ENTRY(<a class="code" href="ui__preferences_8c.html#aeffefe5b1341092d2bcea93eeb54e6e7">filepopup_settings_cover_name_include</a>), TRUE);
<a name="l01242"></a>01242 
<a name="l01243"></a>01243     label_exclude = gtk_label_new(<a class="code" href="i18n_8h.html#a32a3cf3d9dd914f5aeeca5423c157934">_</a>(<span class="stringliteral">&quot;Exclude:&quot;</span>));
<a name="l01244"></a>01244     gtk_table_attach(GTK_TABLE(table), label_exclude, 0, 1, 1, 2,
<a name="l01245"></a>01245                      (GtkAttachOptions) (0),
<a name="l01246"></a>01246                      (GtkAttachOptions) (0), 0, 0);
<a name="l01247"></a>01247     gtk_misc_set_alignment(GTK_MISC(label_exclude), 0, 0.5);
<a name="l01248"></a>01248     gtk_misc_set_padding(GTK_MISC(label_exclude), 12, 0);
<a name="l01249"></a>01249 
<a name="l01250"></a>01250     label_include = gtk_label_new(<a class="code" href="i18n_8h.html#a32a3cf3d9dd914f5aeeca5423c157934">_</a>(<span class="stringliteral">&quot;Include:&quot;</span>));
<a name="l01251"></a>01251     gtk_table_attach(GTK_TABLE(table), label_include, 0, 1, 0, 1,
<a name="l01252"></a>01252                      (GtkAttachOptions) (0),
<a name="l01253"></a>01253                      (GtkAttachOptions) (0), 0, 0);
<a name="l01254"></a>01254     gtk_misc_set_alignment(GTK_MISC(label_include), 0, 0.5);
<a name="l01255"></a>01255     gtk_misc_set_padding(GTK_MISC(label_include), 12, 0);
<a name="l01256"></a>01256 
<a name="l01257"></a>01257     <a class="code" href="ui__preferences_8c.html#a4916123a9b3c4cd69579f6e2ab05f392">filepopup_settings_cover_name_exclude</a> = gtk_entry_new();
<a name="l01258"></a>01258     gtk_table_attach(GTK_TABLE(table), <a class="code" href="ui__preferences_8c.html#a4916123a9b3c4cd69579f6e2ab05f392">filepopup_settings_cover_name_exclude</a>, 1, 2, 1, 2,
<a name="l01259"></a>01259                      (GtkAttachOptions) (GTK_EXPAND | GTK_FILL),
<a name="l01260"></a>01260                      (GtkAttachOptions) (0), 0, 0);
<a name="l01261"></a>01261     gtk_entry_set_activates_default(GTK_ENTRY(<a class="code" href="ui__preferences_8c.html#a4916123a9b3c4cd69579f6e2ab05f392">filepopup_settings_cover_name_exclude</a>), TRUE);
<a name="l01262"></a>01262 
<a name="l01263"></a>01263     alignment = gtk_alignment_new(0.5, 0.5, 1, 1);
<a name="l01264"></a>01264     gtk_box_pack_start(GTK_BOX(vbox), alignment, TRUE, TRUE, 0);
<a name="l01265"></a>01265     gtk_alignment_set_padding(GTK_ALIGNMENT(alignment), 0, 0, 12, 0);
<a name="l01266"></a>01266 
<a name="l01267"></a>01267     <a class="code" href="ui__preferences_8c.html#a131837372172af9db3fc5d91a5f2aa9b">filepopup_settings_recurse_for_cover</a> = gtk_check_button_new_with_mnemonic(<a class="code" href="i18n_8h.html#a32a3cf3d9dd914f5aeeca5423c157934">_</a>(<span class="stringliteral">&quot;Recursively search for cover&quot;</span>));
<a name="l01268"></a>01268     gtk_container_add(GTK_CONTAINER(alignment), <a class="code" href="ui__preferences_8c.html#a131837372172af9db3fc5d91a5f2aa9b">filepopup_settings_recurse_for_cover</a>);
<a name="l01269"></a>01269 
<a name="l01270"></a>01270     alignment = gtk_alignment_new(0.5, 0.5, 1, 1);
<a name="l01271"></a>01271     gtk_box_pack_start(GTK_BOX(vbox), alignment, FALSE, FALSE, 0);
<a name="l01272"></a>01272     gtk_alignment_set_padding(GTK_ALIGNMENT(alignment), 0, 0, 45, 0);
<a name="l01273"></a>01273 
<a name="l01274"></a>01274     <a class="code" href="ui__preferences_8c.html#a95e4e396181962faab937bb13309a48b">filepopup_settings_recurse_for_cover_depth_box</a> = gtk_hbox_new(FALSE, 0);
<a name="l01275"></a>01275     gtk_container_add(GTK_CONTAINER(alignment), <a class="code" href="ui__preferences_8c.html#a95e4e396181962faab937bb13309a48b">filepopup_settings_recurse_for_cover_depth_box</a>);
<a name="l01276"></a>01276 
<a name="l01277"></a>01277     label_search_depth = gtk_label_new(<a class="code" href="i18n_8h.html#a32a3cf3d9dd914f5aeeca5423c157934">_</a>(<span class="stringliteral">&quot;Search depth: &quot;</span>));
<a name="l01278"></a>01278     gtk_box_pack_start(GTK_BOX(<a class="code" href="ui__preferences_8c.html#a95e4e396181962faab937bb13309a48b">filepopup_settings_recurse_for_cover_depth_box</a>), label_search_depth, TRUE, TRUE, 0);
<a name="l01279"></a>01279     gtk_misc_set_padding(GTK_MISC(label_search_depth), 4, 0);
<a name="l01280"></a>01280 
<a name="l01281"></a>01281     recurse_for_cover_depth_adj = gtk_adjustment_new(0, 0, 100, 1, 10, 0);
<a name="l01282"></a>01282     <a class="code" href="ui__preferences_8c.html#ace3440a4371ba3dd0d53bcc054bb483a">filepopup_settings_recurse_for_cover_depth</a> = gtk_spin_button_new(GTK_ADJUSTMENT(recurse_for_cover_depth_adj), 1, 0);
<a name="l01283"></a>01283     gtk_box_pack_start(GTK_BOX(<a class="code" href="ui__preferences_8c.html#a95e4e396181962faab937bb13309a48b">filepopup_settings_recurse_for_cover_depth_box</a>), <a class="code" href="ui__preferences_8c.html#ace3440a4371ba3dd0d53bcc054bb483a">filepopup_settings_recurse_for_cover_depth</a>, TRUE, TRUE, 0);
<a name="l01284"></a>01284     gtk_spin_button_set_numeric(GTK_SPIN_BUTTON(<a class="code" href="ui__preferences_8c.html#ace3440a4371ba3dd0d53bcc054bb483a">filepopup_settings_recurse_for_cover_depth</a>), TRUE);
<a name="l01285"></a>01285 
<a name="l01286"></a>01286     alignment = gtk_alignment_new(0.5, 0.5, 1, 1);
<a name="l01287"></a>01287     gtk_box_pack_start(GTK_BOX(vbox), alignment, TRUE, TRUE, 0);
<a name="l01288"></a>01288     gtk_alignment_set_padding(GTK_ALIGNMENT(alignment), 0, 0, 12, 0);
<a name="l01289"></a>01289 
<a name="l01290"></a>01290     <a class="code" href="ui__preferences_8c.html#a346148c7cc9fc7f3d713fd1280a6a349">filepopup_settings_use_file_cover</a> = gtk_check_button_new_with_mnemonic(<a class="code" href="i18n_8h.html#a32a3cf3d9dd914f5aeeca5423c157934">_</a>(<span class="stringliteral">&quot;Use per-file cover&quot;</span>));
<a name="l01291"></a>01291     gtk_container_add(GTK_CONTAINER(alignment), <a class="code" href="ui__preferences_8c.html#a346148c7cc9fc7f3d713fd1280a6a349">filepopup_settings_use_file_cover</a>);
<a name="l01292"></a>01292 
<a name="l01293"></a>01293     label_misc = gtk_label_new(<a class="code" href="i18n_8h.html#a32a3cf3d9dd914f5aeeca5423c157934">_</a>(<span class="stringliteral">&quot;&lt;b&gt;Miscellaneous&lt;/b&gt;&quot;</span>));
<a name="l01294"></a>01294     gtk_box_pack_start(GTK_BOX(vbox), label_misc, FALSE, FALSE, 0);
<a name="l01295"></a>01295     gtk_label_set_use_markup(GTK_LABEL(label_misc), TRUE);
<a name="l01296"></a>01296     gtk_misc_set_alignment(GTK_MISC(label_misc), 0, 0.5);
<a name="l01297"></a>01297 
<a name="l01298"></a>01298     alignment = gtk_alignment_new(0.5, 0.5, 1, 1);
<a name="l01299"></a>01299     gtk_box_pack_start(GTK_BOX(vbox), alignment, FALSE, FALSE, 0);
<a name="l01300"></a>01300     gtk_alignment_set_padding(GTK_ALIGNMENT(alignment), 0, 0, 12, 0);
<a name="l01301"></a>01301 
<a name="l01302"></a>01302     <a class="code" href="ui__preferences_8c.html#afd8b57e120943e674216fc2854ca1edb">filepopup_settings_showprogressbar</a> = gtk_check_button_new_with_mnemonic(<a class="code" href="i18n_8h.html#a32a3cf3d9dd914f5aeeca5423c157934">_</a>(<span class="stringliteral">&quot;Show Progress bar for the current track&quot;</span>));
<a name="l01303"></a>01303     gtk_container_add(GTK_CONTAINER(alignment), <a class="code" href="ui__preferences_8c.html#afd8b57e120943e674216fc2854ca1edb">filepopup_settings_showprogressbar</a>);
<a name="l01304"></a>01304 
<a name="l01305"></a>01305     alignment = gtk_alignment_new(0, 0.5, 1, 1);
<a name="l01306"></a>01306     gtk_box_pack_start(GTK_BOX(vbox), alignment, TRUE, TRUE, 0);
<a name="l01307"></a>01307     gtk_alignment_set_padding(GTK_ALIGNMENT(alignment), 0, 0, 12, 0);
<a name="l01308"></a>01308 
<a name="l01309"></a>01309     hbox = gtk_hbox_new(FALSE, 0);
<a name="l01310"></a>01310     gtk_container_add(GTK_CONTAINER(alignment), hbox);
<a name="l01311"></a>01311 
<a name="l01312"></a>01312     label_delay = gtk_label_new(<a class="code" href="i18n_8h.html#a32a3cf3d9dd914f5aeeca5423c157934">_</a>(<span class="stringliteral">&quot;Delay until filepopup comes up: &quot;</span>));
<a name="l01313"></a>01313     gtk_box_pack_start(GTK_BOX(hbox), label_delay, TRUE, TRUE, 0);
<a name="l01314"></a>01314     gtk_misc_set_alignment(GTK_MISC(label_delay), 0, 0.5);
<a name="l01315"></a>01315     gtk_misc_set_padding(GTK_MISC(label_delay), 12, 0);
<a name="l01316"></a>01316 
<a name="l01317"></a>01317     delay_adj = gtk_adjustment_new(0, 0, 100, 1, 10, 0);
<a name="l01318"></a>01318     <a class="code" href="ui__preferences_8c.html#a557d900b62cb289e400d6c124f34a3e4">filepopup_settings_delay</a> = gtk_spin_button_new(GTK_ADJUSTMENT(delay_adj), 1, 0);
<a name="l01319"></a>01319     gtk_box_pack_start(GTK_BOX(hbox), <a class="code" href="ui__preferences_8c.html#a557d900b62cb289e400d6c124f34a3e4">filepopup_settings_delay</a>, TRUE, TRUE, 0);
<a name="l01320"></a>01320     gtk_spin_button_set_numeric(GTK_SPIN_BUTTON(<a class="code" href="ui__preferences_8c.html#a557d900b62cb289e400d6c124f34a3e4">filepopup_settings_delay</a>), TRUE);
<a name="l01321"></a>01321 
<a name="l01322"></a>01322     hbuttonbox = gtk_hbutton_box_new();
<a name="l01323"></a>01323     gtk_box_pack_start(GTK_BOX(vbox), hbuttonbox, FALSE, FALSE, 0);
<a name="l01324"></a>01324     gtk_button_box_set_layout(GTK_BUTTON_BOX(hbuttonbox), GTK_BUTTONBOX_END);
<a name="l01325"></a>01325     gtk_box_set_spacing(GTK_BOX(hbuttonbox), 6);
<a name="l01326"></a>01326 
<a name="l01327"></a>01327     btn_cancel = gtk_button_new_from_stock(<span class="stringliteral">&quot;gtk-cancel&quot;</span>);
<a name="l01328"></a>01328     gtk_container_add(GTK_CONTAINER(hbuttonbox), btn_cancel);
<a name="l01329"></a>01329 
<a name="l01330"></a>01330     btn_ok = gtk_button_new_from_stock(<span class="stringliteral">&quot;gtk-ok&quot;</span>);
<a name="l01331"></a>01331     gtk_container_add(GTK_CONTAINER(hbuttonbox), btn_ok);
<a name="l01332"></a>01332     <a class="code" href="gtk-compat_8h.html#a0b9f0f50ef60efc20b44f8bf8959b13d">gtk_widget_set_can_default</a>(btn_ok, TRUE);
<a name="l01333"></a>01333 
<a name="l01334"></a>01334     g_signal_connect(G_OBJECT(<a class="code" href="ui__preferences_8c.html#a6af62902a201b816a4038fd2f97481a2">filepopup_settings</a>), <span class="stringliteral">&quot;delete_event&quot;</span>,
<a name="l01335"></a>01335                      G_CALLBACK(gtk_widget_hide_on_delete),
<a name="l01336"></a>01336                      NULL);
<a name="l01337"></a>01337     g_signal_connect(G_OBJECT(btn_cancel), <span class="stringliteral">&quot;clicked&quot;</span>,
<a name="l01338"></a>01338                      G_CALLBACK(<a class="code" href="ui__preferences_8c.html#a3b6d36d1a01a13d92936188e549bf558">on_filepopup_settings_cancel_clicked</a>),
<a name="l01339"></a>01339                      NULL);
<a name="l01340"></a>01340     g_signal_connect(G_OBJECT(btn_ok), <span class="stringliteral">&quot;clicked&quot;</span>,
<a name="l01341"></a>01341                      G_CALLBACK(<a class="code" href="ui__preferences_8c.html#a049f8fcd8c932908dc9aab7e1e50d299">on_filepopup_settings_ok_clicked</a>),
<a name="l01342"></a>01342                      NULL);
<a name="l01343"></a>01343     g_signal_connect(G_OBJECT(<a class="code" href="ui__preferences_8c.html#a131837372172af9db3fc5d91a5f2aa9b">filepopup_settings_recurse_for_cover</a>), <span class="stringliteral">&quot;toggled&quot;</span>,
<a name="l01344"></a>01344                      G_CALLBACK(<a class="code" href="ui__preferences_8c.html#af73b7a114e444a037308dfc567aea660">on_recurse_for_cover_toggled</a>),
<a name="l01345"></a>01345                      <a class="code" href="ui__preferences_8c.html#a95e4e396181962faab937bb13309a48b">filepopup_settings_recurse_for_cover_depth_box</a>);
<a name="l01346"></a>01346 
<a name="l01347"></a>01347     gtk_widget_grab_default(btn_ok);
<a name="l01348"></a>01348     gtk_widget_show_all(vbox);
<a name="l01349"></a>01349 }
<a name="l01350"></a>01350 
<a name="l01351"></a><a class="code" href="ui__preferences_8c.html#a059d5794e440abe16f0a180b4293434d">01351</a> <span class="keyword">static</span> <span class="keywordtype">void</span> <a class="code" href="ui__preferences_8c.html#a059d5794e440abe16f0a180b4293434d">create_spin_button</a> (PreferencesWidget * widget, GtkWidget * *
<a name="l01352"></a>01352  label_pre, GtkWidget * * spin_btn, GtkWidget * * label_past, <span class="keyword">const</span> gchar *
<a name="l01353"></a>01353  domain)
<a name="l01354"></a>01354 {
<a name="l01355"></a>01355      g_return_if_fail(widget-&gt;type == <a class="code" href="preferences_8h.html#a7b98518122eb2e94554d2b99d29d1452a507a22559fb8f5293dbe10051781e64f">WIDGET_SPIN_BTN</a>);
<a name="l01356"></a>01356 
<a name="l01357"></a>01357      * label_pre = gtk_label_new (dgettext (domain, widget-&gt;label));
<a name="l01358"></a>01358      gtk_misc_set_alignment(GTK_MISC(*label_pre), 0, 0.5);
<a name="l01359"></a>01359      gtk_misc_set_padding(GTK_MISC(*label_pre), 4, 0);
<a name="l01360"></a>01360 
<a name="l01361"></a>01361      *spin_btn = gtk_spin_button_new_with_range(widget-&gt;data.spin_btn.min,
<a name="l01362"></a>01362                                                 widget-&gt;data.spin_btn.max,
<a name="l01363"></a>01363                                                 widget-&gt;data.spin_btn.step);
<a name="l01364"></a>01364 
<a name="l01365"></a>01365 
<a name="l01366"></a>01366      <span class="keywordflow">if</span> (widget-&gt;tooltip)
<a name="l01367"></a>01367          <a class="code" href="gtk-compat_8h.html#a02918fc213b0f3bbf96b6be74d9bd75c">gtk_widget_set_tooltip_text</a> (* spin_btn, dgettext (domain,
<a name="l01368"></a>01368           widget-&gt;tooltip));
<a name="l01369"></a>01369 
<a name="l01370"></a>01370      <span class="keywordflow">if</span> (widget-&gt;data.spin_btn.right_label) {
<a name="l01371"></a>01371          * label_past = gtk_label_new (dgettext (domain,
<a name="l01372"></a>01372           widget-&gt;data.spin_btn.right_label));
<a name="l01373"></a>01373          gtk_misc_set_alignment(GTK_MISC(*label_past), 0, 0.5);
<a name="l01374"></a>01374          gtk_misc_set_padding(GTK_MISC(*label_past), 4, 0);
<a name="l01375"></a>01375      }
<a name="l01376"></a>01376 
<a name="l01377"></a>01377      <span class="keywordflow">switch</span> (widget-&gt;cfg_type) {
<a name="l01378"></a>01378          <span class="keywordflow">case</span> <a class="code" href="preferences_8h.html#ad9971b6ef33e02ba2c75d19c1d2518a1aba052e3feaa532e0d8beeb68a3aa6c83">VALUE_INT</a>:
<a name="l01379"></a>01379              g_signal_connect(G_OBJECT(*spin_btn), <span class="stringliteral">&quot;value_changed&quot;</span>,
<a name="l01380"></a>01380                               G_CALLBACK(<a class="code" href="ui__preferences_8c.html#abff6a22c3da39455a35100f3ee276484">on_spin_btn_changed_gint</a>),
<a name="l01381"></a>01381                               widget-&gt;cfg);
<a name="l01382"></a>01382              g_signal_connect(G_OBJECT(*spin_btn), <span class="stringliteral">&quot;realize&quot;</span>,
<a name="l01383"></a>01383                               G_CALLBACK(<a class="code" href="ui__preferences_8c.html#aa5eae5e861ac69be718ec37aadbe68b0">on_spin_btn_realize_gint</a>),
<a name="l01384"></a>01384                               widget-&gt;cfg);
<a name="l01385"></a>01385              <span class="keywordflow">break</span>;
<a name="l01386"></a>01386          <span class="keywordflow">case</span> <a class="code" href="preferences_8h.html#ad9971b6ef33e02ba2c75d19c1d2518a1a636cea292b122aac7b4c4e193c4cb92f">VALUE_FLOAT</a>:
<a name="l01387"></a>01387              g_signal_connect(G_OBJECT(*spin_btn), <span class="stringliteral">&quot;value_changed&quot;</span>,
<a name="l01388"></a>01388                               G_CALLBACK(<a class="code" href="ui__preferences_8c.html#adae54771d3b742bac8ffc913ef388e5b">on_spin_btn_changed_gfloat</a>),
<a name="l01389"></a>01389                               widget-&gt;cfg);
<a name="l01390"></a>01390              g_signal_connect(G_OBJECT(*spin_btn), <span class="stringliteral">&quot;realize&quot;</span>,
<a name="l01391"></a>01391                               G_CALLBACK(<a class="code" href="ui__preferences_8c.html#a62e4ae92e2841cfc228d7b83038f797f">on_spin_btn_realize_gfloat</a>),
<a name="l01392"></a>01392                               widget-&gt;cfg);
<a name="l01393"></a>01393              <span class="keywordflow">break</span>;
<a name="l01394"></a>01394          <span class="keywordflow">case</span> <a class="code" href="preferences_8h.html#ad9971b6ef33e02ba2c75d19c1d2518a1a1d95631efa74ba82adcf8eb25caeaacf">VALUE_NULL</a>:
<a name="l01395"></a>01395              <span class="keywordflow">break</span>;
<a name="l01396"></a>01396          <span class="keywordflow">default</span>:
<a name="l01397"></a>01397              g_warning(<span class="stringliteral">&quot;Unsupported value type for spin button&quot;</span>);
<a name="l01398"></a>01398      }
<a name="l01399"></a>01399 }
<a name="l01400"></a>01400 
<a name="l01401"></a><a class="code" href="ui__preferences_8c.html#a5744df64bf082af240d96dcb5f2663f8">01401</a> <span class="keywordtype">void</span> <a class="code" href="ui__preferences_8c.html#a5744df64bf082af240d96dcb5f2663f8">create_font_btn</a> (PreferencesWidget * widget, GtkWidget * * label,
<a name="l01402"></a>01402  GtkWidget * * font_btn, <span class="keyword">const</span> gchar * domain)
<a name="l01403"></a>01403 {
<a name="l01404"></a>01404     *font_btn = gtk_font_button_new();
<a name="l01405"></a>01405     gtk_font_button_set_use_font(GTK_FONT_BUTTON(*font_btn), TRUE);
<a name="l01406"></a>01406     gtk_font_button_set_use_size(GTK_FONT_BUTTON(*font_btn), TRUE);
<a name="l01407"></a>01407     <span class="keywordflow">if</span> (widget-&gt;label) {
<a name="l01408"></a>01408         * label = gtk_label_new_with_mnemonic (dgettext (domain, widget-&gt;label));
<a name="l01409"></a>01409         gtk_label_set_use_markup(GTK_LABEL(*label), TRUE);
<a name="l01410"></a>01410         gtk_misc_set_alignment(GTK_MISC(*label), 1, 0.5);
<a name="l01411"></a>01411         gtk_label_set_justify(GTK_LABEL(*label), GTK_JUSTIFY_RIGHT);
<a name="l01412"></a>01412         gtk_label_set_mnemonic_widget(GTK_LABEL(*label), *font_btn);
<a name="l01413"></a>01413     }
<a name="l01414"></a>01414 
<a name="l01415"></a>01415     <span class="keywordflow">if</span> (widget-&gt;data.font_btn.title)
<a name="l01416"></a>01416         gtk_font_button_set_title (GTK_FONT_BUTTON (* font_btn),
<a name="l01417"></a>01417          dgettext (domain, widget-&gt;data.font_btn.title));
<a name="l01418"></a>01418 
<a name="l01419"></a>01419     g_object_set_data ((GObject *) (* font_btn), <span class="stringliteral">&quot;callback&quot;</span>, (<span class="keywordtype">void</span> *)
<a name="l01420"></a>01420      widget-&gt;callback);
<a name="l01421"></a>01421 
<a name="l01422"></a>01422     g_signal_connect(G_OBJECT(*font_btn), <span class="stringliteral">&quot;font_set&quot;</span>,
<a name="l01423"></a>01423                      G_CALLBACK(<a class="code" href="ui__preferences_8c.html#aeb2b0f54933b222483f89e87d6691931">on_font_btn_font_set</a>),
<a name="l01424"></a>01424                      (gchar**)widget-&gt;cfg);
<a name="l01425"></a>01425     g_signal_connect(G_OBJECT(*font_btn), <span class="stringliteral">&quot;realize&quot;</span>,
<a name="l01426"></a>01426                      G_CALLBACK(<a class="code" href="ui__preferences_8c.html#a1cb540a11dbf0f7a7dda0d24c37f2b7e">on_font_btn_realize</a>),
<a name="l01427"></a>01427                      (gchar**)widget-&gt;cfg);
<a name="l01428"></a>01428 }
<a name="l01429"></a>01429 
<a name="l01430"></a><a class="code" href="ui__preferences_8c.html#a972e38fe17c28c3892007e131a4ded12">01430</a> <span class="keyword">static</span> <span class="keywordtype">void</span> <a class="code" href="ui__preferences_8c.html#a972e38fe17c28c3892007e131a4ded12">create_entry</a> (PreferencesWidget * widget, GtkWidget * * label,
<a name="l01431"></a>01431  GtkWidget * * <a class="code" href="structentry.html">entry</a>, <span class="keyword">const</span> gchar * domain)
<a name="l01432"></a>01432 {
<a name="l01433"></a>01433     *entry = gtk_entry_new();
<a name="l01434"></a>01434     gtk_entry_set_visibility(GTK_ENTRY(*entry), !widget-&gt;data.entry.password);
<a name="l01435"></a>01435 
<a name="l01436"></a>01436     <span class="keywordflow">if</span> (widget-&gt;label)
<a name="l01437"></a>01437         * label = gtk_label_new (dgettext (domain, widget-&gt;label));
<a name="l01438"></a>01438 
<a name="l01439"></a>01439     <span class="keywordflow">if</span> (widget-&gt;tooltip)
<a name="l01440"></a>01440         <a class="code" href="gtk-compat_8h.html#a02918fc213b0f3bbf96b6be74d9bd75c">gtk_widget_set_tooltip_text</a> (* entry, dgettext (domain, widget-&gt;tooltip));
<a name="l01441"></a>01441 
<a name="l01442"></a>01442     g_object_set_data ((GObject *) (* entry), <span class="stringliteral">&quot;callback&quot;</span>, (<span class="keywordtype">void</span> *)
<a name="l01443"></a>01443      widget-&gt;callback);
<a name="l01444"></a>01444 
<a name="l01445"></a>01445     <span class="keywordflow">switch</span> (widget-&gt;cfg_type) {
<a name="l01446"></a>01446         <span class="keywordflow">case</span> <a class="code" href="preferences_8h.html#ad9971b6ef33e02ba2c75d19c1d2518a1a35da8b8ef95fd9827e1294f400d01c65">VALUE_STRING</a>:
<a name="l01447"></a>01447             g_signal_connect(G_OBJECT(*entry), <span class="stringliteral">&quot;realize&quot;</span>,
<a name="l01448"></a>01448                              G_CALLBACK(<a class="code" href="ui__preferences_8c.html#a86586275cbfacf5d92fc1fb6a04e40ee">on_entry_realize</a>),
<a name="l01449"></a>01449                              widget-&gt;cfg);
<a name="l01450"></a>01450             g_signal_connect(G_OBJECT(*entry), <span class="stringliteral">&quot;changed&quot;</span>,
<a name="l01451"></a>01451                              G_CALLBACK(<a class="code" href="ui__preferences_8c.html#ade0080a8259000ae1b4ff102d0864724">on_entry_changed</a>),
<a name="l01452"></a>01452                              widget-&gt;cfg);
<a name="l01453"></a>01453             <span class="keywordflow">break</span>;
<a name="l01454"></a>01454         <span class="keywordflow">case</span> <a class="code" href="preferences_8h.html#ad9971b6ef33e02ba2c75d19c1d2518a1aa2654bf717a1ea21127a2fd0d5c68f93">VALUE_CFG_STRING</a>:
<a name="l01455"></a>01455             g_signal_connect(G_OBJECT(*entry), <span class="stringliteral">&quot;realize&quot;</span>,
<a name="l01456"></a>01456                              G_CALLBACK(<a class="code" href="ui__preferences_8c.html#ac2e5f65556a97a5716a900fdc0f56b59">on_entry_cfg_realize</a>),
<a name="l01457"></a>01457                              widget-&gt;cfg);
<a name="l01458"></a>01458             g_signal_connect(G_OBJECT(*entry), <span class="stringliteral">&quot;changed&quot;</span>,
<a name="l01459"></a>01459                              G_CALLBACK(<a class="code" href="ui__preferences_8c.html#a3ac1a8c39cba9ec1fda53b692ac8a1a1">on_entry_cfg_changed</a>),
<a name="l01460"></a>01460                              widget-&gt;cfg);
<a name="l01461"></a>01461             <span class="keywordflow">break</span>;
<a name="l01462"></a>01462         <span class="keywordflow">default</span>:
<a name="l01463"></a>01463             g_warning(<span class="stringliteral">&quot;Unhandled entry value type %d&quot;</span>, widget-&gt;cfg_type);
<a name="l01464"></a>01464     }
<a name="l01465"></a>01465 }
<a name="l01466"></a>01466 
<a name="l01467"></a><a class="code" href="ui__preferences_8c.html#a3c83ee6067f3cf34da8b15557348da4f">01467</a> <span class="keyword">static</span> <span class="keywordtype">void</span> <a class="code" href="ui__preferences_8c.html#a3c83ee6067f3cf34da8b15557348da4f">create_label</a> (PreferencesWidget * widget, GtkWidget * * label,
<a name="l01468"></a>01468  GtkWidget * * icon, <span class="keyword">const</span> gchar * domain)
<a name="l01469"></a>01469 {
<a name="l01470"></a>01470     <span class="keywordflow">if</span> (widget-&gt;data.label.stock_id)
<a name="l01471"></a>01471         *icon = gtk_image_new_from_stock(widget-&gt;data.label.stock_id, GTK_ICON_SIZE_BUTTON);
<a name="l01472"></a>01472 
<a name="l01473"></a>01473     * label = gtk_label_new_with_mnemonic (dgettext (domain, widget-&gt;label));
<a name="l01474"></a>01474     gtk_label_set_use_markup(GTK_LABEL(*label), TRUE);
<a name="l01475"></a>01475 
<a name="l01476"></a>01476     <span class="keywordflow">if</span> (widget-&gt;data.label.single_line == FALSE)
<a name="l01477"></a>01477         gtk_label_set_line_wrap(GTK_LABEL(*label), TRUE);
<a name="l01478"></a>01478 
<a name="l01479"></a>01479     gtk_misc_set_alignment(GTK_MISC(*label), 0, 0.5);
<a name="l01480"></a>01480 }
<a name="l01481"></a>01481 
<a name="l01482"></a><a class="code" href="ui__preferences_8c.html#a78cfc06741de0ca2871b42eea94cba55">01482</a> <span class="keyword">static</span> <span class="keywordtype">void</span> <a class="code" href="ui__preferences_8c.html#a78cfc06741de0ca2871b42eea94cba55">create_cbox</a> (PreferencesWidget * widget, GtkWidget * * label,
<a name="l01483"></a>01483  GtkWidget * * combobox, <span class="keyword">const</span> gchar * domain)
<a name="l01484"></a>01484 {
<a name="l01485"></a>01485     *combobox = gtk_combo_box_new_text();
<a name="l01486"></a>01486 
<a name="l01487"></a>01487     <span class="keywordflow">if</span> (widget-&gt;label) {
<a name="l01488"></a>01488         * label = gtk_label_new (dgettext (domain, widget-&gt;label));
<a name="l01489"></a>01489         gtk_misc_set_alignment(GTK_MISC(*label), 1, 0.5);
<a name="l01490"></a>01490     }
<a name="l01491"></a>01491 
<a name="l01492"></a>01492     g_signal_connect_after(G_OBJECT(*combobox), <span class="stringliteral">&quot;realize&quot;</span>,
<a name="l01493"></a>01493                            G_CALLBACK(<a class="code" href="ui__preferences_8c.html#a22b8e3f9491d3e7fd755f7eeb0bf2b33">on_cbox_realize</a>),
<a name="l01494"></a>01494                            widget);
<a name="l01495"></a>01495 }
<a name="l01496"></a>01496 
<a name="l01497"></a><a class="code" href="ui__preferences_8c.html#ae136d1d84a5af801fea321c20047a8c5">01497</a> <span class="keyword">static</span> <span class="keywordtype">void</span> <a class="code" href="ui__preferences_8c.html#ae136d1d84a5af801fea321c20047a8c5">fill_table</a> (GtkWidget * table, PreferencesWidget * elements, <a class="code" href="misc-api_8h.html#acf599c059f43e0cca83145eb6b0c93cd">gint</a>
<a name="l01498"></a>01498  amt, <span class="keyword">const</span> gchar * domain)
<a name="l01499"></a>01499 {
<a name="l01500"></a>01500     <a class="code" href="misc-api_8h.html#acf599c059f43e0cca83145eb6b0c93cd">gint</a> x;
<a name="l01501"></a>01501     GtkWidget *widget_left, *widget_middle, *widget_right;
<a name="l01502"></a>01502     GtkAttachOptions middle_policy = (GtkAttachOptions) (0);
<a name="l01503"></a>01503 
<a name="l01504"></a>01504     <span class="keywordflow">for</span> (x = 0; x &lt; amt; ++x) {
<a name="l01505"></a>01505         widget_left = widget_middle = widget_right = NULL;
<a name="l01506"></a>01506         <span class="keywordflow">switch</span> (elements[x].<a class="code" href="plugins-api_8h.html#aadb7c01f728e0e29453ee3c1279b3746">type</a>) {
<a name="l01507"></a>01507             <span class="keywordflow">case</span> <a class="code" href="preferences_8h.html#a7b98518122eb2e94554d2b99d29d1452a507a22559fb8f5293dbe10051781e64f">WIDGET_SPIN_BTN</a>:
<a name="l01508"></a>01508                 <a class="code" href="ui__preferences_8c.html#a059d5794e440abe16f0a180b4293434d">create_spin_button</a> (&amp; elements[x], &amp; widget_left,
<a name="l01509"></a>01509                  &amp; widget_middle, &amp; widget_right, domain);
<a name="l01510"></a>01510                 middle_policy = (GtkAttachOptions) (GTK_FILL);
<a name="l01511"></a>01511                 <span class="keywordflow">break</span>;
<a name="l01512"></a>01512             <span class="keywordflow">case</span> <a class="code" href="preferences_8h.html#a7b98518122eb2e94554d2b99d29d1452a546d7ca530397014266faf6f554e3061">WIDGET_LABEL</a>:
<a name="l01513"></a>01513                 <a class="code" href="ui__preferences_8c.html#a3c83ee6067f3cf34da8b15557348da4f">create_label</a> (&amp; elements[x], &amp; widget_middle, &amp; widget_left,
<a name="l01514"></a>01514                  domain);
<a name="l01515"></a>01515                 middle_policy = (GtkAttachOptions) (GTK_FILL);
<a name="l01516"></a>01516                 <span class="keywordflow">break</span>;
<a name="l01517"></a>01517             <span class="keywordflow">case</span> <a class="code" href="preferences_8h.html#a7b98518122eb2e94554d2b99d29d1452a3b4a52484ae6d4f2aaf9fb73cfbba3c0">WIDGET_FONT_BTN</a>:
<a name="l01518"></a>01518                 <a class="code" href="ui__preferences_8c.html#a5744df64bf082af240d96dcb5f2663f8">create_font_btn</a> (&amp; elements[x], &amp; widget_left, &amp; widget_middle,
<a name="l01519"></a>01519                  domain);
<a name="l01520"></a>01520                 middle_policy = (GtkAttachOptions) (GTK_EXPAND | GTK_FILL);
<a name="l01521"></a>01521                 <span class="keywordflow">break</span>;
<a name="l01522"></a>01522             <span class="keywordflow">case</span> <a class="code" href="preferences_8h.html#a7b98518122eb2e94554d2b99d29d1452a494c57d571e067e24c2db77b86ff7e48">WIDGET_ENTRY</a>:
<a name="l01523"></a>01523                 <a class="code" href="ui__preferences_8c.html#a972e38fe17c28c3892007e131a4ded12">create_entry</a> (&amp; elements[x], &amp; widget_left, &amp; widget_middle,
<a name="l01524"></a>01524                  domain);
<a name="l01525"></a>01525                 middle_policy = (GtkAttachOptions) (GTK_EXPAND | GTK_FILL);
<a name="l01526"></a>01526                 <span class="keywordflow">break</span>;
<a name="l01527"></a>01527             <span class="keywordflow">case</span> <a class="code" href="preferences_8h.html#a7b98518122eb2e94554d2b99d29d1452af92f2abad2182229bda2ad5ed80ec9c4">WIDGET_COMBO_BOX</a>:
<a name="l01528"></a>01528                 <a class="code" href="ui__preferences_8c.html#a78cfc06741de0ca2871b42eea94cba55">create_cbox</a> (&amp; elements[x], &amp; widget_left, &amp; widget_middle,
<a name="l01529"></a>01529                  domain);
<a name="l01530"></a>01530                 middle_policy = (GtkAttachOptions) (GTK_EXPAND | GTK_FILL);
<a name="l01531"></a>01531                 <span class="keywordflow">break</span>;
<a name="l01532"></a>01532             <span class="keywordflow">default</span>:
<a name="l01533"></a>01533                 g_warning(<span class="stringliteral">&quot;Unsupported widget type %d in table&quot;</span>, elements[x].type);
<a name="l01534"></a>01534         }
<a name="l01535"></a>01535 
<a name="l01536"></a>01536         <span class="keywordflow">if</span> (widget_left)
<a name="l01537"></a>01537             gtk_table_attach(GTK_TABLE (table), widget_left, 0, 1, x, x+1,
<a name="l01538"></a>01538                              (GtkAttachOptions) (0),
<a name="l01539"></a>01539                              (GtkAttachOptions) (0), 0, 0);
<a name="l01540"></a>01540 
<a name="l01541"></a>01541         <span class="keywordflow">if</span> (widget_middle)
<a name="l01542"></a>01542             gtk_table_attach(GTK_TABLE(table), widget_middle, 1, widget_right ? 2 : 3, x, x+1,
<a name="l01543"></a>01543                              middle_policy,
<a name="l01544"></a>01544                              (GtkAttachOptions) (0), 4, 0);
<a name="l01545"></a>01545 
<a name="l01546"></a>01546         <span class="keywordflow">if</span> (widget_right)
<a name="l01547"></a>01547             gtk_table_attach(GTK_TABLE(table), widget_right, 2, 3, x, x+1,
<a name="l01548"></a>01548                              (GtkAttachOptions) (0),
<a name="l01549"></a>01549                              (GtkAttachOptions) (0), 0, 0);
<a name="l01550"></a>01550     }
<a name="l01551"></a>01551 }
<a name="l01552"></a>01552 
<a name="l01553"></a>01553 <span class="comment">/* void create_widgets_with_domain (GtkBox * box, PreferencesWidget * widgets,</span>
<a name="l01554"></a>01554 <span class="comment"> gint amt, const gchar * domain) */</span>
<a name="l01555"></a><a class="code" href="ui__preferences_8c.html#aeccb55ecf9cf94bc23b4d6f650f10e80">01555</a> <span class="keywordtype">void</span> <a class="code" href="misc-api_8h.html#a6e0e384e167de274bc9fc2f166708970">create_widgets_with_domain</a> (<span class="keywordtype">void</span> * <a class="code" href="misc-api_8h.html#aa99121ebe9596bae026238336718405e">box</a>, PreferencesWidget * <a class="code" href="misc-api_8h.html#af370da80542a87d66230c3b92711cae1">widgets</a>, <a class="code" href="misc-api_8h.html#acf599c059f43e0cca83145eb6b0c93cd">gint</a>
<a name="l01556"></a>01556  amt, <span class="keyword">const</span> gchar * domain)
<a name="l01557"></a>01557 {
<a name="l01558"></a>01558     <a class="code" href="misc-api_8h.html#acf599c059f43e0cca83145eb6b0c93cd">gint</a> x;
<a name="l01559"></a>01559     GtkWidget *alignment = NULL, *widget = NULL;
<a name="l01560"></a>01560     GtkWidget *child_box = NULL;
<a name="l01561"></a>01561     GSList *radio_btn_group = NULL;
<a name="l01562"></a>01562 
<a name="l01563"></a>01563     <span class="keywordflow">for</span> (x = 0; x &lt; amt; ++x) {
<a name="l01564"></a>01564         <span class="keywordflow">if</span> (widgets[x].child) { <span class="comment">/* perhaps this logic can be better */</span>
<a name="l01565"></a>01565             <span class="keywordflow">if</span> (!child_box) {
<a name="l01566"></a>01566                 child_box = gtk_vbox_new(FALSE, 0);
<a name="l01567"></a>01567                 g_object_set_data(G_OBJECT(widget), <span class="stringliteral">&quot;child&quot;</span>, child_box);
<a name="l01568"></a>01568                 alignment = gtk_alignment_new (0.5, 0.5, 1, 1);
<a name="l01569"></a>01569                 gtk_box_pack_start(box, alignment, FALSE, FALSE, 0);
<a name="l01570"></a>01570                 gtk_alignment_set_padding (GTK_ALIGNMENT (alignment), 0, 0, 24, 0);
<a name="l01571"></a>01571                 gtk_container_add (GTK_CONTAINER (alignment), child_box);
<a name="l01572"></a>01572             }
<a name="l01573"></a>01573         } <span class="keywordflow">else</span>
<a name="l01574"></a>01574             child_box = NULL;
<a name="l01575"></a>01575 
<a name="l01576"></a>01576         alignment = gtk_alignment_new (0.5, 0.5, 1, 1);
<a name="l01577"></a>01577         gtk_box_pack_start(child_box ? GTK_BOX(child_box) : box, alignment, FALSE, FALSE, 0);
<a name="l01578"></a>01578 
<a name="l01579"></a>01579         <span class="keywordflow">if</span> (radio_btn_group &amp;&amp; widgets[x].<a class="code" href="plugins-api_8h.html#aadb7c01f728e0e29453ee3c1279b3746">type</a> != <a class="code" href="preferences_8h.html#a7b98518122eb2e94554d2b99d29d1452ab9de9db8d433704ff7b8babe9b892352">WIDGET_RADIO_BTN</a>)
<a name="l01580"></a>01580             radio_btn_group = NULL;
<a name="l01581"></a>01581 
<a name="l01582"></a>01582         <span class="keywordflow">switch</span>(widgets[x].<a class="code" href="plugins-api_8h.html#aadb7c01f728e0e29453ee3c1279b3746">type</a>) {
<a name="l01583"></a>01583             <span class="keywordflow">case</span> <a class="code" href="preferences_8h.html#a7b98518122eb2e94554d2b99d29d1452a1500c50c7cba34aac0d3e542f716d658">WIDGET_CHK_BTN</a>:
<a name="l01584"></a>01584                 gtk_alignment_set_padding(GTK_ALIGNMENT(alignment), 0, 0, 12, 0);
<a name="l01585"></a>01585                 widget = gtk_check_button_new_with_mnemonic (dgettext (domain,
<a name="l01586"></a>01586                  widgets[x].label));
<a name="l01587"></a>01587                 g_object_set_data ((GObject *) widget, <span class="stringliteral">&quot;callback&quot;</span>,
<a name="l01588"></a>01588                  (<span class="keywordtype">void</span> *) widgets[x].callback);
<a name="l01589"></a>01589 
<a name="l01590"></a>01590                 <span class="keywordflow">if</span> (widgets[x].cfg_type == <a class="code" href="preferences_8h.html#ad9971b6ef33e02ba2c75d19c1d2518a1af66df06f8eda912b1e7f44a27ac33f19">VALUE_CFG_BOOLEAN</a>) {
<a name="l01591"></a>01591                     g_signal_connect(G_OBJECT(widget), <span class="stringliteral">&quot;toggled&quot;</span>,
<a name="l01592"></a>01592                                      G_CALLBACK(<a class="code" href="ui__preferences_8c.html#ac74285e56522f2b36a0db57fbbc02829">on_toggle_button_cfg_toggled</a>),
<a name="l01593"></a>01593                                      widgets[x].<a class="code" href="audconfig_8c.html#a98bd56a064259046a6cc6b1a620badf8">cfg</a>);
<a name="l01594"></a>01594                     g_signal_connect(G_OBJECT(widget), <span class="stringliteral">&quot;realize&quot;</span>,
<a name="l01595"></a>01595                                      G_CALLBACK(<a class="code" href="ui__preferences_8c.html#a34bdf3f3820a480c11e78b059d54b23c">on_toggle_button_cfg_realize</a>),
<a name="l01596"></a>01596                                      widgets[x].cfg);
<a name="l01597"></a>01597                 } <span class="keywordflow">else</span> {
<a name="l01598"></a>01598                     <span class="keywordflow">if</span> (widgets[x].<a class="code" href="audconfig_8c.html#a98bd56a064259046a6cc6b1a620badf8">cfg</a>) {
<a name="l01599"></a>01599                         g_signal_connect(G_OBJECT(widget), <span class="stringliteral">&quot;toggled&quot;</span>,
<a name="l01600"></a>01600                                          G_CALLBACK(<a class="code" href="ui__preferences_8c.html#a95e7218024259e4cc8cf004f2e8d6447">on_toggle_button_toggled</a>),
<a name="l01601"></a>01601                                          widgets[x].cfg);
<a name="l01602"></a>01602                     } <span class="keywordflow">else</span> {
<a name="l01603"></a>01603                         gtk_widget_set_sensitive(widget, FALSE);
<a name="l01604"></a>01604                     }
<a name="l01605"></a>01605                     g_signal_connect(G_OBJECT(widget), <span class="stringliteral">&quot;realize&quot;</span>,
<a name="l01606"></a>01606                                      G_CALLBACK(<a class="code" href="ui__preferences_8c.html#ad86421e267a4c8a3ccd390cf41ee14d9">on_toggle_button_realize</a>),
<a name="l01607"></a>01607                                      widgets[x].cfg);
<a name="l01608"></a>01608                 }
<a name="l01609"></a>01609                 <span class="keywordflow">break</span>;
<a name="l01610"></a>01610             <span class="keywordflow">case</span> <a class="code" href="preferences_8h.html#a7b98518122eb2e94554d2b99d29d1452a546d7ca530397014266faf6f554e3061">WIDGET_LABEL</a>:
<a name="l01611"></a>01611                 gtk_alignment_set_padding(GTK_ALIGNMENT(alignment), 12, 6, 0, 0);
<a name="l01612"></a>01612 
<a name="l01613"></a>01613                 GtkWidget *label = NULL, *icon = NULL;
<a name="l01614"></a>01614                 <a class="code" href="ui__preferences_8c.html#a3c83ee6067f3cf34da8b15557348da4f">create_label</a> (&amp; widgets[x], &amp; label, &amp; icon, domain);
<a name="l01615"></a>01615 
<a name="l01616"></a>01616                 <span class="keywordflow">if</span> (icon == NULL)
<a name="l01617"></a>01617                     widget = label;
<a name="l01618"></a>01618                 <span class="keywordflow">else</span> {
<a name="l01619"></a>01619                     widget = gtk_hbox_new(FALSE, 6);
<a name="l01620"></a>01620                     gtk_box_pack_start(GTK_BOX(widget), icon, FALSE, FALSE, 0);
<a name="l01621"></a>01621                     gtk_box_pack_start(GTK_BOX(widget), label, FALSE, FALSE, 0);
<a name="l01622"></a>01622                 }
<a name="l01623"></a>01623                 <span class="keywordflow">break</span>;
<a name="l01624"></a>01624             <span class="keywordflow">case</span> <a class="code" href="preferences_8h.html#a7b98518122eb2e94554d2b99d29d1452ab9de9db8d433704ff7b8babe9b892352">WIDGET_RADIO_BTN</a>:
<a name="l01625"></a>01625                 gtk_alignment_set_padding(GTK_ALIGNMENT(alignment), 0, 0, 12, 0);
<a name="l01626"></a>01626                 widget = gtk_radio_button_new_with_mnemonic (radio_btn_group,
<a name="l01627"></a>01627                  dgettext (domain, widgets[x].label));
<a name="l01628"></a>01628                 radio_btn_group = gtk_radio_button_get_group (GTK_RADIO_BUTTON (widget));
<a name="l01629"></a>01629                 g_signal_connect(G_OBJECT(widget), <span class="stringliteral">&quot;toggled&quot;</span>,
<a name="l01630"></a>01630                                  G_CALLBACK(<a class="code" href="ui__preferences_8c.html#a95e7218024259e4cc8cf004f2e8d6447">on_toggle_button_toggled</a>),
<a name="l01631"></a>01631                                  widgets[x].<a class="code" href="audconfig_8c.html#a98bd56a064259046a6cc6b1a620badf8">cfg</a>);
<a name="l01632"></a>01632                 g_signal_connect(G_OBJECT(widget), <span class="stringliteral">&quot;realize&quot;</span>,
<a name="l01633"></a>01633                                  G_CALLBACK(<a class="code" href="ui__preferences_8c.html#ad86421e267a4c8a3ccd390cf41ee14d9">on_toggle_button_realize</a>),
<a name="l01634"></a>01634                                  widgets[x].cfg);
<a name="l01635"></a>01635                 <span class="keywordflow">break</span>;
<a name="l01636"></a>01636             <span class="keywordflow">case</span> <a class="code" href="preferences_8h.html#a7b98518122eb2e94554d2b99d29d1452a507a22559fb8f5293dbe10051781e64f">WIDGET_SPIN_BTN</a>:
<a name="l01637"></a>01637                 gtk_alignment_set_padding (GTK_ALIGNMENT (alignment), 6, 0, 12, 0);
<a name="l01638"></a>01638 
<a name="l01639"></a>01639                 widget = gtk_hbox_new(FALSE, 6);
<a name="l01640"></a>01640 
<a name="l01641"></a>01641                 GtkWidget *label_pre = NULL, *spin_btn = NULL, *label_past = NULL;
<a name="l01642"></a>01642                 <a class="code" href="ui__preferences_8c.html#a059d5794e440abe16f0a180b4293434d">create_spin_button</a> (&amp; widgets[x], &amp; label_pre, &amp; spin_btn,
<a name="l01643"></a>01643                  &amp; label_past, domain);
<a name="l01644"></a>01644 
<a name="l01645"></a>01645                 <span class="keywordflow">if</span> (label_pre)
<a name="l01646"></a>01646                     gtk_box_pack_start(GTK_BOX(widget), label_pre, FALSE, FALSE, 0);
<a name="l01647"></a>01647                 <span class="keywordflow">if</span> (spin_btn)
<a name="l01648"></a>01648                     gtk_box_pack_start(GTK_BOX(widget), spin_btn, FALSE, FALSE, 0);
<a name="l01649"></a>01649                 <span class="keywordflow">if</span> (label_past)
<a name="l01650"></a>01650                     gtk_box_pack_start(GTK_BOX(widget), label_past, FALSE, FALSE, 0);
<a name="l01651"></a>01651 
<a name="l01652"></a>01652                 <span class="keywordflow">break</span>;
<a name="l01653"></a>01653             <span class="keywordflow">case</span> <a class="code" href="preferences_8h.html#a7b98518122eb2e94554d2b99d29d1452ab06ba654e370d62a33e9faa9c730fa24">WIDGET_CUSTOM</a>:  <span class="comment">/* custom widget. --nenolod */</span>
<a name="l01654"></a>01654                 <span class="keywordflow">if</span> (widgets[x].<a class="code" href="misc-api_8h.html#a2a40119722f785a93d720b769541a543">data</a>.populate)
<a name="l01655"></a>01655                     widget = widgets[x].data.populate();
<a name="l01656"></a>01656                 <span class="keywordflow">else</span>
<a name="l01657"></a>01657                     widget = NULL;
<a name="l01658"></a>01658 
<a name="l01659"></a>01659                 <span class="keywordflow">break</span>;
<a name="l01660"></a>01660             <span class="keywordflow">case</span> <a class="code" href="preferences_8h.html#a7b98518122eb2e94554d2b99d29d1452a3b4a52484ae6d4f2aaf9fb73cfbba3c0">WIDGET_FONT_BTN</a>:
<a name="l01661"></a>01661                 gtk_alignment_set_padding (GTK_ALIGNMENT (alignment), 0, 0, 12, 0);
<a name="l01662"></a>01662 
<a name="l01663"></a>01663                 widget = gtk_hbox_new(FALSE, 6);
<a name="l01664"></a>01664 
<a name="l01665"></a>01665                 GtkWidget *font_btn = NULL;
<a name="l01666"></a>01666                 <a class="code" href="ui__preferences_8c.html#a5744df64bf082af240d96dcb5f2663f8">create_font_btn</a> (&amp; widgets[x], &amp; label, &amp; font_btn, domain);
<a name="l01667"></a>01667 
<a name="l01668"></a>01668                 <span class="keywordflow">if</span> (label)
<a name="l01669"></a>01669                     gtk_box_pack_start(GTK_BOX(widget), label, FALSE, FALSE, 0);
<a name="l01670"></a>01670                 <span class="keywordflow">if</span> (font_btn)
<a name="l01671"></a>01671                     gtk_box_pack_start(GTK_BOX(widget), font_btn, FALSE, FALSE, 0);
<a name="l01672"></a>01672                 <span class="keywordflow">break</span>;
<a name="l01673"></a>01673             <span class="keywordflow">case</span> <a class="code" href="preferences_8h.html#a7b98518122eb2e94554d2b99d29d1452ac9de46f3888daabbe74a9dbd477861ab">WIDGET_TABLE</a>:
<a name="l01674"></a>01674                 gtk_alignment_set_padding (GTK_ALIGNMENT (alignment), 0, 0, 12, 0);
<a name="l01675"></a>01675 
<a name="l01676"></a>01676                 widget = gtk_table_new(widgets[x].<a class="code" href="misc-api_8h.html#a2a40119722f785a93d720b769541a543">data</a>.table.rows, 3, FALSE);
<a name="l01677"></a>01677                 <a class="code" href="ui__preferences_8c.html#ae136d1d84a5af801fea321c20047a8c5">fill_table</a> (widget, widgets[x].<a class="code" href="misc-api_8h.html#a2a40119722f785a93d720b769541a543">data</a>.table.elem,
<a name="l01678"></a>01678                  widgets[x].data.table.rows, domain);
<a name="l01679"></a>01679                 gtk_table_set_row_spacings(GTK_TABLE(widget), 6);
<a name="l01680"></a>01680                 <span class="keywordflow">break</span>;
<a name="l01681"></a>01681             <span class="keywordflow">case</span> <a class="code" href="preferences_8h.html#a7b98518122eb2e94554d2b99d29d1452a494c57d571e067e24c2db77b86ff7e48">WIDGET_ENTRY</a>:
<a name="l01682"></a>01682                 gtk_alignment_set_padding (GTK_ALIGNMENT (alignment), 6, 0, 6, 12);
<a name="l01683"></a>01683 
<a name="l01684"></a>01684                 widget = gtk_hbox_new(FALSE, 6);
<a name="l01685"></a>01685 
<a name="l01686"></a>01686                 GtkWidget *<a class="code" href="structentry.html">entry</a> = NULL;
<a name="l01687"></a>01687                 <a class="code" href="ui__preferences_8c.html#a972e38fe17c28c3892007e131a4ded12">create_entry</a> (&amp; widgets[x], &amp; label, &amp; entry, domain);
<a name="l01688"></a>01688 
<a name="l01689"></a>01689                 <span class="keywordflow">if</span> (label)
<a name="l01690"></a>01690                     gtk_box_pack_start(GTK_BOX(widget), label, FALSE, FALSE, 0);
<a name="l01691"></a>01691                 <span class="keywordflow">if</span> (entry)
<a name="l01692"></a>01692                     gtk_box_pack_start(GTK_BOX(widget), entry, TRUE, TRUE, 0);
<a name="l01693"></a>01693                 <span class="keywordflow">break</span>;
<a name="l01694"></a>01694             <span class="keywordflow">case</span> <a class="code" href="preferences_8h.html#a7b98518122eb2e94554d2b99d29d1452af92f2abad2182229bda2ad5ed80ec9c4">WIDGET_COMBO_BOX</a>:
<a name="l01695"></a>01695                 gtk_alignment_set_padding (GTK_ALIGNMENT (alignment), 0, 0, 12, 0);
<a name="l01696"></a>01696 
<a name="l01697"></a>01697                 widget = gtk_hbox_new(FALSE, 10);
<a name="l01698"></a>01698 
<a name="l01699"></a>01699                 GtkWidget *combo = NULL;
<a name="l01700"></a>01700                 <a class="code" href="ui__preferences_8c.html#a78cfc06741de0ca2871b42eea94cba55">create_cbox</a> (&amp; widgets[x], &amp; label, &amp; combo, domain);
<a name="l01701"></a>01701 
<a name="l01702"></a>01702                 <span class="keywordflow">if</span> (label)
<a name="l01703"></a>01703                     gtk_box_pack_start(GTK_BOX(widget), label, FALSE, FALSE, 0);
<a name="l01704"></a>01704                 <span class="keywordflow">if</span> (combo)
<a name="l01705"></a>01705                     gtk_box_pack_start(GTK_BOX(widget), combo, FALSE, FALSE, 0);
<a name="l01706"></a>01706                 <span class="keywordflow">break</span>;
<a name="l01707"></a>01707             <span class="keywordflow">case</span> <a class="code" href="preferences_8h.html#a7b98518122eb2e94554d2b99d29d1452a905ea6cef9107a59ddbb2aa324d00972">WIDGET_BOX</a>:
<a name="l01708"></a>01708                 gtk_alignment_set_padding (GTK_ALIGNMENT (alignment), 0, 0, 3, 0);
<a name="l01709"></a>01709 
<a name="l01710"></a>01710                 <span class="keywordflow">if</span> (widgets[x].<a class="code" href="misc-api_8h.html#a2a40119722f785a93d720b769541a543">data</a>.box.horizontal) {
<a name="l01711"></a>01711                     widget = gtk_hbox_new(FALSE, 0);
<a name="l01712"></a>01712                 } <span class="keywordflow">else</span> {
<a name="l01713"></a>01713                     widget = gtk_vbox_new(FALSE, 0);
<a name="l01714"></a>01714                 }
<a name="l01715"></a>01715 
<a name="l01716"></a>01716                 create_widgets(GTK_BOX(widget), widgets[x].<a class="code" href="misc-api_8h.html#a2a40119722f785a93d720b769541a543">data</a>.box.elem, widgets[x].data.box.n_elem);
<a name="l01717"></a>01717 
<a name="l01718"></a>01718                 <span class="keywordflow">if</span> (widgets[x].<a class="code" href="misc-api_8h.html#a2a40119722f785a93d720b769541a543">data</a>.box.frame) {
<a name="l01719"></a>01719                     GtkWidget *tmp;
<a name="l01720"></a>01720                     tmp = widget;
<a name="l01721"></a>01721 
<a name="l01722"></a>01722                     widget = gtk_frame_new (dgettext (domain, widgets[x].label));
<a name="l01723"></a>01723                     gtk_container_add(GTK_CONTAINER(widget), tmp);
<a name="l01724"></a>01724                 }
<a name="l01725"></a>01725                 <span class="keywordflow">break</span>;
<a name="l01726"></a>01726             <span class="keywordflow">case</span> <a class="code" href="preferences_8h.html#a7b98518122eb2e94554d2b99d29d1452a24a6a929981daaa788d575f36c9ce579">WIDGET_NOTEBOOK</a>:
<a name="l01727"></a>01727                 gtk_alignment_set_padding (GTK_ALIGNMENT (alignment), 0, 0, 3, 0);
<a name="l01728"></a>01728 
<a name="l01729"></a>01729                 widget = gtk_notebook_new();
<a name="l01730"></a>01730 
<a name="l01731"></a>01731                 <a class="code" href="misc-api_8h.html#acf599c059f43e0cca83145eb6b0c93cd">gint</a> i;
<a name="l01732"></a>01732                 <span class="keywordflow">for</span> (i = 0; i&lt;widgets[x].data.notebook.n_tabs; i++) {
<a name="l01733"></a>01733                     GtkWidget *vbox;
<a name="l01734"></a>01734                     vbox = gtk_vbox_new(FALSE, 5);
<a name="l01735"></a>01735                     create_widgets(GTK_BOX(vbox), widgets[x].<a class="code" href="misc-api_8h.html#a2a40119722f785a93d720b769541a543">data</a>.notebook.tabs[i].settings, widgets[x].data.notebook.tabs[i].n_settings);
<a name="l01736"></a>01736 
<a name="l01737"></a>01737                     gtk_notebook_append_page (GTK_NOTEBOOK (widget), vbox,
<a name="l01738"></a>01738                      gtk_label_new (dgettext (domain,
<a name="l01739"></a>01739                      widgets[x].<a class="code" href="misc-api_8h.html#a2a40119722f785a93d720b769541a543">data</a>.notebook.tabs[i].name)));
<a name="l01740"></a>01740                 }
<a name="l01741"></a>01741                 <span class="keywordflow">break</span>;
<a name="l01742"></a>01742             <span class="keywordflow">case</span> <a class="code" href="preferences_8h.html#a7b98518122eb2e94554d2b99d29d1452a498ceb442e0cc612a26a6db28e3932cc">WIDGET_SEPARATOR</a>:
<a name="l01743"></a>01743                 gtk_alignment_set_padding (GTK_ALIGNMENT (alignment), 6, 6, 0, 0);
<a name="l01744"></a>01744 
<a name="l01745"></a>01745                 <span class="keywordflow">if</span> (widgets[x].<a class="code" href="misc-api_8h.html#a2a40119722f785a93d720b769541a543">data</a>.separator.horizontal == TRUE) {
<a name="l01746"></a>01746                     widget = gtk_hseparator_new();
<a name="l01747"></a>01747                 } <span class="keywordflow">else</span> {
<a name="l01748"></a>01748                     widget = gtk_vseparator_new();
<a name="l01749"></a>01749                 }
<a name="l01750"></a>01750                 <span class="keywordflow">break</span>;
<a name="l01751"></a>01751             <span class="keywordflow">default</span>:
<a name="l01752"></a>01752                 <span class="comment">/* shouldn&#39;t ever happen - expect things to break */</span>
<a name="l01753"></a>01753                 g_error(<span class="stringliteral">&quot;This shouldn&#39;t ever happen - expect things to break.&quot;</span>);
<a name="l01754"></a>01754                 <span class="keywordflow">continue</span>;
<a name="l01755"></a>01755         }
<a name="l01756"></a>01756 
<a name="l01757"></a>01757         <span class="keywordflow">if</span> (widget &amp;&amp; !gtk_widget_get_parent(widget))
<a name="l01758"></a>01758             gtk_container_add(GTK_CONTAINER(alignment), widget);
<a name="l01759"></a>01759         <span class="keywordflow">if</span> (widget &amp;&amp; widgets[x].tooltip &amp;&amp; widgets[x].type != <a class="code" href="preferences_8h.html#a7b98518122eb2e94554d2b99d29d1452a507a22559fb8f5293dbe10051781e64f">WIDGET_SPIN_BTN</a>)
<a name="l01760"></a>01760             <a class="code" href="gtk-compat_8h.html#a02918fc213b0f3bbf96b6be74d9bd75c">gtk_widget_set_tooltip_text</a> (widget, dgettext (domain,
<a name="l01761"></a>01761              widgets[x].tooltip));
<a name="l01762"></a>01762     }
<a name="l01763"></a>01763 
<a name="l01764"></a>01764 }
<a name="l01765"></a>01765 
<a name="l01766"></a>01766 <span class="keyword">static</span> GtkWidget *
<a name="l01767"></a><a class="code" href="ui__preferences_8c.html#aae18119add5470912daf5e9c97566295">01767</a> <a class="code" href="ui__preferences_8c.html#aae18119add5470912daf5e9c97566295">create_titlestring_tag_menu</a>(<span class="keywordtype">void</span>)
<a name="l01768"></a>01768 {
<a name="l01769"></a>01769     GtkWidget *titlestring_tag_menu, *menu_item;
<a name="l01770"></a>01770     guint i;
<a name="l01771"></a>01771 
<a name="l01772"></a>01772     titlestring_tag_menu = gtk_menu_new();
<a name="l01773"></a>01773     <span class="keywordflow">for</span>(i = 0; i &lt; <a class="code" href="ui__preferences_8c.html#af4fd0a20dbb4a65972bc5f4f51c373a8">n_title_field_tags</a>; i++) {
<a name="l01774"></a>01774         menu_item = gtk_menu_item_new_with_label(<a class="code" href="i18n_8h.html#a32a3cf3d9dd914f5aeeca5423c157934">_</a>(title_field_tags[i].name));
<a name="l01775"></a>01775         gtk_menu_shell_append(GTK_MENU_SHELL(titlestring_tag_menu), menu_item);
<a name="l01776"></a>01776         g_signal_connect(menu_item, <span class="stringliteral">&quot;activate&quot;</span>,
<a name="l01777"></a>01777                          G_CALLBACK(<a class="code" href="ui__preferences_8c.html#a08973cd6329d02bf8bfbad71cfa7de74">titlestring_tag_menu_callback</a>),
<a name="l01778"></a>01778                          GINT_TO_POINTER(i));
<a name="l01779"></a>01779     };
<a name="l01780"></a>01780     gtk_widget_show_all(titlestring_tag_menu);
<a name="l01781"></a>01781 
<a name="l01782"></a>01782     <span class="keywordflow">return</span> titlestring_tag_menu;
<a name="l01783"></a>01783 }
<a name="l01784"></a>01784 
<a name="l01785"></a>01785 <span class="keyword">static</span> <span class="keywordtype">void</span>
<a name="l01786"></a><a class="code" href="ui__preferences_8c.html#a29917a569770ad3a83e0ea58d75a7ea3">01786</a> <a class="code" href="ui__preferences_8c.html#a29917a569770ad3a83e0ea58d75a7ea3">create_playback_category</a>(<span class="keywordtype">void</span>)
<a name="l01787"></a>01787 {
<a name="l01788"></a>01788     GtkWidget *playback_page_vbox;
<a name="l01789"></a>01789     GtkWidget *widgets_vbox;
<a name="l01790"></a>01790 
<a name="l01791"></a>01791     playback_page_vbox = gtk_vbox_new (FALSE, 0);
<a name="l01792"></a>01792     gtk_container_add (GTK_CONTAINER (<a class="code" href="ui__preferences_8c.html#a5c1d2afa8759c0f574e9ac02dcd695f8">category_notebook</a>), playback_page_vbox);
<a name="l01793"></a>01793 
<a name="l01794"></a>01794     widgets_vbox = gtk_vbox_new (FALSE, 0);
<a name="l01795"></a>01795     create_widgets(GTK_BOX(widgets_vbox), <a class="code" href="ui__preferences_8c.html#a3aec073b5ab620c9688852feb5069538">playback_page_widgets</a>, G_N_ELEMENTS(<a class="code" href="ui__preferences_8c.html#a3aec073b5ab620c9688852feb5069538">playback_page_widgets</a>));
<a name="l01796"></a>01796     gtk_box_pack_start (GTK_BOX (playback_page_vbox), widgets_vbox, TRUE, TRUE, 0);
<a name="l01797"></a>01797 }
<a name="l01798"></a>01798 
<a name="l01799"></a>01799 <span class="keyword">static</span> <span class="keywordtype">void</span>
<a name="l01800"></a><a class="code" href="ui__preferences_8c.html#a8271be432b813265f2796df55a95a6ab">01800</a> <a class="code" href="ui__preferences_8c.html#a8271be432b813265f2796df55a95a6ab">create_replay_gain_category</a>(<span class="keywordtype">void</span>)
<a name="l01801"></a>01801 {
<a name="l01802"></a>01802     GtkWidget *rg_page_vbox;
<a name="l01803"></a>01803     GtkWidget *widgets_vbox;
<a name="l01804"></a>01804 
<a name="l01805"></a>01805     rg_page_vbox = gtk_vbox_new (FALSE, 0);
<a name="l01806"></a>01806     gtk_container_add (GTK_CONTAINER (<a class="code" href="ui__preferences_8c.html#a5c1d2afa8759c0f574e9ac02dcd695f8">category_notebook</a>), rg_page_vbox);
<a name="l01807"></a>01807 
<a name="l01808"></a>01808     widgets_vbox = gtk_vbox_new (FALSE, 0);
<a name="l01809"></a>01809     create_widgets(GTK_BOX(widgets_vbox), <a class="code" href="ui__preferences_8c.html#aee27d4fb743ba829f98fa99911391dba">replay_gain_page_widgets</a>, G_N_ELEMENTS(<a class="code" href="ui__preferences_8c.html#aee27d4fb743ba829f98fa99911391dba">replay_gain_page_widgets</a>));
<a name="l01810"></a>01810     gtk_box_pack_start (GTK_BOX (rg_page_vbox), widgets_vbox, TRUE, TRUE, 0);
<a name="l01811"></a>01811 }
<a name="l01812"></a>01812 
<a name="l01813"></a><a class="code" href="ui__preferences_8c.html#a1934b77890e06a9d1a7b4d989a78873a">01813</a> <span class="keyword">static</span> <span class="keywordtype">void</span> <a class="code" href="ui__preferences_8c.html#a1934b77890e06a9d1a7b4d989a78873a">show_numbers_cb</a> (GtkToggleButton * numbers, <span class="keywordtype">void</span> * unused)
<a name="l01814"></a>01814 {
<a name="l01815"></a>01815     <a class="code" href="audconfig_8c.html#a98bd56a064259046a6cc6b1a620badf8">cfg</a>.show_numbers_in_pl = gtk_toggle_button_get_active (numbers);
<a name="l01816"></a>01816 
<a name="l01817"></a>01817     <a class="code" href="hook_8c.html#a2db1ccd2efbd82b151393e3aedd42550">hook_call</a> (<span class="stringliteral">&quot;playlist update&quot;</span>, NULL);
<a name="l01818"></a>01818     <a class="code" href="hook_8c.html#a2db1ccd2efbd82b151393e3aedd42550">hook_call</a> (<span class="stringliteral">&quot;title change&quot;</span>, NULL);
<a name="l01819"></a>01819 }
<a name="l01820"></a>01820 
<a name="l01821"></a>01821 <span class="keyword">static</span> <span class="keywordtype">void</span>
<a name="l01822"></a><a class="code" href="ui__preferences_8c.html#a5b35d777746ba3b1aa1d943ca268a6b4">01822</a> <a class="code" href="ui__preferences_8c.html#a5b35d777746ba3b1aa1d943ca268a6b4">create_playlist_category</a>(<span class="keywordtype">void</span>)
<a name="l01823"></a>01823 {
<a name="l01824"></a>01824     GtkWidget *playlist_page_vbox;
<a name="l01825"></a>01825     GtkWidget *vbox5;
<a name="l01826"></a>01826     GtkWidget *alignment55;
<a name="l01827"></a>01827     GtkWidget *label60;
<a name="l01828"></a>01828     GtkWidget *alignment56;
<a name="l01829"></a>01829     GtkWidget *table6;
<a name="l01830"></a>01830     GtkWidget *titlestring_help_button;
<a name="l01831"></a>01831     GtkWidget *image1;
<a name="l01832"></a>01832     GtkWidget *titlestring_cbox;
<a name="l01833"></a>01833     GtkWidget *label62;
<a name="l01834"></a>01834     GtkWidget *label61;
<a name="l01835"></a>01835     GtkWidget *alignment85;
<a name="l01836"></a>01836     GtkWidget *label84;
<a name="l01837"></a>01837     GtkWidget *alignment86;
<a name="l01838"></a>01838     GtkWidget *hbox9;
<a name="l01839"></a>01839     GtkWidget *vbox34;
<a name="l01840"></a>01840     GtkWidget *checkbutton10;
<a name="l01841"></a>01841     GtkWidget *image8;
<a name="l01842"></a>01842     GtkWidget *titlestring_tag_menu = <a class="code" href="ui__preferences_8c.html#aae18119add5470912daf5e9c97566295">create_titlestring_tag_menu</a>();
<a name="l01843"></a>01843     GtkWidget * numbers_alignment, * numbers;
<a name="l01844"></a>01844 
<a name="l01845"></a>01845     playlist_page_vbox = gtk_vbox_new (FALSE, 0);
<a name="l01846"></a>01846     gtk_container_add (GTK_CONTAINER (<a class="code" href="ui__preferences_8c.html#a5c1d2afa8759c0f574e9ac02dcd695f8">category_notebook</a>), playlist_page_vbox);
<a name="l01847"></a>01847 
<a name="l01848"></a>01848     vbox5 = gtk_vbox_new (FALSE, 0);
<a name="l01849"></a>01849     gtk_box_pack_start (GTK_BOX (playlist_page_vbox), vbox5, TRUE, TRUE, 0);
<a name="l01850"></a>01850 
<a name="l01851"></a>01851     create_widgets(GTK_BOX(vbox5), <a class="code" href="ui__preferences_8c.html#a79cfe8200657a5a8dee1014f3d033aed">playlist_page_widgets</a>, G_N_ELEMENTS(<a class="code" href="ui__preferences_8c.html#a79cfe8200657a5a8dee1014f3d033aed">playlist_page_widgets</a>));
<a name="l01852"></a>01852 
<a name="l01853"></a>01853     alignment55 = gtk_alignment_new (0.5, 0.5, 1, 1);
<a name="l01854"></a>01854     gtk_box_pack_start (GTK_BOX (vbox5), alignment55, FALSE, FALSE, 0);
<a name="l01855"></a>01855     gtk_alignment_set_padding ((GtkAlignment *) alignment55, 12, 3, 0, 0);
<a name="l01856"></a>01856 
<a name="l01857"></a>01857     label60 = gtk_label_new (<a class="code" href="i18n_8h.html#a32a3cf3d9dd914f5aeeca5423c157934">_</a>(<span class="stringliteral">&quot;&lt;b&gt;Song Display&lt;/b&gt;&quot;</span>));
<a name="l01858"></a>01858     gtk_container_add (GTK_CONTAINER (alignment55), label60);
<a name="l01859"></a>01859     gtk_label_set_use_markup (GTK_LABEL (label60), TRUE);
<a name="l01860"></a>01860     gtk_misc_set_alignment (GTK_MISC (label60), 0, 0.5);
<a name="l01861"></a>01861 
<a name="l01862"></a>01862     numbers_alignment = gtk_alignment_new (0, 0, 0, 0);
<a name="l01863"></a>01863     gtk_alignment_set_padding ((GtkAlignment *) numbers_alignment, 0, 0, 12, 0);
<a name="l01864"></a>01864     gtk_box_pack_start ((GtkBox *) vbox5, numbers_alignment, 0, 0, 3);
<a name="l01865"></a>01865 
<a name="l01866"></a>01866     numbers = gtk_check_button_new_with_label (<a class="code" href="i18n_8h.html#a32a3cf3d9dd914f5aeeca5423c157934">_</a>(<span class="stringliteral">&quot;Show song numbers&quot;</span>));
<a name="l01867"></a>01867     gtk_toggle_button_set_active ((GtkToggleButton *) numbers,
<a name="l01868"></a>01868      <a class="code" href="audconfig_8c.html#a98bd56a064259046a6cc6b1a620badf8">cfg</a>.show_numbers_in_pl);
<a name="l01869"></a>01869     g_signal_connect ((GObject *) numbers, <span class="stringliteral">&quot;toggled&quot;</span>, (GCallback)
<a name="l01870"></a>01870      <a class="code" href="ui__preferences_8c.html#a1934b77890e06a9d1a7b4d989a78873a">show_numbers_cb</a>, 0);
<a name="l01871"></a>01871     gtk_container_add ((GtkContainer *) numbers_alignment, numbers);
<a name="l01872"></a>01872 
<a name="l01873"></a>01873     alignment56 = gtk_alignment_new (0.5, 0.5, 1, 1);
<a name="l01874"></a>01874     gtk_box_pack_start (GTK_BOX (vbox5), alignment56, FALSE, FALSE, 0);
<a name="l01875"></a>01875     gtk_alignment_set_padding (GTK_ALIGNMENT (alignment56), 0, 0, 12, 0);
<a name="l01876"></a>01876 
<a name="l01877"></a>01877     table6 = gtk_table_new (2, 3, FALSE);
<a name="l01878"></a>01878     gtk_container_add (GTK_CONTAINER (alignment56), table6);
<a name="l01879"></a>01879     gtk_table_set_row_spacings (GTK_TABLE (table6), 4);
<a name="l01880"></a>01880     gtk_table_set_col_spacings (GTK_TABLE (table6), 12);
<a name="l01881"></a>01881 
<a name="l01882"></a>01882     titlestring_help_button = gtk_button_new ();
<a name="l01883"></a>01883     gtk_table_attach (GTK_TABLE (table6), titlestring_help_button, 2, 3, 1, 2,
<a name="l01884"></a>01884                       (GtkAttachOptions) (0),
<a name="l01885"></a>01885                       (GtkAttachOptions) (0), 0, 0);
<a name="l01886"></a>01886 
<a name="l01887"></a>01887     <a class="code" href="gtk-compat_8h.html#a9e38319a819b04877eb4df141de6881f">gtk_widget_set_can_focus</a> (titlestring_help_button, FALSE);
<a name="l01888"></a>01888     <a class="code" href="gtk-compat_8h.html#a02918fc213b0f3bbf96b6be74d9bd75c">gtk_widget_set_tooltip_text</a> (titlestring_help_button, <a class="code" href="i18n_8h.html#a32a3cf3d9dd914f5aeeca5423c157934">_</a>(<span class="stringliteral">&quot;Show information about titlestring format&quot;</span>));
<a name="l01889"></a>01889     gtk_button_set_relief (GTK_BUTTON (titlestring_help_button), GTK_RELIEF_HALF);
<a name="l01890"></a>01890     gtk_button_set_focus_on_click (GTK_BUTTON (titlestring_help_button), FALSE);
<a name="l01891"></a>01891 
<a name="l01892"></a>01892     image1 = gtk_image_new_from_stock (<span class="stringliteral">&quot;gtk-index&quot;</span>, GTK_ICON_SIZE_BUTTON);
<a name="l01893"></a>01893     gtk_container_add (GTK_CONTAINER (titlestring_help_button), image1);
<a name="l01894"></a>01894 
<a name="l01895"></a>01895     titlestring_cbox = gtk_combo_box_new_text ();
<a name="l01896"></a>01896     gtk_table_attach (GTK_TABLE (table6), titlestring_cbox, 1, 3, 0, 1,
<a name="l01897"></a>01897                       (GtkAttachOptions) (GTK_EXPAND | GTK_FILL),
<a name="l01898"></a>01898                       (GtkAttachOptions) (0), 0, 0);
<a name="l01899"></a>01899     gtk_combo_box_append_text (GTK_COMBO_BOX (titlestring_cbox), <a class="code" href="i18n_8h.html#a32a3cf3d9dd914f5aeeca5423c157934">_</a>(<span class="stringliteral">&quot;TITLE&quot;</span>));
<a name="l01900"></a>01900     gtk_combo_box_append_text (GTK_COMBO_BOX (titlestring_cbox), <a class="code" href="i18n_8h.html#a32a3cf3d9dd914f5aeeca5423c157934">_</a>(<span class="stringliteral">&quot;ARTIST - TITLE&quot;</span>));
<a name="l01901"></a>01901     gtk_combo_box_append_text (GTK_COMBO_BOX (titlestring_cbox), <a class="code" href="i18n_8h.html#a32a3cf3d9dd914f5aeeca5423c157934">_</a>(<span class="stringliteral">&quot;ARTIST - ALBUM - TITLE&quot;</span>));
<a name="l01902"></a>01902     gtk_combo_box_append_text (GTK_COMBO_BOX (titlestring_cbox), <a class="code" href="i18n_8h.html#a32a3cf3d9dd914f5aeeca5423c157934">_</a>(<span class="stringliteral">&quot;ARTIST - ALBUM - TRACK. TITLE&quot;</span>));
<a name="l01903"></a>01903     gtk_combo_box_append_text (GTK_COMBO_BOX (titlestring_cbox), <a class="code" href="i18n_8h.html#a32a3cf3d9dd914f5aeeca5423c157934">_</a>(<span class="stringliteral">&quot;ARTIST [ ALBUM ] - TRACK. TITLE&quot;</span>));
<a name="l01904"></a>01904     gtk_combo_box_append_text (GTK_COMBO_BOX (titlestring_cbox), <a class="code" href="i18n_8h.html#a32a3cf3d9dd914f5aeeca5423c157934">_</a>(<span class="stringliteral">&quot;ALBUM - TITLE&quot;</span>));
<a name="l01905"></a>01905     gtk_combo_box_append_text (GTK_COMBO_BOX (titlestring_cbox), <a class="code" href="i18n_8h.html#a32a3cf3d9dd914f5aeeca5423c157934">_</a>(<span class="stringliteral">&quot;Custom&quot;</span>));
<a name="l01906"></a>01906 
<a name="l01907"></a>01907     <a class="code" href="ui__preferences_8c.html#a653d9510fccddd6017f30dab79d0f355">titlestring_entry</a> = gtk_entry_new ();
<a name="l01908"></a>01908     gtk_table_attach (GTK_TABLE (table6), <a class="code" href="ui__preferences_8c.html#a653d9510fccddd6017f30dab79d0f355">titlestring_entry</a>, 1, 2, 1, 2,
<a name="l01909"></a>01909                       (GtkAttachOptions) (GTK_EXPAND | GTK_FILL),
<a name="l01910"></a>01910                       (GtkAttachOptions) (0), 0, 0);
<a name="l01911"></a>01911 
<a name="l01912"></a>01912     label62 = gtk_label_new (<a class="code" href="i18n_8h.html#a32a3cf3d9dd914f5aeeca5423c157934">_</a>(<span class="stringliteral">&quot;Custom string:&quot;</span>));
<a name="l01913"></a>01913     gtk_table_attach (GTK_TABLE (table6), label62, 0, 1, 1, 2,
<a name="l01914"></a>01914                       (GtkAttachOptions) (0),
<a name="l01915"></a>01915                       (GtkAttachOptions) (0), 0, 0);
<a name="l01916"></a>01916     gtk_label_set_justify (GTK_LABEL (label62), GTK_JUSTIFY_RIGHT);
<a name="l01917"></a>01917     gtk_misc_set_alignment (GTK_MISC (label62), 1, 0.5);
<a name="l01918"></a>01918 
<a name="l01919"></a>01919     label61 = gtk_label_new (<a class="code" href="i18n_8h.html#a32a3cf3d9dd914f5aeeca5423c157934">_</a>(<span class="stringliteral">&quot;Title format:&quot;</span>));
<a name="l01920"></a>01920     gtk_table_attach (GTK_TABLE (table6), label61, 0, 1, 0, 1,
<a name="l01921"></a>01921                       (GtkAttachOptions) (0),
<a name="l01922"></a>01922                       (GtkAttachOptions) (0), 0, 0);
<a name="l01923"></a>01923     gtk_label_set_justify (GTK_LABEL (label61), GTK_JUSTIFY_RIGHT);
<a name="l01924"></a>01924     gtk_misc_set_alignment (GTK_MISC (label61), 1, 0.5);
<a name="l01925"></a>01925 
<a name="l01926"></a>01926     alignment85 = gtk_alignment_new (0.5, 0.5, 1, 1);
<a name="l01927"></a>01927     gtk_box_pack_start (GTK_BOX (vbox5), alignment85, FALSE, FALSE, 0);
<a name="l01928"></a>01928     gtk_alignment_set_padding (GTK_ALIGNMENT (alignment85), 12, 12, 0, 0);
<a name="l01929"></a>01929 
<a name="l01930"></a>01930     label84 = gtk_label_new (<a class="code" href="i18n_8h.html#a32a3cf3d9dd914f5aeeca5423c157934">_</a>(<span class="stringliteral">&quot;&lt;b&gt;Popup Information&lt;/b&gt;&quot;</span>));
<a name="l01931"></a>01931     gtk_container_add (GTK_CONTAINER (alignment85), label84);
<a name="l01932"></a>01932     gtk_label_set_use_markup (GTK_LABEL (label84), TRUE);
<a name="l01933"></a>01933     gtk_misc_set_alignment (GTK_MISC (label84), 0, 0.5);
<a name="l01934"></a>01934 
<a name="l01935"></a>01935     alignment86 = gtk_alignment_new (0.5, 0.5, 1, 1);
<a name="l01936"></a>01936     gtk_box_pack_start (GTK_BOX (vbox5), alignment86, FALSE, FALSE, 0);
<a name="l01937"></a>01937     gtk_alignment_set_padding (GTK_ALIGNMENT (alignment86), 0, 0, 12, 0);
<a name="l01938"></a>01938 
<a name="l01939"></a>01939     hbox9 = gtk_hbox_new (FALSE, 12);
<a name="l01940"></a>01940     gtk_container_add (GTK_CONTAINER (alignment86), hbox9);
<a name="l01941"></a>01941 
<a name="l01942"></a>01942     vbox34 = gtk_vbox_new (FALSE, 0);
<a name="l01943"></a>01943     gtk_box_pack_start (GTK_BOX (hbox9), vbox34, TRUE, TRUE, 0);
<a name="l01944"></a>01944 
<a name="l01945"></a>01945     checkbutton10 = gtk_check_button_new_with_mnemonic (<a class="code" href="i18n_8h.html#a32a3cf3d9dd914f5aeeca5423c157934">_</a>(<span class="stringliteral">&quot;Show popup information for playlist entries&quot;</span>));
<a name="l01946"></a>01946     gtk_box_pack_start (GTK_BOX (vbox34), checkbutton10, TRUE, FALSE, 0);
<a name="l01947"></a>01947     <a class="code" href="gtk-compat_8h.html#a02918fc213b0f3bbf96b6be74d9bd75c">gtk_widget_set_tooltip_text</a> (checkbutton10, <a class="code" href="i18n_8h.html#a32a3cf3d9dd914f5aeeca5423c157934">_</a>(<span class="stringliteral">&quot;Toggles popup information window for the pointed entry in the playlist. The window shows title of song, name of album, genre, year of publish, track number, track length, and artwork.&quot;</span>));
<a name="l01948"></a>01948 
<a name="l01949"></a>01949     <a class="code" href="ui__preferences_8c.html#ac603916ed5e941130399cbf62c64e46f">filepopup_for_tuple_settings_button</a> = gtk_button_new ();
<a name="l01950"></a>01950     gtk_box_pack_start (GTK_BOX (hbox9), <a class="code" href="ui__preferences_8c.html#ac603916ed5e941130399cbf62c64e46f">filepopup_for_tuple_settings_button</a>, FALSE, FALSE, 0);
<a name="l01951"></a>01951 
<a name="l01952"></a>01952     <a class="code" href="gtk-compat_8h.html#a9e38319a819b04877eb4df141de6881f">gtk_widget_set_can_focus</a> (<a class="code" href="ui__preferences_8c.html#ac603916ed5e941130399cbf62c64e46f">filepopup_for_tuple_settings_button</a>, FALSE);
<a name="l01953"></a>01953     <a class="code" href="gtk-compat_8h.html#a02918fc213b0f3bbf96b6be74d9bd75c">gtk_widget_set_tooltip_text</a> (<a class="code" href="ui__preferences_8c.html#ac603916ed5e941130399cbf62c64e46f">filepopup_for_tuple_settings_button</a>, <a class="code" href="i18n_8h.html#a32a3cf3d9dd914f5aeeca5423c157934">_</a>(<span class="stringliteral">&quot;Edit settings for popup information&quot;</span>));
<a name="l01954"></a>01954     gtk_button_set_relief (GTK_BUTTON (<a class="code" href="ui__preferences_8c.html#ac603916ed5e941130399cbf62c64e46f">filepopup_for_tuple_settings_button</a>), GTK_RELIEF_HALF);
<a name="l01955"></a>01955 
<a name="l01956"></a>01956     image8 = gtk_image_new_from_stock (<span class="stringliteral">&quot;gtk-properties&quot;</span>, GTK_ICON_SIZE_BUTTON);
<a name="l01957"></a>01957     gtk_container_add (GTK_CONTAINER (<a class="code" href="ui__preferences_8c.html#ac603916ed5e941130399cbf62c64e46f">filepopup_for_tuple_settings_button</a>), image8);
<a name="l01958"></a>01958 
<a name="l01959"></a>01959 
<a name="l01960"></a>01960 
<a name="l01961"></a>01961     g_signal_connect(G_OBJECT(checkbutton10), <span class="stringliteral">&quot;toggled&quot;</span>,
<a name="l01962"></a>01962                      G_CALLBACK(<a class="code" href="ui__preferences_8c.html#a8061d28defce7facf5f92ad05b663353">on_show_filepopup_for_tuple_toggled</a>),
<a name="l01963"></a>01963                      NULL);
<a name="l01964"></a>01964     g_signal_connect_after(G_OBJECT(checkbutton10), <span class="stringliteral">&quot;realize&quot;</span>,
<a name="l01965"></a>01965                            G_CALLBACK(<a class="code" href="ui__preferences_8c.html#a8012debecd1036bfae0ab249efa8a5fe">on_show_filepopup_for_tuple_realize</a>),
<a name="l01966"></a>01966                            NULL);
<a name="l01967"></a>01967     g_signal_connect(G_OBJECT(<a class="code" href="ui__preferences_8c.html#ac603916ed5e941130399cbf62c64e46f">filepopup_for_tuple_settings_button</a>), <span class="stringliteral">&quot;clicked&quot;</span>,
<a name="l01968"></a>01968                      G_CALLBACK(<a class="code" href="ui__preferences_8c.html#af57329a78cd8de1556129e4852bb3e8c">on_filepopup_for_tuple_settings_clicked</a>),
<a name="l01969"></a>01969                      NULL);
<a name="l01970"></a>01970 
<a name="l01971"></a>01971     g_signal_connect(titlestring_cbox, <span class="stringliteral">&quot;realize&quot;</span>,
<a name="l01972"></a>01972                      G_CALLBACK(<a class="code" href="ui__preferences_8c.html#a9673f033564e2412b836a4682beefde6">on_titlestring_cbox_realize</a>),
<a name="l01973"></a>01973                      <a class="code" href="ui__preferences_8c.html#a653d9510fccddd6017f30dab79d0f355">titlestring_entry</a>);
<a name="l01974"></a>01974     g_signal_connect(titlestring_cbox, <span class="stringliteral">&quot;changed&quot;</span>,
<a name="l01975"></a>01975                      G_CALLBACK(<a class="code" href="ui__preferences_8c.html#a1cbdab02f7bef0e10bf27cedd93d5e75">on_titlestring_cbox_changed</a>),
<a name="l01976"></a>01976                      <a class="code" href="ui__preferences_8c.html#a653d9510fccddd6017f30dab79d0f355">titlestring_entry</a>);
<a name="l01977"></a>01977 
<a name="l01978"></a>01978     g_signal_connect(titlestring_cbox, <span class="stringliteral">&quot;changed&quot;</span>,
<a name="l01979"></a>01979                      G_CALLBACK(<a class="code" href="ui__preferences_8c.html#a1cbdab02f7bef0e10bf27cedd93d5e75">on_titlestring_cbox_changed</a>),
<a name="l01980"></a>01980                      titlestring_help_button);
<a name="l01981"></a>01981     g_signal_connect(titlestring_help_button, <span class="stringliteral">&quot;clicked&quot;</span>,
<a name="l01982"></a>01982                      G_CALLBACK(<a class="code" href="ui__preferences_8c.html#adff7a1519c924b3b174b74899afba03a">on_titlestring_help_button_clicked</a>),
<a name="l01983"></a>01983                      titlestring_tag_menu);
<a name="l01984"></a>01984 
<a name="l01985"></a>01985     g_signal_connect(G_OBJECT(<a class="code" href="ui__preferences_8c.html#a653d9510fccddd6017f30dab79d0f355">titlestring_entry</a>), <span class="stringliteral">&quot;changed&quot;</span>,
<a name="l01986"></a>01986                      G_CALLBACK(<a class="code" href="ui__preferences_8c.html#a16b79685f33690135533f9e274eeed5f">on_titlestring_entry_changed</a>),
<a name="l01987"></a>01987                      NULL);
<a name="l01988"></a>01988     g_signal_connect_after(G_OBJECT(<a class="code" href="ui__preferences_8c.html#a653d9510fccddd6017f30dab79d0f355">titlestring_entry</a>), <span class="stringliteral">&quot;realize&quot;</span>,
<a name="l01989"></a>01989                            G_CALLBACK(<a class="code" href="ui__preferences_8c.html#aeafed25ac59eaea23709b083e9c79ede">on_titlestring_entry_realize</a>),
<a name="l01990"></a>01990                            NULL);
<a name="l01991"></a>01991 
<a name="l01992"></a>01992 
<a name="l01993"></a>01993 
<a name="l01994"></a>01994     <span class="comment">/* Create window for filepopup settings */</span>
<a name="l01995"></a>01995     <a class="code" href="ui__preferences_8c.html#a703cc756e60f4799257eb2d2cf5183ee">create_filepopup_settings</a>();
<a name="l01996"></a>01996 }
<a name="l01997"></a>01997 
<a name="l01998"></a>01998 
<a name="l01999"></a>01999 <span class="keyword">static</span> <span class="keywordtype">void</span>
<a name="l02000"></a><a class="code" href="ui__preferences_8c.html#afbca846b58f5989ab00c615b6cff8b33">02000</a> <a class="code" href="ui__preferences_8c.html#afbca846b58f5989ab00c615b6cff8b33">create_audio_category</a>(<span class="keywordtype">void</span>)
<a name="l02001"></a>02001 {
<a name="l02002"></a>02002     GtkWidget *audio_page_vbox;
<a name="l02003"></a>02003     GtkWidget *alignment74;
<a name="l02004"></a>02004     GtkWidget *label77;
<a name="l02005"></a>02005     GtkWidget *alignment73;
<a name="l02006"></a>02006     GtkWidget *vbox33;
<a name="l02007"></a>02007     GtkWidget *table11;
<a name="l02008"></a>02008     GtkWidget *label79;
<a name="l02009"></a>02009     GtkObject *output_plugin_bufsize_adj;
<a name="l02010"></a>02010     GtkWidget *output_plugin_bufsize;
<a name="l02011"></a>02011     GtkWidget *output_plugin_cbox;
<a name="l02012"></a>02012     GtkWidget *label78;
<a name="l02013"></a>02013     GtkWidget *alignment82;
<a name="l02014"></a>02014     GtkWidget *output_plugin_button_box;
<a name="l02015"></a>02015     GtkWidget *output_plugin_prefs;
<a name="l02016"></a>02016     GtkWidget *alignment76;
<a name="l02017"></a>02017     GtkWidget *hbox7;
<a name="l02018"></a>02018     GtkWidget *image5;
<a name="l02019"></a>02019     GtkWidget *label80;
<a name="l02020"></a>02020     GtkWidget *output_plugin_info;
<a name="l02021"></a>02021     GtkWidget *alignment77;
<a name="l02022"></a>02022     GtkWidget *hbox8;
<a name="l02023"></a>02023     GtkWidget *image6;
<a name="l02024"></a>02024     GtkWidget *label81;
<a name="l02025"></a>02025 
<a name="l02026"></a>02026     audio_page_vbox = gtk_vbox_new (FALSE, 0);
<a name="l02027"></a>02027     gtk_container_add (GTK_CONTAINER (<a class="code" href="ui__preferences_8c.html#a5c1d2afa8759c0f574e9ac02dcd695f8">category_notebook</a>), audio_page_vbox);
<a name="l02028"></a>02028 
<a name="l02029"></a>02029     alignment74 = gtk_alignment_new (0.5, 0.5, 1, 1);
<a name="l02030"></a>02030     gtk_box_pack_start (GTK_BOX (audio_page_vbox), alignment74, FALSE, FALSE, 0);
<a name="l02031"></a>02031     gtk_alignment_set_padding (GTK_ALIGNMENT (alignment74), 0, 12, 0, 0);
<a name="l02032"></a>02032 
<a name="l02033"></a>02033     label77 = gtk_label_new (<a class="code" href="i18n_8h.html#a32a3cf3d9dd914f5aeeca5423c157934">_</a>(<span class="stringliteral">&quot;&lt;b&gt;Audio System&lt;/b&gt;&quot;</span>));
<a name="l02034"></a>02034     gtk_container_add (GTK_CONTAINER (alignment74), label77);
<a name="l02035"></a>02035     gtk_label_set_use_markup (GTK_LABEL (label77), TRUE);
<a name="l02036"></a>02036     gtk_misc_set_alignment (GTK_MISC (label77), 0, 0.5);
<a name="l02037"></a>02037 
<a name="l02038"></a>02038     alignment73 = gtk_alignment_new (0.5, 0.5, 1, 1);
<a name="l02039"></a>02039     gtk_box_pack_start (GTK_BOX (audio_page_vbox), alignment73, FALSE, FALSE, 0);
<a name="l02040"></a>02040     gtk_alignment_set_padding (GTK_ALIGNMENT (alignment73), 0, 6, 12, 0);
<a name="l02041"></a>02041 
<a name="l02042"></a>02042     vbox33 = gtk_vbox_new (FALSE, 0);
<a name="l02043"></a>02043     gtk_container_add (GTK_CONTAINER (alignment73), vbox33);
<a name="l02044"></a>02044 
<a name="l02045"></a>02045     table11 = gtk_table_new (3, 2, FALSE);
<a name="l02046"></a>02046     gtk_box_pack_start (GTK_BOX (vbox33), table11, FALSE, FALSE, 0);
<a name="l02047"></a>02047     gtk_table_set_row_spacings (GTK_TABLE (table11), 6);
<a name="l02048"></a>02048     gtk_table_set_col_spacings (GTK_TABLE (table11), 6);
<a name="l02049"></a>02049 
<a name="l02050"></a>02050     label79 = gtk_label_new (<a class="code" href="i18n_8h.html#a32a3cf3d9dd914f5aeeca5423c157934">_</a>(<span class="stringliteral">&quot;Buffer size:&quot;</span>));
<a name="l02051"></a>02051     gtk_table_attach (GTK_TABLE (table11), label79, 0, 1, 1, 2,
<a name="l02052"></a>02052                       (GtkAttachOptions) (GTK_EXPAND | GTK_FILL),
<a name="l02053"></a>02053                       (GtkAttachOptions) (0), 0, 0);
<a name="l02054"></a>02054     gtk_misc_set_alignment (GTK_MISC (label79), 1, 0.5);
<a name="l02055"></a>02055 
<a name="l02056"></a>02056     output_plugin_bufsize_adj =
<a name="l02057"></a>02057         gtk_adjustment_new (0, 100, 10000, 100, 1000, 0);
<a name="l02058"></a>02058     output_plugin_bufsize = gtk_spin_button_new (GTK_ADJUSTMENT (output_plugin_bufsize_adj), 100, 0);
<a name="l02059"></a>02059     gtk_table_attach (GTK_TABLE (table11), output_plugin_bufsize, 1, 2, 1, 2,
<a name="l02060"></a>02060                       (GtkAttachOptions) (GTK_EXPAND | GTK_FILL),
<a name="l02061"></a>02061                       (GtkAttachOptions) (0), 0, 0);
<a name="l02062"></a>02062 
<a name="l02063"></a>02063     output_plugin_cbox = gtk_combo_box_new_text ();
<a name="l02064"></a>02064     gtk_table_attach (GTK_TABLE (table11), output_plugin_cbox, 1, 2, 0, 1,
<a name="l02065"></a>02065                       (GtkAttachOptions) (GTK_EXPAND | GTK_FILL),
<a name="l02066"></a>02066                       (GtkAttachOptions) (0), 0, 0);
<a name="l02067"></a>02067 
<a name="l02068"></a>02068     label78 = gtk_label_new (<a class="code" href="i18n_8h.html#a32a3cf3d9dd914f5aeeca5423c157934">_</a>(<span class="stringliteral">&quot;Current output plugin:&quot;</span>));
<a name="l02069"></a>02069     gtk_table_attach (GTK_TABLE (table11), label78, 0, 1, 0, 1,
<a name="l02070"></a>02070                       (GtkAttachOptions) (0),
<a name="l02071"></a>02071                       (GtkAttachOptions) (0), 0, 0);
<a name="l02072"></a>02072     gtk_misc_set_alignment (GTK_MISC (label78), 0, 0.5);
<a name="l02073"></a>02073 
<a name="l02074"></a>02074     alignment82 = gtk_alignment_new (0.5, 0.5, 1, 1);
<a name="l02075"></a>02075     gtk_box_pack_start (GTK_BOX (audio_page_vbox), alignment82, FALSE, FALSE, 0);
<a name="l02076"></a>02076     gtk_alignment_set_padding (GTK_ALIGNMENT (alignment82), 0, 0, 12, 0);
<a name="l02077"></a>02077 
<a name="l02078"></a>02078     output_plugin_button_box = gtk_hbutton_box_new ();
<a name="l02079"></a>02079     gtk_container_add (GTK_CONTAINER (alignment82), output_plugin_button_box);
<a name="l02080"></a>02080     gtk_button_box_set_layout (GTK_BUTTON_BOX (output_plugin_button_box), GTK_BUTTONBOX_START);
<a name="l02081"></a>02081     gtk_box_set_spacing (GTK_BOX (output_plugin_button_box), 8);
<a name="l02082"></a>02082 
<a name="l02083"></a>02083     output_plugin_prefs = gtk_button_new ();
<a name="l02084"></a>02084     gtk_container_add (GTK_CONTAINER (output_plugin_button_box), output_plugin_prefs);
<a name="l02085"></a>02085     gtk_widget_set_sensitive (output_plugin_prefs, FALSE);
<a name="l02086"></a>02086     <a class="code" href="gtk-compat_8h.html#a0b9f0f50ef60efc20b44f8bf8959b13d">gtk_widget_set_can_default</a>(output_plugin_prefs, TRUE);
<a name="l02087"></a>02087 
<a name="l02088"></a>02088     alignment76 = gtk_alignment_new (0.5, 0.5, 0, 0);
<a name="l02089"></a>02089     gtk_container_add (GTK_CONTAINER (output_plugin_prefs), alignment76);
<a name="l02090"></a>02090 
<a name="l02091"></a>02091     hbox7 = gtk_hbox_new (FALSE, 2);
<a name="l02092"></a>02092     gtk_container_add (GTK_CONTAINER (alignment76), hbox7);
<a name="l02093"></a>02093 
<a name="l02094"></a>02094     image5 = gtk_image_new_from_stock (<span class="stringliteral">&quot;gtk-preferences&quot;</span>, GTK_ICON_SIZE_BUTTON);
<a name="l02095"></a>02095     gtk_box_pack_start (GTK_BOX (hbox7), image5, FALSE, FALSE, 0);
<a name="l02096"></a>02096 
<a name="l02097"></a>02097     label80 = gtk_label_new_with_mnemonic (<a class="code" href="i18n_8h.html#a32a3cf3d9dd914f5aeeca5423c157934">_</a>(<span class="stringliteral">&quot;Output Plugin Preferences&quot;</span>));
<a name="l02098"></a>02098     gtk_box_pack_start (GTK_BOX (hbox7), label80, FALSE, FALSE, 0);
<a name="l02099"></a>02099 
<a name="l02100"></a>02100     output_plugin_info = gtk_button_new ();
<a name="l02101"></a>02101     gtk_container_add (GTK_CONTAINER (output_plugin_button_box), output_plugin_info);
<a name="l02102"></a>02102     gtk_widget_set_sensitive (output_plugin_info, FALSE);
<a name="l02103"></a>02103     <a class="code" href="gtk-compat_8h.html#a0b9f0f50ef60efc20b44f8bf8959b13d">gtk_widget_set_can_default</a>(output_plugin_info, TRUE);
<a name="l02104"></a>02104 
<a name="l02105"></a>02105     alignment77 = gtk_alignment_new (0.5, 0.5, 0, 0);
<a name="l02106"></a>02106     gtk_container_add (GTK_CONTAINER (output_plugin_info), alignment77);
<a name="l02107"></a>02107 
<a name="l02108"></a>02108     hbox8 = gtk_hbox_new (FALSE, 2);
<a name="l02109"></a>02109     gtk_container_add (GTK_CONTAINER (alignment77), hbox8);
<a name="l02110"></a>02110 
<a name="l02111"></a>02111     image6 = gtk_image_new_from_stock (<span class="stringliteral">&quot;gtk-about&quot;</span>, GTK_ICON_SIZE_BUTTON);
<a name="l02112"></a>02112     gtk_box_pack_start (GTK_BOX (hbox8), image6, FALSE, FALSE, 0);
<a name="l02113"></a>02113 
<a name="l02114"></a>02114     label81 = gtk_label_new_with_mnemonic (<a class="code" href="i18n_8h.html#a32a3cf3d9dd914f5aeeca5423c157934">_</a>(<span class="stringliteral">&quot;Output Plugin Information&quot;</span>));
<a name="l02115"></a>02115     gtk_box_pack_start (GTK_BOX (hbox8), label81, FALSE, FALSE, 0);
<a name="l02116"></a>02116 
<a name="l02117"></a>02117     create_widgets(GTK_BOX(audio_page_vbox), <a class="code" href="ui__preferences_8c.html#a96e8471242cd6bc75fff174d77d6e262">audio_page_widgets</a>, G_N_ELEMENTS(<a class="code" href="ui__preferences_8c.html#a96e8471242cd6bc75fff174d77d6e262">audio_page_widgets</a>));
<a name="l02118"></a>02118 
<a name="l02119"></a>02119     g_signal_connect(G_OBJECT(output_plugin_bufsize), <span class="stringliteral">&quot;value_changed&quot;</span>,
<a name="l02120"></a>02120                      G_CALLBACK(<a class="code" href="ui__preferences_8c.html#a62d0958807fbd2286d03dc4a49180037">on_output_plugin_bufsize_value_changed</a>),
<a name="l02121"></a>02121                      NULL);
<a name="l02122"></a>02122     g_signal_connect_after(G_OBJECT(output_plugin_bufsize), <span class="stringliteral">&quot;realize&quot;</span>,
<a name="l02123"></a>02123                            G_CALLBACK(<a class="code" href="ui__preferences_8c.html#a549c6e7c307f18e0b2f047c5acc01cc9">on_output_plugin_bufsize_realize</a>),
<a name="l02124"></a>02124                            NULL);
<a name="l02125"></a>02125     g_signal_connect_after(G_OBJECT(output_plugin_cbox), <span class="stringliteral">&quot;realize&quot;</span>,
<a name="l02126"></a>02126                            G_CALLBACK(<a class="code" href="ui__preferences_8c.html#aba5a53bcd699730e12ae8a3c20eabde5">on_output_plugin_cbox_realize</a>),
<a name="l02127"></a>02127                            NULL);
<a name="l02128"></a>02128 
<a name="l02129"></a>02129     <span class="comment">/* plugin-&gt;output page */</span>
<a name="l02130"></a>02130 
<a name="l02131"></a>02131     g_signal_connect(G_OBJECT(output_plugin_cbox), <span class="stringliteral">&quot;changed&quot;</span>,
<a name="l02132"></a>02132                      G_CALLBACK(<a class="code" href="ui__preferences_8c.html#aedf73cb5b7bfc5230a1e1499bdd8aab5">output_plugin_enable_prefs</a>),
<a name="l02133"></a>02133                      output_plugin_prefs);
<a name="l02134"></a>02134     g_signal_connect_swapped(G_OBJECT(output_plugin_prefs), <span class="stringliteral">&quot;clicked&quot;</span>,
<a name="l02135"></a>02135                              G_CALLBACK(<a class="code" href="ui__preferences_8c.html#a1b84f014b29b9ea443ae51712d0fc0c7">output_plugin_open_prefs</a>),
<a name="l02136"></a>02136                              output_plugin_cbox);
<a name="l02137"></a>02137 
<a name="l02138"></a>02138     g_signal_connect(G_OBJECT(output_plugin_cbox), <span class="stringliteral">&quot;changed&quot;</span>,
<a name="l02139"></a>02139                      G_CALLBACK(<a class="code" href="ui__preferences_8c.html#a888b7b1e4b0131d1d961436820e0d749">output_plugin_enable_info</a>),
<a name="l02140"></a>02140                      output_plugin_info);
<a name="l02141"></a>02141     g_signal_connect_swapped(G_OBJECT(output_plugin_info), <span class="stringliteral">&quot;clicked&quot;</span>,
<a name="l02142"></a>02142                              G_CALLBACK(<a class="code" href="ui__preferences_8c.html#aedebd68ac518ba0633b162bf83f2093a">output_plugin_open_info</a>),
<a name="l02143"></a>02143                              output_plugin_cbox);
<a name="l02144"></a>02144 
<a name="l02145"></a>02145 }
<a name="l02146"></a>02146 
<a name="l02147"></a>02147 <span class="keyword">static</span> <span class="keywordtype">void</span>
<a name="l02148"></a><a class="code" href="ui__preferences_8c.html#a5e80ae4346b25556488479cc492e21ae">02148</a> <a class="code" href="ui__preferences_8c.html#a5e80ae4346b25556488479cc492e21ae">create_connectivity_category</a>(<span class="keywordtype">void</span>)
<a name="l02149"></a>02149 {
<a name="l02150"></a>02150     GtkWidget *connectivity_page_vbox;
<a name="l02151"></a>02151     GtkWidget *vbox29;
<a name="l02152"></a>02152 
<a name="l02153"></a>02153     connectivity_page_vbox = gtk_vbox_new (FALSE, 0);
<a name="l02154"></a>02154     gtk_container_add (GTK_CONTAINER (<a class="code" href="ui__preferences_8c.html#a5c1d2afa8759c0f574e9ac02dcd695f8">category_notebook</a>), connectivity_page_vbox);
<a name="l02155"></a>02155 
<a name="l02156"></a>02156     vbox29 = gtk_vbox_new (FALSE, 0);
<a name="l02157"></a>02157     gtk_box_pack_start (GTK_BOX (connectivity_page_vbox), vbox29, TRUE, TRUE, 0);
<a name="l02158"></a>02158 
<a name="l02159"></a>02159     create_widgets(GTK_BOX(vbox29), <a class="code" href="ui__preferences_8c.html#a41d34000229bbb38c16ada9e5e79f97d">connectivity_page_widgets</a>, G_N_ELEMENTS(<a class="code" href="ui__preferences_8c.html#a41d34000229bbb38c16ada9e5e79f97d">connectivity_page_widgets</a>));
<a name="l02160"></a>02160 }
<a name="l02161"></a>02161 
<a name="l02162"></a>02162 <span class="keyword">static</span> <span class="keywordtype">void</span>
<a name="l02163"></a><a class="code" href="ui__preferences_8c.html#a0e50a007bdd282b5be7f2acb462b02f7">02163</a> <a class="code" href="ui__preferences_8c.html#a0e50a007bdd282b5be7f2acb462b02f7">create_plugin_category</a>(<span class="keywordtype">void</span>)
<a name="l02164"></a>02164 {
<a name="l02165"></a>02165     GtkWidget *plugin_page_vbox;
<a name="l02166"></a>02166     GtkWidget *plugin_notebook;
<a name="l02167"></a>02167     GtkWidget *plugin_input_vbox;
<a name="l02168"></a>02168     GtkWidget *alignment43;
<a name="l02169"></a>02169     GtkWidget *input_plugin_list_label;
<a name="l02170"></a>02170     GtkWidget *scrolledwindow3;
<a name="l02171"></a>02171     GtkWidget *input_plugin_view;
<a name="l02172"></a>02172     GtkWidget *input_plugin_button_box;
<a name="l02173"></a>02173     GtkWidget *input_plugin_prefs;
<a name="l02174"></a>02174     GtkWidget *input_plugin_info;
<a name="l02175"></a>02175     GtkWidget *plugin_input_label;
<a name="l02176"></a>02176     GtkWidget *plugin_general_vbox;
<a name="l02177"></a>02177     GtkWidget *alignment45;
<a name="l02178"></a>02178     GtkWidget *label11;
<a name="l02179"></a>02179     GtkWidget *scrolledwindow5;
<a name="l02180"></a>02180     GtkWidget *general_plugin_view;
<a name="l02181"></a>02181     GtkWidget *general_plugin_button_box;
<a name="l02182"></a>02182     GtkWidget *general_plugin_prefs;
<a name="l02183"></a>02183     GtkWidget *general_plugin_info;
<a name="l02184"></a>02184     GtkWidget *plugin_general_label;
<a name="l02185"></a>02185     GtkWidget *vbox21;
<a name="l02186"></a>02186     GtkWidget *alignment46;
<a name="l02187"></a>02187     GtkWidget *label53;
<a name="l02188"></a>02188     GtkWidget *scrolledwindow7;
<a name="l02189"></a>02189     GtkWidget *vis_plugin_view;
<a name="l02190"></a>02190     GtkWidget *hbuttonbox6;
<a name="l02191"></a>02191     GtkWidget *vis_plugin_prefs;
<a name="l02192"></a>02192     GtkWidget *vis_plugin_info;
<a name="l02193"></a>02193     GtkWidget *vis_label;
<a name="l02194"></a>02194     GtkWidget *vbox25;
<a name="l02195"></a>02195     GtkWidget *alignment58;
<a name="l02196"></a>02196     GtkWidget *label64;
<a name="l02197"></a>02197     GtkWidget *scrolledwindow9;
<a name="l02198"></a>02198     GtkWidget *effect_plugin_view;
<a name="l02199"></a>02199     GtkWidget *hbuttonbox9;
<a name="l02200"></a>02200     GtkWidget *effect_plugin_prefs;
<a name="l02201"></a>02201     GtkWidget *effect_plugin_info;
<a name="l02202"></a>02202     GtkWidget *effects_label;
<a name="l02203"></a>02203 
<a name="l02204"></a>02204     plugin_page_vbox = gtk_vbox_new (FALSE, 0);
<a name="l02205"></a>02205     gtk_container_add (GTK_CONTAINER (<a class="code" href="ui__preferences_8c.html#a5c1d2afa8759c0f574e9ac02dcd695f8">category_notebook</a>), plugin_page_vbox);
<a name="l02206"></a>02206 
<a name="l02207"></a>02207     plugin_notebook = gtk_notebook_new ();
<a name="l02208"></a>02208     gtk_box_pack_start (GTK_BOX (plugin_page_vbox), plugin_notebook, TRUE, TRUE, 0);
<a name="l02209"></a>02209     gtk_notebook_set_show_border (GTK_NOTEBOOK (plugin_notebook), FALSE);
<a name="l02210"></a>02210 
<a name="l02211"></a>02211     plugin_input_vbox = gtk_vbox_new (FALSE, 0);
<a name="l02212"></a>02212     gtk_container_add (GTK_CONTAINER (plugin_notebook), plugin_input_vbox);
<a name="l02213"></a>02213     gtk_container_set_border_width (GTK_CONTAINER (plugin_input_vbox), 12);
<a name="l02214"></a>02214 
<a name="l02215"></a>02215     alignment43 = gtk_alignment_new (0.5, 0.5, 1, 1);
<a name="l02216"></a>02216     gtk_box_pack_start (GTK_BOX (plugin_input_vbox), alignment43, FALSE, FALSE, 4);
<a name="l02217"></a>02217     gtk_alignment_set_padding (GTK_ALIGNMENT (alignment43), 0, 6, 0, 0);
<a name="l02218"></a>02218 
<a name="l02219"></a>02219     input_plugin_list_label = gtk_label_new_with_mnemonic (<a class="code" href="i18n_8h.html#a32a3cf3d9dd914f5aeeca5423c157934">_</a>(<span class="stringliteral">&quot;_Decoder list:&quot;</span>));
<a name="l02220"></a>02220     gtk_container_add (GTK_CONTAINER (alignment43), input_plugin_list_label);
<a name="l02221"></a>02221     gtk_label_set_use_markup (GTK_LABEL (input_plugin_list_label), TRUE);
<a name="l02222"></a>02222     gtk_misc_set_alignment (GTK_MISC (input_plugin_list_label), 0, 0.5);
<a name="l02223"></a>02223 
<a name="l02224"></a>02224     scrolledwindow3 = gtk_scrolled_window_new (NULL, NULL);
<a name="l02225"></a>02225     gtk_box_pack_start (GTK_BOX (plugin_input_vbox), scrolledwindow3, TRUE, TRUE, 0);
<a name="l02226"></a>02226     gtk_scrolled_window_set_policy (GTK_SCROLLED_WINDOW (scrolledwindow3), GTK_POLICY_AUTOMATIC, GTK_POLICY_AUTOMATIC);
<a name="l02227"></a>02227     gtk_scrolled_window_set_shadow_type (GTK_SCROLLED_WINDOW (scrolledwindow3), GTK_SHADOW_IN);
<a name="l02228"></a>02228 
<a name="l02229"></a>02229     input_plugin_view = gtk_tree_view_new ();
<a name="l02230"></a>02230     gtk_container_add (GTK_CONTAINER (scrolledwindow3), input_plugin_view);
<a name="l02231"></a>02231     gtk_tree_view_set_rules_hint (GTK_TREE_VIEW (input_plugin_view), TRUE);
<a name="l02232"></a>02232     gtk_tree_view_set_reorderable (GTK_TREE_VIEW (input_plugin_view), TRUE);
<a name="l02233"></a>02233 
<a name="l02234"></a>02234     input_plugin_button_box = gtk_hbutton_box_new ();
<a name="l02235"></a>02235     gtk_box_pack_start (GTK_BOX (plugin_input_vbox), input_plugin_button_box, FALSE, FALSE, 8);
<a name="l02236"></a>02236     gtk_button_box_set_layout (GTK_BUTTON_BOX (input_plugin_button_box), GTK_BUTTONBOX_START);
<a name="l02237"></a>02237     gtk_box_set_spacing (GTK_BOX (input_plugin_button_box), 8);
<a name="l02238"></a>02238 
<a name="l02239"></a>02239     input_plugin_prefs = gtk_button_new_from_stock (<span class="stringliteral">&quot;gtk-preferences&quot;</span>);
<a name="l02240"></a>02240     gtk_container_add (GTK_CONTAINER (input_plugin_button_box), input_plugin_prefs);
<a name="l02241"></a>02241     gtk_widget_set_sensitive (input_plugin_prefs, FALSE);
<a name="l02242"></a>02242     <a class="code" href="gtk-compat_8h.html#a0b9f0f50ef60efc20b44f8bf8959b13d">gtk_widget_set_can_default</a>(input_plugin_prefs, TRUE);
<a name="l02243"></a>02243 
<a name="l02244"></a>02244     input_plugin_info = gtk_button_new_from_stock (<span class="stringliteral">&quot;gtk-dialog-info&quot;</span>);
<a name="l02245"></a>02245     gtk_container_add (GTK_CONTAINER (input_plugin_button_box), input_plugin_info);
<a name="l02246"></a>02246     gtk_widget_set_sensitive (input_plugin_info, FALSE);
<a name="l02247"></a>02247     <a class="code" href="gtk-compat_8h.html#a0b9f0f50ef60efc20b44f8bf8959b13d">gtk_widget_set_can_default</a>(input_plugin_info, TRUE);
<a name="l02248"></a>02248 
<a name="l02249"></a>02249     plugin_input_label = gtk_label_new (<a class="code" href="i18n_8h.html#a32a3cf3d9dd914f5aeeca5423c157934">_</a>(<span class="stringliteral">&quot;&lt;span size=\&quot;medium\&quot;&gt;&lt;b&gt;Decoders&lt;/b&gt;&lt;/span&gt;&quot;</span>));
<a name="l02250"></a>02250     gtk_notebook_set_tab_label (GTK_NOTEBOOK (plugin_notebook), gtk_notebook_get_nth_page (GTK_NOTEBOOK (plugin_notebook), 0), plugin_input_label);
<a name="l02251"></a>02251     gtk_label_set_use_markup (GTK_LABEL (plugin_input_label), TRUE);
<a name="l02252"></a>02252     gtk_misc_set_alignment (GTK_MISC (plugin_input_label), 0, 0);
<a name="l02253"></a>02253 
<a name="l02254"></a>02254     plugin_general_vbox = gtk_vbox_new (FALSE, 0);
<a name="l02255"></a>02255     gtk_container_add (GTK_CONTAINER (plugin_notebook), plugin_general_vbox);
<a name="l02256"></a>02256     gtk_container_set_border_width (GTK_CONTAINER (plugin_general_vbox), 12);
<a name="l02257"></a>02257 
<a name="l02258"></a>02258     alignment45 = gtk_alignment_new (0.5, 0.5, 1, 1);
<a name="l02259"></a>02259     gtk_box_pack_start (GTK_BOX (plugin_general_vbox), alignment45, FALSE, FALSE, 4);
<a name="l02260"></a>02260     gtk_alignment_set_padding (GTK_ALIGNMENT (alignment45), 0, 6, 0, 0);
<a name="l02261"></a>02261 
<a name="l02262"></a>02262     label11 = gtk_label_new_with_mnemonic (<a class="code" href="i18n_8h.html#a32a3cf3d9dd914f5aeeca5423c157934">_</a>(<span class="stringliteral">&quot;_General plugin list:&quot;</span>));
<a name="l02263"></a>02263     gtk_container_add (GTK_CONTAINER (alignment45), label11);
<a name="l02264"></a>02264     gtk_label_set_use_markup (GTK_LABEL (label11), TRUE);
<a name="l02265"></a>02265     gtk_misc_set_alignment (GTK_MISC (label11), 0, 0.5);
<a name="l02266"></a>02266 
<a name="l02267"></a>02267     scrolledwindow5 = gtk_scrolled_window_new (NULL, NULL);
<a name="l02268"></a>02268     gtk_box_pack_start (GTK_BOX (plugin_general_vbox), scrolledwindow5, TRUE, TRUE, 0);
<a name="l02269"></a>02269     gtk_scrolled_window_set_policy (GTK_SCROLLED_WINDOW (scrolledwindow5), GTK_POLICY_AUTOMATIC, GTK_POLICY_AUTOMATIC);
<a name="l02270"></a>02270     gtk_scrolled_window_set_shadow_type (GTK_SCROLLED_WINDOW (scrolledwindow5), GTK_SHADOW_IN);
<a name="l02271"></a>02271 
<a name="l02272"></a>02272     general_plugin_view = gtk_tree_view_new ();
<a name="l02273"></a>02273     gtk_container_add (GTK_CONTAINER (scrolledwindow5), general_plugin_view);
<a name="l02274"></a>02274     gtk_tree_view_set_rules_hint (GTK_TREE_VIEW (general_plugin_view), TRUE);
<a name="l02275"></a>02275     gtk_tree_view_set_reorderable (GTK_TREE_VIEW (general_plugin_view), TRUE);
<a name="l02276"></a>02276 
<a name="l02277"></a>02277     general_plugin_button_box = gtk_hbutton_box_new ();
<a name="l02278"></a>02278     gtk_box_pack_start (GTK_BOX (plugin_general_vbox), general_plugin_button_box, FALSE, FALSE, 8);
<a name="l02279"></a>02279     gtk_button_box_set_layout (GTK_BUTTON_BOX (general_plugin_button_box), GTK_BUTTONBOX_START);
<a name="l02280"></a>02280     gtk_box_set_spacing (GTK_BOX (general_plugin_button_box), 8);
<a name="l02281"></a>02281 
<a name="l02282"></a>02282     general_plugin_prefs = gtk_button_new_from_stock (<span class="stringliteral">&quot;gtk-preferences&quot;</span>);
<a name="l02283"></a>02283     gtk_container_add (GTK_CONTAINER (general_plugin_button_box), general_plugin_prefs);
<a name="l02284"></a>02284     gtk_widget_set_sensitive (general_plugin_prefs, FALSE);
<a name="l02285"></a>02285     <a class="code" href="gtk-compat_8h.html#a0b9f0f50ef60efc20b44f8bf8959b13d">gtk_widget_set_can_default</a>(general_plugin_prefs, TRUE);
<a name="l02286"></a>02286 
<a name="l02287"></a>02287     general_plugin_info = gtk_button_new_from_stock (<span class="stringliteral">&quot;gtk-dialog-info&quot;</span>);
<a name="l02288"></a>02288     gtk_container_add (GTK_CONTAINER (general_plugin_button_box), general_plugin_info);
<a name="l02289"></a>02289     gtk_widget_set_sensitive (general_plugin_info, FALSE);
<a name="l02290"></a>02290     <a class="code" href="gtk-compat_8h.html#a0b9f0f50ef60efc20b44f8bf8959b13d">gtk_widget_set_can_default</a>(general_plugin_info, TRUE);
<a name="l02291"></a>02291 
<a name="l02292"></a>02292     plugin_general_label = gtk_label_new (<a class="code" href="i18n_8h.html#a32a3cf3d9dd914f5aeeca5423c157934">_</a>(<span class="stringliteral">&quot;&lt;span size=\&quot;medium\&quot;&gt;&lt;b&gt;General&lt;/b&gt;&lt;/span&gt;&quot;</span>));
<a name="l02293"></a>02293     gtk_notebook_set_tab_label (GTK_NOTEBOOK (plugin_notebook), gtk_notebook_get_nth_page (GTK_NOTEBOOK (plugin_notebook), 1), plugin_general_label);
<a name="l02294"></a>02294     gtk_label_set_use_markup (GTK_LABEL (plugin_general_label), TRUE);
<a name="l02295"></a>02295 
<a name="l02296"></a>02296     vbox21 = gtk_vbox_new (FALSE, 0);
<a name="l02297"></a>02297     gtk_container_add (GTK_CONTAINER (plugin_notebook), vbox21);
<a name="l02298"></a>02298     gtk_container_set_border_width (GTK_CONTAINER (vbox21), 12);
<a name="l02299"></a>02299 
<a name="l02300"></a>02300     alignment46 = gtk_alignment_new (0.5, 0.5, 1, 1);
<a name="l02301"></a>02301     gtk_box_pack_start (GTK_BOX (vbox21), alignment46, FALSE, FALSE, 4);
<a name="l02302"></a>02302     gtk_alignment_set_padding (GTK_ALIGNMENT (alignment46), 0, 6, 0, 0);
<a name="l02303"></a>02303 
<a name="l02304"></a>02304     label53 = gtk_label_new_with_mnemonic (<a class="code" href="i18n_8h.html#a32a3cf3d9dd914f5aeeca5423c157934">_</a>(<span class="stringliteral">&quot;_Visualization plugin list:&quot;</span>));
<a name="l02305"></a>02305     gtk_container_add (GTK_CONTAINER (alignment46), label53);
<a name="l02306"></a>02306     gtk_label_set_use_markup (GTK_LABEL (label53), TRUE);
<a name="l02307"></a>02307     gtk_misc_set_alignment (GTK_MISC (label53), 0, 0.5);
<a name="l02308"></a>02308 
<a name="l02309"></a>02309     scrolledwindow7 = gtk_scrolled_window_new (NULL, NULL);
<a name="l02310"></a>02310     gtk_box_pack_start (GTK_BOX (vbox21), scrolledwindow7, TRUE, TRUE, 0);
<a name="l02311"></a>02311     gtk_scrolled_window_set_policy (GTK_SCROLLED_WINDOW (scrolledwindow7), GTK_POLICY_AUTOMATIC, GTK_POLICY_AUTOMATIC);
<a name="l02312"></a>02312     gtk_scrolled_window_set_shadow_type (GTK_SCROLLED_WINDOW (scrolledwindow7), GTK_SHADOW_IN);
<a name="l02313"></a>02313 
<a name="l02314"></a>02314     vis_plugin_view = gtk_tree_view_new ();
<a name="l02315"></a>02315     gtk_container_add (GTK_CONTAINER (scrolledwindow7), vis_plugin_view);
<a name="l02316"></a>02316     gtk_tree_view_set_rules_hint (GTK_TREE_VIEW (vis_plugin_view), TRUE);
<a name="l02317"></a>02317     gtk_tree_view_set_reorderable (GTK_TREE_VIEW (vis_plugin_view), TRUE);
<a name="l02318"></a>02318 
<a name="l02319"></a>02319     hbuttonbox6 = gtk_hbutton_box_new ();
<a name="l02320"></a>02320     gtk_box_pack_start (GTK_BOX (vbox21), hbuttonbox6, FALSE, FALSE, 8);
<a name="l02321"></a>02321     gtk_button_box_set_layout (GTK_BUTTON_BOX (hbuttonbox6), GTK_BUTTONBOX_START);
<a name="l02322"></a>02322     gtk_box_set_spacing (GTK_BOX (hbuttonbox6), 8);
<a name="l02323"></a>02323 
<a name="l02324"></a>02324     vis_plugin_prefs = gtk_button_new_from_stock (<span class="stringliteral">&quot;gtk-preferences&quot;</span>);
<a name="l02325"></a>02325     gtk_container_add (GTK_CONTAINER (hbuttonbox6), vis_plugin_prefs);
<a name="l02326"></a>02326     gtk_widget_set_sensitive (vis_plugin_prefs, FALSE);
<a name="l02327"></a>02327     <a class="code" href="gtk-compat_8h.html#a0b9f0f50ef60efc20b44f8bf8959b13d">gtk_widget_set_can_default</a>(vis_plugin_prefs, TRUE);
<a name="l02328"></a>02328 
<a name="l02329"></a>02329     vis_plugin_info = gtk_button_new_from_stock (<span class="stringliteral">&quot;gtk-dialog-info&quot;</span>);
<a name="l02330"></a>02330     gtk_container_add (GTK_CONTAINER (hbuttonbox6), vis_plugin_info);
<a name="l02331"></a>02331     gtk_widget_set_sensitive (vis_plugin_info, FALSE);
<a name="l02332"></a>02332     <a class="code" href="gtk-compat_8h.html#a0b9f0f50ef60efc20b44f8bf8959b13d">gtk_widget_set_can_default</a>(vis_plugin_info, TRUE);
<a name="l02333"></a>02333 
<a name="l02334"></a>02334     vis_label = gtk_label_new (<a class="code" href="i18n_8h.html#a32a3cf3d9dd914f5aeeca5423c157934">_</a>(<span class="stringliteral">&quot;&lt;b&gt;Visualization&lt;/b&gt;&quot;</span>));
<a name="l02335"></a>02335     gtk_notebook_set_tab_label (GTK_NOTEBOOK (plugin_notebook), gtk_notebook_get_nth_page (GTK_NOTEBOOK (plugin_notebook), 2), vis_label);
<a name="l02336"></a>02336     gtk_label_set_use_markup (GTK_LABEL (vis_label), TRUE);
<a name="l02337"></a>02337 
<a name="l02338"></a>02338     vbox25 = gtk_vbox_new (FALSE, 0);
<a name="l02339"></a>02339     gtk_container_add (GTK_CONTAINER (plugin_notebook), vbox25);
<a name="l02340"></a>02340     gtk_container_set_border_width (GTK_CONTAINER (vbox25), 12);
<a name="l02341"></a>02341 
<a name="l02342"></a>02342     alignment58 = gtk_alignment_new (0.5, 0.5, 1, 1);
<a name="l02343"></a>02343     gtk_box_pack_start (GTK_BOX (vbox25), alignment58, FALSE, FALSE, 4);
<a name="l02344"></a>02344     gtk_alignment_set_padding (GTK_ALIGNMENT (alignment58), 0, 6, 0, 0);
<a name="l02345"></a>02345 
<a name="l02346"></a>02346     label64 = gtk_label_new (<a class="code" href="i18n_8h.html#a32a3cf3d9dd914f5aeeca5423c157934">_</a>(<span class="stringliteral">&quot;Effect plugins:&quot;</span>));
<a name="l02347"></a>02347     gtk_container_add (GTK_CONTAINER (alignment58), label64);
<a name="l02348"></a>02348     gtk_misc_set_alignment (GTK_MISC (label64), 0, 0.5);
<a name="l02349"></a>02349 
<a name="l02350"></a>02350     scrolledwindow9 = gtk_scrolled_window_new (NULL, NULL);
<a name="l02351"></a>02351     gtk_box_pack_start (GTK_BOX (vbox25), scrolledwindow9, TRUE, TRUE, 0);
<a name="l02352"></a>02352     gtk_scrolled_window_set_policy (GTK_SCROLLED_WINDOW (scrolledwindow9), GTK_POLICY_AUTOMATIC, GTK_POLICY_AUTOMATIC);
<a name="l02353"></a>02353     gtk_scrolled_window_set_shadow_type (GTK_SCROLLED_WINDOW (scrolledwindow9), GTK_SHADOW_IN);
<a name="l02354"></a>02354 
<a name="l02355"></a>02355     effect_plugin_view = gtk_tree_view_new ();
<a name="l02356"></a>02356     gtk_container_add (GTK_CONTAINER (scrolledwindow9), effect_plugin_view);
<a name="l02357"></a>02357     gtk_tree_view_set_rules_hint (GTK_TREE_VIEW (effect_plugin_view), TRUE);
<a name="l02358"></a>02358     gtk_tree_view_set_reorderable (GTK_TREE_VIEW (effect_plugin_view), TRUE);
<a name="l02359"></a>02359 
<a name="l02360"></a>02360     hbuttonbox9 = gtk_hbutton_box_new ();
<a name="l02361"></a>02361     gtk_box_pack_start (GTK_BOX (vbox25), hbuttonbox9, FALSE, FALSE, 8);
<a name="l02362"></a>02362     gtk_button_box_set_layout (GTK_BUTTON_BOX (hbuttonbox9), GTK_BUTTONBOX_START);
<a name="l02363"></a>02363     gtk_box_set_spacing (GTK_BOX (hbuttonbox9), 8);
<a name="l02364"></a>02364 
<a name="l02365"></a>02365     effect_plugin_prefs = gtk_button_new_from_stock (<span class="stringliteral">&quot;gtk-preferences&quot;</span>);
<a name="l02366"></a>02366     gtk_container_add (GTK_CONTAINER (hbuttonbox9), effect_plugin_prefs);
<a name="l02367"></a>02367     gtk_widget_set_sensitive (effect_plugin_prefs, FALSE);
<a name="l02368"></a>02368     <a class="code" href="gtk-compat_8h.html#a0b9f0f50ef60efc20b44f8bf8959b13d">gtk_widget_set_can_default</a>(effect_plugin_prefs, TRUE);
<a name="l02369"></a>02369 
<a name="l02370"></a>02370     effect_plugin_info = gtk_button_new_from_stock (<span class="stringliteral">&quot;gtk-dialog-info&quot;</span>);
<a name="l02371"></a>02371     gtk_container_add (GTK_CONTAINER (hbuttonbox9), effect_plugin_info);
<a name="l02372"></a>02372     gtk_widget_set_sensitive (effect_plugin_info, FALSE);
<a name="l02373"></a>02373     <a class="code" href="gtk-compat_8h.html#a0b9f0f50ef60efc20b44f8bf8959b13d">gtk_widget_set_can_default</a>(effect_plugin_info, TRUE);
<a name="l02374"></a>02374 
<a name="l02375"></a>02375     effects_label = gtk_label_new (<a class="code" href="i18n_8h.html#a32a3cf3d9dd914f5aeeca5423c157934">_</a>(<span class="stringliteral">&quot;&lt;b&gt;Effects&lt;/b&gt;&quot;</span>));
<a name="l02376"></a>02376     gtk_notebook_set_tab_label (GTK_NOTEBOOK (plugin_notebook), gtk_notebook_get_nth_page (GTK_NOTEBOOK (plugin_notebook), 3), effects_label);
<a name="l02377"></a>02377     gtk_label_set_use_markup (GTK_LABEL (effects_label), TRUE);
<a name="l02378"></a>02378 
<a name="l02379"></a>02379 
<a name="l02380"></a>02380 
<a name="l02381"></a>02381     gtk_label_set_mnemonic_widget (GTK_LABEL (input_plugin_list_label), <a class="code" href="ui__preferences_8c.html#a5c1d2afa8759c0f574e9ac02dcd695f8">category_notebook</a>);
<a name="l02382"></a>02382     gtk_label_set_mnemonic_widget (GTK_LABEL (label11), <a class="code" href="ui__preferences_8c.html#a5c1d2afa8759c0f574e9ac02dcd695f8">category_notebook</a>);
<a name="l02383"></a>02383     gtk_label_set_mnemonic_widget (GTK_LABEL (label53), <a class="code" href="ui__preferences_8c.html#a5c1d2afa8759c0f574e9ac02dcd695f8">category_notebook</a>);
<a name="l02384"></a>02384     gtk_label_set_mnemonic_widget (GTK_LABEL (label64), <a class="code" href="ui__preferences_8c.html#a5c1d2afa8759c0f574e9ac02dcd695f8">category_notebook</a>);
<a name="l02385"></a>02385 
<a name="l02386"></a>02386 
<a name="l02387"></a>02387 
<a name="l02388"></a>02388     g_signal_connect_after(G_OBJECT(input_plugin_view), <span class="stringliteral">&quot;realize&quot;</span>,
<a name="l02389"></a>02389                            G_CALLBACK(<a class="code" href="ui__preferences_8c.html#a34b12071bf70d1a86af0e2b03fdd5a7b">on_input_plugin_view_realize</a>),
<a name="l02390"></a>02390                            NULL);
<a name="l02391"></a>02391     g_signal_connect_after(G_OBJECT(general_plugin_view), <span class="stringliteral">&quot;realize&quot;</span>,
<a name="l02392"></a>02392                            G_CALLBACK(<a class="code" href="ui__preferences_8c.html#adf48dea152df8dd783858be8749737d8">on_general_plugin_view_realize</a>),
<a name="l02393"></a>02393                            NULL);
<a name="l02394"></a>02394     g_signal_connect_after(G_OBJECT(vis_plugin_view), <span class="stringliteral">&quot;realize&quot;</span>,
<a name="l02395"></a>02395                            G_CALLBACK(<a class="code" href="ui__preferences_8c.html#aa77abe74b362e208f16ad80dcd1caf4b">on_vis_plugin_view_realize</a>),
<a name="l02396"></a>02396                            NULL);
<a name="l02397"></a>02397     g_signal_connect_after(G_OBJECT(effect_plugin_view), <span class="stringliteral">&quot;realize&quot;</span>,
<a name="l02398"></a>02398                            G_CALLBACK(<a class="code" href="ui__preferences_8c.html#af7602fba1e83adf11e84d30b08ff5668">on_effect_plugin_view_realize</a>),
<a name="l02399"></a>02399                            NULL);
<a name="l02400"></a>02400 
<a name="l02401"></a>02401 
<a name="l02402"></a>02402 
<a name="l02403"></a>02403     <span class="comment">/* plugin-&gt;input page */</span>
<a name="l02404"></a>02404     g_object_set_data(G_OBJECT(input_plugin_view), <span class="stringliteral">&quot;plugin_type&quot;</span> , GINT_TO_POINTER(<a class="code" href="ui__preferences_8c.html#a5644eb3f790d5e6ba29119a7d4e6e3d3ab5031417c44d1f05c26c8379ec6bbe3d">PLUGIN_VIEW_TYPE_INPUT</a>));
<a name="l02405"></a>02405     g_signal_connect(G_OBJECT(input_plugin_view), <span class="stringliteral">&quot;row-activated&quot;</span>,
<a name="l02406"></a>02406                      G_CALLBACK(<a class="code" href="ui__preferences_8c.html#a82325604635e4fd9b165e14821330041">plugin_treeview_open_prefs</a>),
<a name="l02407"></a>02407                      NULL);
<a name="l02408"></a>02408     g_signal_connect(G_OBJECT(input_plugin_view), <span class="stringliteral">&quot;cursor-changed&quot;</span>,
<a name="l02409"></a>02409                      G_CALLBACK(<a class="code" href="ui__preferences_8c.html#a9642650849f954a24ea08a068cb2d903">plugin_treeview_enable_prefs</a>),
<a name="l02410"></a>02410                      input_plugin_prefs);
<a name="l02411"></a>02411 
<a name="l02412"></a>02412     g_signal_connect_swapped(G_OBJECT(input_plugin_prefs), <span class="stringliteral">&quot;clicked&quot;</span>,
<a name="l02413"></a>02413                              G_CALLBACK(<a class="code" href="ui__preferences_8c.html#a82325604635e4fd9b165e14821330041">plugin_treeview_open_prefs</a>),
<a name="l02414"></a>02414                              input_plugin_view);
<a name="l02415"></a>02415 
<a name="l02416"></a>02416     g_signal_connect(G_OBJECT(input_plugin_view), <span class="stringliteral">&quot;cursor-changed&quot;</span>,
<a name="l02417"></a>02417                      G_CALLBACK(<a class="code" href="ui__preferences_8c.html#a5fb1d6f4bb7c6ce6ad5a6950ac24fdb9">plugin_treeview_enable_info</a>),
<a name="l02418"></a>02418                      input_plugin_info);
<a name="l02419"></a>02419     g_signal_connect_swapped(G_OBJECT(input_plugin_info), <span class="stringliteral">&quot;clicked&quot;</span>,
<a name="l02420"></a>02420                              G_CALLBACK(<a class="code" href="ui__preferences_8c.html#a00517c485d9ab1fbf26b85a5fcb825bd">plugin_treeview_open_info</a>),
<a name="l02421"></a>02421                              input_plugin_view);
<a name="l02422"></a>02422 
<a name="l02423"></a>02423 
<a name="l02424"></a>02424     <span class="comment">/* plugin-&gt;general page */</span>
<a name="l02425"></a>02425 
<a name="l02426"></a>02426     g_object_set_data(G_OBJECT(general_plugin_view), <span class="stringliteral">&quot;plugin_type&quot;</span> , GINT_TO_POINTER(<a class="code" href="ui__preferences_8c.html#a5644eb3f790d5e6ba29119a7d4e6e3d3a224907d964592908c703588c3bde1bcd">PLUGIN_VIEW_TYPE_GENERAL</a>));
<a name="l02427"></a>02427     g_signal_connect(G_OBJECT(general_plugin_view), <span class="stringliteral">&quot;row-activated&quot;</span>,
<a name="l02428"></a>02428                      G_CALLBACK(<a class="code" href="ui__preferences_8c.html#a82325604635e4fd9b165e14821330041">plugin_treeview_open_prefs</a>),
<a name="l02429"></a>02429                      NULL);
<a name="l02430"></a>02430 
<a name="l02431"></a>02431     g_signal_connect(G_OBJECT(general_plugin_view), <span class="stringliteral">&quot;cursor-changed&quot;</span>,
<a name="l02432"></a>02432                      G_CALLBACK(<a class="code" href="ui__preferences_8c.html#a9642650849f954a24ea08a068cb2d903">plugin_treeview_enable_prefs</a>),
<a name="l02433"></a>02433                      general_plugin_prefs);
<a name="l02434"></a>02434 
<a name="l02435"></a>02435     g_signal_connect_swapped(G_OBJECT(general_plugin_prefs), <span class="stringliteral">&quot;clicked&quot;</span>,
<a name="l02436"></a>02436                              G_CALLBACK(<a class="code" href="ui__preferences_8c.html#a82325604635e4fd9b165e14821330041">plugin_treeview_open_prefs</a>),
<a name="l02437"></a>02437                              general_plugin_view);
<a name="l02438"></a>02438 
<a name="l02439"></a>02439     g_signal_connect(G_OBJECT(general_plugin_view), <span class="stringliteral">&quot;cursor-changed&quot;</span>,
<a name="l02440"></a>02440                      G_CALLBACK(<a class="code" href="ui__preferences_8c.html#a5fb1d6f4bb7c6ce6ad5a6950ac24fdb9">plugin_treeview_enable_info</a>),
<a name="l02441"></a>02441                      general_plugin_info);
<a name="l02442"></a>02442     g_signal_connect_swapped(G_OBJECT(general_plugin_info), <span class="stringliteral">&quot;clicked&quot;</span>,
<a name="l02443"></a>02443                              G_CALLBACK(<a class="code" href="ui__preferences_8c.html#a00517c485d9ab1fbf26b85a5fcb825bd">plugin_treeview_open_info</a>),
<a name="l02444"></a>02444                              general_plugin_view);
<a name="l02445"></a>02445 
<a name="l02446"></a>02446 
<a name="l02447"></a>02447     <span class="comment">/* plugin-&gt;vis page */</span>
<a name="l02448"></a>02448 
<a name="l02449"></a>02449     g_object_set_data(G_OBJECT(vis_plugin_view), <span class="stringliteral">&quot;plugin_type&quot;</span> , GINT_TO_POINTER(<a class="code" href="ui__preferences_8c.html#a5644eb3f790d5e6ba29119a7d4e6e3d3a0c16e7265127af9a2346972168951bad">PLUGIN_VIEW_TYPE_VIS</a>));
<a name="l02450"></a>02450     g_signal_connect(G_OBJECT(vis_plugin_view), <span class="stringliteral">&quot;row-activated&quot;</span>,
<a name="l02451"></a>02451                      G_CALLBACK(<a class="code" href="ui__preferences_8c.html#a82325604635e4fd9b165e14821330041">plugin_treeview_open_prefs</a>),
<a name="l02452"></a>02452                      NULL);
<a name="l02453"></a>02453     g_signal_connect_swapped(G_OBJECT(vis_plugin_prefs), <span class="stringliteral">&quot;clicked&quot;</span>,
<a name="l02454"></a>02454                              G_CALLBACK(<a class="code" href="ui__preferences_8c.html#a82325604635e4fd9b165e14821330041">plugin_treeview_open_prefs</a>),
<a name="l02455"></a>02455                              vis_plugin_view);
<a name="l02456"></a>02456     g_signal_connect(G_OBJECT(vis_plugin_view), <span class="stringliteral">&quot;cursor-changed&quot;</span>,
<a name="l02457"></a>02457                      G_CALLBACK(<a class="code" href="ui__preferences_8c.html#a9642650849f954a24ea08a068cb2d903">plugin_treeview_enable_prefs</a>), vis_plugin_prefs);
<a name="l02458"></a>02458 
<a name="l02459"></a>02459     g_signal_connect(G_OBJECT(vis_plugin_view), <span class="stringliteral">&quot;cursor-changed&quot;</span>,
<a name="l02460"></a>02460                      G_CALLBACK(<a class="code" href="ui__preferences_8c.html#a5fb1d6f4bb7c6ce6ad5a6950ac24fdb9">plugin_treeview_enable_info</a>), vis_plugin_info);
<a name="l02461"></a>02461     g_signal_connect_swapped(G_OBJECT(vis_plugin_info), <span class="stringliteral">&quot;clicked&quot;</span>,
<a name="l02462"></a>02462                              G_CALLBACK(<a class="code" href="ui__preferences_8c.html#a00517c485d9ab1fbf26b85a5fcb825bd">plugin_treeview_open_info</a>),
<a name="l02463"></a>02463                              vis_plugin_view);
<a name="l02464"></a>02464 
<a name="l02465"></a>02465 
<a name="l02466"></a>02466     <span class="comment">/* plugin-&gt;effects page */</span>
<a name="l02467"></a>02467 
<a name="l02468"></a>02468     g_object_set_data(G_OBJECT(effect_plugin_view), <span class="stringliteral">&quot;plugin_type&quot;</span> , GINT_TO_POINTER(<a class="code" href="ui__preferences_8c.html#a5644eb3f790d5e6ba29119a7d4e6e3d3afd0d22de728112565df5c88ed82f3c06">PLUGIN_VIEW_TYPE_EFFECT</a>));
<a name="l02469"></a>02469     g_signal_connect(G_OBJECT(effect_plugin_view), <span class="stringliteral">&quot;row-activated&quot;</span>,
<a name="l02470"></a>02470                      G_CALLBACK(<a class="code" href="ui__preferences_8c.html#a82325604635e4fd9b165e14821330041">plugin_treeview_open_prefs</a>),
<a name="l02471"></a>02471                      NULL);
<a name="l02472"></a>02472     g_signal_connect_swapped(G_OBJECT(effect_plugin_prefs), <span class="stringliteral">&quot;clicked&quot;</span>,
<a name="l02473"></a>02473                              G_CALLBACK(<a class="code" href="ui__preferences_8c.html#a82325604635e4fd9b165e14821330041">plugin_treeview_open_prefs</a>),
<a name="l02474"></a>02474                              effect_plugin_view);
<a name="l02475"></a>02475     g_signal_connect(G_OBJECT(effect_plugin_view), <span class="stringliteral">&quot;cursor-changed&quot;</span>,
<a name="l02476"></a>02476                      G_CALLBACK(<a class="code" href="ui__preferences_8c.html#a9642650849f954a24ea08a068cb2d903">plugin_treeview_enable_prefs</a>), effect_plugin_prefs);
<a name="l02477"></a>02477 
<a name="l02478"></a>02478     g_signal_connect(G_OBJECT(effect_plugin_view), <span class="stringliteral">&quot;cursor-changed&quot;</span>,
<a name="l02479"></a>02479                      G_CALLBACK(<a class="code" href="ui__preferences_8c.html#a5fb1d6f4bb7c6ce6ad5a6950ac24fdb9">plugin_treeview_enable_info</a>), effect_plugin_info);
<a name="l02480"></a>02480     g_signal_connect_swapped(G_OBJECT(effect_plugin_info), <span class="stringliteral">&quot;clicked&quot;</span>,
<a name="l02481"></a>02481                              G_CALLBACK(<a class="code" href="ui__preferences_8c.html#a00517c485d9ab1fbf26b85a5fcb825bd">plugin_treeview_open_info</a>),
<a name="l02482"></a>02482                              effect_plugin_view);
<a name="l02483"></a>02483 
<a name="l02484"></a>02484 }
<a name="l02485"></a>02485 
<a name="l02486"></a>02486 <span class="keyword">static</span> <span class="keywordtype">void</span>
<a name="l02487"></a><a class="code" href="ui__preferences_8c.html#a55e1c303484ff292aa3de3aa566e27a5">02487</a> <a class="code" href="ui__preferences_8c.html#a55e1c303484ff292aa3de3aa566e27a5">destroy_plugin_page</a>(GList *<a class="code" href="misc-api_8h.html#a5b3afcdfb4bae9b4dd1b1ba8f2e6e638">list</a>)
<a name="l02488"></a>02488 {
<a name="l02489"></a>02489     GList *iter;
<a name="l02490"></a>02490 
<a name="l02491"></a>02491     MOWGLI_ITER_FOREACH(iter, list)
<a name="l02492"></a>02492     {
<a name="l02493"></a>02493         Plugin *plugin = <a class="code" href="types_8h.html#a3a1f034ad93243bb3812764cb941dff7">PLUGIN</a>(iter-&gt;data);
<a name="l02494"></a>02494         <span class="keywordflow">if</span> (plugin-&gt;settings &amp;&amp; plugin-&gt;settings-&gt;data) {
<a name="l02495"></a>02495             plugin-&gt;settings-&gt;data = NULL;
<a name="l02496"></a>02496             <span class="keywordflow">if</span> (plugin-&gt;settings-&gt;apply)
<a name="l02497"></a>02497                 plugin-&gt;settings-&gt;apply();
<a name="l02498"></a>02498             <span class="keywordflow">if</span> (plugin-&gt;settings-&gt;cleanup)
<a name="l02499"></a>02499                 plugin-&gt;settings-&gt;cleanup();
<a name="l02500"></a>02500         }
<a name="l02501"></a>02501     }
<a name="l02502"></a>02502 }
<a name="l02503"></a>02503 
<a name="l02504"></a>02504 <span class="keyword">static</span> <span class="keywordtype">void</span>
<a name="l02505"></a><a class="code" href="ui__preferences_8c.html#a807b2287f2af033b15508182172808e3">02505</a> <a class="code" href="ui__preferences_8c.html#a807b2287f2af033b15508182172808e3">destroy_plugin_pages</a>(<span class="keywordtype">void</span>)
<a name="l02506"></a>02506 {
<a name="l02507"></a>02507     <a class="code" href="ui__preferences_8c.html#a55e1c303484ff292aa3de3aa566e27a5">destroy_plugin_page</a>(<a class="code" href="util_8c.html#ac80b918c3b70c80aaf5107a181731281">plugin_get_list</a>(<a class="code" href="plugins_8h.html#a16af7b253440dadd46a80a4b9fddba4da90ccc132a4f44b46e7b671831fc62359">PLUGIN_TYPE_INPUT</a>));
<a name="l02508"></a>02508     <a class="code" href="ui__preferences_8c.html#a55e1c303484ff292aa3de3aa566e27a5">destroy_plugin_page</a>(<a class="code" href="util_8c.html#ac80b918c3b70c80aaf5107a181731281">plugin_get_list</a>(<a class="code" href="plugins_8h.html#a16af7b253440dadd46a80a4b9fddba4da1755e93b8489ab99d93ae2984de17343">PLUGIN_TYPE_GENERAL</a>));
<a name="l02509"></a>02509     <a class="code" href="ui__preferences_8c.html#a55e1c303484ff292aa3de3aa566e27a5">destroy_plugin_page</a>(<a class="code" href="util_8c.html#ac80b918c3b70c80aaf5107a181731281">plugin_get_list</a>(<a class="code" href="plugins_8h.html#a16af7b253440dadd46a80a4b9fddba4da542b11c7fdb0b7ff2dd4f315923efccf">PLUGIN_TYPE_VIS</a>));
<a name="l02510"></a>02510     <a class="code" href="ui__preferences_8c.html#a55e1c303484ff292aa3de3aa566e27a5">destroy_plugin_page</a>(<a class="code" href="util_8c.html#ac80b918c3b70c80aaf5107a181731281">plugin_get_list</a>(<a class="code" href="plugins_8h.html#a16af7b253440dadd46a80a4b9fddba4dae9f4cb7a4f78b0bf25be57d1b05cb613">PLUGIN_TYPE_EFFECT</a>));
<a name="l02511"></a>02511 }
<a name="l02512"></a>02512 
<a name="l02513"></a>02513 <span class="keyword">static</span> <a class="code" href="configdb-api_8h.html#a3ac4dad7ee7fd2890139bff9a134ee9a">gboolean</a>
<a name="l02514"></a><a class="code" href="ui__preferences_8c.html#a287842c382ae454860e39b8b06d9aed7">02514</a> <a class="code" href="ui__preferences_8c.html#a287842c382ae454860e39b8b06d9aed7">prefswin_destroy</a>(GtkWidget *window, GdkEvent *event, gpointer <a class="code" href="misc-api_8h.html#a2a40119722f785a93d720b769541a543">data</a>)
<a name="l02515"></a>02515 {
<a name="l02516"></a>02516     <a class="code" href="ui__preferences_8c.html#a807b2287f2af033b15508182172808e3">destroy_plugin_pages</a>();
<a name="l02517"></a>02517     <a class="code" href="ui__preferences_8c.html#a68dc3d5b54e6e977aedc3ca6a96e92b1">prefswin</a> = NULL;
<a name="l02518"></a>02518     <a class="code" href="ui__preferences_8c.html#a5c1d2afa8759c0f574e9ac02dcd695f8">category_notebook</a> = NULL;
<a name="l02519"></a>02519     gtk_widget_destroy(<a class="code" href="ui__preferences_8c.html#a6af62902a201b816a4038fd2f97481a2">filepopup_settings</a>);
<a name="l02520"></a>02520     <a class="code" href="ui__preferences_8c.html#a6af62902a201b816a4038fd2f97481a2">filepopup_settings</a> = NULL;
<a name="l02521"></a>02521     gtk_widget_destroy(window);
<a name="l02522"></a>02522     <span class="keywordflow">return</span> TRUE;
<a name="l02523"></a>02523 }
<a name="l02524"></a>02524 
<a name="l02525"></a>02525 <span class="keyword">static</span> <span class="keywordtype">void</span>
<a name="l02526"></a><a class="code" href="ui__preferences_8c.html#a1247b92ca556907c36de6db246df7cff">02526</a> <a class="code" href="ui__preferences_8c.html#a1247b92ca556907c36de6db246df7cff">create_plugin_page</a>(GList *<a class="code" href="misc-api_8h.html#a5b3afcdfb4bae9b4dd1b1ba8f2e6e638">list</a>)
<a name="l02527"></a>02527 {
<a name="l02528"></a>02528     GList *iter;
<a name="l02529"></a>02529 
<a name="l02530"></a>02530     MOWGLI_ITER_FOREACH(iter, list)
<a name="l02531"></a>02531     {
<a name="l02532"></a>02532         Plugin *plugin = <a class="code" href="types_8h.html#a3a1f034ad93243bb3812764cb941dff7">PLUGIN</a>(iter-&gt;data);
<a name="l02533"></a>02533         <span class="keywordflow">if</span> (plugin-&gt;settings &amp;&amp; plugin-&gt;settings-&gt;type == <a class="code" href="preferences_8h.html#ad26b29cbcb76e2b44f77713fa0df0f2ea39d4f4d4b0191e8b49988444fc853ef0">PREFERENCES_PAGE</a>) {
<a name="l02534"></a>02534             <a class="code" href="ui__preferences_8c.html#a37055262a6741b11aff36a1c01a5e9a9">create_plugin_preferences_page</a>(plugin-&gt;settings);
<a name="l02535"></a>02535         }
<a name="l02536"></a>02536     }
<a name="l02537"></a>02537 }
<a name="l02538"></a>02538 
<a name="l02539"></a>02539 <span class="keyword">static</span> <span class="keywordtype">void</span>
<a name="l02540"></a><a class="code" href="ui__preferences_8c.html#a023ada1fb358fe894947007d2160072a">02540</a> <a class="code" href="ui__preferences_8c.html#a023ada1fb358fe894947007d2160072a">create_plugin_pages</a>(<span class="keywordtype">void</span>)
<a name="l02541"></a>02541 {
<a name="l02542"></a>02542     <a class="code" href="ui__preferences_8c.html#a1247b92ca556907c36de6db246df7cff">create_plugin_page</a>(<a class="code" href="util_8c.html#ac80b918c3b70c80aaf5107a181731281">plugin_get_list</a>(<a class="code" href="plugins_8h.html#a16af7b253440dadd46a80a4b9fddba4da90ccc132a4f44b46e7b671831fc62359">PLUGIN_TYPE_INPUT</a>));
<a name="l02543"></a>02543     <a class="code" href="ui__preferences_8c.html#a1247b92ca556907c36de6db246df7cff">create_plugin_page</a>(<a class="code" href="util_8c.html#ac80b918c3b70c80aaf5107a181731281">plugin_get_list</a>(<a class="code" href="plugins_8h.html#a16af7b253440dadd46a80a4b9fddba4da1755e93b8489ab99d93ae2984de17343">PLUGIN_TYPE_GENERAL</a>));
<a name="l02544"></a>02544     <a class="code" href="ui__preferences_8c.html#a1247b92ca556907c36de6db246df7cff">create_plugin_page</a>(<a class="code" href="util_8c.html#ac80b918c3b70c80aaf5107a181731281">plugin_get_list</a>(<a class="code" href="plugins_8h.html#a16af7b253440dadd46a80a4b9fddba4da542b11c7fdb0b7ff2dd4f315923efccf">PLUGIN_TYPE_VIS</a>));
<a name="l02545"></a>02545     <a class="code" href="ui__preferences_8c.html#a1247b92ca556907c36de6db246df7cff">create_plugin_page</a>(<a class="code" href="util_8c.html#ac80b918c3b70c80aaf5107a181731281">plugin_get_list</a>(<a class="code" href="plugins_8h.html#a16af7b253440dadd46a80a4b9fddba4dae9f4cb7a4f78b0bf25be57d1b05cb613">PLUGIN_TYPE_EFFECT</a>));
<a name="l02546"></a>02546 }
<a name="l02547"></a>02547 
<a name="l02548"></a>02548 <span class="comment">/* GtkWidget * * create_prefs_window (void) */</span>
<a name="l02549"></a><a class="code" href="ui__preferences_8h.html#a357d0f7b93ef762108b90c52c9d4c19c">02549</a> <span class="keywordtype">void</span> * * <a class="code" href="ui__preferences_8c.html#a357d0f7b93ef762108b90c52c9d4c19c">create_prefs_window</a> (<span class="keywordtype">void</span>)
<a name="l02550"></a>02550 {
<a name="l02551"></a>02551     gchar *aud_version_string;
<a name="l02552"></a>02552 
<a name="l02553"></a>02553     GtkWidget *vbox;
<a name="l02554"></a>02554     GtkWidget *hbox1;
<a name="l02555"></a>02555     GtkWidget *scrolledwindow6;
<a name="l02556"></a>02556     GtkWidget *hseparator1;
<a name="l02557"></a>02557     GtkWidget *hbox4;
<a name="l02558"></a>02558     GtkWidget *audversionlabel;
<a name="l02559"></a>02559     GtkWidget *prefswin_button_box;
<a name="l02560"></a>02560     GtkWidget *hbox11;
<a name="l02561"></a>02561     GtkWidget *image10;
<a name="l02562"></a>02562     GtkWidget *close;
<a name="l02563"></a>02563     GtkAccelGroup *accel_group;
<a name="l02564"></a>02564 
<a name="l02565"></a>02565     accel_group = gtk_accel_group_new ();
<a name="l02566"></a>02566 
<a name="l02567"></a>02567     <a class="code" href="ui__preferences_8c.html#a68dc3d5b54e6e977aedc3ca6a96e92b1">prefswin</a> = gtk_window_new (GTK_WINDOW_TOPLEVEL);
<a name="l02568"></a>02568     gtk_window_set_type_hint (GTK_WINDOW (<a class="code" href="ui__preferences_8c.html#a68dc3d5b54e6e977aedc3ca6a96e92b1">prefswin</a>), GDK_WINDOW_TYPE_HINT_DIALOG);
<a name="l02569"></a>02569     gtk_container_set_border_width (GTK_CONTAINER (<a class="code" href="ui__preferences_8c.html#a68dc3d5b54e6e977aedc3ca6a96e92b1">prefswin</a>), 12);
<a name="l02570"></a>02570     gtk_window_set_title (GTK_WINDOW (<a class="code" href="ui__preferences_8c.html#a68dc3d5b54e6e977aedc3ca6a96e92b1">prefswin</a>), <a class="code" href="i18n_8h.html#a32a3cf3d9dd914f5aeeca5423c157934">_</a>(<span class="stringliteral">&quot;Audacious Preferences&quot;</span>));
<a name="l02571"></a>02571     gtk_window_set_position (GTK_WINDOW (<a class="code" href="ui__preferences_8c.html#a68dc3d5b54e6e977aedc3ca6a96e92b1">prefswin</a>), GTK_WIN_POS_CENTER);
<a name="l02572"></a>02572     gtk_window_set_default_size (GTK_WINDOW (<a class="code" href="ui__preferences_8c.html#a68dc3d5b54e6e977aedc3ca6a96e92b1">prefswin</a>), 680, 400);
<a name="l02573"></a>02573 
<a name="l02574"></a>02574     vbox = gtk_vbox_new (FALSE, 0);
<a name="l02575"></a>02575     gtk_container_add (GTK_CONTAINER (<a class="code" href="ui__preferences_8c.html#a68dc3d5b54e6e977aedc3ca6a96e92b1">prefswin</a>), vbox);
<a name="l02576"></a>02576 
<a name="l02577"></a>02577     hbox1 = gtk_hbox_new (FALSE, 8);
<a name="l02578"></a>02578     gtk_box_pack_start (GTK_BOX (vbox), hbox1, TRUE, TRUE, 0);
<a name="l02579"></a>02579 
<a name="l02580"></a>02580     scrolledwindow6 = gtk_scrolled_window_new (NULL, NULL);
<a name="l02581"></a>02581     gtk_box_pack_start (GTK_BOX (hbox1), scrolledwindow6, TRUE, TRUE, 0);
<a name="l02582"></a>02582     gtk_scrolled_window_set_policy (GTK_SCROLLED_WINDOW (scrolledwindow6), GTK_POLICY_AUTOMATIC, GTK_POLICY_AUTOMATIC);
<a name="l02583"></a>02583     gtk_scrolled_window_set_shadow_type (GTK_SCROLLED_WINDOW (scrolledwindow6), GTK_SHADOW_IN);
<a name="l02584"></a>02584 
<a name="l02585"></a>02585     <a class="code" href="ui__preferences_8c.html#a2d9f22af30312bfb508faf3d100d1a43">category_treeview</a> = gtk_tree_view_new ();
<a name="l02586"></a>02586     gtk_container_add (GTK_CONTAINER (scrolledwindow6), <a class="code" href="ui__preferences_8c.html#a2d9f22af30312bfb508faf3d100d1a43">category_treeview</a>);
<a name="l02587"></a>02587     gtk_widget_set_size_request (<a class="code" href="ui__preferences_8c.html#a2d9f22af30312bfb508faf3d100d1a43">category_treeview</a>, 172, -1);
<a name="l02588"></a>02588     gtk_tree_view_set_headers_visible (GTK_TREE_VIEW (<a class="code" href="ui__preferences_8c.html#a2d9f22af30312bfb508faf3d100d1a43">category_treeview</a>), FALSE);
<a name="l02589"></a>02589 
<a name="l02590"></a>02590     <a class="code" href="ui__preferences_8c.html#a5c1d2afa8759c0f574e9ac02dcd695f8">category_notebook</a> = gtk_notebook_new ();
<a name="l02591"></a>02591     gtk_box_pack_start (GTK_BOX (hbox1), <a class="code" href="ui__preferences_8c.html#a5c1d2afa8759c0f574e9ac02dcd695f8">category_notebook</a>, TRUE, TRUE, 0);
<a name="l02592"></a>02592 
<a name="l02593"></a>02593     <a class="code" href="gtk-compat_8h.html#a9e38319a819b04877eb4df141de6881f">gtk_widget_set_can_focus</a> (<a class="code" href="ui__preferences_8c.html#a5c1d2afa8759c0f574e9ac02dcd695f8">category_notebook</a>, FALSE);
<a name="l02594"></a>02594     gtk_notebook_set_show_tabs (GTK_NOTEBOOK (<a class="code" href="ui__preferences_8c.html#a5c1d2afa8759c0f574e9ac02dcd695f8">category_notebook</a>), FALSE);
<a name="l02595"></a>02595     gtk_notebook_set_show_border (GTK_NOTEBOOK (<a class="code" href="ui__preferences_8c.html#a5c1d2afa8759c0f574e9ac02dcd695f8">category_notebook</a>), FALSE);
<a name="l02596"></a>02596     gtk_notebook_set_scrollable (GTK_NOTEBOOK (<a class="code" href="ui__preferences_8c.html#a5c1d2afa8759c0f574e9ac02dcd695f8">category_notebook</a>), TRUE);
<a name="l02597"></a>02597 
<a name="l02598"></a>02598 
<a name="l02599"></a>02599 
<a name="l02600"></a>02600     <a class="code" href="ui__preferences_8c.html#afbca846b58f5989ab00c615b6cff8b33">create_audio_category</a>();
<a name="l02601"></a>02601     <a class="code" href="ui__preferences_8c.html#a8271be432b813265f2796df55a95a6ab">create_replay_gain_category</a>();
<a name="l02602"></a>02602     <a class="code" href="ui__preferences_8c.html#a5e80ae4346b25556488479cc492e21ae">create_connectivity_category</a>();
<a name="l02603"></a>02603     <a class="code" href="ui__preferences_8c.html#a29917a569770ad3a83e0ea58d75a7ea3">create_playback_category</a>();
<a name="l02604"></a>02604     <a class="code" href="ui__preferences_8c.html#a5b35d777746ba3b1aa1d943ca268a6b4">create_playlist_category</a>();
<a name="l02605"></a>02605     <a class="code" href="ui__preferences_8c.html#a0e50a007bdd282b5be7f2acb462b02f7">create_plugin_category</a>();
<a name="l02606"></a>02606     <a class="code" href="ui__preferences_8c.html#a023ada1fb358fe894947007d2160072a">create_plugin_pages</a>();
<a name="l02607"></a>02607 
<a name="l02608"></a>02608     hseparator1 = gtk_hseparator_new ();
<a name="l02609"></a>02609     gtk_box_pack_start (GTK_BOX (vbox), hseparator1, FALSE, FALSE, 6);
<a name="l02610"></a>02610 
<a name="l02611"></a>02611     hbox4 = gtk_hbox_new (FALSE, 0);
<a name="l02612"></a>02612     gtk_box_pack_start (GTK_BOX (vbox), hbox4, FALSE, FALSE, 0);
<a name="l02613"></a>02613 
<a name="l02614"></a>02614     audversionlabel = gtk_label_new (<span class="stringliteral">&quot;&quot;</span>);
<a name="l02615"></a>02615     gtk_box_pack_start (GTK_BOX (hbox4), audversionlabel, FALSE, FALSE, 0);
<a name="l02616"></a>02616     gtk_label_set_use_markup (GTK_LABEL (audversionlabel), TRUE);
<a name="l02617"></a>02617 
<a name="l02618"></a>02618     prefswin_button_box = gtk_hbutton_box_new ();
<a name="l02619"></a>02619     gtk_box_pack_start (GTK_BOX (hbox4), prefswin_button_box, TRUE, TRUE, 0);
<a name="l02620"></a>02620     gtk_button_box_set_layout (GTK_BUTTON_BOX (prefswin_button_box), GTK_BUTTONBOX_END);
<a name="l02621"></a>02621     gtk_box_set_spacing (GTK_BOX (prefswin_button_box), 6);
<a name="l02622"></a>02622 
<a name="l02623"></a>02623     hbox11 = gtk_hbox_new (FALSE, 2);
<a name="l02624"></a>02624 
<a name="l02625"></a>02625     image10 = gtk_image_new_from_stock (<span class="stringliteral">&quot;gtk-refresh&quot;</span>, GTK_ICON_SIZE_BUTTON);
<a name="l02626"></a>02626     gtk_box_pack_start (GTK_BOX (hbox11), image10, FALSE, FALSE, 0);
<a name="l02627"></a>02627 
<a name="l02628"></a>02628     close = gtk_button_new_from_stock (<span class="stringliteral">&quot;gtk-close&quot;</span>);
<a name="l02629"></a>02629     gtk_container_add (GTK_CONTAINER (prefswin_button_box), close);
<a name="l02630"></a>02630     <a class="code" href="gtk-compat_8h.html#a0b9f0f50ef60efc20b44f8bf8959b13d">gtk_widget_set_can_default</a>(close, TRUE);
<a name="l02631"></a>02631     gtk_widget_add_accelerator (close, <span class="stringliteral">&quot;clicked&quot;</span>, accel_group,
<a name="l02632"></a>02632                                 GDK_Escape, (GdkModifierType) 0,
<a name="l02633"></a>02633                                 GTK_ACCEL_VISIBLE);
<a name="l02634"></a>02634 
<a name="l02635"></a>02635 
<a name="l02636"></a>02636     gtk_window_add_accel_group (GTK_WINDOW (<a class="code" href="ui__preferences_8c.html#a68dc3d5b54e6e977aedc3ca6a96e92b1">prefswin</a>), accel_group);
<a name="l02637"></a>02637 
<a name="l02638"></a>02638     <span class="comment">/* connect signals */</span>
<a name="l02639"></a>02639     g_signal_connect(G_OBJECT(<a class="code" href="ui__preferences_8c.html#a68dc3d5b54e6e977aedc3ca6a96e92b1">prefswin</a>), <span class="stringliteral">&quot;delete_event&quot;</span>,
<a name="l02640"></a>02640                      G_CALLBACK(<a class="code" href="ui__preferences_8c.html#a287842c382ae454860e39b8b06d9aed7">prefswin_destroy</a>),
<a name="l02641"></a>02641                      NULL);
<a name="l02642"></a>02642     g_signal_connect_swapped(G_OBJECT(close), <span class="stringliteral">&quot;clicked&quot;</span>,
<a name="l02643"></a>02643                              G_CALLBACK(<a class="code" href="ui__preferences_8c.html#a287842c382ae454860e39b8b06d9aed7">prefswin_destroy</a>),
<a name="l02644"></a>02644                              GTK_OBJECT (<a class="code" href="ui__preferences_8c.html#a68dc3d5b54e6e977aedc3ca6a96e92b1">prefswin</a>));
<a name="l02645"></a>02645 
<a name="l02646"></a>02646     <span class="comment">/* create category view */</span>
<a name="l02647"></a>02647     <a class="code" href="ui__preferences_8c.html#a73348c5c67f24886ad23e189a33db1a2">on_category_treeview_realize</a> ((GtkTreeView *) <a class="code" href="ui__preferences_8c.html#a2d9f22af30312bfb508faf3d100d1a43">category_treeview</a>,
<a name="l02648"></a>02648      (GtkNotebook *) <a class="code" href="ui__preferences_8c.html#a5c1d2afa8759c0f574e9ac02dcd695f8">category_notebook</a>);
<a name="l02649"></a>02649 
<a name="l02650"></a>02650     <span class="comment">/* audacious version label */</span>
<a name="l02651"></a>02651 
<a name="l02652"></a>02652     aud_version_string = g_strdup_printf
<a name="l02653"></a>02653      (<span class="stringliteral">&quot;&lt;span size=&#39;small&#39;&gt;%s (%s)&lt;/span&gt;&quot;</span>, <span class="stringliteral">&quot;Audacious &quot;</span> PACKAGE_VERSION,
<a name="l02654"></a>02654      BUILDSTAMP);
<a name="l02655"></a>02655 
<a name="l02656"></a>02656     gtk_label_set_markup( GTK_LABEL(audversionlabel) , aud_version_string );
<a name="l02657"></a>02657     g_free(aud_version_string);
<a name="l02658"></a>02658     gtk_widget_show_all(vbox);
<a name="l02659"></a>02659 
<a name="l02660"></a>02660     <span class="keywordflow">return</span> &amp; <a class="code" href="ui__preferences_8c.html#a68dc3d5b54e6e977aedc3ca6a96e92b1">prefswin</a>;
<a name="l02661"></a>02661 }
<a name="l02662"></a>02662 
<a name="l02663"></a>02663 <span class="keywordtype">void</span>
<a name="l02664"></a><a class="code" href="ui__preferences_8h.html#a75d8e0a11cc9be73416732d630f6fb38">02664</a> <a class="code" href="ui__preferences_8c.html#a75d8e0a11cc9be73416732d630f6fb38">destroy_prefs_window</a>(<span class="keywordtype">void</span>)
<a name="l02665"></a>02665 {
<a name="l02666"></a>02666     <a class="code" href="ui__preferences_8c.html#a287842c382ae454860e39b8b06d9aed7">prefswin_destroy</a>(<a class="code" href="ui__preferences_8c.html#a68dc3d5b54e6e977aedc3ca6a96e92b1">prefswin</a>, NULL, NULL);
<a name="l02667"></a>02667 }
<a name="l02668"></a>02668 
<a name="l02669"></a>02669 <span class="keywordtype">void</span>
<a name="l02670"></a><a class="code" href="ui__preferences_8c.html#a37055262a6741b11aff36a1c01a5e9a9">02670</a> <a class="code" href="ui__preferences_8c.html#a37055262a6741b11aff36a1c01a5e9a9">create_plugin_preferences_page</a>(PluginPreferences *settings)
<a name="l02671"></a>02671 {
<a name="l02672"></a>02672     g_return_if_fail(settings-&gt;type == <a class="code" href="preferences_8h.html#ad26b29cbcb76e2b44f77713fa0df0f2ea39d4f4d4b0191e8b49988444fc853ef0">PREFERENCES_PAGE</a>);
<a name="l02673"></a>02673 
<a name="l02674"></a>02674     <span class="keywordflow">if</span> (settings-&gt;data != NULL)
<a name="l02675"></a>02675         <span class="keywordflow">return</span>;
<a name="l02676"></a>02676 
<a name="l02677"></a>02677     <span class="keywordflow">if</span> (settings-&gt;init)
<a name="l02678"></a>02678         settings-&gt;init();
<a name="l02679"></a>02679 
<a name="l02680"></a>02680     GtkWidget *vbox;
<a name="l02681"></a>02681     vbox = gtk_vbox_new(FALSE, 5);
<a name="l02682"></a>02682 
<a name="l02683"></a>02683     create_widgets(GTK_BOX(vbox), settings-&gt;prefs, settings-&gt;n_prefs);
<a name="l02684"></a>02684     gtk_widget_show_all(vbox);
<a name="l02685"></a>02685     <a class="code" href="ui__preferences_8c.html#a6ec6b38ff87a139b46b05db5c8cff100">prefswin_page_new</a>(vbox, settings-&gt;title, settings-&gt;imgurl);
<a name="l02686"></a>02686 
<a name="l02687"></a>02687     settings-&gt;data = (gpointer) vbox;
<a name="l02688"></a>02688 }
<a name="l02689"></a>02689 
<a name="l02690"></a>02690 <span class="keywordtype">void</span>
<a name="l02691"></a><a class="code" href="ui__preferences_8c.html#a8b479180c3fbf93e7d1477b2bc5059ce">02691</a> <a class="code" href="ui__preferences_8c.html#a8b479180c3fbf93e7d1477b2bc5059ce">destroy_plugin_preferences_page</a>(PluginPreferences *settings)
<a name="l02692"></a>02692 {
<a name="l02693"></a>02693     <span class="keywordflow">if</span> (settings-&gt;data) {
<a name="l02694"></a>02694         <span class="keywordflow">if</span> (settings-&gt;apply)
<a name="l02695"></a>02695             settings-&gt;apply();
<a name="l02696"></a>02696 
<a name="l02697"></a>02697         <a class="code" href="ui__preferences_8c.html#acd771c3529890baae02380f3a42f4c58">prefswin_page_destroy</a>(GTK_WIDGET(settings-&gt;data));
<a name="l02698"></a>02698         settings-&gt;data = NULL;
<a name="l02699"></a>02699 
<a name="l02700"></a>02700         <span class="keywordflow">if</span> (settings-&gt;cleanup)
<a name="l02701"></a>02701             settings-&gt;cleanup();
<a name="l02702"></a>02702     }
<a name="l02703"></a>02703 }
<a name="l02704"></a>02704 
<a name="l02705"></a>02705 <span class="keywordtype">void</span>
<a name="l02706"></a><a class="code" href="ui__preferences_8h.html#a3011442f0287d02e2269941791082cc4">02706</a> <a class="code" href="ui__preferences_8c.html#a3011442f0287d02e2269941791082cc4">show_prefs_window</a>(<span class="keywordtype">void</span>)
<a name="l02707"></a>02707 {
<a name="l02708"></a>02708     gtk_window_present(GTK_WINDOW(<a class="code" href="ui__preferences_8c.html#a68dc3d5b54e6e977aedc3ca6a96e92b1">prefswin</a>)); <span class="comment">/* show or raise prefs window */</span>
<a name="l02709"></a>02709 }
<a name="l02710"></a>02710 
<a name="l02711"></a>02711 <span class="keywordtype">void</span>
<a name="l02712"></a><a class="code" href="ui__preferences_8h.html#a0e0c2384c7329b554179511008059fbf">02712</a> <a class="code" href="ui__preferences_8c.html#a0e0c2384c7329b554179511008059fbf">hide_prefs_window</a>(<span class="keywordtype">void</span>)
<a name="l02713"></a>02713 {
<a name="l02714"></a>02714     g_return_if_fail(<a class="code" href="ui__preferences_8c.html#a68dc3d5b54e6e977aedc3ca6a96e92b1">prefswin</a>);
<a name="l02715"></a>02715     gtk_widget_hide(GTK_WIDGET(<a class="code" href="ui__preferences_8c.html#a68dc3d5b54e6e977aedc3ca6a96e92b1">prefswin</a>));
<a name="l02716"></a>02716 }
<a name="l02717"></a>02717 
<a name="l02718"></a><a class="code" href="ui__preferences_8c.html#a8bf15836454cda45dc647da2eb2eeca0">02718</a> <span class="keyword">static</span> <span class="keywordtype">void</span> <a class="code" href="ui__preferences_8c.html#a8bf15836454cda45dc647da2eb2eeca0">prefswin_page_queue_new</a> (GtkWidget * container, <span class="keyword">const</span> gchar * name,
<a name="l02719"></a>02719  <span class="keyword">const</span> gchar * imgurl)
<a name="l02720"></a>02720 {
<a name="l02721"></a>02721     <a class="code" href="structCategoryQueueEntry.html">CategoryQueueEntry</a> *ent = g_new0(<a class="code" href="structCategoryQueueEntry.html">CategoryQueueEntry</a>, 1);
<a name="l02722"></a>02722 
<a name="l02723"></a>02723     ent-&gt;<a class="code" href="structCategoryQueueEntry.html#a921bd11623d976bdc29eda94ecc3090f">container</a> = container;
<a name="l02724"></a>02724     ent-&gt;<a class="code" href="structCategoryQueueEntry.html#a88dc3ce0f0e92236d14c64fc4d6577e0">pg_name</a> = name;
<a name="l02725"></a>02725     ent-&gt;<a class="code" href="structCategoryQueueEntry.html#a4989ec930e5f97de96277f718de0fb15">img_url</a> = imgurl;
<a name="l02726"></a>02726 
<a name="l02727"></a>02727     <span class="keywordflow">if</span> (category_queue)
<a name="l02728"></a>02728         ent-&gt;<a class="code" href="structCategoryQueueEntry.html#ab0ee73d4643c3aedb3ba15b8e680d4e8">next</a> = <a class="code" href="ui__preferences_8c.html#a4ec3c92c0498e384e9b4986b093f2cec">category_queue</a>;
<a name="l02729"></a>02729 
<a name="l02730"></a>02730     category_queue = ent;
<a name="l02731"></a>02731 }
<a name="l02732"></a>02732 
<a name="l02733"></a>02733 <span class="keyword">static</span> <span class="keywordtype">void</span>
<a name="l02734"></a><a class="code" href="ui__preferences_8c.html#a19b121ea803d703ab99cab744e801889">02734</a> <a class="code" href="ui__preferences_8c.html#a19b121ea803d703ab99cab744e801889">prefswin_page_queue_destroy</a>(<a class="code" href="structCategoryQueueEntry.html">CategoryQueueEntry</a> *ent)
<a name="l02735"></a>02735 {
<a name="l02736"></a>02736     category_queue = ent-&gt;<a class="code" href="structCategoryQueueEntry.html#ab0ee73d4643c3aedb3ba15b8e680d4e8">next</a>;
<a name="l02737"></a>02737     g_free(ent);
<a name="l02738"></a>02738 }
<a name="l02739"></a>02739 
<a name="l02740"></a>02740 <span class="comment">/*</span>
<a name="l02741"></a>02741 <span class="comment"> * Public APIs for adding new pages to the prefs window.</span>
<a name="l02742"></a>02742 <span class="comment"> *</span>
<a name="l02743"></a>02743 <span class="comment"> * Basically, the concept here is that third party components can register themselves in the root</span>
<a name="l02744"></a>02744 <span class="comment"> * preferences window.</span>
<a name="l02745"></a>02745 <span class="comment"> *</span>
<a name="l02746"></a>02746 <span class="comment"> * From a usability standpoint this makes the application look more &quot;united&quot;, instead of cluttered</span>
<a name="l02747"></a>02747 <span class="comment"> * and malorganised. Hopefully this option will be used further in the future.</span>
<a name="l02748"></a>02748 <span class="comment"> *</span>
<a name="l02749"></a>02749 <span class="comment"> *    - nenolod</span>
<a name="l02750"></a>02750 <span class="comment"> */</span>
<a name="l02751"></a>02751 <span class="comment">/* gint prefswin_page_new (GtkWidget * container, const gchar * name,</span>
<a name="l02752"></a>02752 <span class="comment"> const gchar * imgurl) */</span>
<a name="l02753"></a><a class="code" href="ui__preferences_8h.html#a6ec6b38ff87a139b46b05db5c8cff100">02753</a> <a class="code" href="misc-api_8h.html#acf599c059f43e0cca83145eb6b0c93cd">gint</a> <a class="code" href="ui__preferences_8c.html#a6ec6b38ff87a139b46b05db5c8cff100">prefswin_page_new</a> (<span class="keywordtype">void</span> * container, <span class="keyword">const</span> gchar * name, <span class="keyword">const</span> gchar *
<a name="l02754"></a>02754  imgurl)
<a name="l02755"></a>02755 {
<a name="l02756"></a>02756     GtkTreeModel *model;
<a name="l02757"></a>02757     GtkTreeIter iter;
<a name="l02758"></a>02758     GdkPixbuf *img = NULL;
<a name="l02759"></a>02759     GtkTreeView *treeview = GTK_TREE_VIEW(<a class="code" href="ui__preferences_8c.html#a2d9f22af30312bfb508faf3d100d1a43">category_treeview</a>);
<a name="l02760"></a>02760     <a class="code" href="misc-api_8h.html#acf599c059f43e0cca83145eb6b0c93cd">gint</a> id;
<a name="l02761"></a>02761 
<a name="l02762"></a>02762     <span class="keywordflow">if</span> (treeview == NULL || <a class="code" href="ui__preferences_8c.html#a5c1d2afa8759c0f574e9ac02dcd695f8">category_notebook</a> == NULL)
<a name="l02763"></a>02763     {
<a name="l02764"></a>02764         <a class="code" href="ui__preferences_8c.html#a8bf15836454cda45dc647da2eb2eeca0">prefswin_page_queue_new</a>(container, name, imgurl);
<a name="l02765"></a>02765         <span class="keywordflow">return</span> -1;
<a name="l02766"></a>02766     }
<a name="l02767"></a>02767 
<a name="l02768"></a>02768     model = gtk_tree_view_get_model(treeview);
<a name="l02769"></a>02769 
<a name="l02770"></a>02770     <span class="keywordflow">if</span> (model == NULL)
<a name="l02771"></a>02771     {
<a name="l02772"></a>02772         <a class="code" href="ui__preferences_8c.html#a8bf15836454cda45dc647da2eb2eeca0">prefswin_page_queue_new</a>(container, name, imgurl);
<a name="l02773"></a>02773         <span class="keywordflow">return</span> -1;
<a name="l02774"></a>02774     }
<a name="l02775"></a>02775 
<a name="l02776"></a>02776     <span class="comment">/* Make sure the widgets are visible. */</span>
<a name="l02777"></a>02777     gtk_widget_show(container);
<a name="l02778"></a>02778     <span class="keywordtype">id</span> = gtk_notebook_append_page(GTK_NOTEBOOK(<a class="code" href="ui__preferences_8c.html#a5c1d2afa8759c0f574e9ac02dcd695f8">category_notebook</a>), container, NULL);
<a name="l02779"></a>02779 
<a name="l02780"></a>02780     <span class="keywordflow">if</span> (<span class="keywordtype">id</span> == -1)
<a name="l02781"></a>02781         <span class="keywordflow">return</span> -1;
<a name="l02782"></a>02782 
<a name="l02783"></a>02783     <span class="keywordflow">if</span> (imgurl != NULL)
<a name="l02784"></a>02784         img = gdk_pixbuf_new_from_file(imgurl, NULL);
<a name="l02785"></a>02785 
<a name="l02786"></a>02786     gtk_list_store_append(GTK_LIST_STORE(model), &amp;iter);
<a name="l02787"></a>02787     gtk_list_store_set(GTK_LIST_STORE(model), &amp;iter,
<a name="l02788"></a>02788                        <a class="code" href="ui__preferences_8c.html#ab327bcf652522bc3ff67a66149322ecaa9f029b74c630e374d42d3487fcb2024b">CATEGORY_VIEW_COL_ICON</a>, img,
<a name="l02789"></a>02789                        <a class="code" href="ui__preferences_8c.html#ab327bcf652522bc3ff67a66149322ecaa2ad7e3c813c7a4c25ec39518ed944b97">CATEGORY_VIEW_COL_NAME</a>,
<a name="l02790"></a>02790                        name, <a class="code" href="ui__preferences_8c.html#ab327bcf652522bc3ff67a66149322ecaa807e88ae3818317d7cb3025cac995a52">CATEGORY_VIEW_COL_ID</a>, <span class="keywordtype">id</span>, -1);
<a name="l02791"></a>02791 
<a name="l02792"></a>02792     <span class="keywordflow">if</span> (img != NULL)
<a name="l02793"></a>02793         g_object_unref(img);
<a name="l02794"></a>02794 
<a name="l02795"></a>02795     <span class="keywordflow">return</span> id;
<a name="l02796"></a>02796 }
<a name="l02797"></a>02797 
<a name="l02798"></a>02798 <span class="keywordtype">void</span>
<a name="l02799"></a><a class="code" href="ui__preferences_8h.html#acd771c3529890baae02380f3a42f4c58">02799</a> <a class="code" href="ui__preferences_8c.html#acd771c3529890baae02380f3a42f4c58">prefswin_page_destroy</a>(GtkWidget *container)
<a name="l02800"></a>02800 {
<a name="l02801"></a>02801     GtkTreeModel *model;
<a name="l02802"></a>02802     GtkTreeIter iter;
<a name="l02803"></a>02803     GtkTreeView *treeview = GTK_TREE_VIEW(<a class="code" href="ui__preferences_8c.html#a2d9f22af30312bfb508faf3d100d1a43">category_treeview</a>);
<a name="l02804"></a>02804     <a class="code" href="configdb-api_8h.html#a3ac4dad7ee7fd2890139bff9a134ee9a">gboolean</a> ret;
<a name="l02805"></a>02805     <a class="code" href="misc-api_8h.html#acf599c059f43e0cca83145eb6b0c93cd">gint</a> id;
<a name="l02806"></a>02806     <a class="code" href="misc-api_8h.html#acf599c059f43e0cca83145eb6b0c93cd">gint</a> <a class="code" href="structindex.html">index</a> = -1;
<a name="l02807"></a>02807 
<a name="l02808"></a>02808     <span class="keywordflow">if</span> (<a class="code" href="ui__preferences_8c.html#a5c1d2afa8759c0f574e9ac02dcd695f8">category_notebook</a> == NULL || treeview == NULL || container == NULL)
<a name="l02809"></a>02809         <span class="keywordflow">return</span>;
<a name="l02810"></a>02810 
<a name="l02811"></a>02811     <span class="keywordtype">id</span> = gtk_notebook_page_num(GTK_NOTEBOOK(<a class="code" href="ui__preferences_8c.html#a5c1d2afa8759c0f574e9ac02dcd695f8">category_notebook</a>), container);
<a name="l02812"></a>02812 
<a name="l02813"></a>02813     <span class="keywordflow">if</span> (<span class="keywordtype">id</span> == -1)
<a name="l02814"></a>02814         <span class="keywordflow">return</span>;
<a name="l02815"></a>02815 
<a name="l02816"></a>02816     gtk_notebook_remove_page(GTK_NOTEBOOK(<a class="code" href="ui__preferences_8c.html#a5c1d2afa8759c0f574e9ac02dcd695f8">category_notebook</a>), <span class="keywordtype">id</span>);
<a name="l02817"></a>02817 
<a name="l02818"></a>02818     model = gtk_tree_view_get_model(treeview);
<a name="l02819"></a>02819 
<a name="l02820"></a>02820     <span class="keywordflow">if</span> (model == NULL)
<a name="l02821"></a>02821         <span class="keywordflow">return</span>;
<a name="l02822"></a>02822 
<a name="l02823"></a>02823     ret = gtk_tree_model_get_iter_first(model, &amp;iter);
<a name="l02824"></a>02824 
<a name="l02825"></a>02825     <span class="keywordflow">while</span> (ret == TRUE)
<a name="l02826"></a>02826     {
<a name="l02827"></a>02827         gtk_tree_model_get(model, &amp;iter, <a class="code" href="ui__preferences_8c.html#ab327bcf652522bc3ff67a66149322ecaa807e88ae3818317d7cb3025cac995a52">CATEGORY_VIEW_COL_ID</a>, &amp;index, -1);
<a name="l02828"></a>02828 
<a name="l02829"></a>02829         <span class="keywordflow">if</span> (index == <span class="keywordtype">id</span>)
<a name="l02830"></a>02830         {
<a name="l02831"></a>02831             gtk_list_store_remove(GTK_LIST_STORE(model), &amp;iter);
<a name="l02832"></a>02832             ret = gtk_tree_model_get_iter_first(model, &amp;iter);
<a name="l02833"></a>02833             <span class="keywordflow">continue</span>;
<a name="l02834"></a>02834         }
<a name="l02835"></a>02835 
<a name="l02836"></a>02836         <span class="keywordflow">if</span> (index &gt; <span class="keywordtype">id</span>)
<a name="l02837"></a>02837         {
<a name="l02838"></a>02838             index--;
<a name="l02839"></a>02839             gtk_list_store_set(GTK_LIST_STORE(model), &amp;iter, <a class="code" href="ui__preferences_8c.html#ab327bcf652522bc3ff67a66149322ecaa807e88ae3818317d7cb3025cac995a52">CATEGORY_VIEW_COL_ID</a>, index, -1);
<a name="l02840"></a>02840         }
<a name="l02841"></a>02841 
<a name="l02842"></a>02842         ret = gtk_tree_model_iter_next(model, &amp;iter);
<a name="l02843"></a>02843     }
<a name="l02844"></a>02844 }
<a name="l02845"></a>02845 
<a name="l02846"></a><a class="code" href="ui__preferences_8c.html#a162e0c2f851d5a3f8b1b0d9fd68b679f">02846</a> <span class="keyword">static</span> <span class="keywordtype">void</span> <a class="code" href="ui__preferences_8c.html#a162e0c2f851d5a3f8b1b0d9fd68b679f">sw_volume_toggled</a> (<span class="keywordtype">void</span>)
<a name="l02847"></a>02847 {
<a name="l02848"></a>02848     <a class="code" href="misc-api_8h.html#acf599c059f43e0cca83145eb6b0c93cd">gint</a> vol[2];
<a name="l02849"></a>02849 
<a name="l02850"></a>02850     <span class="keywordflow">if</span> (<a class="code" href="audconfig_8c.html#a98bd56a064259046a6cc6b1a620badf8">cfg</a>.software_volume_control)
<a name="l02851"></a>02851     {
<a name="l02852"></a>02852         vol[0] = <a class="code" href="audconfig_8c.html#a98bd56a064259046a6cc6b1a620badf8">cfg</a>.sw_volume_left;
<a name="l02853"></a>02853         vol[1] = <a class="code" href="audconfig_8c.html#a98bd56a064259046a6cc6b1a620badf8">cfg</a>.sw_volume_right;
<a name="l02854"></a>02854     }
<a name="l02855"></a>02855     <span class="keywordflow">else</span>
<a name="l02856"></a>02856         <a class="code" href="playback_8c.html#ade54e6821c078a3ddc61da309f5adab3">input_get_volume</a> (&amp; vol[0], &amp; vol[1]);
<a name="l02857"></a>02857 
<a name="l02858"></a>02858     <a class="code" href="hook_8c.html#a2db1ccd2efbd82b151393e3aedd42550">hook_call</a> (<span class="stringliteral">&quot;volume set&quot;</span>, vol);
<a name="l02859"></a>02859 }
</pre></div></div>
</div>
<hr class="footer"/><address class="footer"><small>Generated on Sun Apr 17 2011 for Audacious by&#160;
<a href="http://www.doxygen.org/index.html">
<img class="footer" src="doxygen.png" alt="doxygen"/></a> 1.7.3 </small></address>
</body>
</html>