Archived
2
0

move config from types.

This commit is contained in:
Miroslav Šedivý 2022-09-12 22:18:18 +02:00
parent c0ca073b2d
commit 29f67fad06
18 changed files with 20 additions and 21 deletions

View File

@ -5,7 +5,7 @@ import (
"github.com/spf13/cobra" "github.com/spf13/cobra"
"m1k1o/neko" "m1k1o/neko"
"m1k1o/neko/internal/types/config" "m1k1o/neko/internal/config"
) )
func init() { func init() {

View File

@ -7,7 +7,7 @@ import (
"github.com/rs/zerolog/log" "github.com/rs/zerolog/log"
"m1k1o/neko/internal/capture/gst" "m1k1o/neko/internal/capture/gst"
"m1k1o/neko/internal/types/config" "m1k1o/neko/internal/config"
) )
type BroadcastManager struct { type BroadcastManager struct {

View File

@ -5,9 +5,9 @@ import (
"time" "time"
"m1k1o/neko/internal/capture/gst" "m1k1o/neko/internal/capture/gst"
"m1k1o/neko/internal/config"
"m1k1o/neko/internal/desktop/xorg" "m1k1o/neko/internal/desktop/xorg"
"m1k1o/neko/internal/types" "m1k1o/neko/internal/types"
"m1k1o/neko/internal/types/config"
"github.com/kataras/go-events" "github.com/kataras/go-events"
"github.com/rs/zerolog" "github.com/rs/zerolog"

View File

@ -4,9 +4,9 @@ import (
"sync" "sync"
"time" "time"
"m1k1o/neko/internal/config"
"m1k1o/neko/internal/desktop/xorg" "m1k1o/neko/internal/desktop/xorg"
"m1k1o/neko/internal/types" "m1k1o/neko/internal/types"
"m1k1o/neko/internal/types/config"
"github.com/rs/zerolog" "github.com/rs/zerolog"
"github.com/rs/zerolog/log" "github.com/rs/zerolog/log"

View File

@ -11,8 +11,8 @@ import (
"github.com/rs/zerolog" "github.com/rs/zerolog"
"github.com/rs/zerolog/log" "github.com/rs/zerolog/log"
"m1k1o/neko/internal/config"
"m1k1o/neko/internal/types" "m1k1o/neko/internal/types"
"m1k1o/neko/internal/types/config"
) )
type Server struct { type Server struct {

View File

@ -1,5 +1,17 @@
package types package types
type ScreenSize struct {
Width int `json:"width"`
Height int `json:"height"`
Rate int16 `json:"rate"`
}
type ScreenConfiguration struct {
Width int `json:"width"`
Height int `json:"height"`
Rates map[int]int16 `json:"rates"`
}
type DesktopManager interface { type DesktopManager interface {
Start() Start()
Shutdown() error Shutdown() error

View File

@ -1,13 +0,0 @@
package types
type ScreenSize struct {
Width int `json:"width"`
Height int `json:"height"`
Rate int16 `json:"rate"`
}
type ScreenConfiguration struct {
Width int `json:"width"`
Height int `json:"height"`
Rates map[int]int16 `json:"rates"`
}

View File

@ -14,8 +14,8 @@ import (
"github.com/rs/zerolog" "github.com/rs/zerolog"
"github.com/rs/zerolog/log" "github.com/rs/zerolog/log"
"m1k1o/neko/internal/config"
"m1k1o/neko/internal/types" "m1k1o/neko/internal/types"
"m1k1o/neko/internal/types/config"
) )
func New(sessions types.SessionManager, capture types.CaptureManager, desktop types.DesktopManager, config *config.WebRTC) *WebRTCManager { func New(sessions types.SessionManager, capture types.CaptureManager, desktop types.DesktopManager, config *config.WebRTC) *WebRTCManager {

View File

@ -11,8 +11,8 @@ import (
"github.com/rs/zerolog" "github.com/rs/zerolog"
"github.com/rs/zerolog/log" "github.com/rs/zerolog/log"
"m1k1o/neko/internal/config"
"m1k1o/neko/internal/types" "m1k1o/neko/internal/types"
"m1k1o/neko/internal/types/config"
"m1k1o/neko/internal/types/event" "m1k1o/neko/internal/types/event"
"m1k1o/neko/internal/types/message" "m1k1o/neko/internal/types/message"
"m1k1o/neko/internal/utils" "m1k1o/neko/internal/utils"

View File

@ -7,10 +7,10 @@ import (
"runtime" "runtime"
"m1k1o/neko/internal/capture" "m1k1o/neko/internal/capture"
"m1k1o/neko/internal/config"
"m1k1o/neko/internal/desktop" "m1k1o/neko/internal/desktop"
"m1k1o/neko/internal/http" "m1k1o/neko/internal/http"
"m1k1o/neko/internal/session" "m1k1o/neko/internal/session"
"m1k1o/neko/internal/types/config"
"m1k1o/neko/internal/webrtc" "m1k1o/neko/internal/webrtc"
"m1k1o/neko/internal/websocket" "m1k1o/neko/internal/websocket"