mirror of
https://github.com/levinsv/pgadmin3.git
synced 2026-05-15 14:15:49 -06:00
78 lines
2.7 KiB
Text
78 lines
2.7 KiB
Text
#ifndef DISABLED_PNG_H
|
|
#define DISABLED_PNG_H
|
|
|
|
static const unsigned char disabled_png_data[] = {
|
|
0x89, 0x50, 0x4e, 0x47, 0x0d, 0x0a, 0x1a, 0x0a,
|
|
0x00, 0x00, 0x00, 0x0d, 0x49, 0x48, 0x44, 0x52,
|
|
0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0x00, 0x10,
|
|
0x04, 0x03, 0x00, 0x00, 0x00, 0xed, 0xdd, 0xe2,
|
|
0x52, 0x00, 0x00, 0x00, 0x0f, 0x50, 0x4c, 0x54,
|
|
0x45, 0x00, 0x00, 0x00, 0x80, 0x80, 0x80, 0xff,
|
|
0xff, 0xff, 0x40, 0x40, 0x40, 0xd4, 0xd0, 0xc8,
|
|
0x11, 0xa7, 0xec, 0x07, 0x00, 0x00, 0x00, 0x01,
|
|
0x74, 0x52, 0x4e, 0x53, 0x00, 0x40, 0xe6, 0xd8,
|
|
0x66, 0x00, 0x00, 0x00, 0x01, 0x62, 0x4b, 0x47,
|
|
0x44, 0x02, 0x66, 0x0b, 0x7c, 0x64, 0x00, 0x00,
|
|
0x00, 0x09, 0x70, 0x48, 0x59, 0x73, 0x00, 0x00,
|
|
0x00, 0x48, 0x00, 0x00, 0x00, 0x48, 0x00, 0x46,
|
|
0xc9, 0x6b, 0x3e, 0x00, 0x00, 0x00, 0x26, 0x49,
|
|
0x44, 0x41, 0x54, 0x08, 0xd7, 0x63, 0x60, 0xc0,
|
|
0x00, 0x8c, 0x82, 0x20, 0x20, 0x04, 0x64, 0x18,
|
|
0x83, 0x80, 0x13, 0x90, 0x61, 0x08, 0x12, 0xa1,
|
|
0x26, 0xc3, 0x05, 0x04, 0x80, 0x0c, 0x26, 0x25,
|
|
0x30, 0x40, 0x58, 0x0e, 0x00, 0xa1, 0x61, 0x0a,
|
|
0x88, 0xb6, 0x0f, 0xc2, 0xed, 0x00, 0x00, 0x00,
|
|
0x25, 0x74, 0x45, 0x58, 0x74, 0x64, 0x61, 0x74,
|
|
0x65, 0x3a, 0x63, 0x72, 0x65, 0x61, 0x74, 0x65,
|
|
0x00, 0x32, 0x30, 0x31, 0x30, 0x2d, 0x31, 0x32,
|
|
0x2d, 0x30, 0x31, 0x54, 0x32, 0x30, 0x3a, 0x34,
|
|
0x33, 0x3a, 0x34, 0x34, 0x2b, 0x30, 0x35, 0x3a,
|
|
0x30, 0x30, 0x38, 0x99, 0x25, 0x1e, 0x00, 0x00,
|
|
0x00, 0x25, 0x74, 0x45, 0x58, 0x74, 0x64, 0x61,
|
|
0x74, 0x65, 0x3a, 0x6d, 0x6f, 0x64, 0x69, 0x66,
|
|
0x79, 0x00, 0x32, 0x30, 0x31, 0x30, 0x2d, 0x30,
|
|
0x39, 0x2d, 0x30, 0x38, 0x54, 0x30, 0x31, 0x3a,
|
|
0x30, 0x33, 0x3a, 0x35, 0x39, 0x2b, 0x30, 0x36,
|
|
0x3a, 0x30, 0x30, 0x68, 0xc6, 0x93, 0x0c, 0x00,
|
|
0x00, 0x00, 0x00, 0x49, 0x45, 0x4e, 0x44, 0xae,
|
|
0x42, 0x60, 0x82,
|
|
};
|
|
|
|
#include "wx/mstream.h"
|
|
|
|
static wxImage *disabled_png_img()
|
|
{
|
|
if (!wxImage::FindHandler(wxT("PNG file")))
|
|
wxImage::AddHandler(new wxPNGHandler());
|
|
static wxImage *img_disabled_png = new wxImage();
|
|
if (!img_disabled_png || !img_disabled_png->IsOk())
|
|
{
|
|
wxMemoryInputStream img_disabled_pngIS(disabled_png_data, sizeof(disabled_png_data));
|
|
img_disabled_png->LoadFile(img_disabled_pngIS, wxBITMAP_TYPE_PNG);
|
|
}
|
|
return img_disabled_png;
|
|
}
|
|
#define disabled_png_img disabled_png_img()
|
|
|
|
static wxBitmap *disabled_png_bmp()
|
|
{
|
|
static wxBitmap *bmp_disabled_png;
|
|
if (!bmp_disabled_png || !bmp_disabled_png->IsOk())
|
|
bmp_disabled_png = new wxBitmap(*disabled_png_img);
|
|
return bmp_disabled_png;
|
|
}
|
|
#define disabled_png_bmp disabled_png_bmp()
|
|
|
|
static wxIcon *disabled_png_ico()
|
|
{
|
|
static wxIcon *ico_disabled_png;
|
|
if (!ico_disabled_png || !ico_disabled_png->IsOk())
|
|
{
|
|
ico_disabled_png = new wxIcon();
|
|
ico_disabled_png->CopyFromBitmap(*disabled_png_bmp);
|
|
}
|
|
return ico_disabled_png;
|
|
}
|
|
#define disabled_png_ico disabled_png_ico()
|
|
|
|
#endif // DISABLED_PNG_H
|