Sha256: c53f5b9ff1945fc66b85cd548b0c73069e7b3c86aa96fa1eeb45e8ab7334c128
Contents?: true
Size: 1.02 KB
Versions: 3
Compression:
Stored size: 1.02 KB
Contents
#include "StdAfx.h" #include "AutomationControl.h" #include "AutomationFinder.h" AutomationControl::AutomationControl(const HWND windowHandle) { _control = AutomationElement::FromHandle(IntPtr(windowHandle)); } AutomationControl::AutomationControl(const FindInformation& findInformation) { try { auto rootElement = AutomationElement::FromHandle(IntPtr(findInformation.rootWindow)); auto finder = gcnew AutomationFinder(rootElement); _control = finder->Find(findInformation); } catch(Exception^ e) { Debug::WriteLine("AutomationControl error: {0}", e->Message); } } AutomationControl::AutomationControl(AutomationElement^ automationElement) { _control = automationElement; } void AutomationControl::Value::set(String^ value) { AsValuePattern->SetValue(value); } String^ AutomationControl::Value::get() { return AsValuePattern->Current.Value; } bool AutomationControl::IsValuePattern::get() { try { return nullptr != AsValuePattern; } catch(Exception^ e) { return false; } }
Version data entries
3 entries across 3 versions & 1 rubygems
Version | Path |
---|---|
rautomation-0.10.0 | ext/UiaDll/UiaDll/AutomationControl.cpp |
rautomation-0.9.4 | ext/UiaDll/UiaDll/AutomationControl.cpp |
rautomation-0.9.3 | ext/UiaDll/UiaDll/AutomationControl.cpp |