Skip to content

Instantly share code, notes, and snippets.

Avatar

Kenny Kerr kennykerr

View GitHub Profile
View diff.txt
1 alljoyn_interfacedescription_property_getannotationscount
current:12
expected:16
2 alljoyn_interfacedescription_property_getannotation
current:24
expected:28
3 JsCreateRuntime
current:16
expected:12
4 JsCreateContext
View stdcall.txt
UiaRaiseAutomationPropertyChangedEvent
current:544
expected:40
VarCyAdd
current:36
expected:20
VarCyNeg
current:20
expected:12
ItemContainerPattern_FindItemByProperty
View exports.txt
umutablecptrie_clone
current:8
expected:
utrans_clone
current:8
expected:
ucfpos_getInt64IterationContext
current:8
expected:
VarBoolFromCy
View dumpbin.txt
Microsoft (R) COFF/PE Dumper Version 14.31.31104.0
Copyright (C) Microsoft Corporation. All rights reserved.
Dump of file test.winmd
PE signature found
File Type: DLL
View gen.rs
use super::*;
#[derive(Default)]
pub struct Gen<'a> {
pub namespace: &'a str,
pub sys: bool,
pub flatten: bool,
pub cfg: bool,
pub doc: bool,
pub min_enum: bool,
@kennykerr
kennykerr / IMemoryBufferByteAccess.cpp
Last active Feb 15, 2022
How to use IMemoryBufferByteAccess with C++/WinRT
View IMemoryBufferByteAccess.cpp
#include "winrt/Windows.Foundation.h"
struct __declspec(uuid("5b0d3235-4dba-4d44-865e-8f1d0e4fd04d")) __declspec(novtable) IMemoryBufferByteAccess : ::IUnknown
{
virtual HRESULT __stdcall GetBuffer(uint8_t** value, uint32_t* capacity) = 0;
};
using namespace winrt;
using namespace Windows::Foundation;
View DesktopToastNotification.cpp
#pragma comment(lib, "onecore")
#pragma comment(lib, "propsys")
#include <shlobj.h>
#include <propvarutil.h>
#include <propkey.h>
#include <notificationactivationcallback.h>
#include <winrt/Windows.UI.Notifications.h>
#include <winrt/Windows.Data.Xml.Dom.h>
@kennykerr
kennykerr / buffer.cpp
Last active Jan 17, 2022
How to implement a custom Windows::Storage buffer with C++/WinRT
View buffer.cpp
struct __declspec(uuid("905a0fef-bc53-11df-8c49-001e4fc686da")) IBufferByteAccess : ::IUnknown
{
virtual HRESULT __stdcall Buffer(uint8_t** value) = 0;
};
struct CustomBuffer : implements<CustomBuffer, IBuffer, IBufferByteAccess>
{
std::vector<uint8_t> m_buffer;
uint32_t m_length{};
View DesktopWindowTarget.cpp
#include <winrt/Windows.System.h>
#include <winrt/Windows.UI.Composition.Desktop.h>
#include <windows.ui.composition.interop.h>
#include <DispatcherQueue.h>
extern "C" IMAGE_DOS_HEADER __ImageBase;
using namespace winrt;
using namespace Windows::UI;
using namespace Windows::UI::Composition;
View DesktopComposition.cpp
#include <windows.ui.composition.interop.h>
#include <ShellScalingAPI.h>
#include <DispatcherQueue.h>
#include <winrt/Windows.System.h>
#include <winrt/Windows.UI.Composition.Desktop.h>
extern "C" IMAGE_DOS_HEADER __ImageBase;
using namespace winrt;
using namespace Windows::UI;