]> git.saurik.com Git - wxWidgets.git/blobdiff - contrib/src/xrc/xh_stlin.cpp
changed wxXML to XRC, wx/xml/*.h->wx/xrc/*.h
[wxWidgets.git] / contrib / src / xrc / xh_stlin.cpp
diff --git a/contrib/src/xrc/xh_stlin.cpp b/contrib/src/xrc/xh_stlin.cpp
new file mode 100644 (file)
index 0000000..9418de0
--- /dev/null
@@ -0,0 +1,55 @@
+/////////////////////////////////////////////////////////////////////////////
+// Name:        xh_stbox.cpp
+// Purpose:     XML resource for wxStaticLine
+// Author:      Brian Gavin
+// Created:     2000/09/09
+// RCS-ID:      $Id$
+// Copyright:   (c) 2000 Brian Gavin
+// Licence:     wxWindows licence
+/////////////////////////////////////////////////////////////////////////////
+#ifdef __GNUG__
+#pragma implementation "xh_stlin.h"
+#endif
+
+// For compilers that support precompilation, includes "wx.h".
+#include "wx/wxprec.h"
+
+#ifdef __BORLANDC__
+    #pragma hdrstop
+#endif
+
+#include "wx/xrc/xh_stlin.h"
+#include "wx/statline.h"
+
+#if wxUSE_STATLINE
+
+wxStaticLineXmlHandler::wxStaticLineXmlHandler() 
+: wxXmlResourceHandler() 
+{
+    ADD_STYLE(wxLI_HORIZONTAL);
+    ADD_STYLE(wxLI_VERTICAL);
+    AddWindowStyles();
+}
+
+wxObject *wxStaticLineXmlHandler::DoCreateResource()
+{ 
+    wxStaticLine *line = new wxStaticLine(m_parentAsWindow,
+                                    GetID(),
+                                    GetPosition(), GetSize(),
+                                    GetStyle(wxT("style"), wxLI_HORIZONTAL),
+                                    GetName()
+                                    );
+    SetupWindow(line);
+    
+    return line;
+}
+
+
+
+bool wxStaticLineXmlHandler::CanHandle(wxXmlNode *node)
+{
+    return IsOfClass(node, wxT("wxStaticLine"));
+}
+
+#endif