2 * Copyright (C) 2010 Stephan Aßmus <superstippi@gmx.de>
4 * All rights reserved. Distributed under the terms of the MIT License.
10 #include <Messenger.h>
22 class TabContainerGroup
;
23 class TabContainerView
;
24 class TabManagerController
;
28 TabManager(const BMessenger
& target
,
29 BMessage
* newTabMessage
);
30 virtual ~TabManager();
32 void SetTarget(const BMessenger
& target
);
33 const BMessenger
& Target() const;
35 #if INTEGRATE_MENU_INTO_TAB_BAR
39 BView
* TabGroup() const;
40 BView
* GetTabContainerView() const;
41 BView
* ContainerView() const;
43 BView
* ViewForTab(int32 tabIndex
) const;
44 int32
TabForView(const BView
* containedView
) const;
45 bool HasView(const BView
* containedView
) const;
47 void SelectTab(int32 tabIndex
);
48 void SelectTab(const BView
* containedView
);
49 int32
SelectedTabIndex() const;
50 void CloseTab(int32 tabIndex
);
52 void AddTab(BView
* view
, const char* label
,
54 BView
* RemoveTab(int32 index
);
55 int32
CountTabs() const;
57 void SetTabLabel(int32 tabIndex
, const char* label
);
58 const BString
& TabLabel(int32
);
59 void SetTabIcon(const BView
* containedView
,
61 void SetCloseButtonsAvailable(bool available
);
64 #if INTEGRATE_MENU_INTO_TAB_BAR
67 TabContainerGroup
* fTabContainerGroup
;
68 TabContainerView
* fTabContainerView
;
69 BView
* fContainerView
;
70 BCardLayout
* fCardLayout
;
71 TabManagerController
* fController
;
76 #endif // TAB_MANAGER_H