Skip to content

Commit

Permalink
Fix nogtksource mishap
Browse files Browse the repository at this point in the history
  • Loading branch information
diamondburned committed Aug 24, 2024
1 parent 9a47dd7 commit 99096aa
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 4 deletions.
8 changes: 8 additions & 0 deletions internal/messages/composer/input_good_os.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ import (
"log/slog"

"github.com/diamondburned/gotk4/pkg/gtk/v4"
"github.com/diamondburned/gotkit/app"
"github.com/diamondburned/gotkit/app/prefs"
"libdb.so/gotk4-sourceview/pkg/gtksource/v5"
"libdb.so/gotk4-spelling/pkg/spelling"
Expand All @@ -17,6 +18,13 @@ var spellCheck = prefs.NewBool(true, prefs.PropMeta{
Description: "Enable spell checking in the composer.",
})

func init() {
app.Hook(func(*app.Application) {
gtksource.Init()
spelling.Init()
})
}

func initializeInput() initializedInput {
languageManager := gtksource.LanguageManagerGetDefault()
spellChecker := spelling.CheckerGetDefault()
Expand Down
4 changes: 0 additions & 4 deletions main.go
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,6 @@ import (
"libdb.so/dissent/internal/gtkcord"
"libdb.so/dissent/internal/window"
"libdb.so/dissent/internal/window/about"
"libdb.so/gotk4-sourceview/pkg/gtksource/v5"
"libdb.so/gotk4-spelling/pkg/spelling"

_ "github.com/diamondburned/gotkit/gtkutil/aggressivegc"
_ "libdb.so/dissent/internal/icons"
Expand Down Expand Up @@ -60,8 +58,6 @@ func init() {
app.Hook(func(*app.Application) {
adw.Init()
adaptive.Init()
spelling.Init()
gtksource.Init()
})
}

Expand Down

0 comments on commit 99096aa

Please sign in to comment.