示例#1
0
static gboolean
gui_unique_win32_idle_open (IdleOpenData *data)
{
  /*  We want to be called again later in case that GIMP is not fully
   *  started yet.
   */
  if (! gimp_is_restored (unique_gimp))
    return TRUE;

  if (data->name)
    {
      file_open_from_command_line (unique_gimp, data->name, data->as_new);
    }
  else
    {
      /*  raise the first display  */
      GimpObject *display;

      display = gimp_container_get_first_child (unique_gimp->displays);

      gtk_window_present (GTK_WINDOW (GIMP_DISPLAY (display)->shell));
    }

  return FALSE;
}
示例#2
0
static gboolean
gui_unique_mac_idle_open (gchar *data)
{
  /*  We want to be called again later in case that GIMP is not fully
   *  started yet.
   */
  if (! gimp_is_restored (unique_gimp))
    return TRUE;

  if (data)
    {
      file_open_from_command_line (unique_gimp, data, FALSE);
    }

  return FALSE;
}
示例#3
0
gboolean
gimp_dbus_service_activate (GimpDBusService  *service,
                            GError          **dbus_error)
{
  GimpObject *display;

  g_return_val_if_fail (GIMP_IS_DBUS_SERVICE (service), FALSE);

  /*  We want to be called again later in case that GIMP is not fully
   *  started yet.
   */
  if (! gimp_is_restored (service->gimp))
    return TRUE;

  display = gimp_container_get_first_child (service->gimp->displays);

  if (display)
    gimp_display_shell_present (gimp_display_get_shell (GIMP_DISPLAY (display)));

  return TRUE;
}
示例#4
0
gboolean
gimp_dbus_service_activate (GimpDBusServiceUI     *service,
                            GDBusMethodInvocation *invocation)
{
  Gimp *gimp = GIMP_DBUS_SERVICE (service)->gimp;

  /*  We want to be called again later in case that GIMP is not fully
   *  started yet.
   */
  if (gimp_is_restored (gimp))
    {
      GimpObject *display;

      display = gimp_container_get_first_child (gimp->displays);

      if (display)
        gimp_display_shell_present (gimp_display_get_shell (GIMP_DISPLAY (display)));
    }

  gimp_dbus_service_ui_complete_activate (service, invocation);

  return TRUE;
}