Sha256: aa970ca7b984ca1b015f15b8a4cc374bb9247be08c86f29e1a89d1050b5b304f

Contents?: true

Size: 1.11 KB

Versions: 9

Compression:

Stored size: 1.11 KB

Contents

#include "Stdafx.h"

extern "C" {
  __declspec(dllexport) void Selection_Release(SelectionInformationPtr selectionInfo) {
    delete selectionInfo;
  }

  __declspec(dllexport) SelectionInformationPtr Selection_Information(ElementInformationPtr element, char* errorInfo, const int errorInfoLength) {
    try {
      return new SelectionInformation(Find(element)->As<SelectionPattern^>(SelectionPattern::Pattern)->Current);
    } catch(Exception^ e) {
      StringHelper::CopyToUnmanagedString(e->Message, errorInfo, errorInfoLength);
      return NULL;
    }
  }

  __declspec(dllexport) int Selection_Selections(ElementInformationPtr element, ElementInformation** selections, char* errorInfo, const int errorInfoLength) {
    try {
      auto selectedElements = Element::From(Find(element)->As<SelectionPattern^>(SelectionPattern::Pattern)->Current.GetSelection());
      *selections = ElementInformation::From(selectedElements);
      return selectedElements->Length;
    } catch(Exception^ e) {
      StringHelper::CopyToUnmanagedString(e->Message, errorInfo, errorInfoLength);
      return 0;
    }
  }
}

Version data entries

9 entries across 9 versions & 1 rubygems

Version Path
uia-0.1.3.1 ext/UiaDll/UiaDll/SelectionMethods.cpp
uia-0.1.3 ext/UiaDll/UiaDll/SelectionMethods.cpp
uia-0.1.2.3 ext/UiaDll/UiaDll/SelectionMethods.cpp
uia-0.1.2.2 ext/UiaDll/UiaDll/SelectionMethods.cpp
uia-0.1.2.1 ext/UiaDll/UiaDll/SelectionMethods.cpp
uia-0.1.2 ext/UiaDll/UiaDll/SelectionMethods.cpp
uia-0.1.1 ext/UiaDll/UiaDll/SelectionMethods.cpp
uia-0.1 ext/UiaDll/UiaDll/SelectionMethods.cpp
uia-0.0.9 ext/UiaDll/UiaDll/SelectionMethods.cpp