summaryrefslogtreecommitdiff
path: root/src/icon.cpp
diff options
context:
space:
mode:
authorDanny Baumann <dannybaumann@web.de>2008-10-14 08:13:21 +0200
committerDanny Baumann <dannybaumann@web.de>2008-10-14 08:13:21 +0200
commit436908e5988381b9c92c03fe2806731acf7ecd35 (patch)
treefb5d320861f9ae66193045183b9de630c51956e4 /src/icon.cpp
parent5cd7dce9863ec6349f37f68f67726083cd798e9a (diff)
downloadunity-window-decorator-436908e5988381b9c92c03fe2806731acf7ecd35.tar.gz
unity-window-decorator-436908e5988381b9c92c03fe2806731acf7ecd35.tar.bz2
Better use of classes in icon and image handling.
Diffstat (limited to 'src/icon.cpp')
-rw-r--r--src/icon.cpp15
1 files changed, 4 insertions, 11 deletions
diff --git a/src/icon.cpp b/src/icon.cpp
index 46cd537..aa17e35 100644
--- a/src/icon.cpp
+++ b/src/icon.cpp
@@ -29,8 +29,7 @@
CompIcon::CompIcon (CompScreen *screen, unsigned int width,
unsigned int height) :
- mWidth (width),
- mHeight (height),
+ mSize (width, height),
mData (new unsigned char[width * height * 4])
{
}
@@ -40,16 +39,10 @@ CompIcon::~CompIcon ()
delete mData;
}
-unsigned int
-CompIcon::width () const
+const CompSize &
+CompIcon::size () const
{
- return mWidth;
-}
-
-unsigned int
-CompIcon::height () const
-{
- return mHeight;
+ return mSize;
}
unsigned char*