From f04d64869f3b1de54fb343f28f955584780001b8 Mon Sep 17 00:00:00 2001 From: mataes2007 Date: Sat, 26 Nov 2011 15:41:10 +0000 Subject: Project folders rename part 3 git-svn-id: http://miranda-plugins.googlecode.com/svn/trunk@215 e753b5eb-9565-29b2-b5c5-2cc6f99dfbcb --- skinengine/src/skin_object.cpp | 116 ----------------------------------------- 1 file changed, 116 deletions(-) delete mode 100644 skinengine/src/skin_object.cpp (limited to 'skinengine/src/skin_object.cpp') diff --git a/skinengine/src/skin_object.cpp b/skinengine/src/skin_object.cpp deleted file mode 100644 index 3224191..0000000 --- a/skinengine/src/skin_object.cpp +++ /dev/null @@ -1,116 +0,0 @@ -#include "headers.h" - -static int sttParseTextToInt(const TCHAR *str) -{ - if (!str) return 0; - if (!lstrcmp(str, _T("auto"))) return -1; - return _ttoi(str); -} - -void CSkinObject::LoadFromXml(HXML hXml) -{ - m_width = sttParseTextToInt(xi.getAttrValue(hXml, _T("width"))); - m_height = sttParseTextToInt(xi.getAttrValue(hXml, _T("height"))); -} - -void CSkinObject::SetParent(ISkinElement *parent) -{ - if (m_parent) m_parent->RemoveChild(this); - m_parent = parent; -} - -void CSkinObject::SetId(const TCHAR *id) -{ - if (m_id) free(m_id); - m_id = _tcsdup(id); -} - -void CSkinObject::SetDataSource(ISkinDataSource *ds) -{ - m_ds = ds; -} - -void CSkinObject::Destroy() -{ - delete this; -} - -void CSkinObject::Measure(SkinRenderParams *params) -{ - SetRect(¶ms->rc, 0, 0, m_width, m_height); -} - -void CSkinObject::Layout(SkinRenderParams *params) -{ - m_rcPosition = params->rc; -} - -bool CSkinObject::IsComplexObject() -{ - return false; -} - -ISkinElement *CSkinObject::GetParent() -{ - return m_parent; -} - -int CSkinObject::GetChildCount() -{ - return 0; -} - -ISkinElement *CSkinObject::GetChild(int index) -{ - return NULL; -} - -bool CSkinObject::AppendChild(ISkinElement *child) -{ - return false; -} - -bool CSkinObject::InsertChild(ISkinElement *child, int index) -{ - return false; -} - -void CSkinObject::RemoveChild(ISkinElement *child) -{ -} - -void CSkinObject::SetPropText(const TCHAR *key, const TCHAR *value) -{ - m_properties.insert(new Property(key, value)); -} - -const TCHAR *CSkinObject::GetPropText(const TCHAR *key, const TCHAR *value) -{ - Property search(key, 0); - if (Property *result = m_properties.find(&search)) - if (result->m_type == Property::Text) - return result->m_valueText; - return NULL; -} - -void CSkinObject::SetPropInt(const TCHAR *key, int value) -{ - m_properties.insert(new Property(key, value)); - - if (!lstrcmp(key, _T("width"))) m_width = value; else - if (!lstrcmp(key, _T("height"))) m_height = value; -} - -void CSkinObject::SetPropIntText(const TCHAR *key, const TCHAR *value) -{ - SetPropInt(key, sttParseTextToInt(value)); -} - -int CSkinObject::GetPropInt(const TCHAR *key) -{ - Property search(key, 0); - if (Property *result = m_properties.find(&search)) - if (result->m_type == Property::Integer) - return result->m_valueInt; - return 0; -} -- cgit v1.2.3