Enlightenment CVS committal
Author : leviathan
Project : e17
Module : libs/etk-perl
Dir : e17/libs/etk-perl/etk_test
Modified Files:
etk_test.pl
Log Message:
more implementation of the Combobox_Entry widget
===================================================================
RCS file: /cvs/e/e17/libs/etk-perl/etk_test/etk_test.pl,v
retrieving revision 1.53
retrieving revision 1.54
diff -u -3 -r1.53 -r1.54
--- etk_test.pl 29 Jun 2007 19:23:50 -0000 1.53
+++ etk_test.pl 29 Jul 2007 07:56:12 -0000 1.54
@@ -714,6 +714,30 @@
return $menu_item;
}
+sub __combobox_entry_populate
+{
+ my $combo = shift;
+ my $dir = shift;
+
+ $combo->Clear();
+ $combo->ItemPrepend(
+ Etk::Image::new_from_stock(PlacesFolder, SizeSmall),
+ "..");
+
+ while (<$dir/*>) {
+ if (-d) {
+ $combo->ItemPrepend(
+ Etk::Image::new_from_stock(PlacesFolder, SizeSmall),
+ $_);
+ } else {
+ $combo->ItemPrepend(
+ Etk::Image::new_from_stock(TextXGeneric, SizeSmall),
+ $_);
+ }
+
+ }
+
+}
sub combobox_window_show
{
@@ -729,6 +753,19 @@
$combobox->ItemAppend("Test 1");
$combobox->ItemAppend("Test 2");
$combobox->ItemAppend("Test 3");
+
+ $frame = Etk::Frame->new("Entry combobox");
+ $vbox->Append($frame);
+
+ $combobox = Etk::Combobox::Entry->new();
+ $combobox->SignalConnect("active-item-changed", sub {
+ print "TODO\n";
+ });
+ $combobox->ColumnAdd(EntryImage, 24, EntryNone, 0.0);
+ $combobox->ColumnAdd(EntryLabel, 75, EntryExpand, 0.0);
+ $combobox->Build();
+ $frame->Add($combobox);
+ __combobox_entry_populate($combobox, ".");
$frame = Etk::Frame->new("Some stock icons");
$vbox->Append($frame);
-------------------------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems? Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/
_______________________________________________
enlightenment-cvs mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/enlightenment-cvs