~ubuntu-branches/ubuntu/oneiric/avant-window-navigator/oneiric

« back to all changes in this revision

Viewing changes to applets/taskmanager/task-icon-build-context-menus.c

  • Committer: Bazaar Package Importer
  • Author(s): Julien Lavergne
  • Date: 2010-02-18 00:22:52 UTC
  • mfrom: (1.1.6 upstream)
  • Revision ID: james.westby@ubuntu.com-20100218002252-fe6vniq3o8ct3cdz
Tags: 0.3.9.1~bzr603-0ubuntu1
* New upstream snapshot. 
 - Switch to main trunk branch.
* debian/control:
 - Add Conflicts on awn-manager for awn-settings (LP: #507822)
 - Remove build-depends on python-elementtree.

Show diffs side-by-side

added added

removed removed

Lines of Context:
503
503
  TaskIconPrivate * priv = TASK_ICON_GET_PRIVATE(icon);
504
504
  GValueArray *launcher_paths;
505
505
  GValue val = {0,};
506
 
  TaskItem * launcher = task_icon_get_launcher (icon);
 
506
  const TaskItem * launcher = task_icon_get_launcher (icon);
507
507
  gboolean found = FALSE;
508
508
  if (launcher)
509
509
  {
825
825
  gint width;
826
826
  gint height;
827
827
  item = gtk_image_menu_item_new_with_label (_("Launch"));
828
 
  TaskItem * launcher = task_icon_get_launcher (icon);
 
828
  const TaskItem * launcher = task_icon_get_launcher (icon);
829
829
 
830
830
  if (!launcher)
831
831
  {
846
846
  gtk_widget_show (item);
847
847
  g_signal_connect_swapped (item,"activate",
848
848
                G_CALLBACK(task_item_middle_click),
849
 
                launcher);
 
849
                (gpointer)launcher);
850
850
  g_object_unref (launcher_pbuf);
851
851
  return item;
852
852
}
1137
1137
  }
1138
1138
}
1139
1139
 
 
1140
static void
 
1141
task_icon_insert_plugin_menu_items (TaskIcon * icon,GtkMenu * menu)
 
1142
{
 
1143
  TaskIconPrivate * priv = TASK_ICON_GET_PRIVATE (icon);
 
1144
  GList * i;
 
1145
 
 
1146
  for (i=priv->plugin_menu_items;i;i=i->next)
 
1147
  {
 
1148
    g_debug ("Appending plugin menu item");
 
1149
    gtk_widget_show (i->data);
 
1150
    gtk_menu_shell_append(GTK_MENU_SHELL(menu), i->data);
 
1151
  }
 
1152
}
 
1153
 
1140
1154
typedef enum{
1141
1155
      DBUS_SIGNAL,
1142
1156
      EXTERNAL_COMMAND,
1374
1388
    case EXTERNAL_COMMAND:
1375
1389
      {
1376
1390
        const TaskItem * mainitem = task_icon_get_main_item (icon);
1377
 
        TaskItem * launcher = task_icon_get_launcher (icon);
 
1391
        const TaskItem * launcher = task_icon_get_launcher (icon);
1378
1392
        if (!mainitem || !TASK_IS_WINDOW (mainitem))
1379
1393
        {
1380
1394
          break;
1444
1458
      task_icon_inline_action_menu_active (icon,GTK_MENU(menu));
1445
1459
      break;
1446
1460
    case INTERNAL_INLINE_PLUGINS:
1447
 
      g_message ("%s: stub... plugin support not present",__func__);
 
1461
      task_icon_insert_plugin_menu_items (icon, GTK_MENU (menu));
1448
1462
      break;
1449
1463
    case INTERNAL_INLINE_SUBMENUS_ACTION_MENU_INACTIVES:
1450
1464
      task_icon_get_menu_item_submenu_action_menu_inactives (icon,GTK_MENU(menu));