1 /* 2 * pixbufs.c 3 * 4 * Copyright 2010 Alexander Petukhov <devel(at)apetukhov.ru> 5 * 6 * This program is free software; you can redistribute it and/or modify 7 * it under the terms of the GNU General Public License as published by 8 * the Free Software Foundation; either version 2 of the License, or 9 * (at your option) any later version. 10 * 11 * This program is distributed in the hope that it will be useful, 12 * but WITHOUT ANY WARRANTY; without even the implied warranty of 13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 * GNU General Public License for more details. 15 * 16 * You should have received a copy of the GNU General Public License 17 * along with this program; if not, write to the Free Software 18 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, 19 * MA 02110-1301, USA. 20 */ 21 22 /* 23 * pixbuffers 24 */ 25 26 #include <gtk/gtk.h> 27 28 #include "pixbuf.h" 29 30 #include "xpm/breakpoint.xpm" 31 #include "xpm/breakpoint_disabled.xpm" 32 #include "xpm/breakpoint_condition.xpm" 33 34 #include "xpm/argument.xpm" 35 #include "xpm/local.xpm" 36 #include "xpm/watch.xpm" 37 38 #include "xpm/frame.xpm" 39 #include "xpm/frame_current.xpm" 40 41 GdkPixbuf *break_pixbuf = NULL; 42 GdkPixbuf *break_disabled_pixbuf = NULL; 43 GdkPixbuf *break_condition_pixbuf = NULL; 44 45 GdkPixbuf *argument_pixbuf = NULL; 46 GdkPixbuf *local_pixbuf = NULL; 47 GdkPixbuf *watch_pixbuf = NULL; 48 49 GdkPixbuf *frame_pixbuf = NULL; 50 GdkPixbuf *frame_current_pixbuf = NULL; 51 52 /* 53 * create pixbuffers 54 */ pixbufs_init(void)55void pixbufs_init(void) 56 { 57 break_pixbuf = gdk_pixbuf_new_from_xpm_data(breakpoint_xpm); 58 break_disabled_pixbuf = gdk_pixbuf_new_from_xpm_data(breakpoint_disabled_xpm); 59 break_condition_pixbuf = gdk_pixbuf_new_from_xpm_data(breakpoint_condition_xpm); 60 61 argument_pixbuf = gdk_pixbuf_new_from_xpm_data(argument_xpm); 62 local_pixbuf = gdk_pixbuf_new_from_xpm_data(local_xpm); 63 watch_pixbuf = gdk_pixbuf_new_from_xpm_data(watch_xpm); 64 65 frame_pixbuf = gdk_pixbuf_new_from_xpm_data(frame_xpm); 66 frame_current_pixbuf = gdk_pixbuf_new_from_xpm_data(frame_current_xpm); 67 } 68 69 /* 70 * free pixbuffers 71 */ pixbufs_destroy(void)72void pixbufs_destroy(void) 73 { 74 g_object_unref(break_pixbuf); 75 g_object_unref(break_disabled_pixbuf); 76 g_object_unref(break_condition_pixbuf); 77 78 g_object_unref(argument_pixbuf); 79 g_object_unref(local_pixbuf); 80 g_object_unref(watch_pixbuf); 81 82 g_object_unref(frame_pixbuf); 83 g_object_unref(frame_current_pixbuf); 84 } 85 86