~ubuntu-branches/ubuntu/jaunty/gimp/jaunty-security

« back to all changes in this revision

Viewing changes to app/display/gimpdisplayshell-filter.c

  • Committer: Bazaar Package Importer
  • Author(s): Daniel Holbach
  • Date: 2007-05-02 16:33:03 UTC
  • mfrom: (1.1.4 upstream)
  • Revision ID: james.westby@ubuntu.com-20070502163303-bvzhjzbpw8qglc4y
Tags: 2.3.16-1ubuntu1
* Resynchronized with Debian, remaining Ubuntu changes:
  - debian/rules: i18n magic.
* debian/control.in:
  - Maintainer: Ubuntu Core Developers <ubuntu-devel@lists.ubuntu.com>
* debian/patches/02_help-message.patch,
  debian/patches/03_gimp.desktop.in.in.patch,
  debian/patches/10_dont_show_wizard.patch: updated.
* debian/patches/04_composite-signedness.patch,
  debian/patches/05_add-letter-spacing.patch: dropped, used upstream.

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
/* The GIMP -- an image manipulation program
 
1
/* GIMP - The GNU Image Manipulation Program
2
2
 * Copyright (C) 1999 Manish Singh
3
3
 *
4
4
 * This program is free software; you can redistribute it and/or modify
20
20
 
21
21
#include <gtk/gtk.h>
22
22
 
 
23
#include "libgimpconfig/gimpconfig.h"
23
24
#include "libgimpwidgets/gimpwidgets.h"
24
25
 
25
26
#include "display-types.h"
26
27
 
 
28
#include "config/gimpcoreconfig.h"
 
29
 
27
30
#include "gimpdisplayshell.h"
28
31
#include "gimpdisplayshell-filter.h"
29
32
 
69
72
  gimp_display_shell_filter_changed (NULL, shell);
70
73
}
71
74
 
 
75
GimpColorDisplayStack *
 
76
gimp_display_shell_filter_new (GimpColorConfig *config)
 
77
{
 
78
  g_return_val_if_fail (GIMP_IS_COLOR_CONFIG (config), NULL);
 
79
 
 
80
  if (config->display_module)
 
81
    {
 
82
      GType type = g_type_from_name (config->display_module);
 
83
 
 
84
      if (g_type_is_a (type, GIMP_TYPE_COLOR_DISPLAY))
 
85
        {
 
86
          GimpColorDisplay      *display;
 
87
          GimpColorDisplayStack *stack;
 
88
 
 
89
          display = g_object_new (type,
 
90
                                  "config", config,
 
91
                                  NULL);
 
92
 
 
93
          stack = gimp_color_display_stack_new ();
 
94
 
 
95
          gimp_color_display_stack_add (stack, display);
 
96
          g_object_unref (display);
 
97
 
 
98
          return stack;
 
99
        }
 
100
    }
 
101
 
 
102
  return NULL;
 
103
}
 
104
 
72
105
 
73
106
/*  private functions  */
74
107