make the sample 2.4 friendly

svn path=/trunk/gtk-sharp/; revision=46842
This commit is contained in:
Mike Kestner 2005-07-01 17:45:07 +00:00
parent 3c531aa299
commit 762a1576fd

View File

@ -53,7 +53,10 @@ namespace WidgetViewer {
static void OnComboActivated (object o, EventArgs args)
{
Console.WriteLine ((o as ComboBox).ActiveText);
ComboBox combo = o as ComboBox;
TreeIter iter;
combo.GetActiveIter (out iter);
Console.WriteLine ((string)combo.Model.GetValue (iter, 0));
}
}
}