]> git.saurik.com Git - wxWidgets.git/blame_incremental - src/xrc/xh_stlin.cpp
add support for alpha in color dialog on OSX, see #14127
[wxWidgets.git] / src / xrc / xh_stlin.cpp
... / ...
CommitLineData
1/////////////////////////////////////////////////////////////////////////////
2// Name: src/xrc/xh_stlin.cpp
3// Purpose: XRC resource for wxStaticLine
4// Author: Brian Gavin
5// Created: 2000/09/09
6// RCS-ID: $Id$
7// Copyright: (c) 2000 Brian Gavin
8// Licence: wxWindows licence
9/////////////////////////////////////////////////////////////////////////////
10
11// For compilers that support precompilation, includes "wx.h".
12#include "wx/wxprec.h"
13
14#ifdef __BORLANDC__
15 #pragma hdrstop
16#endif
17
18#if wxUSE_XRC && wxUSE_STATLINE
19
20#include "wx/xrc/xh_stlin.h"
21#include "wx/statline.h"
22
23IMPLEMENT_DYNAMIC_CLASS(wxStaticLineXmlHandler, wxXmlResourceHandler)
24
25wxStaticLineXmlHandler::wxStaticLineXmlHandler()
26: wxXmlResourceHandler()
27{
28 XRC_ADD_STYLE(wxLI_HORIZONTAL);
29 XRC_ADD_STYLE(wxLI_VERTICAL);
30 AddWindowStyles();
31}
32
33wxObject *wxStaticLineXmlHandler::DoCreateResource()
34{
35 XRC_MAKE_INSTANCE(line, wxStaticLine)
36
37 line->Create(m_parentAsWindow,
38 GetID(),
39 GetPosition(), GetSize(),
40 GetStyle(wxT("style"), wxLI_HORIZONTAL),
41 GetName());
42
43 SetupWindow(line);
44
45 return line;
46}
47
48bool wxStaticLineXmlHandler::CanHandle(wxXmlNode *node)
49{
50 return IsOfClass(node, wxT("wxStaticLine"));
51}
52
53#endif // wxUSE_XRC && wxUSE_STATLINE