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

Diff of /xlog/src/callbacks_toolbar.c

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

revision 1.9 by pa4tu, Sun Dec 8 19:26:02 2002 UTC revision 1.10 by pa4tu, Mon Dec 16 20:31:05 2002 UTC
# Line 51  on_abutton_clicked (GtkButton * button, Line 51  on_abutton_clicked (GtkButton * button,
51      *powerentry, *namehbox, *nameentry, *qthhbox, *qthentry,      *powerentry, *namehbox, *nameentry, *qthhbox, *qthentry,
52      *locatorhbox, *locatorentry, *unknown1hbox, *unknownentry1,      *locatorhbox, *locatorentry, *unknown1hbox, *unknownentry1,
53      *unknown2hbox, *unknownentry2, *qslhbox, *remarksvbox;      *unknown2hbox, *unknownentry2, *qslhbox, *remarksvbox;
54    gchar *frametext, *temp;    gchar *frametext, *temp, *logfile;
55    gint newrow, bandindex, modeindex, i = 0, page;    gint newrow, bandindex, modeindex, i = 0, page;
56    logtype *logwindow = NULL;    logtype *logwindow = NULL;
57    
# Line 211  on_abutton_clicked (GtkButton * button, Line 211  on_abutton_clicked (GtkButton * button,
211    
212        gtk_clist_unselect_all (GTK_CLIST (logwindow->clist));        gtk_clist_unselect_all (GTK_CLIST (logwindow->clist));
213    
214        /* update status bar */        if (preferences.saving == 2)
215        temp = g_strdup_printf (_("QSO %s added to %s log"), qso[NR],        {
216                                logwindow->logname);          logfile = g_strconcat (preferences.savedir, G_DIR_SEPARATOR_S,
217              logwindow->logname, ".xlog", NULL);
218            savelog (logwindow, logfile, TYPE_FLOG);
219            logwindow->logchanged = FALSE;
220            temp = g_strdup_printf (_("QSO %s added to %s log, log saved"),
221              qso[NR], logwindow->logname);
222          }
223          else
224          {
225            temp = g_strdup_printf (_("QSO %s added to %s log"), qso[NR],
226              logwindow->logname);
227            logwindow->logchanged = TRUE;
228            gtk_label_set_text (GTK_LABEL (logwindow->label),
229              g_strconcat (logwindow->logname, " *", NULL));
230          }
231        update_statusbar (temp);        update_statusbar (temp);
232        g_free (temp);        g_free (temp);
233    
       logwindow->logchanged = TRUE;  
       gtk_label_set_text (GTK_LABEL (logwindow->label),  
                           g_strconcat (logwindow->logname, " *", NULL));  
