23
#ifndef COLORPREVIEW_H
24
#define COLORPREVIEW_H
26
#include "NuxGraphics/GLDeviceFactory.h"
27
#include "NuxGraphics/GLDeviceObjects.h"
36
class ColorDialogProxy;
38
class ColorPreview : public ActiveInterfaceObject
41
ColorPreview(float red = 0.0f, float green = 0.0f, float blue = 0.0f, eColorModel colormodel = CM_RGB);
43
virtual long ProcessEvent(IEvent &ievent, long TraverseInfo, long ProcessEventInfo);
44
virtual void Draw(GraphicsContext& GfxContext, bool force_draw);
45
virtual void DrawContent(GraphicsContext& GfxContext, bool force_draw);
46
virtual void PostDraw(GraphicsContext& GfxContext, bool force_draw);
48
sigc::signal< void, const weaksmptr(ColorEditor) > sigColorChanged;
50
void SetRed(double r);
51
void SetGreen(double g);
52
void SetBlue(double b);
54
void SetRGB(double r, double g, double b);
55
void SetRGBA(double r, double g, double b, double a);
56
void SetColor(Color rgb);
57
Color GetRGBColor() const;
60
void RecvTimer(void* v);
61
void RecvClick(int x, int y, unsigned long button_flags, unsigned long key_flags);
63
TimerFunctor* m_ChangeDetectionTimer;
64
TimerHandle* m_ChangeTimerHandler;
67
smptr(HLayout) m_hlayout;
68
smptr(CoreArea) m_ColorArea;
69
smptr(StaticTextBox) m_ColorValue;
70
ColorDialogProxy* m_DialogThreadProxy;
76
#endif // COLORPREVIEW_H
23
#ifndef COLORPREVIEW_H
24
#define COLORPREVIEW_H
26
#include "NuxGraphics/GLDeviceFactory.h"
27
#include "NuxGraphics/GLDeviceObjects.h"
36
class ColorDialogProxy;
38
class ColorPreview : public ActiveInterfaceObject
41
ColorPreview(float red = 0.0f, float green = 0.0f, float blue = 0.0f, eColorModel colormodel = CM_RGB);
43
virtual long ProcessEvent(IEvent &ievent, long TraverseInfo, long ProcessEventInfo);
44
virtual void Draw(GraphicsContext& GfxContext, bool force_draw);
45
virtual void DrawContent(GraphicsContext& GfxContext, bool force_draw);
46
virtual void PostDraw(GraphicsContext& GfxContext, bool force_draw);
48
sigc::signal< void, const weaksmptr(ColorEditor) > sigColorChanged;
50
void SetRed(double r);
51
void SetGreen(double g);
52
void SetBlue(double b);
54
void SetRGB(double r, double g, double b);
55
void SetRGBA(double r, double g, double b, double a);
56
void SetColor(Color rgb);
57
Color GetRGBColor() const;
60
void RecvTimer(void* v);
61
void RecvClick(int x, int y, unsigned long button_flags, unsigned long key_flags);
63
TimerFunctor* m_ChangeDetectionTimer;
64
TimerHandle* m_ChangeTimerHandler;
67
smptr(HLayout) m_hlayout;
68
smptr(CoreArea) m_ColorArea;
69
smptr(StaticTextBox) m_ColorValue;
70
ColorDialogProxy* m_DialogThreadProxy;
76
#endif // COLORPREVIEW_H