mirror of
https://github.com/Ryujinx/GtkSharp.git
synced 2024-12-29 15:35:43 +00:00
d33dd8a15f
* gconf, sample/gconf: Added. * glue/combo.c: This was never added, add it now. * configure.in, makefile, sample/Makefile.in: Build new gconf bindings if gnome is enabled. svn path=/trunk/gtk-sharp/; revision=8389
38 lines
803 B
C#
38 lines
803 B
C#
namespace GConf.PropertyEditors
|
|
{
|
|
using Gtk;
|
|
using Gnome;
|
|
using System;
|
|
|
|
public class PropertyEditorFileEntry : PropertyEditor
|
|
{
|
|
protected override void ValueChanged (object sender, NotifyEventArgs args)
|
|
{
|
|
object val = args.Value;
|
|
if (val == null)
|
|
return;
|
|
FileEntry entry = (FileEntry) Control;
|
|
entry.Filename = (string) val;
|
|
}
|
|
|
|
void Changed (object obj, EventArgs args)
|
|
{
|
|
FileEntry entry = (FileEntry) Control;
|
|
string filename = entry.Filename;
|
|
if (filename == null)
|
|
filename = String.Empty;
|
|
Set (filename);
|
|
}
|
|
|
|
protected override void ConnectHandlers ()
|
|
{
|
|
FileEntry entry = (FileEntry) Control;
|
|
entry.Changed += new EventHandler (Changed);
|
|
}
|
|
|
|
public PropertyEditorFileEntry (string key, FileEntry entry) : base (key, entry)
|
|
{
|
|
}
|
|
}
|
|
}
|