diff options
author | pescuma <pescuma@c086bb3d-8645-0410-b8da-73a8550f86e7> | 2009-01-06 05:45:37 +0000 |
---|---|---|
committer | pescuma <pescuma@c086bb3d-8645-0410-b8da-73a8550f86e7> | 2009-01-06 05:45:37 +0000 |
commit | 3abd781670e4cd7a82d5ab2966ef9f8131535b54 (patch) | |
tree | 85cc3fcad80d491c706d77ed7a399cc17349dc6f /Plugins/skins/SkinLib/DialogState.cpp | |
parent | 30f9565911217d38cefda3920f55d183d8f6e219 (diff) |
skins:
Added border to fields
State is now got through interface
It works!
git-svn-id: http://pescuma.googlecode.com/svn/trunk/Miranda@124 c086bb3d-8645-0410-b8da-73a8550f86e7
Diffstat (limited to 'Plugins/skins/SkinLib/DialogState.cpp')
-rw-r--r-- | Plugins/skins/SkinLib/DialogState.cpp | 53 |
1 files changed, 52 insertions, 1 deletions
diff --git a/Plugins/skins/SkinLib/DialogState.cpp b/Plugins/skins/SkinLib/DialogState.cpp index 8643c06..e1e7654 100644 --- a/Plugins/skins/SkinLib/DialogState.cpp +++ b/Plugins/skins/SkinLib/DialogState.cpp @@ -34,6 +34,36 @@ FieldState * DialogState::getField(const char *name) const return NULL;
}
+int DialogState::getX() const
+{
+ return 0;
+}
+
+int DialogState::getY() const
+{
+ return 0;
+}
+
+int DialogState::getLeft() const
+{
+ return getX();
+}
+
+int DialogState::getTop() const
+{
+ return getY();
+}
+
+int DialogState::getRight() const
+{
+ return getX() + getWidth();
+}
+
+int DialogState::getBottom() const
+{
+ return getY() + getHeight();
+}
+
int DialogState::getWidth() const
{
if (size.x >= 0)
@@ -78,4 +108,25 @@ int DialogState::getHorizontalBorders() const int DialogState::getVerticalBorders() const
{
return borders.getTop() + borders.getBottom();
-}
\ No newline at end of file +}
+
+RECT DialogState::getInsideRect() const
+{
+ RECT ret;
+ ret.left = borders.getLeft();
+ ret.right = ret.left + getWidth();
+ ret.top = borders.getTop();
+ ret.bottom = ret.top + getHeight();
+ return ret;
+}
+
+RECT DialogState::getRect() const
+{
+ RECT ret;
+ ret.left = 0;
+ ret.right = borders.getLeft() + getWidth() + borders.getRight();
+ ret.top = 0;
+ ret.bottom = borders.getTop() + getHeight() + borders.getBottom();
+ return ret;
+}
+
|