summaryrefslogtreecommitdiffstatshomepage
path: root/lineedit.go
diff options
context:
space:
mode:
authorAlexander Neumann <an2048@gmail.com>2012-09-29 16:49:27 +0200
committerAlexander Neumann <an2048@gmail.com>2012-09-29 16:49:27 +0200
commitc2e0da6876614200358874e3382dadddc997d89f (patch)
tree78c1fbb3192382c674f1e0d5aaf05017c8785274 /lineedit.go
parentdeclarative: Add WebView (diff)
downloadwireguard-windows-c2e0da6876614200358874e3382dadddc997d89f.tar.xz
wireguard-windows-c2e0da6876614200358874e3382dadddc997d89f.zip
LineEdit: Fix SetPasswordMode which ignored its parameter.
Diffstat (limited to 'lineedit.go')
-rw-r--r--lineedit.go7
1 files changed, 6 insertions, 1 deletions
diff --git a/lineedit.go b/lineedit.go
index 00d75e30..577bce79 100644
--- a/lineedit.go
+++ b/lineedit.go
@@ -116,7 +116,12 @@ func (le *LineEdit) PasswordMode() bool {
}
func (le *LineEdit) SetPasswordMode(value bool) {
- le.SendMessage(EM_SETPASSWORDCHAR, uintptr('*'), 0)
+ var c uintptr
+ if value {
+ c = uintptr('*')
+ }
+
+ le.SendMessage(EM_SETPASSWORDCHAR, c, 0)
}
func (le *LineEdit) ReadOnly() bool {