Skip to content

Commit

Permalink
Merge pull request halildurmus#709 from dart-windows/708
Browse files Browse the repository at this point in the history
Add service management functions
  • Loading branch information
timsneath authored May 16, 2023
2 parents c7f91fe + 4fa6001 commit a43ae72
Show file tree
Hide file tree
Showing 14 changed files with 3,196 additions and 1,338 deletions.
3 changes: 2 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
## 5.0.2

- Add some additional user32 exports (#706, thanks to @ilopX)
- Add some additional user32 exports (#707, thanks to @ilopX)
- Add service management APIs (#709)

## 5.0.1

Expand Down
22 changes: 22 additions & 0 deletions lib/src/callbacks.dart
Original file line number Diff line number Diff line change
Expand Up @@ -83,6 +83,17 @@ typedef FRHookProc = UINT_PTR Function(HWND, UINT, WPARAM, LPARAM);
/// new thread in the process to execute the function.
typedef HandlerRoutine = BOOL Function(DWORD dwCtrlType);

/// Application-defined callback function used with the
/// RegisterServiceCtrlHandler function. A service program can use it as the
/// control handler function of a particular service.
typedef LphandlerFunction = Void Function(DWORD dwControl);

/// Application-defined callback function used with the
/// RegisterServiceCtrlHandlerEx function. A service program can use it as the
/// control handler function of a particular service.
typedef LphandlerFunctionEx = DWORD Function(
DWORD dwControl, DWORD dwEventType, LPVOID lpEventData, LPVOID lpContext);

/// Application-defined callback function used with the ReadFileEx and
/// WriteFileEx functions. It is called when the asynchronous input and output
/// (I/O) operation is completed or canceled and the calling thread is in an
Expand All @@ -92,6 +103,17 @@ typedef HandlerRoutine = BOOL Function(DWORD dwCtrlType);
typedef LpoverlappedCompletionRoutine = Void Function(DWORD dwErrorCode,
DWORD dwNumberOfBytesTransfered, OVERLAPPED lpOverlapped);

/// Application-defined callback function used as the entry point for a service.
/// The LPSERVICE_MAIN_FUNCTION type defines a pointer to this callback
/// function. ServiceMain is a placeholder for an application-defined function
/// name.
typedef LpserviceMainFunctionw = Void Function(
DWORD dwNumServicesArgs, Pointer<LPWSTR> lpServiceArgVectors);

/// Application-defined callback function that receives a pointer to the
/// SERVICE_NOTIFY structure provided by the caller.
typedef PfnScNotifyCallbackFunction = PVOID Function(PVOID pParameter);

/// Application-defined callback function implements a custom transform for
/// image scaling.
typedef MagImageScalingCallback = BOOL Function(
Expand Down
Loading

0 comments on commit a43ae72

Please sign in to comment.