jamulussoftware / jamulussoftware/jamulus
Refactor CClientDlgOnConnectDisconnectBut()
- Lingua principale
- C
- Stelle
- 1.1k
- Fork
- 248
- Merge medio
- 2g 3h
- PR unite (30g)
- 9
Descrizione
This should be implemented by switching the `connect` setting for the signal handler for the button, rather than having one signal handler with an if that consults the state of the client.
Button life-cycle:
- (public) ConnectDlg onClickConnect is connected to (private) ClientDlg onConnectDlgConnect
- onClickConnect launches ConnectDlg if it's not already open (and nothing else)
- onConnectDlgConnect _disables_ the button and asks the client to connect to the provided address
- onConnect switches the onClick handler to onClickDisconnect and enables the button
- onConnectFailed just enables the button (keeping the onClickConnect handler) -- although, if Client is passing an error, here's where it would get displayed to the user
- onClickDisconnect _disables_ the button and asks the client to disconnect
- onDisconnect (which should be handled) switches the onClick handler to onClickDisconnect and enables the button
_Originally posted by @pljones in https://github.com/jamulussoftware/jamulus/pull/3372#discussion_r1761635248_
Guida per i contributori
Apri la guida per i contributori
Direzione di ricerca
Inizia tracciando gli handler ClientDlg indicati e le relative connessioni dei segnali: onClickConnect, onConnectDlgConnect, onConnect, onConnectFailed, onClickDisconnect e onDisconnect. Conferma il ciclo di vita dei pulsanti descritto nell’issue, quindi verifica che la connessione e la disconnessione selezionino il click handler appropriato senza consultare lo stato del client in un handler condiviso.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Valutazione
- Stack tecnologico
- c
- Ambito
- desktop
- Tipo di issue
- Refactoring
- Difficoltà
- 4/5
- Tempo stimato
- 3-5 giorni
- Stato di attività
- Ferma
- Chiarezza
- Abbastanza chiara
- Idoneità per principianti
- 45/100