Fix formatting after import
diff --git a/LockOSThread.md b/LockOSThread.md
index bb25131..e120c00 100644
--- a/LockOSThread.md
+++ b/LockOSThread.md
@@ -14,7 +14,7 @@
// Arrange that main.main runs on main thread.
func init() {
- runtime.LockOSThread()
+ runtime.LockOSThread()
}
// Main runs the main SDL service loop.
@@ -22,9 +22,9 @@
// Main does not return. If the binary needs to do other work, it
// must do it in separate goroutines.
func Main() {
- for f = range mainfunc {
- f()
- }
+ for f = range mainfunc {
+ f()
+ }
}
// queue of work to run in main thread.
@@ -32,20 +32,20 @@
// do runs f on the main thread.
func do(f func()) {
- done := make(chan bool, 1)
- mainfunc <- func() {
- f()
- done <- true
- }
- <-done
+ done := make(chan bool, 1)
+ mainfunc <- func() {
+ f()
+ done <- true
+ }
+ <-done
}
```
And then other functions you write in package sdl can be like
```
func Beep() {
- do(func() {
- // whatever must run in main thread
- })
+ do(func() {
+ // whatever must run in main thread
+ })
}
```
\ No newline at end of file