Optimize multi-window services

This commit is contained in:
2025-11-05 22:07:43 +08:00
parent 1f0254822f
commit df79267e16
11 changed files with 1103 additions and 218 deletions

View File

@@ -39,11 +39,11 @@ type SelfUpdateService struct {
}
// NewSelfUpdateService 创建自我更新服务实例
func NewSelfUpdateService(configService *ConfigService, badgeService *dock.DockService, notificationService *notifications.NotificationService, logger *log.LogService) (*SelfUpdateService, error) {
func NewSelfUpdateService(configService *ConfigService, badgeService *dock.DockService, notificationService *notifications.NotificationService, logger *log.LogService) *SelfUpdateService {
// 获取配置
appConfig, err := configService.GetConfig()
if err != nil {
return nil, fmt.Errorf("failed to get config: %w", err)
panic(err)
}
service := &SelfUpdateService{
@@ -55,7 +55,7 @@ func NewSelfUpdateService(configService *ConfigService, badgeService *dock.DockS
isUpdating: false,
}
return service, nil
return service
}
// CheckForUpdates 检查更新