[Gtk-sharp-list] Design for Indexer for GLib.List to allow [] based addressing.

Mike Kestner mkestner@speakeasy.net
Fri, 24 Oct 2003 10:24:27 -0500


Hi Daniel,

On Thu, 2003-10-23 at 13:49, Daniel Kornhauser wrote:

> Note that I only did the pach for the get accesor for the List.cs and
> SList.cs . Does it make sense to make the set accesor ?
> If it makes sense should it be made with g_list_insert and
> g_slist_insert

Thanks for the patch.  I think a readonly property is fine.

Just a couple of *minor* points added below, otherwise it looks great. 
Do you have cvs commit permissions?  If so, please commit with the
following updates.

Thanks again.
________________________________________________________________________
> Index: ListBase.cs
> ===================================================================

> @@ -125,6 +135,25 @@
>  			orig.CopyTo (array, index); 
>  		}
>  
> +		internal object DataMarshal (IntPtr data) {

For methods, the standard is to put the curly brace on the next line.

> @@ -135,24 +164,11 @@
>  				this.list = list;
>  			}
>  
> -			public object Current {
> +			public object  Current {

Try to avoid whitespace changes like this in your patches.  They just
increase the size of patches and make it harder to determine when/bywhom
code was added.

-- 
Mike Kestner <mkestner@speakeasy.net>