#include "inttypes.h"
#include "XBDateTime.h"
#include "utils/Observer.h"
+#include "interfaces/info/InfoBool.h"
#include "interfaces/info/SkinVariable.h"
#include "cores/IPlayer.h"
class CDateTime;
namespace INFO
{
- class InfoBool;
class InfoSingle;
}
#define CONTROL_HAS_FOCUS 30000
#define VERSION_MAJOR 13
-#define VERSION_MINOR 0
-#define VERSION_TAG "-ALPHA11"
+#define VERSION_MINOR 1
+#define VERSION_TAG ""
#define LISTITEM_START 35000
#define LISTITEM_THUMB (LISTITEM_START)
\param expression the boolean condition or expression
\param context the context window
\return an identifier used to reference this expression
-
- \sa GetBoolValue
*/
- unsigned int Register(const CStdString &expression, int context = 0);
-
- /*! \brief Get a previously registered boolean expression's value
- Checks the cache and evaluates the boolean expression if required.
- \sa Register
- */
- bool GetBoolValue(unsigned int expression, const CGUIListItem *item = NULL);
+ INFO::InfoPtr Register(const CStdString &expression, int context = 0);
/*! \brief Evaluate a boolean expression
\param expression the expression to evaluate
\param context the context in which to evaluate the expression (currently windows)
\return the value of the evaluated expression.
- \sa Register, GetBoolValue
+ \sa Register
*/
bool EvaluateBool(const CStdString &expression, int context = 0);
// Current song stuff
/// \brief Retrieves tag info (if necessary) and fills in our current song path.
void SetCurrentSong(CFileItem &item);
- void SetCurrentAlbumThumb(const CStdString thumbFileName);
+ void SetCurrentAlbumThumb(const CStdString &thumbFileName);
void SetCurrentMovie(CFileItem &item);
void SetCurrentSlide(CFileItem &item);
const CFileItem &GetCurrentSlide() const;
CStdString GetSkinVariableString(int info, bool preferImage = false, const CGUIListItem *item=NULL);
/// \brief iterates through boolean conditions and compares their stored values to current values. Returns true if any condition changed value.
- bool ConditionsChangedValues(const std::map<int, bool>& map);
+ bool ConditionsChangedValues(const std::map<INFO::InfoPtr, bool>& map);
bool m_AVInfoValid;
protected:
friend class INFO::InfoSingle;
bool GetBool(int condition, int contextWindow = 0, const CGUIListItem *item=NULL);
+ int TranslateSingleString(const CStdString &strCondition, bool &listItemDependent);
// routines for window retrieval
bool CheckWindowCondition(CGUIWindow *window, int condition) const;
int m_nextWindowID;
int m_prevWindowID;
- std::vector<INFO::InfoBool*> m_bools;
+ std::vector<INFO::InfoPtr> m_bools;
std::vector<INFO::CSkinVariableString> m_skinVariableStrings;
- unsigned int m_updateTime;
int m_libraryHasMusic;
int m_libraryHasMovies;