* Added BListItem::SetOutlineLevel() method.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@36713 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
@@ -1,5 +1,5 @@
|
|||||||
/*
|
/*
|
||||||
* Copyright 2006-2009, Haiku, Inc. All rights reserved.
|
* Copyright 2006-2010, Haiku, Inc. All rights reserved.
|
||||||
* Distributed under the terms of the MIT License.
|
* Distributed under the terms of the MIT License.
|
||||||
*/
|
*/
|
||||||
#ifndef _LIST_ITEM_H
|
#ifndef _LIST_ITEM_H
|
||||||
@@ -9,6 +9,7 @@
|
|||||||
#include <Archivable.h>
|
#include <Archivable.h>
|
||||||
#include <Rect.h>
|
#include <Rect.h>
|
||||||
|
|
||||||
|
|
||||||
class BFont;
|
class BFont;
|
||||||
class BList;
|
class BList;
|
||||||
class BMessage;
|
class BMessage;
|
||||||
@@ -44,6 +45,7 @@ public:
|
|||||||
bool IsExpanded() const;
|
bool IsExpanded() const;
|
||||||
void SetExpanded(bool expanded);
|
void SetExpanded(bool expanded);
|
||||||
uint32 OutlineLevel() const;
|
uint32 OutlineLevel() const;
|
||||||
|
void SetOutlineLevel(uint32 level);
|
||||||
|
|
||||||
virtual status_t Perform(perform_code code, void* arg);
|
virtual status_t Perform(perform_code code, void* arg);
|
||||||
|
|
||||||
@@ -83,7 +85,7 @@ private:
|
|||||||
|
|
||||||
|
|
||||||
inline float
|
inline float
|
||||||
BListItem::Top(void) const
|
BListItem::Top(void) const
|
||||||
{
|
{
|
||||||
return fTop;
|
return fTop;
|
||||||
}
|
}
|
||||||
@@ -99,4 +101,5 @@ BListItem::Bottom(void) const
|
|||||||
#include <StringItem.h>
|
#include <StringItem.h>
|
||||||
// to maintain source compatibility
|
// to maintain source compatibility
|
||||||
|
|
||||||
|
|
||||||
#endif // _LIST_ITEM_H
|
#endif // _LIST_ITEM_H
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
/*
|
/*
|
||||||
* Copyright 2001-2009, Haiku, Inc. All Rights Reserved.
|
* Copyright 2001-2010, Haiku, Inc. All Rights Reserved.
|
||||||
* Distributed under the terms of the MIT License.
|
* Distributed under the terms of the MIT License.
|
||||||
*
|
*
|
||||||
* Authors:
|
* Authors:
|
||||||
@@ -8,6 +8,7 @@
|
|||||||
* Rene Gollent
|
* Rene Gollent
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
#include <ListItem.h>
|
#include <ListItem.h>
|
||||||
|
|
||||||
#include <Message.h>
|
#include <Message.h>
|
||||||
@@ -65,7 +66,7 @@ BListItem::Archive(BMessage* archive, bool deep) const
|
|||||||
status_t status = BArchivable::Archive(archive, deep);
|
status_t status = BArchivable::Archive(archive, deep);
|
||||||
if (status == B_OK && fSelected)
|
if (status == B_OK && fSelected)
|
||||||
status = archive->AddBool("_sel", true);
|
status = archive->AddBool("_sel", true);
|
||||||
|
|
||||||
if (status == B_OK && !fEnabled)
|
if (status == B_OK && !fEnabled)
|
||||||
status = archive->AddBool("_disable", true);
|
status = archive->AddBool("_disable", true);
|
||||||
|
|
||||||
@@ -181,6 +182,13 @@ BListItem::OutlineLevel() const
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
void
|
||||||
|
BListItem::SetOutlineLevel(uint32 level)
|
||||||
|
{
|
||||||
|
fLevel = level;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
bool
|
bool
|
||||||
BListItem::HasSubitems() const
|
BListItem::HasSubitems() const
|
||||||
{
|
{
|
||||||
|
|||||||
Reference in New Issue
Block a user