2005-06-17 23:10:15 +04:00
|
|
|
/*
|
|
|
|
* Copyright (c) 2001-2005, Haiku, Inc.
|
|
|
|
* Distributed under the terms of the MIT license.
|
|
|
|
*
|
|
|
|
* Author: DarkWyrm <bpmagic@columbus.rr.com>
|
|
|
|
*/
|
2005-11-03 20:03:36 +03:00
|
|
|
#ifndef DECOR_MANAGER_H
|
|
|
|
#define DECOR_MANAGER_H
|
|
|
|
|
2005-06-17 23:10:15 +04:00
|
|
|
|
|
|
|
#include <image.h>
|
|
|
|
#include <String.h>
|
|
|
|
#include <Locker.h>
|
2005-11-03 20:03:36 +03:00
|
|
|
#include <ObjectList.h>
|
2005-06-17 23:10:15 +04:00
|
|
|
|
|
|
|
#include "Decorator.h"
|
|
|
|
|
|
|
|
class DecorInfo;
|
2005-11-03 20:03:36 +03:00
|
|
|
class Desktop;
|
|
|
|
|
|
|
|
|
|
|
|
class DecorManager : public BLocker {
|
|
|
|
public:
|
|
|
|
DecorManager();
|
|
|
|
~DecorManager();
|
|
|
|
|
|
|
|
void RescanDecorators();
|
|
|
|
|
|
|
|
Decorator* AllocateDecorator(Desktop* desktop, BRect rect,
|
2005-12-01 17:56:01 +03:00
|
|
|
const char *title, window_look look,
|
|
|
|
uint32 flags);
|
2005-11-03 20:03:36 +03:00
|
|
|
|
|
|
|
int32 CountDecorators() const;
|
|
|
|
|
|
|
|
int32 GetDecorator() const;
|
|
|
|
bool SetDecorator(int32 index);
|
|
|
|
bool SetR5Decorator(int32 value);
|
|
|
|
const char* GetDecoratorName(int32 index);
|
|
|
|
|
|
|
|
// TODO: Implement this method once the rest of the necessary infrastructure
|
|
|
|
// is in place
|
|
|
|
//status_t GetPreview(int32 index, ServerBitmap *bitmap);
|
|
|
|
|
|
|
|
private:
|
|
|
|
void _EmptyList();
|
|
|
|
DecorInfo* _FindDecor(const char *name);
|
2005-06-17 23:10:15 +04:00
|
|
|
|
2005-11-03 20:03:36 +03:00
|
|
|
BObjectList<DecorInfo> fDecorList;
|
|
|
|
DecorInfo* fCurrentDecor;
|
2005-06-17 23:10:15 +04:00
|
|
|
};
|
|
|
|
|
|
|
|
extern DecorManager gDecorManager;
|
|
|
|
|
2005-11-03 20:03:36 +03:00
|
|
|
#endif /* DECOR_MANAGER_H */
|