Skip to content
This repository was archived by the owner on Feb 22, 2023. It is now read-only.
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
clang-format
  • Loading branch information
stuartmorgan-g committed Oct 13, 2020
commit e4fc5f5466ef63fb1d89e41cb1be62943c0e046c
Original file line number Diff line number Diff line change
Expand Up @@ -2,15 +2,15 @@
// Microsoft Visual C++ generated include file.
// Used by Runner.rc
//
#define IDI_APP_ICON 101
#define IDI_APP_ICON 101

// Next default values for new objects
//
#ifdef APSTUDIO_INVOKED
#ifndef APSTUDIO_READONLY_SYMBOLS
#define _APS_NEXT_RESOURCE_VALUE 102
#define _APS_NEXT_COMMAND_VALUE 40001
#define _APS_NEXT_CONTROL_VALUE 1001
#define _APS_NEXT_SYMED_VALUE 101
#define _APS_NEXT_RESOURCE_VALUE 102
#define _APS_NEXT_COMMAND_VALUE 40001
#define _APS_NEXT_CONTROL_VALUE 1001
#define _APS_NEXT_SYMED_VALUE 101
#endif
#endif
Original file line number Diff line number Diff line change
Expand Up @@ -21,12 +21,10 @@ class RunLoop {
void Run();

// Registers the given Flutter instance for event servicing.
void RegisterFlutterInstance(
flutter::FlutterEngine* flutter_instance);
void RegisterFlutterInstance(flutter::FlutterEngine* flutter_instance);

// Unregisters the given Flutter instance from event servicing.
void UnregisterFlutterInstance(
flutter::FlutterEngine* flutter_instance);
void UnregisterFlutterInstance(flutter::FlutterEngine* flutter_instance);

private:
using TimePoint = std::chrono::steady_clock::time_point;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -93,17 +93,14 @@ void WindowClassRegistrar::UnregisterWindowClass() {
class_registered_ = false;
}

Win32Window::Win32Window() {
++g_active_window_count;
}
Win32Window::Win32Window() { ++g_active_window_count; }

Win32Window::~Win32Window() {
--g_active_window_count;
Destroy();
}

bool Win32Window::CreateAndShow(const std::wstring& title,
const Point& origin,
bool Win32Window::CreateAndShow(const std::wstring& title, const Point& origin,
const Size& size) {
Destroy();

Expand All @@ -130,8 +127,7 @@ bool Win32Window::CreateAndShow(const std::wstring& title,
}

// static
LRESULT CALLBACK Win32Window::WndProc(HWND const window,
UINT const message,
LRESULT CALLBACK Win32Window::WndProc(HWND const window, UINT const message,
WPARAM const wparam,
LPARAM const lparam) noexcept {
if (message == WM_NCCREATE) {
Expand All @@ -150,9 +146,7 @@ LRESULT CALLBACK Win32Window::WndProc(HWND const window,
}

LRESULT
Win32Window::MessageHandler(HWND hwnd,
UINT const message,
WPARAM const wparam,
Win32Window::MessageHandler(HWND hwnd, UINT const message, WPARAM const wparam,
LPARAM const lparam) noexcept {
switch (message) {
case WM_DESTROY:
Expand Down Expand Up @@ -226,9 +220,7 @@ RECT Win32Window::GetClientArea() {
return frame;
}

HWND Win32Window::GetHandle() {
return window_handle_;
}
HWND Win32Window::GetHandle() { return window_handle_; }

void Win32Window::SetQuitOnClose(bool quit_on_close) {
quit_on_close_ = quit_on_close;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -34,8 +34,7 @@ class Win32Window {
// consistent size to will treat the width height passed in to this function
// as logical pixels and scale to appropriate for the default monitor. Returns
// true if the window was created successfully.
bool CreateAndShow(const std::wstring& title,
const Point& origin,
bool CreateAndShow(const std::wstring& title, const Point& origin,
const Size& size);

// Release OS resources associated with window.
Expand All @@ -58,8 +57,7 @@ class Win32Window {
// Processes and route salient window messages for mouse handling,
// size change and DPI. Delegates handling of these to member overloads that
// inheriting classes can handle.
virtual LRESULT MessageHandler(HWND window,
UINT const message,
virtual LRESULT MessageHandler(HWND window, UINT const message,
WPARAM const wparam,
LPARAM const lparam) noexcept;

Expand All @@ -78,8 +76,7 @@ class Win32Window {
// non-client DPI scaling so that the non-client area automatically
// responsponds to changes in DPI. All other messages are handled by
// MessageHandler.
static LRESULT CALLBACK WndProc(HWND const window,
UINT const message,
static LRESULT CALLBACK WndProc(HWND const window, UINT const message,
WPARAM const wparam,
LPARAM const lparam) noexcept;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,15 +2,15 @@
// Microsoft Visual C++ generated include file.
// Used by Runner.rc
//
#define IDI_APP_ICON 101
#define IDI_APP_ICON 101

// Next default values for new objects
//
#ifdef APSTUDIO_INVOKED
#ifndef APSTUDIO_READONLY_SYMBOLS
#define _APS_NEXT_RESOURCE_VALUE 102
#define _APS_NEXT_COMMAND_VALUE 40001
#define _APS_NEXT_CONTROL_VALUE 1001
#define _APS_NEXT_SYMED_VALUE 101
#define _APS_NEXT_RESOURCE_VALUE 102
#define _APS_NEXT_COMMAND_VALUE 40001
#define _APS_NEXT_CONTROL_VALUE 1001
#define _APS_NEXT_SYMED_VALUE 101
#endif
#endif
Original file line number Diff line number Diff line change
Expand Up @@ -21,12 +21,10 @@ class RunLoop {
void Run();

// Registers the given Flutter instance for event servicing.
void RegisterFlutterInstance(
flutter::FlutterEngine* flutter_instance);
void RegisterFlutterInstance(flutter::FlutterEngine* flutter_instance);

// Unregisters the given Flutter instance from event servicing.
void UnregisterFlutterInstance(
flutter::FlutterEngine* flutter_instance);
void UnregisterFlutterInstance(flutter::FlutterEngine* flutter_instance);

private:
using TimePoint = std::chrono::steady_clock::time_point;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -93,17 +93,14 @@ void WindowClassRegistrar::UnregisterWindowClass() {
class_registered_ = false;
}

Win32Window::Win32Window() {
++g_active_window_count;
}
Win32Window::Win32Window() { ++g_active_window_count; }

Win32Window::~Win32Window() {
--g_active_window_count;
Destroy();
}

bool Win32Window::CreateAndShow(const std::wstring& title,
const Point& origin,
bool Win32Window::CreateAndShow(const std::wstring& title, const Point& origin,
const Size& size) {
Destroy();

Expand All @@ -130,8 +127,7 @@ bool Win32Window::CreateAndShow(const std::wstring& title,
}

// static
LRESULT CALLBACK Win32Window::WndProc(HWND const window,
UINT const message,
LRESULT CALLBACK Win32Window::WndProc(HWND const window, UINT const message,
WPARAM const wparam,
LPARAM const lparam) noexcept {
if (message == WM_NCCREATE) {
Expand All @@ -150,9 +146,7 @@ LRESULT CALLBACK Win32Window::WndProc(HWND const window,
}

LRESULT
Win32Window::MessageHandler(HWND hwnd,
UINT const message,
WPARAM const wparam,
Win32Window::MessageHandler(HWND hwnd, UINT const message, WPARAM const wparam,
LPARAM const lparam) noexcept {
switch (message) {
case WM_DESTROY:
Expand Down Expand Up @@ -226,9 +220,7 @@ RECT Win32Window::GetClientArea() {
return frame;
}

HWND Win32Window::GetHandle() {
return window_handle_;
}
HWND Win32Window::GetHandle() { return window_handle_; }

void Win32Window::SetQuitOnClose(bool quit_on_close) {
quit_on_close_ = quit_on_close;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -34,8 +34,7 @@ class Win32Window {
// consistent size to will treat the width height passed in to this function
// as logical pixels and scale to appropriate for the default monitor. Returns
// true if the window was created successfully.
bool CreateAndShow(const std::wstring& title,
const Point& origin,
bool CreateAndShow(const std::wstring& title, const Point& origin,
const Size& size);

// Release OS resources associated with window.
Expand All @@ -58,8 +57,7 @@ class Win32Window {
// Processes and route salient window messages for mouse handling,
// size change and DPI. Delegates handling of these to member overloads that
// inheriting classes can handle.
virtual LRESULT MessageHandler(HWND window,
UINT const message,
virtual LRESULT MessageHandler(HWND window, UINT const message,
WPARAM const wparam,
LPARAM const lparam) noexcept;

Expand All @@ -78,8 +76,7 @@ class Win32Window {
// non-client DPI scaling so that the non-client area automatically
// responsponds to changes in DPI. All other messages are handled by
// MessageHandler.
static LRESULT CALLBACK WndProc(HWND const window,
UINT const message,
static LRESULT CALLBACK WndProc(HWND const window, UINT const message,
WPARAM const wparam,
LPARAM const lparam) noexcept;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,15 +2,15 @@
// Microsoft Visual C++ generated include file.
// Used by Runner.rc
//
#define IDI_APP_ICON 101
#define IDI_APP_ICON 101

// Next default values for new objects
//
#ifdef APSTUDIO_INVOKED
#ifndef APSTUDIO_READONLY_SYMBOLS
#define _APS_NEXT_RESOURCE_VALUE 102
#define _APS_NEXT_COMMAND_VALUE 40001
#define _APS_NEXT_CONTROL_VALUE 1001
#define _APS_NEXT_SYMED_VALUE 101
#define _APS_NEXT_RESOURCE_VALUE 102
#define _APS_NEXT_COMMAND_VALUE 40001
#define _APS_NEXT_CONTROL_VALUE 1001
#define _APS_NEXT_SYMED_VALUE 101
#endif
#endif
Original file line number Diff line number Diff line change
Expand Up @@ -21,12 +21,10 @@ class RunLoop {
void Run();

// Registers the given Flutter instance for event servicing.
void RegisterFlutterInstance(
flutter::FlutterEngine* flutter_instance);
void RegisterFlutterInstance(flutter::FlutterEngine* flutter_instance);

// Unregisters the given Flutter instance from event servicing.
void UnregisterFlutterInstance(
flutter::FlutterEngine* flutter_instance);
void UnregisterFlutterInstance(flutter::FlutterEngine* flutter_instance);

private:
using TimePoint = std::chrono::steady_clock::time_point;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -93,17 +93,14 @@ void WindowClassRegistrar::UnregisterWindowClass() {
class_registered_ = false;
}

Win32Window::Win32Window() {
++g_active_window_count;
}
Win32Window::Win32Window() { ++g_active_window_count; }

Win32Window::~Win32Window() {
--g_active_window_count;
Destroy();
}

bool Win32Window::CreateAndShow(const std::wstring& title,
const Point& origin,
bool Win32Window::CreateAndShow(const std::wstring& title, const Point& origin,
const Size& size) {
Destroy();

Expand All @@ -130,8 +127,7 @@ bool Win32Window::CreateAndShow(const std::wstring& title,
}

// static
LRESULT CALLBACK Win32Window::WndProc(HWND const window,
UINT const message,
LRESULT CALLBACK Win32Window::WndProc(HWND const window, UINT const message,
WPARAM const wparam,
LPARAM const lparam) noexcept {
if (message == WM_NCCREATE) {
Expand All @@ -150,9 +146,7 @@ LRESULT CALLBACK Win32Window::WndProc(HWND const window,
}

LRESULT
Win32Window::MessageHandler(HWND hwnd,
UINT const message,
WPARAM const wparam,
Win32Window::MessageHandler(HWND hwnd, UINT const message, WPARAM const wparam,
LPARAM const lparam) noexcept {
switch (message) {
case WM_DESTROY:
Expand Down Expand Up @@ -226,9 +220,7 @@ RECT Win32Window::GetClientArea() {
return frame;
}

HWND Win32Window::GetHandle() {
return window_handle_;
}
HWND Win32Window::GetHandle() { return window_handle_; }

void Win32Window::SetQuitOnClose(bool quit_on_close) {
quit_on_close_ = quit_on_close;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -34,8 +34,7 @@ class Win32Window {
// consistent size to will treat the width height passed in to this function
// as logical pixels and scale to appropriate for the default monitor. Returns
// true if the window was created successfully.
bool CreateAndShow(const std::wstring& title,
const Point& origin,
bool CreateAndShow(const std::wstring& title, const Point& origin,
const Size& size);

// Release OS resources associated with window.
Expand All @@ -58,8 +57,7 @@ class Win32Window {
// Processes and route salient window messages for mouse handling,
// size change and DPI. Delegates handling of these to member overloads that
// inheriting classes can handle.
virtual LRESULT MessageHandler(HWND window,
UINT const message,
virtual LRESULT MessageHandler(HWND window, UINT const message,
WPARAM const wparam,
LPARAM const lparam) noexcept;

Expand All @@ -78,8 +76,7 @@ class Win32Window {
// non-client DPI scaling so that the non-client area automatically
// responsponds to changes in DPI. All other messages are handled by
// MessageHandler.
static LRESULT CALLBACK WndProc(HWND const window,
UINT const message,
static LRESULT CALLBACK WndProc(HWND const window, UINT const message,
WPARAM const wparam,
LPARAM const lparam) noexcept;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,15 +2,15 @@
// Microsoft Visual C++ generated include file.
// Used by Runner.rc
//
#define IDI_APP_ICON 101
#define IDI_APP_ICON 101

// Next default values for new objects
//
#ifdef APSTUDIO_INVOKED
#ifndef APSTUDIO_READONLY_SYMBOLS
#define _APS_NEXT_RESOURCE_VALUE 102
#define _APS_NEXT_COMMAND_VALUE 40001
#define _APS_NEXT_CONTROL_VALUE 1001
#define _APS_NEXT_SYMED_VALUE 101
#define _APS_NEXT_RESOURCE_VALUE 102
#define _APS_NEXT_COMMAND_VALUE 40001
#define _APS_NEXT_CONTROL_VALUE 1001
#define _APS_NEXT_SYMED_VALUE 101
#endif
#endif
Original file line number Diff line number Diff line change
Expand Up @@ -21,12 +21,10 @@ class RunLoop {
void Run();

// Registers the given Flutter instance for event servicing.
void RegisterFlutterInstance(
flutter::FlutterEngine* flutter_instance);
void RegisterFlutterInstance(flutter::FlutterEngine* flutter_instance);

// Unregisters the given Flutter instance from event servicing.
void UnregisterFlutterInstance(
flutter::FlutterEngine* flutter_instance);
void UnregisterFlutterInstance(flutter::FlutterEngine* flutter_instance);

private:
using TimePoint = std::chrono::steady_clock::time_point;
Expand Down
Loading