[chronojump] textview_signal_comment change easily add at beginning of text
- From: Xavier de Blas <xaviblas src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [chronojump] textview_signal_comment change easily add at beginning of text
- Date: Sat, 9 Dec 2017 18:20:16 +0000 (UTC)
commit e544f0ab281e9b64fb7dddb83cce544a1122fde5
Author: Xavier de Blas <xaviblas gmail com>
Date: Sat Dec 9 13:54:48 2017 +0100
textview_signal_comment change easily add at beginning of text
src/gui/encoder.cs | 19 +++++--------------
1 files changed, 5 insertions(+), 14 deletions(-)
---
diff --git a/src/gui/encoder.cs b/src/gui/encoder.cs
index 73a3cda..f6e2778 100644
--- a/src/gui/encoder.cs
+++ b/src/gui/encoder.cs
@@ -302,7 +302,6 @@ public partial class ChronoJumpWindow
private EncoderAnalyzeInstant eai;
private ArrayList array1RM;
- private bool textviewEncoderSignalCommentChanging = false;
//private static double [] encoderReaded; //data coming from encoder and converted (can
be double)
//private static int [] encoderReaded; //data coming from encoder and converted
@@ -1197,22 +1196,14 @@ public partial class ChronoJumpWindow
void on_textview_encoder_signal_comment_key_press_event (object o, EventArgs args)
{
- //1 manage ' " on textview avoiding circular calls
- if(textviewEncoderSignalCommentChanging)
- return;
-
- textviewEncoderSignalCommentChanging = true;
-
- textview_encoder_signal_comment.Buffer.Text =
- Util.MakeValidSQL(textview_encoder_signal_comment.Buffer.Text);
-
- textviewEncoderSignalCommentChanging = false;
-
- //2 button label and sensitiveness
button_encoder_signal_save_comment.Label = Catalog.GetString("Save comment");
button_encoder_signal_save_comment.Sensitive = true;
}
- void on_button_encoder_signal_save_comment_clicked (object o, EventArgs args) {
+ void on_button_encoder_signal_save_comment_clicked (object o, EventArgs args)
+ {
+ textview_encoder_signal_comment.Buffer.Text =
+ Util.MakeValidSQL(textview_encoder_signal_comment.Buffer.Text);
+
LogB.Debug(encoderSignalUniqueID);
if(encoderSignalUniqueID != null && Convert.ToInt32(encoderSignalUniqueID) > 0) {
Sqlite.Update(false, Constants.EncoderTable, "description", "",
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]