File: Icon.cc

package info (click to toggle)
wbar 1.3.3%2Bdfsg2-1
  • links: PTS
  • area: main
  • in suites: squeeze, wheezy
  • size: 224 kB
  • ctags: 201
  • sloc: cpp: 1,307; sh: 102; makefile: 70
file content (17 lines) | stat: -rw-r--r-- 381 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
#include "Icon.h"

using namespace std;

Icon::Icon(string iconImg, string cmd, int xx, int yy) :
    ox(xx), oy(yy), x(xx), y(yy), need_update(1), cx(xx), command(cmd){

    if( !(icon = LOAD_IMAGE(iconImg.c_str())) )
	throw (iconImg + " -> Couldn't load icon image.").c_str();

    USE_IMAGE(icon);
    osize = size = IMAGE_WIDTH();
}    

Icon::~Icon(){
    FREE_IMAGE(icon);
}