234    
235        qsoframe = lookup_widget (mainwindow, "qsoframe");        qsoframe = lookup_widget (mainwindow, "qsoframe");
236        frametext = g_strdup_printf (_("New QSO"));        frametext = g_strdup_printf (_("New QSO"));
# Line 240  on_dbutton_clicked (GtkButton * button, Line 251  on_dbutton_clicked (GtkButton * button,
251      *modeentry, *rstentry, *myrstentry, *remarksentry, *powerentry,      *modeentry, *rstentry, *myrstentry, *remarksentry, *powerentry,
252      *nameentry, *qthentry, *unknownentry1, *unknownentry2,      *nameentry, *qthentry, *unknownentry1, *unknownentry2,
253      *locatorentry, *incheckbutton, *outcheckbutton;      *locatorentry, *incheckbutton, *outcheckbutton;
254    gchar *statustext, *qsonumber;    gchar *statustext, *qsonumber, *logfile;
255    gint i, selectedrow, page;    gint i, selectedrow, page;
256    logtype *logwindow;    logtype *logwindow;
257    
# Line 315  on_dbutton_clicked (GtkButton * button, Line 326  on_dbutton_clicked (GtkButton * button,
326              }              }
327            gtk_clist_thaw (GTK_CLIST (logwindow->clist));            gtk_clist_thaw (GTK_CLIST (logwindow->clist));
328    
329            logwindow->logchanged = TRUE;            if (preferences.saving == 2)
330            gtk_label_set_text (GTK_LABEL (logwindow->label),            {
331                                g_strconcat (logwindow->logname, " *", NULL));              logfile = g_strconcat (preferences.savedir, G_DIR_SEPARATOR_S,
332                  logwindow->logname, ".xlog", NULL);
333                savelog (logwindow, logfile, TYPE_FLOG);
334                logwindow->logchanged = FALSE;
335              }
336              else
337              {
338                logwindow->logchanged = TRUE;
339                gtk_label_set_text (GTK_LABEL (logwindow->label),
340                  g_strconcat (logwindow->logname, " *", NULL));
341              }
342    
343            gmtbutton = lookup_widget (mainwindow, "gmtbutton");            gmtbutton = lookup_widget (mainwindow, "gmtbutton");
344            gtk_widget_grab_focus (gmtbutton);            gtk_widget_grab_focus (gmtbutton);
# Line 337  on_ubutton_clicked (GtkButton * button, Line 358  on_ubutton_clicked (GtkButton * button,
358      *locatorhbox, *locatorentry, *unknown1hbox, *unknownentry1,      *locatorhbox, *locatorentry, *unknown1hbox, *unknownentry1,
359      *unknown2hbox, *unknownentry2, *qslhbox, *remarksvbox, *gmtbutton;      *unknown2hbox, *unknownentry2, *qslhbox, *remarksvbox, *gmtbutton;
360    gint bandindex, modeindex, updatedrow, i = 0, page;    gint bandindex, modeindex, updatedrow, i = 0, page;
361    gchar *frametext, *nr, *statustext;    gchar *frametext, *nr, *statustext, *logfile;
362    logtype *logwindow;    logtype *logwindow;
363    
364    page = gtk_notebook_get_current_page (GTK_NOTEBOOK (mainnotebook));    page = gtk_notebook_get_current_page (GTK_NOTEBOOK (mainnotebook));
# Line 505  on_ubutton_clicked (GtkButton * button, Line 526  on_ubutton_clicked (GtkButton * button,
526            gtk_clist_remove (GTK_CLIST (logwindow->clist), updatedrow);            gtk_clist_remove (GTK_CLIST (logwindow->clist), updatedrow);
527            gtk_clist_insert (GTK_CLIST (logwindow->clist), updatedrow, qso);            gtk_clist_insert (GTK_CLIST (logwindow->clist), updatedrow, qso);
528    
           /* update status bar */  
           statustext =  
             g_strdup_printf (_("QSO %s updated in %s log"), qso[NR],  
                              logwindow->logname);  
           update_statusbar (statustext);  
           g_free (statustext);  
   
529            gtk_editable_delete_text (GTK_EDITABLE (gmtentry), 0, -1);            gtk_editable_delete_text (GTK_EDITABLE (gmtentry), 0, -1);
530            gtk_editable_delete_text (GTK_EDITABLE (callentry), 0, -1);            gtk_editable_delete_text (GTK_EDITABLE (callentry), 0, -1);
531            if (preferences.modeseditbox == 1)            if (preferences.modeseditbox == 1)
# Line 532  on_ubutton_clicked (GtkButton * button, Line 546  on_ubutton_clicked (GtkButton * button,
546            gtk_frame_set_label (GTK_FRAME (qsoframe), frametext);            gtk_frame_set_label (GTK_FRAME (qsoframe), frametext);
547            g_free (frametext);            g_free (frametext);
548    
549            gtk_label_set_text (GTK_LABEL (logwindow->label),            if (preferences.saving == 2)
550                                g_strconcat (logwindow->logname, " *", NULL));            {
551            logwindow->logchanged = TRUE;              logfile = g_strconcat (preferences.savedir, G_DIR_SEPARATOR_S,
552                  logwindow->logname, ".xlog", NULL);
553                savelog (logwindow, logfile, TYPE_FLOG);
554                logwindow->logchanged = FALSE;
555                statustext =
556                  g_strdup_printf (_("QSO %s updated in %s log, log saved"),
557                    qso[NR], logwindow->logname);
558              }
559              else
560              {
561                logwindow->logchanged = TRUE;
562                gtk_label_set_text (GTK_LABEL (logwindow->label),
563                  g_strconcat (logwindow->logname, " *", NULL));
564                statustext =
565                  g_strdup_printf (_("QSO %s updated in %s log"), qso[NR],
566                    logwindow->logname);
567              }
568              update_statusbar (statustext);
569              g_free (statustext);
570    
571            gmtbutton = lookup_widget (mainwindow, "gmtbutton");            gmtbutton = lookup_widget (mainwindow, "gmtbutton");
572            gtk_widget_grab_focus (gmtbutton);            gtk_widget_grab_focus (gmtbutton);

Legend:
Removed from v.1.9  
changed lines
  Added in v.1.10

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