~ubuntu-branches/ubuntu/oneiric/indicator-session/oneiric-proposed

« back to all changes in this revision

Viewing changes to src/apt-transaction.c

  • Committer: Package Import Robot
  • Author(s): Sebastien Bacher
  • Date: 2011-09-09 11:18:26 UTC
  • mfrom: (1.1.40 upstream)
  • Revision ID: package-import@ubuntu.com-20110909111826-5cu458yxgnu4k3nu
Tags: 0.3.5.0-0ubuntu1
* New upstream release:
  - fix the updates menu items randomly working (lp: #842946)
  - "Guest Session should not show if guest session was disabled in 
     the display manager" (lp: #835084)
  - segfault fix (lp: #840660)
  - don't display temporary guest user generated username (lp: #844272)
  - respect "show-real-name-on-panel" to hide the username (lp: #812728)

Show diffs side-by-side

added added

removed removed

Lines of Context:
160
160
  AptTransaction* self = APT_TRANSACTION(user_data);
161
161
  AptState current_state = DONT_KNOW;
162
162
  
163
 
  if (g_strcmp0(signal_name, "PropertyChanged") == 0 && self->type == SIMULATION) 
 
163
  if (g_strcmp0(signal_name, "PropertyChanged") == 0) 
164
164
  {
165
165
    gchar* prop_name= NULL;
166
166
    GVariant* value = NULL;
204
204
        current_state = UP_TO_DATE;
205
205
      }
206
206
    }
 
207
    if (self->type == REAL)
 
208
    {
 
209
      GVariant* role = g_dbus_proxy_get_cached_property (self->proxy,
 
210
                                                         "Role");
 
211
      if (g_variant_is_of_type (role, G_VARIANT_TYPE_STRING) == TRUE){
 
212
        gchar* current_role = NULL;
 
213
        g_variant_get (role, "s", &current_role);
 
214
        //g_debug ("Current transaction role = %s", current_role);
 
215
        if (g_strcmp0 (current_role, "role-commit-packages") == 0 ||
 
216
            g_strcmp0 (current_role, "role-upgrade-system") == 0){
 
217
          g_debug ("UPGRADE IN PROGRESS");
 
218
          current_state = UPGRADE_IN_PROGRESS;                        
 
219
        }
 
220
      }
 
221
    } 
207
222
  }
208
 
  else if (g_strcmp0(signal_name, "PropertyChanged") == 0 &&
209
 
           self->type == REAL)
210
 
  {
211
 
    GVariant* role = g_dbus_proxy_get_cached_property (self->proxy,
212
 
                                                       "Role");
213
 
    if (g_variant_is_of_type (role, G_VARIANT_TYPE_STRING) == TRUE){
214
 
      gchar* current_role = NULL;
215
 
      g_variant_get (role, "s", &current_role);
216
 
      //g_debug ("Current transaction role = %s", current_role);
217
 
      if (g_strcmp0 (current_role, "role-commit-packages") == 0 ||
218
 
          g_strcmp0 (current_role, "role-upgrade-system") == 0){
219
 
        g_debug ("UPGRADE IN PROGRESS");
220
 
        current_state = UPGRADE_IN_PROGRESS;                        
221
 
      }
222
 
    }
223
 
  } 
224
223
  else if (g_strcmp0(signal_name, "Finished") == 0) 
225
224
  {
226
225
    g_debug ("TRANSACTION Finished");