5#ifndef FLUTTER_SHELL_PLATFORM_WINDOWS_FLUTTER_DESKTOP_MESSENGER_H_
6#define FLUTTER_SHELL_PLATFORM_WINDOWS_FLUTTER_DESKTOP_MESSENGER_H_
11#include "flutter/fml/macros.h"
12#include "flutter/shell/platform/common/public/flutter_messenger.h"
16class FlutterWindowsEngine;
43 std::scoped_lock lock(mutex_);
51 ref_count_.fetch_add(1);
60 int32_t old_count = ref_count_.fetch_sub(1);
76 std::atomic<int32_t> ref_count_ = 0;
FlutterDesktopMessengerRef ToRef()
Convert to FlutterDesktopMessengerRef.
flutter::FlutterWindowsEngine * GetEngine() const
Getter for the engine field.
static FlutterDesktopMessenger * FromRef(FlutterDesktopMessengerRef ref)
Convert from FlutterDesktopMessengerRef.
void SetEngine(flutter::FlutterWindowsEngine *arg_engine)
FlutterDesktopMessenger()=default
FlutterDesktopMessenger * AddRef()