Skip to content

Commit

Permalink
fix: dock bluetooth module is missing
Browse files Browse the repository at this point in the history
dock depends dde-session-daemon bluetooth adapter add signal to show
bluetooth module

Log:
  • Loading branch information
dengbo11 committed Sep 15, 2023
1 parent d695df3 commit a46ed1c
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions bluetooth1/bluetooth.go
Original file line number Diff line number Diff line change
Expand Up @@ -383,6 +383,18 @@ func (b *Bluetooth) init() {
b.adapters.mu.Lock()
b.adapters.infos = adapterInfos
b.adapters.mu.Unlock()
for _, adapterInfo := range adapterInfos {
data, err := json.Marshal(adapterInfo)
if err != nil {
logger.Warning(err)
continue
}
err = b.service.Emit(b, "AdapterAdded", string(data))
if err != nil {
logger.Warning(err)
continue
}
}
} else {
logger.Warning(err)
}
Expand Down

0 comments on commit a46ed1c

Please sign in to comment.