[Gtk-sharp-list] Entry EditingDone Event
Luciano Callero
lnc19@hotmail.com
Fri, 24 Oct 2003 09:13:02 -0300
Someone to help me on this? please?
>From: "Luciano Callero" <lnc19@hotmail.com>
>To: gtk-sharp-list@lists.ximian.com
>Subject: [Gtk-sharp-list] Entry EditingDone Event
>Date: Wed, 22 Oct 2003 12:04:40 -0300
>MIME-Version: 1.0
>X-Originating-IP: [200.32.99.34]
>X-Originating-Email: [lnc19@hotmail.com]
>Received: from listsmx.ximian.com ([141.154.95.15]) by mc5-f15.hotmail.com
>with Microsoft SMTPSVC(5.0.2195.5600); Wed, 22 Oct 2003 08:09:20 -0700
>Received: from headcheese.ximian.com (localhost [127.0.0.1])by
>listsmx.ximian.com (Postfix) with ESMTPid F1F03124428; Wed, 22 Oct 2003
>11:06:02 -0400 (EDT)
>Received: by listsmx.ximian.com (Postfix, from userid 38)id 491F912415B;
>Wed, 22 Oct 2003 11:05:16 -0400 (EDT)
>Received: from hotmail.com (bay2-f62.bay2.hotmail.com [65.54.247.62])by
>listsmx.ximian.com (Postfix) with ESMTP id 2BC541242E1for
><gtk-sharp-list@lists.ximian.com>; Wed, 22 Oct 2003 11:04:45 -0400 (EDT)
>Received: from mail pickup service by hotmail.com with Microsoft SMTPSVC;
>Wed, 22 Oct 2003 08:04:44 -0700
>Received: from 200.32.99.34 by by2fd.bay2.hotmail.msn.com with HTTP;Wed, 22
>Oct 2003 15:04:40 GMT
>X-Message-Info: vAu4ZEtdRijGn7GwA+c3wvCCO1SVa0pw
>Message-ID: <BAY2-F62zRS0IiI7NHa000060fe@hotmail.com>
>X-OriginalArrivalTime: 22 Oct 2003 15:04:44.0101 (UTC)
>FILETIME=[D3763750:01C398AD]
>X-Spam-Status: No, hits=0.7 required=5.0tests=FROM_ENDS_IN_NUMSversion=2.53
>X-Spam-Level: X-Spam-Checker-Version: SpamAssassin 2.53
>(1.174.2.15-2003-03-30-exp)
>Sender: gtk-sharp-list-admin@lists.ximian.com
>Errors-To: gtk-sharp-list-admin@lists.ximian.com
>X-BeenThere: gtk-sharp-list@lists.ximian.com
>X-Mailman-Version: 2.0.13
>Precedence: bulk
>List-Help: <mailto:gtk-sharp-list-request@lists.ximian.com?subject=help>
>List-Post: <mailto:gtk-sharp-list@lists.ximian.com>
>List-Subscribe:
><http://lists.ximian.com/mailman/listinfo/gtk-sharp-list>,<mailto:gtk-sharp-list-request@lists.ximian.com?subject=subscribe>
>List-Id: Discussion of the C# bindings for Gtk+
><gtk-sharp-list.lists.ximian.com>
>List-Unsubscribe:
><http://lists.ximian.com/mailman/listinfo/gtk-sharp-list>,<mailto:gtk-sharp-list-request@lists.ximian.com?subject=unsubscribe>
>List-Archive: <http://lists.ximian.com/archives/public/gtk-sharp-list/>
>Return-Path: gtk-sharp-list-admin@lists.ximian.com
>
>Hi:
>
>I've a Gtk Window with an Entry Widget. This entry must update a value
>(store in a property) after end editing.
>I think that the EditingDone event that inherit from other its the correct,
>beacause i need to update when is changed in the entry and not when is
>change by Programming.
>
>This is an "Example":
>
>class Test:Window
>
> {
> public string EntryValue = "";
> static void Main()
> {
> Button button1 = new Button("Change The Entry");
> Entry entry1 = new Entry();
>
> // All the code that initialize the window
>
> button1.Clicked += new EventHandler(button1_clicked);
> entry1.EditingDonde += new EventHandler(entry1_editingdone);
> entry1.OnChange += new EventHandler(entry1_onchange);
> }
>
> public void button1_clicked(System.Object Sender, EventArgs
>args)
> {
> entry1.Text = "Test of Change"; // This must not
>update the value
> }
>
> public void entry1_editingdone(System.Object Sender, EventArgs
>args)
> {
> // HERE Does Not Enter
> EntryValue = ((Entry)Sender).Text;
> }
>
> public void entry1_onchange(System.Object Sender, EventArgs args)
> {
> Console.WriteLine("This is shown every time.");
> }
> }
>
>
>I try 3 thinks:
>1) Use OnChange event, but the problem was that on every key pressed (every
>value that is inserted) in the entry is updated automaticaly, and this will
>be very slow, beacause in realy i need to update a Row in a DataTable, and
>i must to search some positions and other thinks.
>The other and the bigger problem is that, if i change the value of the
>entry internaly (like button1) it is fire the event onChange, and i must to
>use some "flag" and this is not very efficient. (Not for my)
>2) The second idea that i have is to use EditingDone Event, but the problem
>is that it is never fires this event. I dont know if i'm using like it is.
>
>
>The finally Question: Do i have to commit suicide? :) Do i need to start
>reading again?
>Is there an event that is fire when end editing, but before that focus is
>lost. Like a Validate (in m$) event?
>I'm using correctly the EditingDone Event?
>
>Thanks in advance.
>
>_________________________________________________________________
>¿Estás buscando un auto nuevo? http://www.yupimsn.com/autos/
>
>_______________________________________________
>Gtk-sharp-list maillist - Gtk-sharp-list@lists.ximian.com
>http://lists.ximian.com/mailman/listinfo/gtk-sharp-list
_________________________________________________________________
¿Estás buscando un auto nuevo? http://www.yupimsn.com/autos/