mirror of
https://github.com/ElectronNET/Electron.NET.git
synced 2026-02-03 21:25:13 +00:00
[PR #920] [MERGED] feat: Add "Once" socket listener registration for one-time handlers #1353
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
📋 Pull Request Information
Original PR: https://github.com/ElectronNET/Electron.NET/pull/920
Author: @Denny09310
Created: 11/10/2025
Status: ✅ Merged
Merged: 11/10/2025
Merged by: @FlorianRappl
Base:
develop← Head:feature/using-once📝 Commits (3)
d8062aafix: scale factor can be a doubleadc1e81fix: simplified add/remove of socket listener through usage of "Once"9a0a494fix: missing "Once" changes, rollback to "On" on Notification📊 Changes
24 files changed (+310 additions, -750 deletions)
View changed files
📝
src/ElectronNET.API/API/ApiBase.cs(+1 -3)📝
src/ElectronNET.API/API/App.cs(+11 -60)📝
src/ElectronNET.API/API/AutoUpdater.cs(+39 -93)📝
src/ElectronNET.API/API/BrowserView.cs(+3 -8)📝
src/ElectronNET.API/API/BrowserWindow.cs(+3 -8)📝
src/ElectronNET.API/API/Clipboard.cs(+21 -59)📝
src/ElectronNET.API/API/CommandLine.cs(+10 -20)📝
src/ElectronNET.API/API/Dialog.cs(+17 -34)📝
src/ElectronNET.API/API/Dock.cs(+16 -36)📝
src/ElectronNET.API/API/Entities/Display.cs(+1 -1)📝
src/ElectronNET.API/API/GlobalShortcut.cs(+3 -9)📝
src/ElectronNET.API/API/HostHook.cs(+8 -11)📝
src/ElectronNET.API/API/IpcMain.cs(+4 -4)📝
src/ElectronNET.API/API/NativeTheme.cs(+12 -32)📝
src/ElectronNET.API/API/Notification.cs(+3 -8)📝
src/ElectronNET.API/API/Process.cs(+44 -88)📝
src/ElectronNET.API/API/Screen.cs(+18 -48)📝
src/ElectronNET.API/API/Session.cs(+42 -112)📝
src/ElectronNET.API/API/Shell.cs(+19 -43)📝
src/ElectronNET.API/API/Tray.cs(+3 -9)...and 4 more files
📄 Description
This PR updates the socket listener handling to use the already existing
Oncemethod rather than manually adding and removing event handlers. This simplifies the code and reduces unnecessary listener cleanup logic while keeping the behavior the same.🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.