mirror of
https://github.com/tuxbox-neutrino/neutrino.git
synced 2025-08-29 16:31:11 +02:00
CComponentsShapeSircle: fix segfault on init
This commit is contained in:
@@ -389,4 +389,16 @@ class CComponentsTitleBar : public CComponentsItemBox
|
||||
|
||||
};
|
||||
|
||||
|
||||
class CComponentsForm : public CComponentsContainer
|
||||
{
|
||||
private:
|
||||
|
||||
public:
|
||||
CComponentsForm();
|
||||
|
||||
void paint(bool do_save_bg = CC_SAVE_SCREEN_YES);
|
||||
|
||||
};
|
||||
|
||||
#endif
|
||||
|
@@ -455,8 +455,7 @@ CComponentsShapeCircle::CComponentsShapeCircle( int x_pos, int y_pos, int diam,
|
||||
//CComponents
|
||||
x = x_pos;
|
||||
y = y_pos;
|
||||
width = d;
|
||||
height = d;
|
||||
//width = height = d = diam;
|
||||
shadow = has_shadow;
|
||||
shadow_w = SHADOW_OFFSET;
|
||||
col_frame = color_frame;
|
||||
@@ -467,7 +466,7 @@ CComponentsShapeCircle::CComponentsShapeCircle( int x_pos, int y_pos, int diam,
|
||||
bgMode = CC_BGMODE_PERMANENT;
|
||||
|
||||
//CComponentsShapeCircle
|
||||
d = diam;
|
||||
width = height = d = diam;
|
||||
|
||||
//CComponentsContainer
|
||||
corner_rad = d/2;
|
||||
@@ -1314,3 +1313,17 @@ void CComponentsTitleBar::paint(bool do_save_bg)
|
||||
paintItemBox(do_save_bg);
|
||||
}
|
||||
|
||||
|
||||
//-------------------------------------------------------------------------------------------------------
|
||||
//sub class CComponentsForm from CComponentsItemBox
|
||||
CComponentsForm::CComponentsForm()
|
||||
{
|
||||
//CComponentsContainer
|
||||
initVarContainer();
|
||||
}
|
||||
|
||||
void CComponentsForm::paint(bool do_save_bg)
|
||||
{
|
||||
paintInit(do_save_bg);
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user