Implemented unarchiving constructor more or less correctly. Minor cleanup
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@16668 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
@@ -61,7 +61,10 @@ BMenuBar::BMenuBar(BMessage *data)
|
|||||||
if (data->FindInt32("_border", &border) == B_OK)
|
if (data->FindInt32("_border", &border) == B_OK)
|
||||||
SetBorder((menu_bar_border)border);
|
SetBorder((menu_bar_border)border);
|
||||||
|
|
||||||
// TODO: InitData() ??
|
menu_layout layout = B_ITEMS_IN_COLUMN;
|
||||||
|
data->FindInt32("_layout", (int32 *)&layout);
|
||||||
|
|
||||||
|
InitData(layout);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@@ -81,7 +84,7 @@ BMenuBar::Instantiate(BMessage *data)
|
|||||||
{
|
{
|
||||||
if (validate_instantiation(data, "BMenuBar"))
|
if (validate_instantiation(data, "BMenuBar"))
|
||||||
return new BMenuBar(data);
|
return new BMenuBar(data);
|
||||||
else
|
|
||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -224,9 +227,7 @@ BMenuBar::Hide()
|
|||||||
|
|
||||||
|
|
||||||
BHandler *
|
BHandler *
|
||||||
BMenuBar::ResolveSpecifier(BMessage *msg, int32 index,
|
BMenuBar::ResolveSpecifier(BMessage *msg, int32 index, BMessage *specifier, int32 form, const char *property)
|
||||||
BMessage *specifier, int32 form,
|
|
||||||
const char *property)
|
|
||||||
{
|
{
|
||||||
return BMenu::ResolveSpecifier(msg, index, specifier, form, property);
|
return BMenu::ResolveSpecifier(msg, index, specifier, form, property);
|
||||||
}
|
}
|
||||||
@@ -295,8 +296,7 @@ BMenuBar::operator=(const BMenuBar &)
|
|||||||
|
|
||||||
|
|
||||||
void
|
void
|
||||||
BMenuBar::StartMenuBar(int32 menuIndex, bool sticky, bool showMenu,
|
BMenuBar::StartMenuBar(int32 menuIndex, bool sticky, bool showMenu, BRect *specialRect)
|
||||||
BRect *specialRect)
|
|
||||||
{
|
{
|
||||||
BWindow *window = Window();
|
BWindow *window = Window();
|
||||||
if (window == NULL)
|
if (window == NULL)
|
||||||
|
|||||||
Reference in New Issue
Block a user