OpenClonk
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros
fileicon.h File Reference
#include <gdk-pixbuf/gdk-pixbuf.h>
#include <gtk/gtk.h>
#include "mape/forward.h"
Include dependency graph for fileicon.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

struct  MapeFileIcon_
 
struct  MapeFileIconSet_
 

Typedefs

typedef enum MapeFileIconType_ MapeFileIconType
 

Enumerations

enum  MapeFileIconType_ {
  MAPE_FILE_ICON_DRIVE, MAPE_FILE_ICON_FOLDER, MAPE_FILE_ICON_C4GROUP, MAPE_FILE_ICON_C4SCENARIO,
  MAPE_FILE_ICON_C4OBJECT, MAPE_FILE_ICON_C4FOLDER, MAPE_FILE_ICON_C4MATERIAL, MAPE_FILE_ICON_COUNT
}
 

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)
 

Class Documentation

struct MapeFileIcon_

Definition at line 36 of file fileicon.h.

Class Members
GdkPixbuf * pixbuf
MapeFileIconType type
struct MapeFileIconSet_

Definition at line 41 of file fileicon.h.

Collaboration diagram for MapeFileIconSet_:
[legend]
Class Members
MapeFileIcon * icons[MAPE_FILE_ICON_COUNT]

Typedef Documentation

Enumeration Type Documentation

Enumerator
MAPE_FILE_ICON_DRIVE 
MAPE_FILE_ICON_FOLDER 
MAPE_FILE_ICON_C4GROUP 
MAPE_FILE_ICON_C4SCENARIO 
MAPE_FILE_ICON_C4OBJECT 
MAPE_FILE_ICON_C4FOLDER 
MAPE_FILE_ICON_C4MATERIAL 
MAPE_FILE_ICON_COUNT 

Definition at line 24 of file fileicon.h.

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: