~eliasnaur/gio

fix example code in document v1 PROPOSED

Thanks! I added the "ui/app: " prefix to the subject line, but
otherwise it was good.

To git.sr.ht:~eliasnaur/gio
   41ea609..ea2ee1a  master -> master
Export patchset (mbox)
How do I use this?

Copy & paste the following snippet into your terminal to import this patchset into git:

curl -s https://lists.sr.ht/~eliasnaur/gio/%3C20190829153814.29286-1-kenshi.kamata%40gmail.com%3E/mbox | git am -3
Learn more about email & git

[PATCH] fix example code in document Export this patch

Signed-off-by: Kenshi Kamata <kenshi.kamata@gmail.com>
---
 ui/app/doc.go | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/ui/app/doc.go b/ui/app/doc.go
index 143291a..52379be 100644
--- a/ui/app/doc.go
+++ b/ui/app/doc.go
@@ -18,7 +18,7 @@ For example:
 
 	import "gioui.org/ui"
 
-	w := app.NewWindow(nil)
+	w := app.NewWindow()
 	for e := range w.Events() {
 		if e, ok := e.(app.UpdateEvent); ok {
 			ops.Reset()
@@ -47,7 +47,7 @@ For example, to display a blank but otherwise functional window:
 
 	func main() {
 		go func() {
-			w := app.NewWindow(nil)
+			w := app.NewWindow()
 			for range w.Events() {
 			}
 		}()
-- 
2.23.0
Thanks! I added the "ui/app: " prefix to the subject line, but
otherwise it was good.

To git.sr.ht:~eliasnaur/gio
   41ea609..ea2ee1a  master -> master
View this thread in the archives