diff options
author | Alexander Neumann <an2048@gmail.com> | 2012-09-15 17:36:36 +0200 |
---|---|---|
committer | Alexander Neumann <an2048@gmail.com> | 2012-09-15 17:36:36 +0200 |
commit | 3c3df31ed665d6fbec30e0725b875f56b3cc90a5 (patch) | |
tree | 58659964fb2b20d96310e3425b3f4ff37b6bc0d8 /groupbox.go | |
parent | WidgetBase: Remove superfluous layoutFlags field. (diff) | |
download | wireguard-windows-3c3df31ed665d6fbec30e0725b875f56b3cc90a5.tar.xz wireguard-windows-3c3df31ed665d6fbec30e0725b875f56b3cc90a5.zip |
Clean up window class registration
Diffstat (limited to 'groupbox.go')
-rw-r--r-- | groupbox.go | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/groupbox.go b/groupbox.go index 603a7e48..92382531 100644 --- a/groupbox.go +++ b/groupbox.go @@ -10,7 +10,9 @@ import . "github.com/lxn/go-winapi" const groupBoxWindowClass = `\o/ Walk_GroupBox_Class \o/` -var groupBoxWindowClassRegistered bool +func init() { + mustRegisterWindowClass(groupBoxWindowClass) +} type GroupBox struct { WidgetBase @@ -19,8 +21,6 @@ type GroupBox struct { } func NewGroupBox(parent Container) (*GroupBox, error) { - ensureRegisteredWindowClass(groupBoxWindowClass, &groupBoxWindowClassRegistered) - gb := &GroupBox{} if err := initChildWidget( |