2006-11-16 03:12:15 +03:00
|
|
|
/*
|
2014-06-19 03:07:02 +04:00
|
|
|
* Copyright 2002-2010 Haiku, Inc. All rights reserved.
|
2006-11-16 03:12:15 +03:00
|
|
|
* Distributed under the terms of the MIT License.
|
|
|
|
*/
|
2002-08-12 11:24:02 +04:00
|
|
|
#ifndef _NODE_INFO_H
|
|
|
|
#define _NODE_INFO_H
|
2002-07-09 16:24:59 +04:00
|
|
|
|
2010-04-13 13:48:02 +04:00
|
|
|
|
2002-07-09 16:24:59 +04:00
|
|
|
#include <BeBuild.h>
|
|
|
|
#include <Entry.h>
|
2010-04-13 13:48:02 +04:00
|
|
|
#include <File.h>
|
|
|
|
#include <Message.h>
|
|
|
|
#include <Mime.h>
|
|
|
|
#include <SupportDefs.h>
|
2002-07-09 16:24:59 +04:00
|
|
|
|
|
|
|
|
|
|
|
class BBitmap;
|
|
|
|
class BResources;
|
|
|
|
|
|
|
|
|
|
|
|
class BNodeInfo {
|
|
|
|
public:
|
2010-04-13 13:48:02 +04:00
|
|
|
BNodeInfo();
|
|
|
|
BNodeInfo(BNode* node);
|
|
|
|
virtual ~BNodeInfo();
|
|
|
|
|
|
|
|
status_t SetTo(BNode* node);
|
|
|
|
|
|
|
|
status_t InitCheck() const;
|
|
|
|
|
|
|
|
virtual status_t GetType(char* type) const;
|
|
|
|
virtual status_t SetType(const char* type);
|
|
|
|
virtual status_t GetIcon(BBitmap* icon,
|
2014-06-19 03:07:02 +04:00
|
|
|
icon_size which = B_LARGE_ICON) const;
|
2010-04-13 13:48:02 +04:00
|
|
|
virtual status_t SetIcon(const BBitmap* icon,
|
2014-06-19 03:07:02 +04:00
|
|
|
icon_size which = B_LARGE_ICON);
|
2010-04-13 13:48:02 +04:00
|
|
|
status_t GetIcon(uint8** data, size_t* size,
|
|
|
|
type_code* type) const;
|
|
|
|
status_t SetIcon(const uint8* data, size_t size);
|
|
|
|
|
|
|
|
status_t GetPreferredApp(char* signature,
|
|
|
|
app_verb verb = B_OPEN) const;
|
|
|
|
status_t SetPreferredApp(const char* signature,
|
|
|
|
app_verb verb = B_OPEN);
|
|
|
|
status_t GetAppHint(entry_ref* ref) const;
|
|
|
|
status_t SetAppHint(const entry_ref* ref);
|
|
|
|
|
|
|
|
status_t GetTrackerIcon(BBitmap* icon,
|
2014-06-19 03:07:02 +04:00
|
|
|
icon_size which = B_LARGE_ICON) const;
|
2010-04-13 13:48:02 +04:00
|
|
|
static status_t GetTrackerIcon(const entry_ref* ref,
|
|
|
|
BBitmap* icon,
|
2014-06-19 03:07:02 +04:00
|
|
|
icon_size which = B_LARGE_ICON);
|
2002-07-09 16:24:59 +04:00
|
|
|
private:
|
2010-04-13 13:48:02 +04:00
|
|
|
friend class BAppFileInfo;
|
2002-07-09 16:24:59 +04:00
|
|
|
|
2010-04-13 13:48:02 +04:00
|
|
|
virtual void _ReservedNodeInfo1();
|
|
|
|
virtual void _ReservedNodeInfo2();
|
|
|
|
virtual void _ReservedNodeInfo3();
|
2002-07-09 16:24:59 +04:00
|
|
|
|
2010-04-13 13:48:02 +04:00
|
|
|
BNodeInfo &operator=(const BNodeInfo& other);
|
|
|
|
BNodeInfo(const BNodeInfo& other);
|
|
|
|
// not implemented
|
2002-07-09 16:24:59 +04:00
|
|
|
|
2010-04-13 13:48:02 +04:00
|
|
|
private:
|
|
|
|
BNode* fNode;
|
|
|
|
uint32 _reserved[2];
|
|
|
|
status_t fCStatus;
|
2002-07-09 16:24:59 +04:00
|
|
|
};
|
|
|
|
|
|
|
|
|
2002-08-12 11:24:02 +04:00
|
|
|
#endif // _NODE_INFO_H
|