/[xlog]/xlog/src/callbacks_mainwindow_toolbar.c
ViewVC logotype

Diff of /xlog/src/callbacks_mainwindow_toolbar.c

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.7 by pa4tu, Fri Feb 25 13:14:59 2005 UTC revision 1.8 by pa4tu, Mon Feb 28 22:26:09 2005 UTC
# Line 22  Line 22 
22   */   */
23    
24  #include <gtk/gtk.h>  #include <gtk/gtk.h>
25    #include <string.h>
26  #include "callbacks_mainwindow_toolbar.h"  #include "callbacks_mainwindow_toolbar.h"
27  #include "callbacks_mainwindow_menu.h"  #include "callbacks_mainwindow_menu.h"
28  #include "support.h"  #include "support.h"
# Line 56  on_abutton_clicked (GtkButton * button, Line 57  on_abutton_clicked (GtkButton * button,
57                  *powerentry, *namehbox, *nameentry, *qthhbox, *qthentry,                  *powerentry, *namehbox, *nameentry, *qthhbox, *qthentry,
58                  *locatorhbox, *locatorentry, *unknown1hbox, *unknownentry1,                  *locatorhbox, *locatorentry, *unknown1hbox, *unknownentry1,
59                  *unknown2hbox, *unknownentry2, *qslhbox, *remarksvbox, *framelabel;                  *unknown2hbox, *unknownentry2, *qslhbox, *remarksvbox, *framelabel;
60          gchar *temp;          gchar *temp, *countstr, *str;
61          gint bandindex, modeindex, i = 0, page, c;          gint bandindex, modeindex, i = 0, page, c;
62          logtype *logw = NULL;          logtype *logw = NULL;
63          GtkTreeIter iter, selected;          GtkTreeIter iter, selected;
# Line 232  on_abutton_clicked (GtkButton * button, Line 233  on_abutton_clicked (GtkButton * button,
233    
234                  gtk_widget_grab_focus (callentry);                  gtk_widget_grab_focus (callentry);
235                  if (keyerwindow)                  if (keyerwindow)
236                  {       /* increment counter and fill in data for next QSO */                  {       /* increment counter and fill in rst/myrst for next QSO */
237                          count = lookup_widget (keyerwindow, "count");                          count = lookup_widget (keyerwindow, "count");
238                          c = gtk_spin_button_get_value (GTK_SPIN_BUTTON (count));                          c = gtk_spin_button_get_value (GTK_SPIN_BUTTON (count));
239                          gtk_spin_button_set_value (GTK_SPIN_BUTTON (count), c + 1);                          gtk_spin_button_set_value (GTK_SPIN_BUTTON (count), c + 1);
240                          on_clickall_activate (NULL, NULL);  
241                            if (g_ascii_strcasecmp (preferences.defaulttxrst, "?"))
242                            {
243                                    if (g_strrstr (preferences.defaulttxrst, "#"))
244                                    {
245                                            if (c < 10)
246                                                    countstr = g_strdup_printf ("00%d", c);
247                                            else if (c < 100)
248                                                    countstr = g_strdup_printf ("0%d", c);
249                                            else
250                                                    countstr = g_strdup_printf ("%d", c);
251                                            str = my_strreplace (preferences.defaulttxrst, "#", countstr);
252                                            g_free (countstr);
253                                            gtk_entry_set_text (GTK_ENTRY (rstentry), str);
254                                            g_free (str);
255                                    }
256                                    else
257                                            gtk_entry_set_text (GTK_ENTRY (rstentry), preferences.defaulttxrst);
258                            }
259                            if (g_ascii_strcasecmp (preferences.defaultrxrst, "?"))
260                                    gtk_entry_set_text (GTK_ENTRY (myrstentry), preferences.defaultrxrst);
261                  }                  }
262          }          }
263  }  }

Legend:
Removed from v.1.7  
changed lines
  Added in v.1.8

savannah-hackers-public@gnu.org
ViewVC Help
Powered by ViewVC 1.1.26