Guiliani  Version 2.6 revision 7293 (documentation build 12)
GUIFactoryManager.h
1/*
2* Copyright (C) TES Electronic Solutions GmbH,
3* All Rights Reserved.
4* Contact: info@guiliani.de
5*
6* This file is part of the Guiliani HMI framework
7* for the development of graphical user interfaces on embedded systems.
8*/
9
10#if defined(GUILIANI_STREAM_GUI)
11
12#ifndef GUIFACTORY_MANAGER_H
13#define GUIFACTORY_MANAGER_H
14
15#include "GUIStreamTypes.h"
16#include "GUIStandardFactory.h"
17#include "GUICommand.h"
18
19#include "GUIComponentManager.h"
20
22#define GETFACTORY CGUIComponentManager::GetInstance().GetFactoryManager()
23
25
52{
53 friend class CGUICompositeObject;
54 friend class CGUIComponentManager;
55
56public:
58 static void CreateInstance();
59
61 static void DeleteInstance();
62
67 void AddUserFactory(CGUIFactory* pkFactory, const eC_Bool& bDelete = true);
68
75 CGUIObject* LoadDialogFromFile(const eC_String& rkPath);
76
87 CGUIObject* LoadDialogFromFile(eC_File* pkFile);
88
96
104
112
120
121#ifdef GUILIANI_ANIMATION_ACTIVE
129#endif
130
136 {
137 return m_pkCurrentlyStreamingObject;
138 }
139
143 const eC_Bool CurrentlyStreamingObjectExists() const
144 {
145 return m_bCurrentlyStreamingObjectExists;
146 }
147
152 void SetCurrentFileName(const eC_String& kFilename)
153 {
154 m_kCurrentFileName = kFilename;
155 }
156
160 const eC_String& GetCurrentFileName() const
161 {
162 return m_kCurrentFileName;
163 }
164
168 eC_Bool DialogLoadingError() const
169 {
170 return m_bDialogLoadingError;
171 }
172
176 void SetSkipCorruptedData(const eC_Bool& bSkipCorruptedData)
177 {
178 m_bSkipCorruptedData = bSkipCorruptedData;
179 }
180
184 eC_Bool GetSkipCorruptedData() const
185 {
186 return m_bSkipCorruptedData;
187 }
188
193 {
194 return m_bDialogHasSkippedElement;
195 }
196
200 void SetDefaultStreamingMode(const FileType_t& eStreamingMode)
201 {
202 m_eDefaultStreamingMode = eStreamingMode;
203 }
204
208 FileType_t GetDefaultStreamingMode() const
209 {
210 return m_eDefaultStreamingMode;
211 }
212
213private:
216
219
222
224 CGUIFactoryManager& operator=(const CGUIFactoryManager& kSource);
225
236 CGUIObject* LoadDialogFromStream();
237
241 void CheckNofFactoryEntries(void);
242
247 eC_Bool SkipWholeObject(const eC_String& kTagName, const eC_String& kControlID);
248
249private:
251 eC_String m_kCurrentFileName;
252
254 struct FactoryEntry
255 {
256 eC_Bool DeleteAtRemove;
257 CGUIFactory* Factory;
258 };
259
261 typedef eC_TListDoubleLinked<FactoryEntry> FactoryList;
262
264 FactoryList m_kFactories;
265
270 CGUIObject* m_pkCurrentlyStreamingObject;
271
272 eC_Bool m_bCurrentlyStreamingObjectExists;
273
275 eC_Bool m_bDialogLoadingError;
276
278 eC_Bool m_bSkipCorruptedData;
279
281 eC_Bool m_bDialogHasSkippedElement;
282
283 FileType_t m_eDefaultStreamingMode;
284};
285
286#endif // GUILIANI_STREAM_GUI
287#endif // GUIFACTORY_MANAGER_H
Base class for modular Guiliani animations.
Definition: GUIAnimation.h:75
GUIBehaviourDecorator base class.
Definition: GUIBehaviourDecorator.h:78
central component-manager
Definition: GUIComponentManager.h:62
This is the Guiliani base class for all composite objects.
Definition: GUICompositeObject.h:70
Interface for streaming factories.
Definition: GUIFactory.h:341
Manages the CGUIStandardFactory and user factories.
Definition: GUIFactoryManager.h:52
const eC_String & GetCurrentFileName() const
Definition: GUIFactoryManager.h:160
static void CreateInstance()
Creates the singleton instance of this class.
CGUIObject * LoadDialogFromFile(const eC_String &rkPath)
void SetCurrentFileName(const eC_String &kFilename)
Definition: GUIFactoryManager.h:152
CGUIBehaviourDecorator * LoadBehaviourFromStream()
CGUILayouter * LoadLayouterFromStream()
FileType_t GetDefaultStreamingMode() const
Definition: GUIFactoryManager.h:208
const eC_Bool CurrentlyStreamingObjectExists() const
Definition: GUIFactoryManager.h:143
void SetSkipCorruptedData(const eC_Bool &bSkipCorruptedData)
Definition: GUIFactoryManager.h:176
void AddUserFactory(CGUIFactory *pkFactory, const eC_Bool &bDelete=true)
CGUIObject * LoadDialogFromFile(eC_File *pkFile)
CGUIText * LoadTextFromStream()
eC_Bool DialogHasSkippedElements() const
Definition: GUIFactoryManager.h:192
eC_Bool GetSkipCorruptedData() const
Definition: GUIFactoryManager.h:184
CGUICommandPtr LoadCommandFromStream()
CGUIAnimation * LoadAnimationFromStream()
eC_Bool DialogLoadingError() const
Definition: GUIFactoryManager.h:168
void SetDefaultStreamingMode(const FileType_t &eStreamingMode)
Definition: GUIFactoryManager.h:200
const CGUIObject * GetCurrentlyStreamingObject() const
Definition: GUIFactoryManager.h:135
static void DeleteInstance()
Deletes the singleton instance of this class.
Definition: GUILayouter.h:57
This is the Guiliani base class all controls are derived from.
Definition: GUIObject.h:81
Class for handling a text.
Definition: GUIText.h:103