forgotten commit. disabled until egl is adapted.
[AROS-Contrib.git] / gfx / lunapaint / src / app / layers.h
blob29a2daf5d19f237d443a50c7e5e8d2a9ecfd0fe2
1 /****************************************************************************
2 * *
3 * layers.h -- Lunapaint, *
4 * http://developer.berlios.de/projects/lunapaintami/ *
5 * Copyright (C) 2006, 2007, Hogne Titlestad <hogga@sub-ether.org> *
6 * Copyright (C) 2009-2011 LunaPaint Development Team *
7 * *
8 * This program is free software; you can redistribute it and/or modify *
9 * it under the terms of the GNU General Public License as published by *
10 * the Free Software Foundation; either version 2 of the License, or *
11 * (at your option) any later version. *
12 * *
13 * This program is distributed in the hope that it will be useful, *
14 * but WITHOUT ANY WARRANTY; without even the implied warranty of *
15 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
16 * GNU General Public License for more details. *
17 * *
18 * You should have received a copy of the GNU General Public License *
19 * along with this program; if not, write to the Free Software Foundation, *
20 * Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. *
21 * *
22 ****************************************************************************/
24 #ifndef _layers_h_
25 #define _layers_h_
27 #include <stdio.h>
29 #ifndef __AROS__
30 #include "aros/aros.h"
31 #endif
33 #include <exec/types.h>
34 #include <libraries/mui.h>
35 #include <cybergraphx/cybergraphics.h>
37 #include <proto/utility.h>
38 #include <proto/exec.h>
39 #include <proto/intuition.h>
40 #include <proto/gadtools.h>
41 #include <proto/muimaster.h>
42 #include <proto/graphics.h>
43 #include <proto/cybergraphics.h>
44 #include <clib/alib_protos.h>
45 #include <string.h>
47 #ifndef __AROS__
48 #include "aros/aros.h"
49 #endif
51 #include "canvas.h"
53 #include "config.h"
55 extern Object *WindowLayers;
56 extern Object *WidgetLayers;
57 extern Object *ScrollLayers;
58 extern Object *BtnAddLayer;
59 extern Object *BtnDelLayer;
60 extern Object *BtnSwapLayer;
61 extern Object *BtnMergeLayer;
62 extern Object *BtnCopyLayer;
63 extern Object *LayerOpacity;
64 extern Object *LayerName;
65 extern Object *LayerVisible;
66 extern Object *LayerControlGroup;
67 extern Object *LayerOpacityValue;
69 extern unsigned int *LayersWidgetTmpBuf;
70 extern unsigned int layersWidgetWidth;
71 extern unsigned int layersWidgetHeight;
72 extern int layersLastScrollPos;
73 extern int layersUpdateX, layersUpdateY, layersUpdateW, layersUpdateH;
75 extern struct Hook changeOpacityHook;
76 extern struct Hook acknowledgeOpacity;
77 extern struct Hook acknowledgeLayName;
78 extern struct Hook changeVisibilityHook;
79 extern struct oCanvas* lastDrawnCanvas;
80 extern BOOL forceLayerRedraw;
83 This function initializes the layer window and the widget
85 void Init_LayersWindow ( );
88 This function returns the dimensions of the layer widget
90 IPTR layerMinMax ( Class *CLASS, Object *self, struct MUIP_AskMinMax *message );
93 Blank box on the layer widget
95 void layerRenderBlank ( );
98 This function renders the layer widget
100 BOOL layerRender ( Class *CLASS, Object *self );
103 Render OS friendly text to the layer preview
105 void RenderLayerNames ( int x, int y, int w, int h );
108 This function handles input on the layer widget
110 IPTR layerHandleInput ( Class *CLASS, Object *self, struct MUIP_HandleInput *msg );
113 Repaint the actual widget
115 void layersRepaintWindow ( Class *CLASS, Object *self );
118 Clean up
120 void Exit_LayersWindow ( );
123 #endif