The very basic client app, not adapted for mobiles.
This commit is contained in:
23
client/internal/services/core/options/models/option_pane.go
Normal file
23
client/internal/services/core/options/models/option_pane.go
Normal file
@@ -0,0 +1,23 @@
|
||||
package models
|
||||
|
||||
import (
|
||||
"bunker/client/internal/services/core/options/dto"
|
||||
|
||||
"fyne.io/fyne/v2"
|
||||
)
|
||||
|
||||
// OptionPane это описание одной панели настроек в окне настроек.
|
||||
type OptionPane struct {
|
||||
Widget fyne.CanvasObject
|
||||
SaveHandler func() error
|
||||
Name string
|
||||
}
|
||||
|
||||
// OptionPaneFromDTO конвертирует параметры панели настроек из DTO во внутреннее представление.
|
||||
func OptionPaneFromDTO(dtoData *dto.OptionPane) *OptionPane {
|
||||
return &OptionPane{
|
||||
Widget: dtoData.Widget,
|
||||
SaveHandler: dtoData.SaveHandler,
|
||||
Name: dtoData.Name,
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user