OpenClonk
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros
fileicon.c File Reference
#include <stdlib.h>
#include <gtk/gtk.h>
#include "mape/fileicon.h"
Include dependency graph for fileicon.c:

Go to the source code of this file.

Functions

MapeFileIconSetmape_file_icon_set_new (GtkWidget *widget)
 
void mape_file_icon_set_destroy (MapeFileIconSet *set)
 
MapeFileIconmape_file_icon_set_lookup (MapeFileIconSet *set, MapeFileIconType type)
 
GdkPixbuf * mape_file_icon_get (MapeFileIcon *icon)
 

Function Documentation

GdkPixbuf* mape_file_icon_get ( MapeFileIcon icon)

Definition at line 137 of file fileicon.c.

References MapeFileIcon_::pixbuf.

Referenced by mape_mat_tex_view_reload().

138 {
139  return icon->pixbuf;
140 }
GdkPixbuf * pixbuf
Definition: fileicon.h:38

Here is the caller graph for this function:

void mape_file_icon_set_destroy ( MapeFileIconSet set)

Definition at line 122 of file fileicon.c.

References MapeFileIconSet_::icons, and MAPE_FILE_ICON_COUNT.

Referenced by mape_window_destroy(), and mape_window_new().

123 {
124  unsigned int i;
125  for(i = 0; i < MAPE_FILE_ICON_COUNT; ++ i)
126  mape_file_icon_destroy(set->icons[i]);
127 }
MapeFileIcon * icons[MAPE_FILE_ICON_COUNT]
Definition: fileicon.h:42

Here is the caller graph for this function:

MapeFileIcon* mape_file_icon_set_lookup ( MapeFileIconSet set,
MapeFileIconType  type 
)

Definition at line 129 of file fileicon.c.

References MapeFileIconSet_::icons, and MAPE_FILE_ICON_COUNT.

Referenced by mape_mat_tex_view_reload().

131 {
132  g_assert(type < MAPE_FILE_ICON_COUNT);
133 
134  return set->icons[type];
135 }
MapeFileIcon * icons[MAPE_FILE_ICON_COUNT]
Definition: fileicon.h:42

Here is the caller graph for this function:

MapeFileIconSet* mape_file_icon_set_new ( GtkWidget *  widget)

Definition at line 109 of file fileicon.c.

References MapeFileIconSet_::icons, and MAPE_FILE_ICON_COUNT.

Referenced by mape_window_new().

110 {
111  MapeFileIconSet* set;
112  unsigned int i;
113 
114  set = malloc(sizeof(MapeFileIconSet) );
115 
116  for(i = 0; i < MAPE_FILE_ICON_COUNT; ++ i)
117  set->icons[i] = mape_file_icon_new(widget, (MapeFileIconType)i);
118 
119  return set;
120 }
MapeFileIcon * icons[MAPE_FILE_ICON_COUNT]
Definition: fileicon.h:42
enum MapeFileIconType_ MapeFileIconType

Here is the caller graph for this function: