* modified 'font' member from '*font' to 'font'. '*font' was getting the pointer to system's plain font, and worse, it modified it. Now, it's all OK.

git-svn-id: file:///srv/svn/repos/haiku/trunk/current@4682 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
Adi Oanca
2003-09-15 18:58:06 +00:00
parent 36845b1281
commit 09c067b8e4
+7 -7
View File
@@ -35,8 +35,7 @@ public:
alphaFncMode = B_ALPHA_OVERLAY; alphaFncMode = B_ALPHA_OVERLAY;
scale = 1.0; scale = 1.0;
fontAliasing = true; fontAliasing = true;
font = fontserver->GetSystemPlain(); font = *(fontserver->GetSystemPlain());
//font = NULL;
clippReg = NULL; clippReg = NULL;
@@ -51,10 +50,6 @@ public:
} }
~LayerData(void) ~LayerData(void)
{ {
if(font) {
delete font;
font = NULL;
}
if (image){ if (image){
/* NOTE: I don't know yet how bitmap allocation/deallocation /* NOTE: I don't know yet how bitmap allocation/deallocation
is managed by server. I tend to think it's a reference is managed by server. I tend to think it's a reference
@@ -84,7 +79,7 @@ public:
alpha_function alphaFncMode; alpha_function alphaFncMode;
float scale; float scale;
bool fontAliasing; bool fontAliasing;
ServerFont *font; ServerFont font;
BRegion *clippReg; BRegion *clippReg;
@@ -98,3 +93,8 @@ public:
escapement_delta edelta; escapement_delta edelta;
}; };
#endif #endif
/*
@log
* modified 'font' member from '*font' to 'font'. '*font' was getting the pointer to system's plain font, and worse, it modified it. Now, it's all OK.
*/