/[aleader]/aleader/aleader/appipname.c
ViewVC logotype

Diff of /aleader/aleader/appipname.c

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

revision 1.1.1.1 by jpritikin, Mon Jun 16 02:29:28 2003 UTC revision 1.2 by jpritikin, Thu Oct 9 03:18:59 2003 UTC
# Line 103  app_ip_name_set_property (GObject      * Line 103  app_ip_name_set_property (GObject      *
103      if (nm->note)      if (nm->note)
104        g_free (nm->note);        g_free (nm->note);
105    
106      gchar *val = g_value_dup_string (value);      nm->note = g_value_dup_string (value);
     if (val)  
       nm->note = val;  
     else  
       nm->note = NULL;  
107    
108      app_ip_name_changed (nm);      app_ip_name_changed (nm);
109      break;}      break;}
# Line 190  app_ip_name_use (AppIpName *nm) Line 186  app_ip_name_use (AppIpName *nm)
186    
187    AppTranscript *cx = nm->tx;    AppTranscript *cx = nm->tx;
188    
   g_ptr_set_remove (cx->names_by_use, nm);  
189    ++ nm->use_count;    ++ nm->use_count;
   g_ptr_set_add (cx->names_by_use, nm);  
190    
191    g_object_notify (G_OBJECT (nm), "use-count");    g_object_notify (G_OBJECT (nm), "use-count");
192    
# Line 206  app_ip_name_unuse (AppIpName *nm) Line 200  app_ip_name_unuse (AppIpName *nm)
200    
201    AppTranscript *cx = nm->tx;    AppTranscript *cx = nm->tx;
202    
   g_ptr_set_remove (cx->names_by_use, nm);  
203    -- nm->use_count;    -- nm->use_count;
   g_ptr_set_add (cx->names_by_use, nm);  
204    
205    g_object_notify (G_OBJECT (nm), "use-count");    g_object_notify (G_OBJECT (nm), "use-count");
206  }  }
# Line 229  app_ip_name_new (AppTranscript *cx, cons Line 221  app_ip_name_new (AppTranscript *cx, cons
221    
222    g_assert (!g_ptr_set_lookup (cx->names_by_alpha, NULL, nm));    g_assert (!g_ptr_set_lookup (cx->names_by_alpha, NULL, nm));
223    g_ptr_set_add (cx->names_by_alpha, nm);    g_ptr_set_add (cx->names_by_alpha, nm);
   g_ptr_set_add (cx->names_by_use, nm);  
224    
225    app_ip_name_changed (nm);    app_ip_name_changed (nm);
226    
# Line 249  app_ip_name_dispose (GObject *object) Line 240  app_ip_name_dispose (GObject *object)
240      g_critical ("use=%d for unreferenced AppIpName `%s'",      g_critical ("use=%d for unreferenced AppIpName `%s'",
241                  nm->use_count, nm->name);                  nm->use_count, nm->name);
242    
   g_ptr_set_remove (nm->tx->names_by_use, nm);  
243    g_ptr_set_remove (nm->tx->names_by_alpha, nm);    g_ptr_set_remove (nm->tx->names_by_alpha, nm);
244    
245    app_ip_name_changed (nm);    app_ip_name_changed (nm);

Legend:
Removed from v.1.1.1.1  
changed lines
  Added in v.1.2

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