├── DirectUI
├── event.h
├── BorderLayout.h
├── TouchButton.h
├── AutoThread.h
├── AutoLock.h
├── AutoVariant.h
├── FontCheckOut.h
├── DuiNavigate.h
├── CClassFactory.h
├── NavScoring.h
├── LinkedList.h
├── SelectorSelection.h
├── BrowserSelection.h
├── FontCache.h
├── SelectorSelectionItem.h
├── host.h
├── ElementWithHWND.h
├── provider.h
├── Expandable.h
├── Repeater.h
├── AutoButton.h
├── PText.h
├── Clipper.h
├── CVScrollBar.h
├── CHScrollBar.h
├── CAVI.h
├── UnknownElement.h
├── Thumb.h
├── CListView.h
├── CProgressBar.h
├── CListBox.h
├── CCheckBox.h
├── SelectorNoDefault.h
├── Bind.h
├── Primitives.h
├── CCSysLink.h
├── CheckBoxGlyph.h
├── RepeatButton.h
├── RadioButtonGlyph.h
├── ExpandoButtonGlyph.h
├── CBaseCheckRadioButton.h
├── StyledScrollViewer.h
├── TextGraphic.h
├── PushButton.h
├── CRadioButton.h
├── ScrollItem.h
├── Browser.h
├── Expando.h
├── Toggle.h
├── ScrollViewer.h
├── TableItem.h
├── Table.h
├── DirectUI.def
├── CCommandLink.h
├── Macro.h
├── Selection.h
├── Selector.h
├── Grid.h
├── RefPointElement.h
├── SelectionItem.h
├── AccessibleButton.h
├── RangeValue.h
├── CTreeView.h
├── GridItem.h
├── Combobox.h
├── Button.h
├── Page.h
├── Progress.h
├── CTrackBar.h
├── Navigator.h
├── ExpandCollapse.h
├── NativeHWNDHost.h
├── XBaby.h
├── XElement.h
├── Viewer.h
├── CBase.h
├── AnimationStrip.h
├── CPushButton.h
├── CBaseScrollBar.h
├── CallstackTracker.h
├── Scroll.h
├── Edit.h
├── InvokeHelper.h
├── TaskPage.h
├── Movie.h
├── DialogElement.h
├── XProvider.h
├── ScrollBar.h
├── EventManager.h
├── HWNDHost.h
├── misc.h
├── HWNDElement.h
├── RichText.h
├── Value.h
├── base.h
├── Interfaces.h
├── types.h
├── DirectUI.h
└── accessibility.h
├── UITest
├── .clang-format
├── UITest.rc
├── resource.h
├── packages.config
├── app.manifest
└── UITest.vcxproj.filters
├── demangler
├── stdafx.h
├── stdafx.cpp
├── demangler.cpp
├── targetver.h
├── ReadMe.txt
└── demangler.vcxproj.filters
├── docs
├── TouchEditBaseClass.g.txt
├── TouchEditInnerClass.g.txt
├── TouchEdit2Class.g.txt
├── duixml
│ ├── AuthBrokerUI.dll.xml
│ ├── SYSTEMSETTINGSSTYLES.xml
│ └── dpapimig.exe.xml
├── ElementClass.g.txt
├── PagesClass.g.txt
└── BrowserClass.g.txt
├── README.md
├── LICENSE
├── .gitattributes
├── DirectUI Library.sln
└── .gitignore
/DirectUI/event.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 |
3 |
--------------------------------------------------------------------------------
/UITest/.clang-format:
--------------------------------------------------------------------------------
1 | BasedOnStyle: LLVM
2 |
--------------------------------------------------------------------------------
/DirectUI/BorderLayout.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 |
3 | namespace DirectUI
4 | {
5 | }
--------------------------------------------------------------------------------
/UITest/UITest.rc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/seven-mile/dui70/HEAD/UITest/UITest.rc
--------------------------------------------------------------------------------
/UITest/resource.h:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/seven-mile/dui70/HEAD/UITest/resource.h
--------------------------------------------------------------------------------
/demangler/stdafx.h:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/seven-mile/dui70/HEAD/demangler/stdafx.h
--------------------------------------------------------------------------------
/demangler/stdafx.cpp:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/seven-mile/dui70/HEAD/demangler/stdafx.cpp
--------------------------------------------------------------------------------
/demangler/demangler.cpp:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/seven-mile/dui70/HEAD/demangler/demangler.cpp
--------------------------------------------------------------------------------
/demangler/targetver.h:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/seven-mile/dui70/HEAD/demangler/targetver.h
--------------------------------------------------------------------------------
/UITest/packages.config:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
--------------------------------------------------------------------------------
/DirectUI/TouchButton.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 |
3 | namespace DirectUI {
4 |
5 | struct UILIB_API TouchButton : public RichText {
6 |
7 | static UID WINAPI Click(void);
8 |
9 | };
10 |
11 | }
12 |
--------------------------------------------------------------------------------
/DirectUI/AutoThread.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 |
3 | namespace DirectUI
4 | {
5 | class UILIB_API AutoThread
6 | {
7 | public:
8 | AutoThread();
9 | ~AutoThread();
10 | AutoThread& operator=(const AutoThread &);
11 | HRESULT Init();
12 | };
13 | }
--------------------------------------------------------------------------------
/DirectUI/AutoLock.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 |
3 | namespace DirectUI
4 | {
5 | class UILIB_API AutoLock
6 | {
7 | public:
8 | AutoLock(LPCRITICAL_SECTION lpCriticalSection);
9 | AutoLock& operator=(const AutoLock& );
10 | ~AutoLock();
11 | };
12 | }
--------------------------------------------------------------------------------
/DirectUI/AutoVariant.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 | #include "types.h"
3 |
4 | namespace DirectUI
5 | {
6 | class UILIB_API AutoVariant
7 | {
8 | public:
9 | AutoVariant();
10 | AutoVariant& operator=(const AutoVariant &);
11 | ~AutoVariant();
12 | };
13 | }
--------------------------------------------------------------------------------
/DirectUI/FontCheckOut.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 |
3 | namespace DirectUI
4 | {
5 | class UILIB_API FontCheckOut
6 | {
7 | public:
8 | FontCheckOut(Element *, HDC);
9 | ~FontCheckOut(void);
10 | FontCheckOut & operator=(FontCheckOut const &);
11 | };
12 | }
--------------------------------------------------------------------------------
/DirectUI/DuiNavigate.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 |
3 | namespace DirectUI
4 | {
5 | class UILIB_API DuiNavigate
6 | {
7 | public:
8 | static Element * __stdcall Navigate(Element *, DynamicArray *, int);
9 | DuiNavigate & operator=(DuiNavigate const &);
10 | };
11 | }
--------------------------------------------------------------------------------
/DirectUI/CClassFactory.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 |
3 | namespace DirectUI
4 | {
5 | struct UILIB_API CClassFactory {
6 | //static long __stdcall Create(unsigned int, Element *, unsigned long *, Element * *);
7 | //long Register(struct IClassInfo*);
8 | };
9 |
10 | //CClassFactory *g_pClassFactory;
11 |
12 | }
13 |
--------------------------------------------------------------------------------
/DirectUI/NavScoring.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 |
3 | namespace DirectUI
4 | {
5 | struct UILIB_API NavScoring
6 | {
7 | public:
8 | void Init(Element *, int, NavReference const *);
9 | NavScoring & operator=(NavScoring const &);
10 | int TrackScore(Element *, Element *);
11 | int Try(Element *, int, NavReference const *, unsigned long);
12 | };
13 | }
--------------------------------------------------------------------------------
/DirectUI/LinkedList.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 |
3 | namespace DirectUI
4 | {
5 | class UILIB_API LinkedListNode
6 | {
7 | public:
8 | LinkedListNode& operator=(LinkedListNode const &);
9 | };
10 |
11 | class UILIB_API LinkedList
12 | {
13 | public:
14 | LinkedList(void);
15 | ~LinkedList(void);
16 | LinkedList & operator=(LinkedList const &);
17 | void Add(LinkedListNode *);
18 | void Remove(LinkedListNode *);
19 | class LinkedListNode * RemoveTail(void);
20 | };
21 |
22 | }
--------------------------------------------------------------------------------
/DirectUI/SelectorSelection.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 |
3 | namespace DirectUI
4 | {
5 | class UILIB_API SelectorSelectionProxy :IProxy
6 | {
7 | public:
8 | SelectorSelectionProxy(SelectorSelectionProxy const &);
9 | SelectorSelectionProxy(void);
10 | SelectorSelectionProxy & operator=(SelectorSelectionProxy const &);
11 |
12 | virtual long DoMethod(int, char *);
13 | protected:
14 | virtual void Init(Element *);
15 | private:
16 | long GetIsSelectionRequired(int *);
17 |
18 | };
19 | }
--------------------------------------------------------------------------------
/DirectUI/BrowserSelection.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 |
3 | namespace DirectUI
4 | {
5 | class UILIB_API BrowserSelectionProxy : public IProxy
6 | {
7 | public:
8 | BrowserSelectionProxy(BrowserSelectionProxy const &);
9 | BrowserSelectionProxy(void);
10 | BrowserSelectionProxy & operator=(BrowserSelectionProxy const &);
11 | virtual long DoMethod(int, char *);
12 | protected:
13 | virtual void Init(Element *);
14 | private:
15 | long GetIsSelectionRequired(int *);
16 | long GetSelection(SAFEARRAY * *);
17 |
18 | };
19 | }
--------------------------------------------------------------------------------
/DirectUI/FontCache.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 |
3 | namespace DirectUI
4 | {
5 | class UILIB_API FontCache
6 | {
7 | public:
8 | FontCache(FontCache const &);
9 | FontCache(void);
10 | FontCache & operator=(FontCache const &);
11 |
12 | static long __stdcall InitProcess(void);
13 | static long __stdcall InitThread(void);
14 | static void __stdcall UninitProcess(void);
15 | static void __stdcall UninitThread(void);
16 |
17 | virtual void T1() = 0;
18 | virtual void T2() = 0;
19 | virtual void T3() = 0;
20 | virtual void T4() = 0;
21 | };
22 | }
--------------------------------------------------------------------------------
/DirectUI/SelectorSelectionItem.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 |
3 | namespace DirectUI
4 | {
5 | class UILIB_API SelectorSelectionItemProxy : public IProxy
6 | {
7 | public:
8 | SelectorSelectionItemProxy(SelectorSelectionItemProxy const &);
9 | SelectorSelectionItemProxy(void);
10 | SelectorSelectionItemProxy & operator=(SelectorSelectionItemProxy const &);
11 |
12 | virtual long DoMethod(int, char *);
13 | protected:
14 | virtual void Init(Element *);
15 | private:
16 | long AddToSelection(void);
17 | long GetSelectionContainer(IRawElementProviderSimple * *);
18 | long Select(void);
19 |
20 | };
21 | }
--------------------------------------------------------------------------------
/DirectUI/host.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 |
3 | namespace DirectUI
4 | {
5 | class UILIB_API XHost
6 | {
7 | public:
8 |
9 | XHost();
10 | ~XHost();
11 | XHost & operator=(XHost const &);
12 |
13 | static long WINAPI Create(class IXElementCP*, XHost**);
14 | void Destroy();
15 | void DestroyWindow();
16 |
17 | class Element* GetElement();
18 | HWND GetHWND();
19 |
20 | void HideWindow();
21 | void Host(class Element*);
22 | long Initialize(class IXElementCP*);
23 | void ShowWindow(int);
24 |
25 | static LRESULT WINAPI WndProc(HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM lParam);
26 | };
27 | }
--------------------------------------------------------------------------------
/docs/TouchEditBaseClass.g.txt:
--------------------------------------------------------------------------------
1 | ClassInfo:
2 | Base Class:
3 | Properties:
4 | [PasswordCharacter]: Int
5 | [IgnoredKeyCombos]: Int
6 | Enum values:
7 | None : 0x0 (0)
8 | Copy : 0x11 (17)
9 | Paste : 0xa (10)
10 | Cut : 0x24 (36)
11 | Default : 0x1 (1)
12 | Left : 0x1 (1)
13 | Center : 0x2 (2)
14 | Right : 0x4 (4)
15 | [KeyboardNavigationCapture]: Int
16 | Enum values:
17 | Default : 0x0 (0)
18 | None : 0x1 (1)
19 | VisualState : 0x6 (6)
20 | : 0x0 (0)
21 |
--------------------------------------------------------------------------------
/docs/TouchEditInnerClass.g.txt:
--------------------------------------------------------------------------------
1 | ClassInfo:
2 | Base Class:
3 | Properties:
4 | [PasswordCharacter]: Int
5 | [IgnoredKeyCombos]: Int
6 | Enum values:
7 | None : 0x0 (0)
8 | Copy : 0x11 (17)
9 | Paste : 0xa (10)
10 | Cut : 0x24 (36)
11 | Default : 0x1 (1)
12 | Left : 0x1 (1)
13 | Center : 0x2 (2)
14 | Right : 0x4 (4)
15 | [KeyboardNavigationCapture]: Int
16 | Enum values:
17 | Default : 0x0 (0)
18 | None : 0x1 (1)
19 | VisualState : 0x6 (6)
20 | : 0x0 (0)
21 |
--------------------------------------------------------------------------------
/DirectUI/ElementWithHWND.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 |
3 | namespace DirectUI
4 | {
5 | class UILIB_API ElementWithHWND : public Element
6 | {
7 | public:
8 | ElementWithHWND(const ElementWithHWND &);
9 | ElementWithHWND();
10 | ElementWithHWND& operator=(const ElementWithHWND &);
11 |
12 | virtual ~ElementWithHWND();
13 |
14 | static long WINAPI Create(Element*, unsigned long*, Element**);
15 | static IClassInfo* WINAPI GetClassInfoPtr();
16 | static long WINAPI Register();
17 | static void WINAPI SetClassInfoPtr(IClassInfo*);
18 |
19 | virtual IClassInfo* GetClassInfoW();
20 |
21 | private:
22 | static IClassInfo*s_pClassInfo;
23 | };
24 | }
--------------------------------------------------------------------------------
/DirectUI/provider.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 |
3 | namespace DirectUI
4 | {
5 |
6 |
7 | class UILIB_API XResourceProvider
8 | {
9 | public:
10 | XResourceProvider();
11 | XResourceProvider( const XResourceProvider& );
12 | XResourceProvider& operator=( const XResourceProvider& );
13 |
14 | static long WINAPI Create(XResourceProvider**pOut);
15 | static long WINAPI Create(HINSTANCE, UCString, UCString, UCString, XResourceProvider**pOut );
16 |
17 | long Initialize(HINSTANCE h, UCString s1, UCString s2, UCString s3);
18 |
19 | //1
20 | virtual long CreateDUICP(HWNDElement*, HWND, HWND, Element**, class DUIXmlParser**);
21 | //2
22 | virtual long CreateParserCP(class DUIXmlParser**pOut);
23 | //3
24 | virtual void DestroyCP();
25 |
26 | };
27 | }
--------------------------------------------------------------------------------
/DirectUI/Expandable.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 |
3 | namespace DirectUI
4 | {
5 | class UILIB_API Expandable :public Element
6 | {
7 | public:
8 | Expandable(Expandable const &);
9 | Expandable(void);
10 | virtual ~Expandable(void);
11 | Expandable & operator=(Expandable const &);
12 |
13 | static long __stdcall Create(Element *, unsigned long *, Element * *);
14 | static const PropertyInfo* __stdcall ExpandedProp(void);
15 | static IClassInfo * __stdcall GetClassInfoPtr(void);
16 | static long __stdcall Register(void);
17 | static void __stdcall SetClassInfoPtr(IClassInfo *);
18 |
19 | bool GetExpanded(void);
20 | long SetExpanded(bool);
21 |
22 | virtual IClassInfo * GetClassInfoW(void);
23 |
24 | private:
25 | static IClassInfo * s_pClassInfo;
26 |
27 | };
28 | }
--------------------------------------------------------------------------------
/DirectUI/Repeater.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 |
3 | namespace DirectUI
4 | {
5 | class UILIB_API Repeater : public Macro
6 | {
7 | public:
8 | Repeater(Repeater const &);
9 | Repeater(void);
10 | virtual ~Repeater(void);
11 | Repeater & operator=(Repeater const &);
12 |
13 | static long __stdcall Create(Element *, unsigned long *, Element * *);
14 | static IClassInfo * __stdcall GetClassInfoPtr(void);
15 | static long __stdcall Register(void);
16 | static void __stdcall SetClassInfoPtr(IClassInfo *);
17 |
18 | long Initialize(Element *, unsigned long *);
19 | void SetDataEngine(IDataEngine *);
20 |
21 | virtual IClassInfo * GetClassInfoW(void);
22 | protected:
23 | virtual long BuildElement(void);
24 | private:
25 | static IClassInfo * s_pClassInfo;
26 |
27 | };
28 | }
--------------------------------------------------------------------------------
/DirectUI/AutoButton.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 |
3 | namespace DirectUI
4 | {
5 | //所有虚函数均是重载,无需调整顺序
6 | class UILIB_API AutoButton :public AccessibleButton
7 | {
8 | public:
9 | AutoButton(const AutoButton &);
10 | AutoButton();
11 | AutoButton & operator=(const AutoButton&);
12 | virtual ~AutoButton();
13 |
14 | static long __stdcall Create(Element* , unsigned long *, Element** );
15 | static IClassInfo* __stdcall GetClassInfoPtr();
16 | static long __stdcall Register();
17 | static void __stdcall SetClassInfoPtr(IClassInfo *);
18 | static UID __stdcall Toggle();
19 |
20 | virtual IClassInfo* GetClassInfoW();
21 | virtual void OnEvent(Event *);
22 |
23 | long Initialize(Element *, unsigned long *);
24 |
25 | private:
26 | static IClassInfo* s_pClassInfo;
27 | };
28 | }
--------------------------------------------------------------------------------
/DirectUI/PText.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 |
3 | namespace DirectUI
4 | {
5 | class UILIB_API PText : public TextGraphic
6 | {
7 | public:
8 | PText(PText const &);
9 | PText(void);
10 | virtual ~PText(void);
11 | PText & operator=(PText const &);
12 |
13 | static long __stdcall Create(Element *, unsigned long *, Element * *);
14 | static IClassInfo * __stdcall GetClassInfoPtr(void);
15 | static long __stdcall Register(void);
16 | static void __stdcall SetClassInfoPtr(IClassInfo *);
17 |
18 | long Initialize(Element *, unsigned long *);
19 | void SetDataEntry(IDataEntry *);
20 |
21 | virtual IClassInfo * GetClassInfoW(void);
22 | virtual bool OnPropertyChanging(PropertyInfo const *, int, Value *, Value *);
23 |
24 | private:
25 | static IClassInfo * s_pClassInfo;
26 | };
27 | }
--------------------------------------------------------------------------------
/DirectUI/Clipper.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 |
3 | namespace DirectUI
4 | {
5 | class UILIB_API Clipper : public Expandable
6 | {
7 | public:
8 | Clipper(Clipper const &);
9 | Clipper(void);
10 | virtual ~Clipper(void);
11 | Clipper & operator=(Clipper const &);
12 |
13 | static long __stdcall Create(Element *, unsigned long *, Element * *);
14 | static IClassInfo * __stdcall GetClassInfoPtr(void);
15 | static long __stdcall Register(void);
16 | static void __stdcall SetClassInfoPtr(IClassInfo *);
17 |
18 | long Initialize(Element *, unsigned long *);
19 |
20 | virtual IClassInfo * GetClassInfoW(void);
21 | virtual void _SelfLayoutDoLayout(int, int);
22 | virtual SIZE _SelfLayoutUpdateDesiredSize(int, int, Surface *);
23 |
24 | private:
25 | static IClassInfo * s_pClassInfo;
26 | };
27 | }
--------------------------------------------------------------------------------
/DirectUI/CVScrollBar.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 |
3 | namespace DirectUI
4 | {
5 | class UILIB_API CCVScrollBar : public CCBaseScrollBar
6 | {
7 | public:
8 | CCVScrollBar(CCVScrollBar const &);
9 | CCVScrollBar(void);
10 | virtual ~CCVScrollBar(void);
11 | CCVScrollBar & operator=(CCVScrollBar const &);
12 |
13 | static long __stdcall Create(unsigned int, Element *, unsigned long *, Element * *);
14 | static long __stdcall Create(Element *, unsigned long *, Element * *);
15 | static IClassInfo * __stdcall GetClassInfoPtr(void);
16 | static long __stdcall Register(void);
17 | static void __stdcall SetClassInfoPtr(IClassInfo *);
18 |
19 | virtual IClassInfo * GetClassInfoW(void);
20 | virtual SIZE GetContentSize(int, int, Surface *);
21 |
22 | private:
23 | static IClassInfo * s_pClassInfo;
24 |
25 | };
26 | }
--------------------------------------------------------------------------------
/DirectUI/CHScrollBar.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 |
3 | namespace DirectUI
4 | {
5 | //此类虚函数全部来自父
6 | class UILIB_API CCHScrollBar : public CCBaseScrollBar
7 | {
8 | public:
9 | CCHScrollBar(const CCHScrollBar &);
10 | CCHScrollBar(void);
11 | CCHScrollBar & operator=(const CCHScrollBar &);
12 | virtual ~CCHScrollBar(void);
13 | static long __stdcall Create(unsigned int, Element *, unsigned long *, Element * *);
14 | static long __stdcall Create(Element *, unsigned long *, Element * *);
15 | static IClassInfo * __stdcall GetClassInfoPtr(void);
16 | static long __stdcall Register(void);
17 | static void __stdcall SetClassInfoPtr(IClassInfo *);
18 |
19 | virtual IClassInfo * GetClassInfoW(void);
20 | virtual SIZE GetContentSize(int, int, Surface *);
21 |
22 | private:
23 | static IClassInfo * s_pClassInfo;
24 | };
25 | }
--------------------------------------------------------------------------------
/DirectUI/CAVI.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 |
3 | namespace DirectUI
4 | {
5 | class UILIB_API CCAVI :public CCBase
6 | {
7 | public:
8 | CCAVI(const CCAVI &);
9 | CCAVI(void);
10 | CCAVI & operator=(const CCAVI &);
11 |
12 | virtual ~CCAVI(void);
13 | static long __stdcall Create(unsigned int, Element *, unsigned long *, Element * *);
14 | static long __stdcall Create(Element *, unsigned long *, Element * *);
15 | static IClassInfo * __stdcall GetClassInfoPtr(void);
16 | static long __stdcall Register(void);
17 | static void __stdcall SetClassInfoPtr(IClassInfo *);
18 |
19 | void Play(HWND);
20 | void Stop(void);
21 | virtual IClassInfo * GetClassInfoW(void);
22 | protected:
23 | virtual void PostCreate(HWND);
24 | private:
25 | void OpenAnimation(HWND);
26 |
27 | static IClassInfo * s_pClassInfo;
28 |
29 | };
30 | }
--------------------------------------------------------------------------------
/DirectUI/UnknownElement.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 |
3 | namespace DirectUI
4 | {
5 | class UILIB_API UnknownElement : public Element
6 | {
7 | public:
8 | UnknownElement(UnknownElement const &);
9 | UnknownElement(void);
10 | virtual ~UnknownElement(void);
11 | UnknownElement & operator=(UnknownElement const &);
12 |
13 | static long __stdcall Create(unsigned int, Element *, unsigned long *, Element * *);
14 | static long __stdcall Create(Element *, unsigned long *, Element * *);
15 | static IClassInfo * __stdcall GetClassInfoPtr(void);
16 | static long __stdcall Register(void);
17 | static void __stdcall SetClassInfoPtr(IClassInfo *);
18 |
19 | long Initialize(unsigned int, Element *, unsigned long *);
20 |
21 | virtual IClassInfo * GetClassInfoW(void);
22 | private:
23 | static IClassInfo * s_pClassInfo;
24 |
25 | };
26 | }
--------------------------------------------------------------------------------
/DirectUI/Thumb.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 |
3 | namespace DirectUI
4 | {
5 | class UILIB_API Thumb : public Button
6 | {
7 | public:
8 | Thumb(Thumb const &);
9 | Thumb(void);
10 | virtual ~Thumb(void);
11 | Thumb & operator=(Thumb const &);
12 |
13 | static long __stdcall Create(unsigned int, Element *, unsigned long *, Element * *);
14 | static long __stdcall Create(Element *, unsigned long *, Element * *);
15 | static UID __stdcall Drag(void);
16 | static IClassInfo * __stdcall GetClassInfoPtr(void);
17 | static long __stdcall Register(void);
18 | static void __stdcall SetClassInfoPtr(IClassInfo *);
19 |
20 | long Initialize(unsigned int, Element *, unsigned long *);
21 |
22 | virtual IClassInfo * GetClassInfoW(void);
23 | virtual void OnInput(InputEvent *);
24 | private:
25 | static IClassInfo * s_pClassInfo;
26 |
27 | };
28 | }
--------------------------------------------------------------------------------
/DirectUI/CListView.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 |
3 | namespace DirectUI
4 | {
5 | class UILIB_API CCListView : public CCBase
6 | {
7 | public:
8 | CCListView(CCListView const &);
9 | CCListView(void);
10 | virtual ~CCListView(void);
11 | CCListView & operator=(CCListView const &);
12 |
13 | static long __stdcall Create(unsigned int, Element *, unsigned long *, Element * *);
14 | static long __stdcall Create(Element *, unsigned long *, Element * *);
15 | static IClassInfo * __stdcall GetClassInfoPtr(void);
16 | static long __stdcall Register(void);
17 | static void __stdcall SetClassInfoPtr(IClassInfo *);
18 |
19 | long Initialize(unsigned int, Element *, unsigned long *);
20 |
21 | virtual IClassInfo * GetClassInfoW(void);
22 | virtual SIZE GetContentSize(int, int, Surface *);
23 | private:
24 | static IClassInfo * s_pClassInfo;
25 | };
26 | }
--------------------------------------------------------------------------------
/DirectUI/CProgressBar.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 |
3 | namespace DirectUI
4 | {
5 | class UILIB_API CCProgressBar :public CCBase
6 | {
7 | public:
8 | CCProgressBar(CCProgressBar const &);
9 | CCProgressBar(void);
10 | virtual ~CCProgressBar(void);
11 | CCProgressBar & operator=(CCProgressBar const &);
12 |
13 | static long __stdcall Create(unsigned int, Element *, unsigned long *, Element * *);
14 | static long __stdcall Create(Element *, unsigned long *, Element * *);
15 | static IClassInfo * __stdcall GetClassInfoPtr(void);
16 | static long __stdcall Register(void);
17 | static void __stdcall SetClassInfoPtr(IClassInfo *);
18 |
19 | long Initialize(unsigned int, Element *, unsigned long *);
20 |
21 | virtual IClassInfo * GetClassInfoW(void);
22 | virtual void OnInput(InputEvent *);
23 |
24 | private:
25 | static IClassInfo * s_pClassInfo;
26 | };
27 | }
--------------------------------------------------------------------------------
/DirectUI/CListBox.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 |
3 | namespace DirectUI
4 | {
5 | class UILIB_API CCListBox : public CCBase
6 | {
7 | public:
8 | CCListBox(CCListBox const &);
9 | CCListBox(void);
10 | virtual ~CCListBox(void);
11 | CCListBox & operator=(CCListBox const &);
12 |
13 | static long __stdcall Create(unsigned int, Element *, unsigned long *, Element * *);
14 | static long __stdcall Create(Element *, unsigned long *, Element * *);
15 | static IClassInfo * __stdcall GetClassInfoPtr(void);
16 | static long __stdcall Register(void);
17 | static void __stdcall SetClassInfoPtr(IClassInfo *);
18 |
19 | int DeleteString(int);
20 | int AddString(unsigned short const *);
21 | int GetCount(void);
22 |
23 | virtual IClassInfo * GetClassInfoW(void);
24 | virtual SIZE GetContentSize(int, int, Surface *);
25 |
26 | private:
27 | static IClassInfo * s_pClassInfo;
28 | };
29 | }
--------------------------------------------------------------------------------
/docs/TouchEdit2Class.g.txt:
--------------------------------------------------------------------------------
1 | ClassInfo:
2 | Base Class:
3 | Properties:
4 | [PromptText]: String
5 | [PromptWithCaret]: Bool
6 | [SuppressClearButton]: Bool
7 | [ShowClearButtonMinWidth]: Int
8 | [PasswordRevealMode]: Int
9 | Enum values:
10 | Normal : 0x0 (0)
11 | Disabled : 0x1 (1)
12 | [InnerBorderThickness]: Rect
13 | [PasswordCharacter]: Int
14 | [IgnoredKeyCombos]: Int
15 | Enum values:
16 | None : 0x0 (0)
17 | Copy : 0x11 (17)
18 | Paste : 0xa (10)
19 | Cut : 0x24 (36)
20 | Default : 0x1 (1)
21 | Left : 0x1 (1)
22 | Center : 0x2 (2)
23 | Right : 0x4 (4)
24 | [KeyboardNavigationCapture]: Int
25 | Enum values:
26 | Default : 0x0 (0)
27 | None : 0x1 (1)
28 | VisualState : 0x6 (6)
29 | : 0x0 (0)
30 |
--------------------------------------------------------------------------------
/DirectUI/CCheckBox.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 |
3 | namespace DirectUI
4 | {
5 | class UILIB_API CCCheckBox :public CCBaseCheckRadioButton
6 | {
7 | public:
8 | CCCheckBox(const CCCheckBox &);
9 | CCCheckBox(unsigned long v1=0x403);
10 | CCCheckBox & operator=(const CCCheckBox &);
11 | virtual ~CCCheckBox(void);
12 |
13 | static long __stdcall Create(unsigned int, Element *, unsigned long *, Element * *);
14 | static long __stdcall Create(Element *, unsigned long *, Element * *);
15 | static long __stdcall Register(void);
16 | static void __stdcall SetClassInfoPtr(IClassInfo *);
17 | static IClassInfo * __stdcall GetClassInfoPtr(void);
18 |
19 | virtual IClassInfo * GetClassInfoW(void);
20 | virtual void OnInput(InputEvent *);
21 | virtual bool OnNotify(UINT uMsg, WPARAM wParam, LPARAM lParam, LRESULT* plResult);
22 |
23 | private:
24 | static IClassInfo * s_pClassInfo;
25 | };
26 | }
--------------------------------------------------------------------------------
/DirectUI/SelectorNoDefault.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 |
3 | namespace DirectUI
4 | {
5 | class UILIB_API SelectorNoDefault :public Selector
6 | {
7 | public:
8 | SelectorNoDefault(SelectorNoDefault const &);
9 | SelectorNoDefault(void);
10 | virtual ~SelectorNoDefault(void);
11 | SelectorNoDefault & operator=(SelectorNoDefault const &);
12 |
13 | static long __stdcall Create(Element *, unsigned long *, Element * *);
14 | static IClassInfo * __stdcall GetClassInfoPtr(void);
15 | static long __stdcall Register(void);
16 | static void __stdcall SetClassInfoPtr(IClassInfo *);
17 |
18 | long Initialize(Element *, unsigned long *);
19 |
20 | virtual IClassInfo * GetClassInfoW(void);
21 | virtual void OnEvent(Event *);
22 | virtual void OnKeyFocusMoved(Element *, Element *);
23 | virtual long SetSelection(Element *);
24 | private:
25 | static IClassInfo * s_pClassInfo;
26 |
27 | };
28 | }
--------------------------------------------------------------------------------
/DirectUI/Bind.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 |
3 | namespace DirectUI
4 | {
5 | class UILIB_API Bind :public Element
6 | {
7 | public:
8 | Bind(const Bind &);
9 | Bind(void);
10 | Bind & operator=(const Bind &);
11 | virtual ~Bind(void);
12 |
13 | static const PropertyInfo * __stdcall ConnectProp(void);
14 | static long __stdcall Create(Element *, unsigned long *, Element * *);
15 | static IClassInfo * __stdcall GetClassInfoPtr(void);
16 | static const PropertyInfo * __stdcall PropertyProp(void);
17 | static long __stdcall Register(void);
18 | static void __stdcall SetClassInfoPtr(IClassInfo *);
19 |
20 | virtual IClassInfo * GetClassInfoW(void);
21 |
22 | UCString GetConnect(Value * *);
23 | UCString GetProperty(Value * *);
24 | long Initialize(Element *, unsigned long *);
25 | long SetConnect(UCString);
26 | long SetProperty(UCString);
27 | private:
28 | static IClassInfo* s_pClassInfo;
29 | };
30 | }
--------------------------------------------------------------------------------
/DirectUI/Primitives.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 |
3 | namespace DirectUI
4 | {
5 |
6 | struct Fill
7 | {
8 |
9 | };
10 |
11 | struct Cursor
12 | {
13 |
14 | };
15 |
16 | struct Graphic
17 | {
18 |
19 | };
20 |
21 |
22 | struct EnumMap
23 | {
24 |
25 | };
26 |
27 | struct PropertyInfo
28 | {
29 | UCString name;
30 | UINT64 unk1;
31 | struct PropCapability {
32 | ValueType type : 6;
33 | UINT other : 26;
34 | UINT unk;
35 | } *cap;
36 | struct { UCString str_value; int int_value; } *enum_value_map;
37 | Value *(*get_default_value)();
38 | UINT64 *unk2;
39 | };
40 |
41 | struct DepRecs
42 | {
43 |
44 | };
45 |
46 | struct UILIB_API NavReference
47 | {
48 | public:
49 | NavReference() = delete;
50 | NavReference(const NavReference&) = delete;
51 | ~NavReference() = delete;
52 |
53 | void Init(Element *, RECT *);
54 | NavReference& operator=(NavReference const &);
55 | };
56 | }
--------------------------------------------------------------------------------
/README.md:
--------------------------------------------------------------------------------
1 | # DirectUI
2 |
3 | `dui70.dll`,延续 mingkuang 的工作,主要探索了其制成成品软件的能力:
4 |
5 | * `DirectUI::Value` 的各个 Type 。
6 | * `IClassInfo`, `PropertyInfo`, `EnumMap` 构成的反射,并由此 dump 出 `/docs`,写 xml 查起来应该比较方便。
7 | * 做了 `IEventListener` 的接口修正,和事件系统稍微一缝就能跑起来了。
8 | * 只看了 InputEvent,普通 Event 没看,估计是每种消息都有一种 Event,太麻烦了。
9 | * 大致的 Layout 方法,看代码应该能看懂,光 `BorderLayout()` 就已经足够排出大部分自适应布局。
10 | * style 的写法,`if` `unless` 是抄的 css 选择器,而 `ressheet` `resstr` 等资源相关的比较简单, duixml 中比较迷惑的是 `gtc` `gtf` 这些,实际上都是 uxtheme 的 API,想了解 ida 从 parser 找过去就可以了。
11 | * 动画,虽然插值方法很多种,但属性比较少,所以只能支持简单的动画,看 animation enum 的取值即可。如果你有旧系统,可以把 Win7 或 Vista 的 "入门" 控制面板项中的 UIFILE 提取出来读,里面有伸缩位移+透明度混合的动画。
12 | * Interop,由于底层是 Gdip,我想也没什么必要特地做;实际上有自己实现 IClassInfo,重写 Element 的虚方法,自制控件的办法,此时既可以用传统 WndProc 子类化,也可以弄个 Host 在自己里面继续套娃做 UserControl,就是写起来应该比较抽象。
13 | * 兼容性,虽然 dui70 是个随系统 ship 的库,而且还有像是 ieui 等不少 fork,但它的兼容性似乎没什么问题,旧的接口从版本 8 一直到现在的版本 14 还是能用。
14 |
15 | UxTheme 的时代曾还没开始就已经结束,Qt, yue 和 dui70 是三个仅存的火种。
16 |
--------------------------------------------------------------------------------
/DirectUI/CCSysLink.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 |
3 | namespace DirectUI
4 | {
5 | class UILIB_API CCSysLink :public CCBase
6 | {
7 | public:
8 | CCSysLink(CCSysLink const &);
9 | CCSysLink(void);
10 | virtual ~CCSysLink(void);
11 | CCSysLink & operator=(CCSysLink const &);
12 |
13 | static long __stdcall Create(unsigned int, Element *, unsigned long *, Element * *);
14 | static long __stdcall Create(Element *, unsigned long *, Element * *);
15 | static IClassInfo * __stdcall GetClassInfoPtr(void);
16 | static long __stdcall Register(void);
17 | static void __stdcall SetClassInfoPtr(IClassInfo *);
18 |
19 | virtual IClassInfo * GetClassInfoW(void);
20 | virtual struct tagSIZE GetContentSize(int, int, Surface *);
21 | virtual void OnInput(InputEvent *);
22 | virtual bool OnLostDialogFocus(DialogElement *);
23 | virtual bool OnReceivedDialogFocus(DialogElement *);
24 |
25 | private:
26 | static IClassInfo * s_pClassInfo;
27 | };
28 | }
--------------------------------------------------------------------------------
/DirectUI/CheckBoxGlyph.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 |
3 | namespace DirectUI
4 | {
5 | class UILIB_API CheckBoxGlyph : public Button
6 | {
7 | public:
8 | CheckBoxGlyph(CheckBoxGlyph const &);
9 | CheckBoxGlyph(void);
10 | virtual ~CheckBoxGlyph(void);
11 | CheckBoxGlyph & operator=(CheckBoxGlyph const &);
12 |
13 | static long __stdcall Create(unsigned int, Element *, unsigned long *, Element * *);
14 | static long __stdcall Create(Element *, unsigned long *, Element * *);
15 | static IClassInfo * __stdcall GetClassInfoPtr(void);
16 | static long __stdcall Register(void);
17 | static void __stdcall SetClassInfoPtr(IClassInfo *);
18 |
19 | long Initialize(unsigned int, Element *, unsigned long *);
20 |
21 | virtual IClassInfo * GetClassInfoW(void);
22 | virtual bool OnLostDialogFocus(DialogElement *);
23 | virtual bool OnReceivedDialogFocus(DialogElement *);
24 |
25 | private:
26 | static IClassInfo * s_pClassInfo;
27 |
28 | };
29 | }
--------------------------------------------------------------------------------
/DirectUI/RepeatButton.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 |
3 | namespace DirectUI
4 | {
5 |
6 | class UILIB_API RepeatButton : public Button
7 | {
8 | public:
9 | RepeatButton(RepeatButton const &);
10 | RepeatButton(void);
11 | virtual ~RepeatButton(void);
12 | RepeatButton & operator=(RepeatButton const &);
13 |
14 | static long __stdcall Create(unsigned int, Element *, unsigned long *, Element * *);
15 | static long __stdcall Create(Element *, unsigned long *, Element * *);
16 | static IClassInfo * __stdcall GetClassInfoPtr(void);
17 | static long __stdcall Register(void);
18 | static void __stdcall SetClassInfoPtr(IClassInfo *);
19 |
20 | long Initialize(unsigned int, Element *, unsigned long *);
21 |
22 | virtual IClassInfo * GetClassInfoW(void);
23 | virtual void OnInput(struct InputEvent *);
24 | private:
25 | static void __stdcall _RepeatButtonActionCallback(struct GMA_ACTIONINFO *);
26 | static IClassInfo * s_pClassInfo;
27 |
28 | };
29 | }
--------------------------------------------------------------------------------
/DirectUI/RadioButtonGlyph.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 |
3 | namespace DirectUI
4 | {
5 | class UILIB_API RadioButtonGlyph : public Button
6 | {
7 | public:
8 | RadioButtonGlyph(RadioButtonGlyph const &);
9 | RadioButtonGlyph(void);
10 | virtual ~RadioButtonGlyph(void);
11 | RadioButtonGlyph & operator=(RadioButtonGlyph const &);
12 |
13 | static long __stdcall Create(unsigned int, Element *, unsigned long *, Element * *);
14 | static long __stdcall Create(Element *, unsigned long *, Element * *);
15 | static IClassInfo * __stdcall GetClassInfoPtr(void);
16 | static long __stdcall Register(void);
17 | static void __stdcall SetClassInfoPtr(IClassInfo *);
18 |
19 | long Initialize(unsigned int, Element *, unsigned long *);
20 |
21 | virtual IClassInfo * GetClassInfoW(void);
22 | virtual bool OnLostDialogFocus(DialogElement *);
23 | virtual bool OnReceivedDialogFocus(DialogElement *);
24 | private:
25 | static IClassInfo * s_pClassInfo;
26 |
27 | };
28 | }
--------------------------------------------------------------------------------
/DirectUI/ExpandoButtonGlyph.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 |
3 | namespace DirectUI
4 | {
5 | class UILIB_API ExpandoButtonGlyph : public Button
6 | {
7 | public:
8 | ExpandoButtonGlyph(ExpandoButtonGlyph const &);
9 | ExpandoButtonGlyph(void);
10 | virtual ~ExpandoButtonGlyph(void);
11 | ExpandoButtonGlyph & operator=(ExpandoButtonGlyph const &);
12 |
13 | static long __stdcall Create(unsigned int, Element *, unsigned long *, Element * *);
14 | static long __stdcall Create(Element *, unsigned long *, Element * *);
15 | static IClassInfo * __stdcall GetClassInfoPtr(void);
16 | static long __stdcall Register(void);
17 | static void __stdcall SetClassInfoPtr(IClassInfo *);
18 |
19 | long Initialize(unsigned int, Element *, unsigned long *);
20 |
21 | virtual IClassInfo * GetClassInfoW(void);
22 | virtual bool OnLostDialogFocus(DialogElement *);
23 | virtual bool OnReceivedDialogFocus(DialogElement *);
24 |
25 | private:
26 | static IClassInfo * s_pClassInfo;
27 | };
28 | }
--------------------------------------------------------------------------------
/DirectUI/CBaseCheckRadioButton.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 |
3 | namespace DirectUI
4 | {
5 | //此类无新增虚函数
6 | class UILIB_API CCBaseCheckRadioButton : public CCPushButton
7 | {
8 | public:
9 | CCBaseCheckRadioButton(const CCBaseCheckRadioButton &);
10 | CCBaseCheckRadioButton(unsigned long);
11 | CCBaseCheckRadioButton & operator=(const CCBaseCheckRadioButton &);
12 |
13 | virtual ~CCBaseCheckRadioButton(void);
14 |
15 | static IClassInfo * __stdcall GetClassInfoPtr(void);
16 | static long __stdcall Register(void);
17 | static void __stdcall SetClassInfoPtr(IClassInfo *);
18 |
19 | virtual IClassInfo * GetClassInfoW(void);
20 | virtual SIZE GetContentSize(int, int, Surface *);
21 | virtual bool OnLostDialogFocus(DialogElement *);
22 | virtual void OnPropertyChanged(PropertyInfo const *, int, Value *, Value *);
23 | virtual bool OnReceivedDialogFocus(DialogElement *);
24 | protected:
25 | virtual void PostCreate(HWND);
26 |
27 | private:
28 | static IClassInfo * s_pClassInfo;
29 | };
30 | }
--------------------------------------------------------------------------------
/DirectUI/StyledScrollViewer.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 |
3 | namespace DirectUI
4 | {
5 | class UILIB_API StyledScrollViewer
6 | : public BaseScrollViewer
7 | {
8 | public:
9 | StyledScrollViewer(StyledScrollViewer const &);
10 | StyledScrollViewer(void);
11 | virtual ~StyledScrollViewer(void);
12 | StyledScrollViewer & operator=(StyledScrollViewer const &);
13 |
14 | static long __stdcall Create(Element *, unsigned long *, Element * *);
15 | static IClassInfo * __stdcall GetClassInfoPtr(void);
16 | static long __stdcall Register(void);
17 | static void __stdcall SetClassInfoPtr(IClassInfo *);
18 |
19 | virtual IClassInfo * GetClassInfoW(void);
20 | virtual void OnListenedPropertyChanged(Element *, PropertyInfo const *, int, Value *, Value *);
21 | protected:
22 | virtual long AddChildren(void);
23 | virtual long CreateScrollBars(void);
24 | virtual BaseScrollBar * GetHScroll(void);
25 | virtual BaseScrollBar * GetVScroll(void);
26 | private:
27 | static IClassInfo * s_pClassInfo;
28 |
29 | };
30 | }
--------------------------------------------------------------------------------
/DirectUI/TextGraphic.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 |
3 | namespace DirectUI
4 | {
5 | class UILIB_API TextGraphic : public Element
6 | {
7 | public:
8 | TextGraphic(TextGraphic const &);
9 | TextGraphic(void);
10 | virtual ~TextGraphic(void);
11 | TextGraphic & operator=(TextGraphic const &);
12 |
13 | static long __stdcall Create(Element *, unsigned long *, Element * *);
14 | static IClassInfo * __stdcall GetClassInfoPtr(void);
15 | static long __stdcall Register(void);
16 | static void __stdcall SetClassInfoPtr(IClassInfo *);
17 | static PropertyInfo const * __stdcall SideGraphicProp(void);
18 |
19 | long Initialize(Element *, unsigned long *);
20 |
21 | virtual IClassInfo * GetClassInfoW(void);
22 | virtual unsigned short const * GetContentStringAsDisplayed(Value * *);
23 | virtual void OnPropertyChanged(PropertyInfo const *, int, Value *, Value *);
24 | virtual bool OnPropertyChanging(PropertyInfo const *, int, Value *, Value *);
25 |
26 | private:
27 | static IClassInfo * s_pClassInfo;
28 | };
29 | }
--------------------------------------------------------------------------------
/DirectUI/PushButton.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 |
3 |
4 | namespace DirectUI
5 | {
6 | class UILIB_API PushButton : public AutoButton
7 | {
8 | public:
9 | PushButton(PushButton const &);
10 | PushButton(void);
11 | virtual ~PushButton(void);
12 | PushButton & operator=(PushButton const &);
13 |
14 | static long __stdcall Create(Element *, unsigned long *, Element * *);
15 | static PropertyInfo const * __stdcall EnforceSizeProp(void);
16 | static IClassInfo * __stdcall GetClassInfoPtr(void);
17 | static UID __stdcall Hosted(void);
18 | static long __stdcall Register(void);
19 | static void __stdcall SetClassInfoPtr(IClassInfo *);
20 |
21 | bool GetEnforceSize(void);
22 | long SetEnforceSize(bool);
23 |
24 | virtual IClassInfo * GetClassInfoW(void);
25 | virtual SIZE GetContentSize(int, int, Surface *);
26 | virtual void OnHosted(Element *);
27 | virtual void OnUnHosted(Element *);
28 |
29 | private:
30 | static IClassInfo * s_pClassInfo;
31 | void FireHostEvent(Element *, bool);
32 |
33 | };
34 | }
--------------------------------------------------------------------------------
/demangler/ReadMe.txt:
--------------------------------------------------------------------------------
1 | ========================================================================
2 | 控制台应用程序:demangler 项目概述
3 | ========================================================================
4 |
5 | 应用程序向导已为您创建了此 demangler 应用程序。
6 |
7 | 本文件概要介绍组成 demangler 应用程序的每个文件的内容。
8 |
9 |
10 | demangler.vcxproj
11 | 这是使用应用程序向导生成的 VC++ 项目的主项目文件,其中包含生成该文件的 Visual C++ 的版本信息,以及有关使用应用程序向导选择的平台、配置和项目功能的信息。
12 |
13 | demangler.vcxproj.filters
14 | 这是使用“应用程序向导”生成的 VC++ 项目筛选器文件。它包含有关项目文件与筛选器之间的关联信息。在 IDE 中,通过这种关联,在特定节点下以分组形式显示具有相似扩展名的文件。例如,“.cpp”文件与“源文件”筛选器关联。
15 |
16 | demangler.cpp
17 | 这是主应用程序源文件。
18 |
19 | /////////////////////////////////////////////////////////////////////////////
20 | 其他标准文件:
21 |
22 | StdAfx.h, StdAfx.cpp
23 | 这些文件用于生成名为 demangler.pch 的预编译头 (PCH) 文件和名为 StdAfx.obj 的预编译类型文件。
24 |
25 | /////////////////////////////////////////////////////////////////////////////
26 | 其他注释:
27 |
28 | 应用程序向导使用“TODO:”注释来指示应添加或自定义的源代码部分。
29 |
30 | /////////////////////////////////////////////////////////////////////////////
31 |
--------------------------------------------------------------------------------
/DirectUI/CRadioButton.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 |
3 | namespace DirectUI
4 | {
5 | class UILIB_API CCRadioButton : public CCBaseCheckRadioButton
6 | {
7 | public:
8 | CCRadioButton(CCRadioButton const &);
9 | CCRadioButton(void);
10 | virtual ~CCRadioButton(void);
11 | CCRadioButton & operator=(CCRadioButton const &);
12 |
13 | static PropertyInfo const * __stdcall AutoGroupingProp(void);
14 | static long __stdcall Create(unsigned int, Element *, unsigned long *, Element * *);
15 | static long __stdcall Create(Element *, unsigned long *, Element * *);
16 | static void __stdcall SetClassInfoPtr(IClassInfo *);
17 | static IClassInfo * __stdcall GetClassInfoPtr(void);
18 | static long __stdcall Register(void);
19 |
20 | bool GetAutoGrouping(void);
21 | long SetAutoGrouping(bool);
22 |
23 | virtual IClassInfo * GetClassInfoW(void);
24 | virtual void OnInput(InputEvent *);
25 | virtual bool OnNotify(UINT uMsg, WPARAM wParam, LPARAM lParam, LRESULT* plResult);
26 | private:
27 | static IClassInfo * s_pClassInfo;
28 | };
29 | }
--------------------------------------------------------------------------------
/DirectUI/ScrollItem.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 |
3 | namespace DirectUI
4 | {
5 | class UILIB_API ScrollItemProvider
6 | : public PatternProvider
7 | , public IScrollItemProvider
8 | {
9 | public:
10 | ScrollItemProvider(void);
11 | virtual ~ScrollItemProvider(void);
12 |
13 | virtual unsigned long __stdcall AddRef(void);
14 | virtual ProviderProxyCall GetProxyCreator(void);
15 | virtual long __stdcall QueryInterface(struct _GUID const &, void * *);
16 | virtual unsigned long __stdcall Release(void);
17 | virtual long __stdcall ScrollIntoView(void);
18 |
19 | };
20 |
21 | class UILIB_API ScrollItemProxy : public IProxy
22 | {
23 | public:
24 | ScrollItemProxy(ScrollItemProxy const &);
25 | ScrollItemProxy(void);
26 | ScrollItemProxy & operator=(ScrollItemProxy const &);
27 |
28 | static ScrollItemProxy * __stdcall Create(Element *);
29 | static bool __stdcall IsPatternSupported(Element *);
30 |
31 | virtual long DoMethod(int, char *);
32 | protected:
33 | virtual void Init(Element *);
34 | };
35 | }
--------------------------------------------------------------------------------
/DirectUI/Browser.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 |
3 | namespace DirectUI
4 | {
5 | class UILIB_API Browser :public Element
6 | {
7 | public:
8 | Browser(const Browser &);
9 | Browser(void);
10 | Browser & operator=(const Browser &);
11 | virtual ~Browser(void);
12 |
13 | static long __stdcall Create(Element *, unsigned long *, Element * *);
14 | static UID __stdcall Entered(void);
15 | static IClassInfo * __stdcall GetClassInfoPtr(void);
16 | static UID __stdcall Leaving(void);
17 | static long __stdcall Register(void);
18 | static void __stdcall SetClassInfoPtr(IClassInfo *);
19 | static UID __stdcall StartNavigate(void);
20 |
21 | Element * GetCurrentPage(void);
22 | unsigned short GetCurrentPageID(void);
23 | class Pages * GetPages(void);
24 | long Initialize(Element *, unsigned long *);
25 |
26 | virtual IClassInfo * GetClassInfoW(void);
27 | virtual void OnEvent(Event *);
28 | virtual void OnPropertyChanged(const PropertyInfo *, int, Value *, Value *);
29 | private:
30 | int FireNavigate(unsigned short);
31 | static IClassInfo * s_pClassInfo;
32 | };
33 | }
--------------------------------------------------------------------------------
/DirectUI/Expando.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 |
3 | namespace DirectUI
4 | {
5 | class UILIB_API Expando : public Expandable
6 | {
7 | public:
8 | Expando(Expando const &);
9 | Expando(void);
10 | virtual ~Expando(void);
11 | Expando & operator=(Expando const &);
12 |
13 | static long __stdcall Register(void);
14 | static void __stdcall SetClassInfoPtr(IClassInfo *);
15 | static long __stdcall Create(Element *, unsigned long *, Element * *);
16 | static IClassInfo * __stdcall GetClassInfoPtr(void);
17 |
18 | long Initialize(Element *, unsigned long *);
19 |
20 | virtual long Add(Element * *, unsigned int);
21 | virtual IClassInfo * GetClassInfoW(void);
22 | virtual void OnEvent(Event *);
23 | virtual void OnPropertyChanged(PropertyInfo const *, int, Value *, Value *);
24 | protected:
25 | static unsigned short __stdcall Arrow(void);
26 | static unsigned short __stdcall Clipper(void);
27 | void UpdateChildren(Value *);
28 |
29 | private:
30 | static unsigned short _atmArrow;
31 | static unsigned short _atmClipper;
32 | static IClassInfo * s_pClassInfo;
33 | };
34 | }
--------------------------------------------------------------------------------
/DirectUI/Toggle.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 |
3 | namespace DirectUI
4 | {
5 | class UILIB_API ToggleProvider
6 | : public PatternProvider
7 | , public IToggleProvider
8 | {
9 | public:
10 | ToggleProvider(void);
11 | virtual ~ToggleProvider(void);
12 | virtual unsigned long __stdcall AddRef(void);
13 | virtual ProviderProxyCall GetProxyCreator(void);
14 | virtual long __stdcall QueryInterface(GUID const &, void * *);
15 | virtual unsigned long __stdcall Release(void);
16 | virtual long __stdcall Toggle(void);
17 | virtual long __stdcall get_ToggleState(ToggleState *);
18 | };
19 |
20 | class UILIB_API ToggleProxy : IProxy
21 | {
22 | public:
23 | ToggleProxy(ToggleProxy const &);
24 | ToggleProxy(void);
25 | ToggleProxy & operator=(ToggleProxy const &);
26 | static ToggleProxy * __stdcall Create(Element *);
27 | static bool __stdcall IsPatternSupported(Element *);
28 | virtual long DoMethod(int, char *);
29 |
30 | protected:
31 | virtual void Init(Element *);
32 |
33 | private:
34 | long GetToggleState(ToggleState *);
35 |
36 | };
37 | }
--------------------------------------------------------------------------------
/DirectUI/ScrollViewer.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 |
3 | namespace DirectUI
4 | {
5 | class UILIB_API ScrollViewer
6 | : public BaseScrollViewer
7 | {
8 | public:
9 | ScrollViewer(ScrollViewer const &);
10 | ScrollViewer(void);
11 | virtual ~ScrollViewer(void);
12 | ScrollViewer & operator=(ScrollViewer const &);
13 |
14 | static long __stdcall Create(Element *, unsigned long *, Element * *);
15 | static IClassInfo * __stdcall GetClassInfoPtr(void);
16 | static long __stdcall Register(void);
17 | static void __stdcall SetClassInfoPtr(IClassInfo *);
18 |
19 | virtual IClassInfo * GetClassInfoW(void);
20 | virtual void OnListenedPropertyChanged(Element *, PropertyInfo const *, int, Value *, Value *);
21 | virtual void OnPropertyChanged(PropertyInfo const *, int, Value *, Value *);
22 | protected:
23 | //1
24 | virtual long CreateScrollBars(void);
25 | //2
26 | virtual long AddChildren(void);
27 | //3
28 | virtual BaseScrollBar * GetHScroll(void);
29 | //4
30 | virtual BaseScrollBar * GetVScroll(void);
31 |
32 | private:
33 | static IClassInfo * s_pClassInfo;
34 |
35 | };
36 | }
--------------------------------------------------------------------------------
/DirectUI/TableItem.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 |
3 | namespace DirectUI
4 | {
5 | class UILIB_API TableItemProvider
6 | : public PatternProvider
7 | , public ITableItemProvider
8 | {
9 | public:
10 | TableItemProvider(void);
11 | virtual ~TableItemProvider(void);
12 |
13 | virtual unsigned long __stdcall AddRef(void);
14 | virtual long __stdcall GetColumnHeaderItems(SAFEARRAY * *);
15 | virtual ProviderProxyCall GetProxyCreator(void);
16 | virtual long __stdcall GetRowHeaderItems(SAFEARRAY * *);
17 | virtual long __stdcall QueryInterface(GUID const &, void * *);
18 | virtual unsigned long __stdcall Release(void);
19 |
20 | };
21 |
22 | class UILIB_API TableItemProxy : public IProxy
23 | {
24 | public:
25 | TableItemProxy(TableItemProxy const &);
26 | TableItemProxy(void);
27 | TableItemProxy & operator=(TableItemProxy const &);
28 |
29 | static TableItemProxy * __stdcall Create(Element *);
30 | static bool __stdcall IsPatternSupported(Element *);
31 | virtual long DoMethod(int, char *);
32 | protected:
33 | virtual void Init(Element *);
34 |
35 | };
36 | }
--------------------------------------------------------------------------------
/DirectUI/Table.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 |
3 | namespace DirectUI
4 | {
5 | class UILIB_API TableProvider
6 | : public PatternProvider
7 | , public ITableProvider
8 | {
9 | public:
10 | TableProvider(void);
11 | virtual ~TableProvider(void);
12 |
13 | virtual unsigned long __stdcall AddRef(void);
14 | virtual long __stdcall GetColumnHeaders(SAFEARRAY * *);
15 | virtual ProviderProxyCall GetProxyCreator(void);
16 | virtual long __stdcall GetRowHeaders(SAFEARRAY * *);
17 | virtual long __stdcall QueryInterface(GUID const &, void * *);
18 | virtual unsigned long __stdcall Release(void);
19 | virtual long __stdcall get_RowOrColumnMajor(RowOrColumnMajor *);
20 | };
21 |
22 | class UILIB_API TableProxy : public IProxy
23 | {
24 | public:
25 | TableProxy(TableProxy const &);
26 | TableProxy(void);
27 | TableProxy & operator=(TableProxy const &);
28 |
29 | static TableProxy * __stdcall Create(Element *);
30 | static bool __stdcall IsPatternSupported(Element *);
31 |
32 | virtual long DoMethod(int, char *);
33 |
34 | protected:
35 | virtual void Init(Element *);
36 |
37 | };
38 | }
--------------------------------------------------------------------------------
/LICENSE:
--------------------------------------------------------------------------------
1 | The MIT License (MIT)
2 |
3 | Copyright (c) 2016 Chuyu-Team
4 |
5 | Permission is hereby granted, free of charge, to any person obtaining a copy
6 | of this software and associated documentation files (the "Software"), to deal
7 | in the Software without restriction, including without limitation the rights
8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9 | copies of the Software, and to permit persons to whom the Software is
10 | furnished to do so, subject to the following conditions:
11 |
12 | The above copyright notice and this permission notice shall be included in all
13 | copies or substantial portions of the Software.
14 |
15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21 | SOFTWARE.
22 |
--------------------------------------------------------------------------------
/DirectUI/DirectUI.def:
--------------------------------------------------------------------------------
1 | LIBRARY
2 | EXPORTS
3 | InitProcessPriv
4 | UnInitProcessPriv
5 | InitThread
6 | UnInitThread
7 | CreateDUIWrapper
8 | CreateDUIWrapperEx
9 | CreateDUIWrapperFromResource
10 | GetScreenDPI
11 | RegisterAllControls
12 | RegisterBaseControls
13 | RegisterBrowserControls
14 | RegisterCommonControls
15 | RegisterExtendedControls
16 | RegisterMacroControls
17 | RegisterMiscControls
18 | RegisterStandardControls
19 | RegisterXControls
20 | StartMessagePump
21 | StopMessagePump
22 | StrToID
23 | UnicodeToMultiByte
24 | MultiByteToUnicode
25 | IsAnimationsEnabled
26 | IsPalette
27 | IsUIAutomationProviderEnabled
28 | BlurBitmap
29 | BrushFromEnumI
30 | ColorFromEnumI
31 | DisableAnimations
32 | DrawShadowTextEx
33 | DUIDrawShadowText
34 | ElementFromGadget
35 | EnableAnimations
36 | FlushThemeHandles
37 | ForceDebugBreak
38 | GetElementDataEntry
39 | GetElementMacro
40 | GetFontCache
41 | GetThemeHandle
42 | HrSysAllocString
43 | HStrDup
44 | InitPreprocessor
45 | SetDefAction
46 | UiaHideOnGetObject
47 | UiaOnDestroySink
48 | UiaOnGetObject
49 | UiaOnToolTip
50 | NotifyAccessibilityEvent
51 | PreprocessBuffer
52 | ProcessAlphaBitmapI
53 | PurgeThemeHandles
--------------------------------------------------------------------------------
/DirectUI/CCommandLink.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 |
3 | namespace DirectUI
4 | {
5 | class UILIB_API CCCommandLink :public CCPushButton
6 | {
7 | public:
8 | CCCommandLink(CCCommandLink const &);
9 | CCCommandLink(unsigned long v1=0xE);
10 | virtual ~CCCommandLink(void);
11 | CCCommandLink & operator=(CCCommandLink const &);
12 |
13 | static long __stdcall Create(unsigned int, Element *, unsigned long *, Element * *);
14 | static long __stdcall Create(Element *, unsigned long *, Element * *);
15 | static IClassInfo * __stdcall GetClassInfoPtr(void);
16 | static long __stdcall Register(void);
17 | static void __stdcall SetClassInfoPtr(IClassInfo *);
18 | static PropertyInfo const * __stdcall NoteProp(void);
19 |
20 | UCString GetNote(Value * *);
21 | long SetNote(UCString);
22 |
23 | virtual IClassInfo * GetClassInfoW(void);
24 | virtual SIZE GetContentSize(int, int, Surface *);
25 | virtual void OnPropertyChanged(PropertyInfo const *, int, Value *, Value *);
26 | virtual void OnSelectedPropertyChanged(void);
27 | protected:
28 | void SyncNoteAndGlyph(HWND);
29 | virtual void PostCreate(HWND);
30 |
31 | private:
32 | static IClassInfo * s_pClassInfo;
33 | };
34 | }
--------------------------------------------------------------------------------
/DirectUI/Macro.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 |
3 | namespace DirectUI
4 | {
5 | class UILIB_API Macro : public Element
6 | {
7 | public:
8 | Macro(Macro const &);
9 | Macro(void);
10 | virtual ~Macro(void);
11 | Macro & operator=(Macro const &);
12 |
13 | static long __stdcall Create(Element *, unsigned long *, Element * *);
14 | static PropertyInfo const * __stdcall ExpandProp(void);
15 | static IClassInfo * __stdcall GetClassInfoPtr(void);
16 | static long __stdcall Register(void);
17 | static void __stdcall SetClassInfoPtr(IClassInfo *);
18 |
19 | void SetDataEntry(IDataEntry *, Element *);;
20 | long SetExpand(unsigned short const *);
21 | void SetParser(DUIXmlParser *);
22 | IDataEntry * GetDataEntry(void);
23 | unsigned short const * GetExpand(Value * *);
24 | long Initialize(Element *, unsigned long *);
25 |
26 |
27 | virtual long Add(Element * *, unsigned int);
28 | virtual IClassInfo * GetClassInfoW(void);
29 | virtual void OnPropertyChanged(PropertyInfo const *, int, Value *, Value *);
30 | protected:
31 | //1
32 | virtual long BuildElement(void);
33 | void ResolveBindings(void);
34 |
35 | private:
36 | static IClassInfo * s_pClassInfo;
37 | };
38 | }
--------------------------------------------------------------------------------
/DirectUI/Selection.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 |
3 | namespace DirectUI
4 | {
5 | class UILIB_API SelectionProvider
6 | : public PatternProvider
7 | , public ISelectionProvider
8 | {
9 | public:
10 | SelectionProvider(void);
11 | virtual ~SelectionProvider(void);
12 |
13 | virtual unsigned long __stdcall AddRef(void);
14 | virtual ProviderProxyCall GetProxyCreator(void);
15 | virtual long __stdcall GetSelection(SAFEARRAY * *);
16 | virtual long __stdcall QueryInterface(GUID const &, void * *);
17 | virtual unsigned long __stdcall Release(void);
18 | virtual long __stdcall get_CanSelectMultiple(int *);
19 | virtual long __stdcall get_IsSelectionRequired(int *);
20 |
21 | };
22 |
23 | class UILIB_API SelectionProxy : public IProxy
24 | {
25 | protected:
26 | SelectionProxy(void);
27 | public:
28 | SelectionProxy(SelectionProxy const &);
29 | SelectionProxy & operator=(SelectionProxy const &);
30 |
31 | static SelectionProxy * __stdcall Create(Element *);
32 | static bool __stdcall IsPatternSupported(Element *);
33 |
34 | virtual long DoMethod(int, char *);
35 | protected:
36 | virtual void Init(Element *);
37 |
38 | };
39 | }
--------------------------------------------------------------------------------
/UITest/app.manifest:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
15 |
16 |
17 |
18 |
19 |
20 |
24 | true/PM
25 | PerMonitorV2, PerMonitor
26 |
27 |
28 |
29 |
30 |
--------------------------------------------------------------------------------
/DirectUI/Selector.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 |
3 | namespace DirectUI
4 | {
5 | class UILIB_API Selector : public Element
6 | {
7 | public:
8 | Selector(Selector const &);
9 | Selector(void);
10 | virtual ~Selector(void);
11 | Selector & operator=(Selector const &);
12 |
13 | static long __stdcall Create(Element *, unsigned long *, Element * *);
14 | static long __stdcall Register(void);
15 | static UID __stdcall SelectionChange(void);
16 | static PropertyInfo const * __stdcall SelectionProp(void);
17 | static void __stdcall SetClassInfoPtr(IClassInfo *);
18 | static IClassInfo * __stdcall GetClassInfoPtr(void);
19 |
20 | Element * GetSelection(void);
21 | long Initialize(Element *, unsigned long *);
22 |
23 | virtual Element * GetAdjacent(Element *, int, NavReference const *, unsigned long);
24 | virtual IClassInfo * GetClassInfoW(void);
25 | virtual void OnEvent(Event *);
26 | virtual void OnInput(struct InputEvent *);
27 | virtual void OnKeyFocusMoved(Element *, Element *);
28 | virtual void OnPropertyChanged(PropertyInfo const *, int, Value *, Value *);
29 |
30 | //1
31 | virtual long SetSelection(Element *);
32 |
33 | private:
34 | static IClassInfo * s_pClassInfo;
35 |
36 | };
37 | }
--------------------------------------------------------------------------------
/DirectUI/Grid.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 |
3 | namespace DirectUI
4 | {
5 | class UILIB_API GridProvider
6 | : public PatternProvider
7 | , public IGridProvider
8 | {
9 | public:
10 | GridProvider(void);
11 | virtual ~GridProvider(void);;
12 |
13 | virtual unsigned long __stdcall AddRef(void);
14 | virtual long __stdcall GetItem(int, int, IRawElementProviderSimple * *);
15 | virtual ProviderProxyCall GetProxyCreator(void);
16 | virtual long __stdcall QueryInterface(GUID const &, void * *);
17 | virtual unsigned long __stdcall Release(void);
18 | virtual long __stdcall get_ColumnCount(int *);
19 | virtual long __stdcall get_RowCount(int *);
20 |
21 | };
22 |
23 | class UILIB_API GridProxy : public IProxy
24 | {
25 | public:
26 | GridProxy(GridProxy const &);
27 | GridProxy();
28 | GridProxy & operator=(GridProxy const &);
29 |
30 | static GridProxy * __stdcall Create(Element *);
31 | static bool __stdcall IsPatternSupported(Element *);
32 |
33 | virtual long DoMethod(int, char *);
34 |
35 | protected:
36 | virtual void Init(Element *);
37 |
38 | private:
39 | long GetColumnCount(int *);
40 | long GetItem(unsigned int, unsigned int, IRawElementProviderSimple * *);
41 | long GetRowCount(int *);
42 | };
43 | }
--------------------------------------------------------------------------------
/DirectUI/RefPointElement.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 |
3 | namespace DirectUI
4 | {
5 | class UILIB_API RefPointElement : public Element
6 | {
7 | public:
8 | RefPointElement(RefPointElement const &);
9 | RefPointElement(void);
10 | virtual ~RefPointElement(void);
11 | RefPointElement & operator=(RefPointElement const &);
12 |
13 | static PropertyInfo const * __stdcall ActualReferencePointProp(void);
14 | static long __stdcall Create(unsigned int, Element *, unsigned long *, Element * *);
15 | static long __stdcall Create(Element *, unsigned long *, Element * *);
16 | static Element * __stdcall FindRefPoint(Element *, POINT *);
17 | static IClassInfo * __stdcall GetClassInfoPtr(void);
18 | static PropertyInfo const * __stdcall ReferencePointProp(void);
19 | static long __stdcall Register(void);
20 | static void __stdcall SetClassInfoPtr(IClassInfo *);
21 | static RefPointElement * __stdcall Locate(Element *);
22 |
23 | POINT const * GetActualReferencePoint(Value * *);
24 | POINT const * GetReferencePoint(Value * *);
25 | long Initialize(unsigned int, Element *, unsigned long *);
26 | long SetReferencePoint(int, int);
27 |
28 | virtual IClassInfo * GetClassInfoW(void);
29 | virtual void OnPropertyChanged(PropertyInfo const *, int, Value *, Value *);
30 | private:
31 | static IClassInfo * s_pClassInfo;
32 |
33 | };
34 | }
--------------------------------------------------------------------------------
/DirectUI/SelectionItem.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 |
3 | namespace DirectUI
4 | {
5 | class UILIB_API SelectionItemProvider
6 | : public PatternProvider
7 | , public ISelectionItemProvider
8 | {
9 | public:
10 | SelectionItemProvider(void);
11 | virtual ~SelectionItemProvider(void);
12 |
13 | virtual unsigned long __stdcall AddRef(void);
14 | virtual long __stdcall AddToSelection(void);
15 | virtual ProviderProxyCall GetProxyCreator(void);
16 | virtual long __stdcall QueryInterface(GUID const &, void * *);
17 | virtual unsigned long __stdcall Release(void);
18 | virtual long __stdcall RemoveFromSelection(void);
19 | virtual long __stdcall Select(void);
20 | virtual long __stdcall get_IsSelected(int *);
21 | virtual long __stdcall get_SelectionContainer(IRawElementProviderSimple * *);
22 |
23 | };
24 |
25 | class UILIB_API SelectionItemProxy : IProxy
26 | {
27 | protected:
28 | SelectionItemProxy(void);
29 | public:
30 | SelectionItemProxy(SelectionItemProxy const &);
31 | SelectionItemProxy & operator=(SelectionItemProxy const &);
32 |
33 | static SelectionItemProxy * __stdcall Create(Element *);
34 | static bool __stdcall IsPatternSupported(Element *);
35 |
36 | virtual long DoMethod(int, char *);
37 | protected:
38 | virtual void Init(Element *);
39 |
40 | };
41 | }
--------------------------------------------------------------------------------
/DirectUI/AccessibleButton.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 |
3 | namespace DirectUI
4 | {
5 | class UILIB_API AccessibleButton : public Button
6 | {
7 | public:
8 | AccessibleButton(const AccessibleButton&);
9 | AccessibleButton();
10 |
11 | virtual ~AccessibleButton();
12 | AccessibleButton& operator=(const AccessibleButton&);
13 |
14 | static HRESULT WINAPI Create(Element*, unsigned long*, Element**);
15 | static IClassInfo* WINAPI GetClassInfoPtr();
16 | //Button函数重写
17 | //0
18 | virtual void OnPropertyChanged(const PropertyInfo*, int, Value*, Value*);
19 | //1
20 | virtual IClassInfo* GetClassInfoW();
21 |
22 | long Initialize(Element*, unsigned long*);
23 |
24 | void Recalc();
25 | static HRESULT WINAPI Register();
26 | static void WINAPI SetClassInfoPtr(IClassInfo*);
27 |
28 | // member types
29 | struct UILIB_API ACCESSIBLEROLE
30 | {
31 | ACCESSIBLEROLE() = delete;
32 | ACCESSIBLEROLE(const ACCESSIBLEROLE&) = delete;
33 | ~ACCESSIBLEROLE() = delete;
34 |
35 | // see http://msdn.microsoft.com/en-us/library/system.windows.forms.accessiblerole.aspx
36 | ACCESSIBLEROLE& operator=(const ACCESSIBLEROLE&);
37 | };
38 |
39 | private:
40 | static const ACCESSIBLEROLE* WINAPI FindAccessibleRole(int);
41 |
42 | static const ACCESSIBLEROLE* __ptr32 c_rgar;
43 | static IClassInfo* s_pClassInfo;
44 | };
45 |
46 | }
--------------------------------------------------------------------------------
/DirectUI/RangeValue.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 |
3 | namespace DirectUI
4 | {
5 | class UILIB_API RangeValueProvider
6 | : public PatternProvider
7 | , public IRangeValueProvider
8 | {
9 | public:
10 | RangeValueProvider(void);
11 | virtual ~RangeValueProvider(void);
12 |
13 | virtual unsigned long __stdcall AddRef(void);
14 | virtual ProviderProxyCall GetProxyCreator(void);
15 | virtual long __stdcall QueryInterface(GUID const &, void * *);
16 | virtual unsigned long __stdcall Release(void);
17 | virtual long __stdcall SetValue(double);
18 | virtual long __stdcall get_IsReadOnly(int *);
19 | virtual long __stdcall get_LargeChange(double *);
20 | virtual long __stdcall get_Maximum(double *);
21 | virtual long __stdcall get_Minimum(double *);
22 | virtual long __stdcall get_SmallChange(double *);
23 | virtual long __stdcall get_Value(double *);
24 | };
25 |
26 | class UILIB_API RangeValueProxy : public IProxy
27 | {
28 | public:
29 | RangeValueProxy(RangeValueProxy const &);
30 | RangeValueProxy & operator=(RangeValueProxy const &);
31 |
32 | static RangeValueProxy * __stdcall Create(Element *);
33 | static bool __stdcall IsPatternSupported(Element *);
34 |
35 | virtual long DoMethod(int, char *);
36 | protected:
37 | RangeValueProxy(void);
38 |
39 | virtual void Init(Element *);
40 |
41 | };
42 | }
--------------------------------------------------------------------------------
/DirectUI/CTreeView.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 |
3 | namespace DirectUI
4 | {
5 | class UILIB_API CCTreeView : public CCBase
6 | {
7 | public:
8 | CCTreeView(CCTreeView const &);
9 | CCTreeView(unsigned long v1=0);
10 | virtual~CCTreeView(void);
11 | CCTreeView &operator=(CCTreeView const &);
12 |
13 | static long __stdcall Create(unsigned int, Element *, unsigned long *, Element * *);
14 | static long __stdcall Create(Element *, unsigned long *, Element * *);
15 | static IClassInfo * __stdcall GetClassInfoPtr(void);
16 | static long __stdcall Register(void);
17 | static void __stdcall SetClassInfoPtr(IClassInfo *);
18 |
19 | HTREEITEM InsertItem(unsigned short *, unsigned int, const HTREEITEM, const HTREEITEM);
20 | HTREEITEM InsertItem(const TVINSERTSTRUCTW *);
21 | unsigned int GetItemState(HTREEITEM const);
22 | unsigned long GetStyle(void);
23 | void SetItemState(HTREEITEM, unsigned int);
24 |
25 | virtual IClassInfo *GetClassInfoW(void);
26 | virtual SIZE GetContentSize(int, int, Surface *);
27 | virtual bool OnNotify(UINT uMsg, WPARAM wParam, LPARAM lParam, LRESULT* plResult);
28 | unsigned long SetStyle(unsigned long);
29 |
30 | protected:
31 | //1
32 | virtual long _OnGetInfoTip(NMTVGETINFOTIPW const *);
33 | //2
34 | virtual long _OnItemChanged(NMTVITEMCHANGE const *);
35 |
36 | private:
37 | static IClassInfo * s_pClassInfo;
38 | };
39 | }
--------------------------------------------------------------------------------
/DirectUI/GridItem.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 |
3 | namespace DirectUI
4 | {
5 | class UILIB_API GridItemProvider
6 | : PatternProvider
7 | , public IGridItemProvider
8 | {
9 | public:
10 | GridItemProvider(void);
11 | virtual ~GridItemProvider(void);
12 |
13 | virtual unsigned long __stdcall AddRef(void);
14 | virtual ProviderProxyCall GetProxyCreator(void);;
15 | virtual long __stdcall QueryInterface(GUID const &, void * *);
16 | virtual unsigned long __stdcall Release(void);
17 | virtual long __stdcall get_Column(int *);
18 | virtual long __stdcall get_ColumnSpan(int *);
19 | virtual long __stdcall get_ContainingGrid(IRawElementProviderSimple * *);
20 | virtual long __stdcall get_Row(int *);
21 | virtual long __stdcall get_RowSpan(int *);
22 | };
23 |
24 | class UILIB_API GridItemProxy : public IProxy
25 | {
26 | public:
27 | GridItemProxy(GridItemProxy const &);
28 | GridItemProxy(void);
29 | GridItemProxy & operator=(GridItemProxy const &);
30 |
31 | static GridItemProxy * __stdcall Create(Element *);
32 | static bool __stdcall IsPatternSupported(Element *);
33 | //1
34 | virtual long DoMethod(int, char *);
35 | protected:
36 | //2
37 | virtual void Init(Element *);
38 |
39 | private:
40 | long GetColumn(int *);
41 | long GetContainingGrid(IRawElementProviderSimple * *);
42 | long GetRow(int *);
43 | };
44 | }
--------------------------------------------------------------------------------
/demangler/demangler.vcxproj.filters:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | {4FC737F1-C7A5-4376-A066-2A32D752A2FF}
6 | cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx
7 |
8 |
9 | {93995380-89BD-4b04-88EB-625FBE52EBFB}
10 | h;hh;hpp;hxx;hm;inl;inc;xsd
11 |
12 |
13 | {67DA6AB6-F800-4c08-8B7A-83BB121AAD01}
14 | rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx;tiff;tif;png;wav;mfcribbon-ms
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 | 头文件
23 |
24 |
25 | 头文件
26 |
27 |
28 |
29 |
30 | 源文件
31 |
32 |
33 | 源文件
34 |
35 |
36 |
--------------------------------------------------------------------------------
/DirectUI/Combobox.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 |
3 | namespace DirectUI
4 | {
5 | class UILIB_API Combobox : public HWNDHost
6 | {
7 | public:
8 | Combobox(Combobox const &);
9 | Combobox(void);
10 | virtual ~Combobox(void);
11 | Combobox & operator=(Combobox const &);
12 |
13 |
14 | static long __stdcall Create(unsigned int, Element *, unsigned long *, Element * *);
15 | static long __stdcall Create(Element *, unsigned long *, Element * *);
16 | static IClassInfo * __stdcall GetClassInfoPtr(void);
17 | static long __stdcall Register(void);
18 | static UID __stdcall SelectionChange(void);
19 | static const PropertyInfo* __stdcall SelectionProp(void);
20 | static void __stdcall SetClassInfoPtr(IClassInfo *);
21 |
22 | long SetSelection(int);
23 | int AddString(unsigned short const *);
24 | int GetSelection(void);
25 | long Initialize(unsigned int, Element *, unsigned long *);
26 |
27 | virtual HWND CreateHWND(HWND);
28 | virtual IClassInfo * GetClassInfoW(void);
29 | virtual SIZE GetContentSize(int, int, Surface *);
30 | virtual int OnAdjustWindowSize(int, int, unsigned int);
31 | virtual void OnHosted(Element *);
32 | virtual void OnInput(InputEvent *);
33 | virtual bool OnNotify(UINT uMsg, WPARAM wParam, LPARAM lParam, LRESULT* plResult);
34 | virtual void OnPropertyChanged(const PropertyInfo*, int, Value *, Value *);
35 |
36 | private:
37 | static IClassInfo * s_pClassInfo;
38 |
39 | };
40 | }
--------------------------------------------------------------------------------
/DirectUI/Button.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 |
3 | namespace DirectUI
4 | {
5 | class UILIB_API Button : public Element
6 | {
7 | public:
8 | Button(const Button&);
9 | Button();
10 | virtual ~Button();
11 | Button & operator=(const Button&);
12 |
13 | long Initialize(unsigned int, Element*, unsigned long*);
14 | static HRESULT WINAPI Create(unsigned int, Element*, unsigned long*, Element**);
15 | static HRESULT WINAPI Create(Element*, unsigned long*, Element**);
16 |
17 | static UID WINAPI Click();
18 | static UID WINAPI Context();
19 | //Element类函数重写
20 | //0
21 | virtual void OnPropertyChanged(const PropertyInfo*, int, Value*, Value*);
22 | //1
23 | virtual void OnInput(InputEvent*);
24 |
25 | //2
26 | virtual IClassInfo* GetClassInfoW();
27 |
28 | //3
29 | virtual long DefaultAction();
30 |
31 | bool GetCaptured();
32 | static IClassInfo* WINAPI GetClassInfoPtr();
33 | bool GetPressed();
34 | //Button 新增虚函数
35 | //0
36 | virtual bool OnLostDialogFocus(class DialogElement*);
37 | //1
38 | virtual bool OnReceivedDialogFocus(class DialogElement*);
39 |
40 | static long WINAPI Register();
41 | static const PropertyInfo* WINAPI CapturedProp();
42 | static const PropertyInfo* WINAPI PressedProp();
43 | static void WINAPI SetClassInfoPtr(IClassInfo*);
44 |
45 | long SetCaptured(bool);
46 | long SetPressed(bool);
47 |
48 |
49 | private:
50 | static IClassInfo* s_pClassInfo;
51 | };
52 | }
--------------------------------------------------------------------------------
/docs/duixml/AuthBrokerUI.dll.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
20 |
21 |
22 |
--------------------------------------------------------------------------------
/DirectUI/Page.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 |
3 | namespace DirectUI
4 | {
5 | class UILIB_API Page : public Macro
6 | {
7 | public:
8 | Page(Page const &);
9 | Page(void);
10 | virtual ~Page(void);
11 | Page & operator=(Page const &);
12 |
13 | static long __stdcall Create(Element *, unsigned long *, Element * *);
14 | static IClassInfo * __stdcall GetClassInfoPtr(void);
15 | static long __stdcall Register(void);
16 | static void __stdcall SetClassInfoPtr(IClassInfo *);
17 |
18 | long Initialize(Element *, unsigned long *);
19 |
20 | virtual IClassInfo * GetClassInfoW(void);
21 |
22 | private:
23 | static IClassInfo * s_pClassInfo;
24 |
25 | };
26 |
27 | class UILIB_API Pages : public Element
28 | {
29 | public:
30 | Pages(Pages const &);
31 | Pages(void);
32 | virtual ~Pages(void);
33 | Pages & operator=(Pages const &);
34 |
35 | static long __stdcall Create(Element *, unsigned long *, Element * *);
36 | static IClassInfo * __stdcall GetClassInfoPtr(void);
37 | static long __stdcall Register(void);
38 | static void __stdcall SetClassInfoPtr(IClassInfo *);
39 |
40 | unsigned int GetCount(void);
41 | Element * GetPage(unsigned int);
42 | Element * GetPage(unsigned short const *);
43 | long Initialize(Element *, unsigned long *);
44 | void SetNoBrowseOnFirstAdd(void);
45 |
46 | virtual long Add(Element * *, unsigned int);
47 | virtual IClassInfo * GetClassInfoW(void);
48 |
49 | private:
50 | static IClassInfo * s_pClassInfo;
51 |
52 | };
53 | }
--------------------------------------------------------------------------------
/DirectUI/Progress.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 |
3 | namespace DirectUI
4 | {
5 | class UILIB_API Progress : public Element
6 | {
7 | public:
8 | Progress(Progress const &);
9 | Progress(void);
10 | virtual ~Progress(void);
11 | Progress & operator=(Progress const &);
12 |
13 | static long __stdcall Create(Element *, unsigned long *, Element * *);
14 | static IClassInfo * __stdcall GetClassInfoPtr(void);
15 | static PropertyInfo const * __stdcall PositionProp(void);
16 | static long __stdcall Register(void);
17 | static void __stdcall SetClassInfoPtr(IClassInfo *);
18 | static PropertyInfo const * __stdcall MaximumProp(void);
19 | static PropertyInfo const * __stdcall MinimumProp(void);
20 |
21 | int GetMaximum(void);
22 | int GetMinimum(void);
23 | int GetPosition(void);
24 | long Initialize(Element *, unsigned long *);
25 | long SetMaximum(int);
26 | long SetMinimum(int);
27 | long SetPosition(int);
28 |
29 | virtual IClassInfo * GetClassInfoW(void);
30 | virtual SIZE GetContentSize(int, int, Surface *);
31 | virtual void Paint(HDC, RECT const *, RECT const *, RECT *, RECT *);
32 | private:
33 | static IClassInfo * s_pClassInfo;
34 |
35 | };
36 |
37 | class UILIB_API ProgressRangeValueProxy : public IProxy
38 | {
39 | public:
40 | ProgressRangeValueProxy(ProgressRangeValueProxy const &);
41 | ProgressRangeValueProxy(void);
42 | ProgressRangeValueProxy & operator=(ProgressRangeValueProxy const &);
43 |
44 | virtual long DoMethod(int, char *);
45 | protected:
46 | virtual void Init(Element *);
47 | };
48 | }
--------------------------------------------------------------------------------
/DirectUI/CTrackBar.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 |
3 | namespace DirectUI
4 | {
5 | class UILIB_API CCTrackBar : public CCBase
6 | {
7 | public:
8 | CCTrackBar(CCTrackBar const &);
9 | CCTrackBar(void);
10 | virtual ~CCTrackBar(void);
11 | CCTrackBar & operator=(CCTrackBar const &);
12 |
13 | static long __stdcall Create(unsigned int, Element *, unsigned long *, Element * *);
14 | static long __stdcall Create(Element *, unsigned long *, Element * *);
15 | static IClassInfo * __stdcall GetClassInfoPtr(void);
16 | static const PropertyInfo* __stdcall LineSizeProp(void);
17 | static const PropertyInfo* __stdcall ThumbPositionProp(void);
18 | static const PropertyInfo* __stdcall RangeMaxProp(void);
19 | static const PropertyInfo* __stdcall RangeMinProp(void);
20 | static long __stdcall Register(void);
21 | static void __stdcall SetClassInfoPtr(IClassInfo *);
22 |
23 | int GetLineSize(void);
24 | int GetRangeMax(void);
25 | int GetRangeMin(void);
26 | int GetThumbPosition(void);
27 | long SetLineSize(int);
28 | long SetRangeMax(int);
29 | long SetRangeMin(int);
30 | long SetThumbPosition(int);
31 |
32 | virtual IClassInfo * GetClassInfoW(void);
33 | virtual bool OnMessage(UINT message, WPARAM wParam, LPARAM lParam, LRESULT* plResult);
34 | virtual void OnPropertyChanged(const PropertyInfo*, int, Value *, Value *);
35 | virtual bool OnPropertyChanging(const PropertyInfo*, int, Value *, Value *);
36 |
37 | protected:
38 | virtual void PostCreate(HWND);
39 | private:
40 | static IClassInfo * s_pClassInfo;
41 |
42 | };
43 | }
--------------------------------------------------------------------------------
/DirectUI/Navigator.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 |
3 | namespace DirectUI
4 | {
5 | class UILIB_API Navigator : public PushButton
6 | {
7 | public:
8 | Navigator(Navigator const &);
9 | Navigator(void);
10 | virtual ~Navigator(void);
11 | Navigator & operator=(Navigator const &);
12 |
13 | static UID __stdcall ActionInitiated(void);
14 | static long __stdcall Create(Element *, unsigned long *, Element * *);
15 | static long __stdcall Register(void);
16 | static void __stdcall SetClassInfoPtr(IClassInfo *);
17 | static IClassInfo * __stdcall GetClassInfoPtr(void);
18 | static PropertyInfo const * __stdcall TargetPageProp(void);
19 |
20 | Browser * GetBrowser(void);
21 | unsigned short const * GetTargetPage(Value * *);
22 | long Initialize(Element *, unsigned long *);
23 | long SetTargetPage(unsigned short const *);
24 |
25 | virtual IClassInfo * GetClassInfoW(void);
26 | virtual void OnEvent(Event *);
27 |
28 | private:
29 | static IClassInfo * s_pClassInfo;
30 | void FireNavigationEvent(void);
31 |
32 | };
33 |
34 | class UILIB_API NavigatorSelectionItemProxy : public IProxy
35 | {
36 | public:
37 | NavigatorSelectionItemProxy(NavigatorSelectionItemProxy const &);
38 | NavigatorSelectionItemProxy(void);
39 | NavigatorSelectionItemProxy & operator=(NavigatorSelectionItemProxy const &);
40 | //1
41 | virtual long DoMethod(int, char *);
42 | protected:
43 | //2
44 | virtual void Init(Element *);
45 |
46 | private:
47 | long AddToSelection(Browser *);
48 | long GetIsSelected(Browser *, int *);
49 |
50 | };
51 | }
--------------------------------------------------------------------------------
/DirectUI/ExpandCollapse.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 |
3 | namespace DirectUI
4 | {
5 |
6 | class UILIB_API ExpandCollapseProvider
7 | : public PatternProvider
8 | , public IExpandCollapseProvider
9 | {
10 | public:
11 | ExpandCollapseProvider(void);
12 |
13 | virtual ~ExpandCollapseProvider(void);;
14 |
15 |
16 | virtual ProviderProxyCall GetProxyCreator(void);
17 |
18 |
19 | //IUnknown
20 | virtual HRESULT STDMETHODCALLTYPE QueryInterface(
21 | /* [in] */ REFIID riid,
22 | /* [iid_is][out] */ _COM_Outptr_ void __RPC_FAR *__RPC_FAR *ppvObject);
23 |
24 | virtual ULONG STDMETHODCALLTYPE AddRef(void);
25 |
26 | virtual ULONG STDMETHODCALLTYPE Release(void);
27 |
28 |
29 | //IExpandCollapseProvider
30 | virtual HRESULT STDMETHODCALLTYPE Expand(void);
31 |
32 | virtual HRESULT STDMETHODCALLTYPE Collapse(void);
33 |
34 | virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_ExpandCollapseState(
35 | /* [retval][out] */ __RPC__out enum ExpandCollapseState *pRetVal);
36 |
37 | };
38 |
39 | class UILIB_API ExpandCollapseProxy : public IProxy
40 | {
41 | public:
42 | ExpandCollapseProxy(ExpandCollapseProxy const &);
43 | ExpandCollapseProxy(void);
44 | ExpandCollapseProxy & operator=(ExpandCollapseProxy const &);
45 |
46 | static ExpandCollapseProxy * __stdcall Create(Element *);
47 | static bool __stdcall IsPatternSupported(Element *);
48 |
49 | //1
50 | virtual long DoMethod(int, char *);
51 |
52 |
53 | protected:
54 | //2
55 | virtual void Init(Element *);
56 | };
57 |
58 | }
--------------------------------------------------------------------------------
/DirectUI/NativeHWNDHost.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 |
3 | namespace DirectUI
4 | {
5 |
6 | class UILIB_API NativeHWNDHost
7 | {
8 | public:
9 | NativeHWNDHost(const NativeHWNDHost&);
10 | NativeHWNDHost();
11 | virtual ~NativeHWNDHost();
12 |
13 | static LRESULT WINAPI WndProc(HWND, UINT, WPARAM, LPARAM);
14 | NativeHWNDHost& operator=(const NativeHWNDHost&);
15 | static UINT WINAPI AsyncDestroyMsg();
16 |
17 | static HRESULT WINAPI Create(UCString lpClassName, UCString lpWindowName, HWND hWndParent, HICON hIcon, int x, int y, int nWidth, int nHeight, int dwExStyle, int dwStyle, HINSTANCE, UINT, NativeHWNDHost**out);
18 | static HRESULT WINAPI Create(UCString lpWindowName, HWND hWndParent, HICON hIcon, int x, int y, int nWidth, int nHeight, int dwExStyle, int dwStyle, unsigned int, NativeHWNDHost**out);
19 |
20 | void Destroy();
21 | void DestroyWindow();
22 |
23 | class Element* GetElement();
24 | HWND GetHWND();
25 |
26 | void HideWindow();
27 | void Host(class Element*);
28 |
29 | HRESULT Initialize(UCString lpClassName, UCString lpWindowName, HWND hWndParent, HICON hIcon, int x, int y, int nWidth, int nHeight, int dwExStyle, int dwStyle, HINSTANCE, UINT);
30 | HRESULT Initialize(UCString, HWND, HICON, int, int, int, int, int, int, UINT);
31 |
32 | virtual HRESULT OnMessage(UINT uMsg, WPARAM wParam, LPARAM lParam, LRESULT*);
33 |
34 | int RestoreFocus();
35 | void SaveFocus();
36 | void SetDefaultFocusID(UCString);
37 | void ShowWindow(int);
38 |
39 | private:
40 | HWND m_hWnd;
41 | void*unk2;
42 | void*unk3;
43 | void*unk4;
44 | char unk5;
45 | };
46 | }
--------------------------------------------------------------------------------
/DirectUI/XBaby.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 |
3 | namespace DirectUI
4 | {
5 | class UILIB_API XBaby : public DialogElement
6 | {
7 | public:
8 | XBaby(XBaby const &);
9 | XBaby(void);
10 | virtual ~XBaby(void);
11 | XBaby & operator=(XBaby const &);
12 | void CacheParser(DUIXmlParser *);
13 |
14 | static long __stdcall Create(Element *, unsigned long *, Element * *);
15 | static long __stdcall Create(IXElementCP *,class XProvider *, HWND, Element *, unsigned long *, Element * *);
16 | static IClassInfo * __stdcall GetClassInfoPtr(void);
17 | static long __stdcall Register(void);
18 | static void __stdcall SetClassInfoPtr(IClassInfo *);
19 |
20 | void ForceThemeChange(UINT_PTR, LONG_PTR);
21 | SIZE GetContentDesiredSize(int, int);
22 | long GetHostedElementID(unsigned short *);
23 | long SetToHost(Element *);
24 |
25 | virtual bool CanSetFocus(void);
26 | virtual long CreateStyleParser(DUIXmlParser * *);
27 | virtual Element * GetAdjacent(Element *, int, NavReference const *, unsigned long);
28 | virtual IClassInfo * GetClassInfoW(void);
29 | virtual bool OnChildLostFocus(Element *);
30 | virtual bool OnChildReceivedFocus(Element *);
31 | virtual void OnEvent(Event *);
32 | virtual void OnNoChildWithShortcutFound(KeyboardEvent *);
33 | virtual void OnThemeChanged(ThemeChangedEvent *);
34 | virtual void OnWmThemeChanged(WPARAM wParam, LPARAM lParam);
35 | virtual void SetKeyFocus(void);
36 |
37 | //1
38 | virtual Element * GetFocusableElement(void);
39 | protected:
40 | long Initialize(IXElementCP *, XProvider *, HWND, Element *, unsigned long *);
41 | private:
42 | static IClassInfo * s_pClassInfo;
43 | };
44 | }
--------------------------------------------------------------------------------
/DirectUI/XElement.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 |
3 | namespace DirectUI
4 | {
5 | class UILIB_API XElement
6 | : public HWNDHost
7 | , public IXElementCP
8 | {
9 | public:
10 | XElement(XElement const &);
11 | XElement(void);
12 | virtual ~XElement(void);
13 | XElement & operator=(XElement const &);
14 | static long __stdcall Create(unsigned int, Element *, unsigned long *, Element * *);
15 | static long __stdcall Create(Element *, unsigned long *, Element * *);
16 | static unsigned int const s_uButtonFocusChangeMsg;
17 | static unsigned int const s_uNavigateOutMsg;
18 | static unsigned int const s_uUnhandledSyscharMsg;
19 | static UID __stdcall UnhandledSyschar(void);
20 | static IClassInfo * __stdcall GetClassInfoPtr(void);
21 | static long __stdcall Register(void);
22 | static void __stdcall SetClassInfoPtr(IClassInfo *);
23 |
24 | void FreeProvider(void);
25 | HWND GetInnerHWND(void);
26 | class IXProvider * GetProvider(void);
27 | long Initialize(unsigned int, Element *, unsigned long *);
28 | bool IsDescendent(Element *);
29 | long SetProvider(IUnknown *);
30 |
31 | virtual HWND CreateHWND(HWND);
32 | virtual IClassInfo * GetClassInfoW(void);
33 | virtual void OnEvent(Event *);
34 | virtual void OnInput(InputEvent *);
35 | virtual bool OnMessage(UINT uMsg, WPARAM wParam, LPARAM lParam, LRESULT*);
36 | virtual bool OnSinkThemeChanged(UINT uMsg, WPARAM wParam, LPARAM lParam, LRESULT*);
37 | virtual bool OnSysChar(unsigned short);
38 | virtual void SetKeyFocus(void);
39 |
40 | //IXElementCP
41 | virtual HWND GetNotificationSinkHWND(void);
42 |
43 | private:
44 | static IClassInfo * s_pClassInfo;
45 | };
46 | }
--------------------------------------------------------------------------------
/DirectUI/Viewer.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 |
3 | namespace DirectUI
4 | {
5 | class UILIB_API Viewer : public Element
6 | {
7 | public:
8 | Viewer(Viewer const &);
9 | Viewer(void);
10 | virtual ~Viewer(void);
11 | Viewer & operator=(Viewer const &);
12 |
13 | static long __stdcall Create(Element *, unsigned long *, Element * *);
14 | static long __stdcall Register(void);
15 | static void __stdcall SetClassInfoPtr(IClassInfo *);
16 | static PropertyInfo const * __stdcall XOffsetProp(void);
17 | static PropertyInfo const * __stdcall XScrollableProp(void);
18 | static PropertyInfo const * __stdcall YOffsetProp(void);
19 | static PropertyInfo const * __stdcall YScrollableProp(void);
20 | static IClassInfo * __stdcall GetClassInfoPtr(void);
21 |
22 | int GetXOffset(void);
23 | bool GetXScrollable(void);
24 | int GetYOffset(void);
25 | bool GetYScrollable(void);
26 | long Initialize(Element *, unsigned long *);
27 | long SetXOffset(int);
28 | long SetXScrollable(bool);
29 | long SetYOffset(int);
30 | long SetYScrollable(bool);
31 |
32 | virtual bool EnsureVisible(int, int, int, int);
33 | virtual IClassInfo * GetClassInfoW(void);
34 | virtual void OnEvent(Event *);
35 | virtual void OnInput(InputEvent *);
36 | virtual void OnPropertyChanged(PropertyInfo const *, int, Value *, Value *);
37 | virtual bool OnPropertyChanging(PropertyInfo const *, int, Value *, Value *);
38 | virtual void _SelfLayoutDoLayout(int, int);
39 | virtual SIZE _SelfLayoutUpdateDesiredSize(int, int, Surface *);
40 |
41 | private:
42 | static IClassInfo * s_pClassInfo;
43 | Element * GetContent(void);
44 | bool InternalEnsureVisible(int, int, int, int);
45 |
46 | };
47 | }
--------------------------------------------------------------------------------
/DirectUI/CBase.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 |
3 | namespace DirectUI
4 | {
5 | class UILIB_API CCBase :public HWNDHost
6 | {
7 | public:
8 | CCBase(const CCBase &);
9 | CCBase(unsigned long v1 =0, UCString v2=NULL);
10 | CCBase & operator=(const CCBase &);
11 |
12 | virtual ~CCBase(void);
13 |
14 | static long __stdcall Create(unsigned int, Element *, unsigned long *, Element * *);
15 | static long __stdcall Create(Element *, unsigned long *, Element * *);
16 | static long __stdcall Register(void);
17 | static void __stdcall SetClassInfoPtr(IClassInfo *);
18 | static IClassInfo * __stdcall GetClassInfoPtr(void);
19 | static PropertyInfo const * __stdcall WinStyleProp(void);
20 |
21 | int GetWinStyle(void);
22 | long Initialize(unsigned int, Element *, unsigned long *);
23 | void SetNotifyHandler(BOOL (WINAPI*)(UINT uMsg, WPARAM wParam, LPARAM lParam, LRESULT* plResult, void* pUserData), void* pUserData);
24 | long SetWinStyle(int);
25 |
26 | //父类父函数重载
27 | virtual void OnPropertyChanged(PropertyInfo const *, int, Value *, Value *);
28 | virtual HWND CreateHWND(HWND);
29 | virtual long DefaultAction(void);
30 | virtual IClassInfo * GetClassInfoW(void);
31 | virtual SIZE GetContentSize(int, int, Surface *);
32 | virtual void OnInput(InputEvent *);
33 | virtual bool OnNotify(UINT uMsg, WPARAM wParam, LPARAM lParam, LRESULT* plResult);
34 |
35 | //1
36 | virtual bool OnCustomDraw(NMCUSTOMDRAW *, LRESULT *);
37 | //2
38 | virtual bool OnLostDialogFocus(DialogElement *);
39 | //3
40 | virtual bool OnReceivedDialogFocus(DialogElement *);
41 |
42 | protected:
43 | //4
44 | virtual void PostCreate(HWND);
45 | private:
46 | static IClassInfo * s_pClassInfo;
47 | };
48 | }
--------------------------------------------------------------------------------
/UITest/UITest.vcxproj.filters:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | {4FC737F1-C7A5-4376-A066-2A32D752A2FF}
6 | cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx
7 |
8 |
9 | {93995380-89BD-4b04-88EB-625FBE52EBFB}
10 | h;hh;hpp;hxx;hm;inl;inc;xsd
11 |
12 |
13 | {67DA6AB6-F800-4c08-8B7A-83BB121AAD01}
14 | rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx;tiff;tif;png;wav;mfcribbon-ms
15 |
16 |
17 |
18 |
19 | 源文件
20 |
21 |
22 |
23 |
24 | 头文件
25 |
26 |
27 |
28 |
29 | 资源文件
30 |
31 |
32 |
33 |
34 | 资源文件
35 |
36 |
37 |
38 |
39 |
40 |
41 |
42 |
43 |
44 |
45 |
46 |
47 |
--------------------------------------------------------------------------------
/DirectUI/AnimationStrip.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 |
3 | namespace DirectUI
4 | {
5 | //此类所有虚函数继承自父类,无需额外调整
6 | class UILIB_API AnimationStrip :public Element
7 | {
8 | public:
9 | AnimationStrip(const AnimationStrip&);
10 | AnimationStrip();
11 | AnimationStrip& operator=(const AnimationStrip&);
12 | virtual ~AnimationStrip();
13 |
14 | static long __stdcall Create(Element*, unsigned long*, Element**);
15 | static const PropertyInfo* __stdcall FrameDurationProp();
16 | static const PropertyInfo* __stdcall FrameIndexProp();
17 | static const PropertyInfo* __stdcall FrameWidthProp();
18 | static IClassInfo* __stdcall GetClassInfoPtr();
19 | static const PropertyInfo* __stdcall PlayProp(void);
20 | static long __stdcall Register();
21 | static void __stdcall SetClassInfoPtr(IClassInfo*);
22 |
23 | int GetFrameDuration();
24 | int GetFrameIndex();
25 | int GetFrameWidth();
26 | bool GetPlay();
27 | long Initialize(unsigned int, Element*, unsigned long *);
28 | long SetFrameDuration(int);
29 | long SetFrameIndex(int);
30 | long SetFrameWidth(int);
31 | long SetPlay(bool);
32 | virtual IClassInfo* GetClassInfoW();
33 |
34 | protected:
35 | virtual void OnDestroy(void);
36 | virtual void OnPropertyChanged(const PropertyInfo*, int, Value *, Value *);
37 | virtual void Paint(HDC, const RECT*, const RECT*, RECT *, RECT *);
38 |
39 | void AdvanceFrame(void);
40 | long LoadImagesIntoAnimationStrip();
41 | void OnAction(GMA_ACTIONINFO *);
42 |
43 | static void __stdcall RawActionProc(GMA_ACTIONINFO *);
44 |
45 | private:
46 | long LoadCommonControlExports();
47 | long Start();
48 | void Stop();
49 | void UnloadCommonControlExports();
50 | static IClassInfo* s_pClassInfo;
51 | };
52 | }
--------------------------------------------------------------------------------
/DirectUI/CPushButton.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 |
3 | namespace DirectUI
4 | {
5 | class UILIB_API CCPushButton : public CCBase
6 | {
7 | public:
8 | CCPushButton(const CCPushButton &);
9 | CCPushButton(unsigned long v1=0);
10 | CCPushButton & operator=(const CCPushButton &);
11 |
12 | virtual ~CCPushButton(void);
13 |
14 | static long __stdcall Create(unsigned int, Element *, unsigned long *, Element * *);
15 | static long __stdcall Create(Element *, unsigned long *, Element * *);
16 | static const PropertyInfo * __stdcall OverrideButtonBackgroundProp(void);
17 | static long __stdcall Register(void);
18 | static void __stdcall SetClassInfoPtr(IClassInfo *);
19 | static IClassInfo * __stdcall GetClassInfoPtr(void);
20 | static const PropertyInfo * __stdcall HasShieldProp(void);
21 |
22 | long SetOverrideButtonBackground(bool);
23 | bool GetHasShield(void);
24 | bool GetOverrideButtonBackground(void);
25 |
26 | //父类虚函数重载
27 | virtual long DefaultAction(void);
28 | virtual IClassInfo * GetClassInfoW(void);
29 | virtual SIZE GetContentSize(int, int, Surface *);
30 | virtual void OnInput(InputEvent *);
31 | virtual bool OnLostDialogFocus(DialogElement *);
32 | virtual bool OnMessage(UINT message, WPARAM wParam, LPARAM lParam, LRESULT* plResult);
33 | virtual bool OnNotify(UINT uMsg, WPARAM wParam, LPARAM lParam, LRESULT* plResult);
34 | virtual void OnPropertyChanged(const PropertyInfo *, int, Value *, Value *);
35 | virtual bool OnReceivedDialogFocus(DialogElement *);
36 |
37 | //1
38 | virtual bool GetButtonColor(HDC, HBRUSH*);
39 | //2
40 | virtual void OnSelectedPropertyChanged(void);
41 | //3
42 | virtual SIZE EstimateContentSize(int, int, Surface *);
43 |
44 | protected:
45 | void SetDefaultState(unsigned long, unsigned long);
46 | private:
47 | static IClassInfo * s_pClassInfo;
48 | };
49 | }
--------------------------------------------------------------------------------
/DirectUI/CBaseScrollBar.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 |
3 | namespace DirectUI
4 | {
5 | //此类虚函数全部来自父
6 | class UILIB_API CCBaseScrollBar
7 | : public CCBase
8 | , public BaseScrollBar
9 | {
10 | public:
11 | CCBaseScrollBar(const CCBaseScrollBar &);
12 | CCBaseScrollBar(unsigned long v1=0);
13 | CCBaseScrollBar & operator=(const CCBaseScrollBar &);
14 |
15 | virtual ~CCBaseScrollBar(void);
16 |
17 | static IClassInfo * __stdcall GetClassInfoPtr(void);
18 | static const PropertyInfo* __stdcall LineProp(void);
19 | static const PropertyInfo* __stdcall MaximumProp(void);
20 | static const PropertyInfo* __stdcall MinimumProp(void);
21 | static const PropertyInfo* __stdcall PageProp(void);
22 | static const PropertyInfo* __stdcall PositionProp(void);
23 | static long __stdcall Register(void);
24 | static void __stdcall SetClassInfoPtr(IClassInfo *);
25 | static const PropertyInfo* __stdcall TrackingProp(void);
26 |
27 | bool GetTracking(void);
28 | long Initialize(unsigned int, Element *, unsigned long *);
29 | long SetTracking(bool);
30 | void SyncScrollBar(void);
31 |
32 |
33 | virtual HWND CreateHWND(HWND);
34 | virtual IClassInfo * GetClassInfoW(void);
35 | virtual Element * GetElement(void);
36 | virtual int GetLine(void);
37 | virtual int GetMaximum(void);
38 | virtual int GetMinimum(void);
39 | virtual int GetPage(void);
40 | virtual int GetPosition(void);
41 | virtual bool GetProportional(void);
42 | virtual bool OnMessage(UINT message, WPARAM wParam, LPARAM lParam, LRESULT* plResult);
43 | virtual void OnPropertyChanged(const PropertyInfo*, int, Value *, Value *);
44 | virtual bool OnPropertyChanging(const PropertyInfo*, int, Value *, Value *);
45 | virtual long SetLine(int);
46 | virtual long SetMaximum(int);
47 | virtual long SetMinimum(int);
48 | virtual long SetPage(int);
49 | virtual long SetPosition(int);
50 |
51 | private:
52 | static IClassInfo * s_pClassInfo;
53 | };
54 | }
--------------------------------------------------------------------------------
/DirectUI/CallstackTracker.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 |
3 | namespace DirectUI
4 | {
5 | class UILIB_API CallstackTracker
6 | {
7 | public:
8 | CallstackTracker(void);
9 | ~CallstackTracker(void);
10 | CallstackTracker & operator=(CallstackTracker const &);
11 | int CaptureCallstackFrames(void);
12 | int EnumCallstackFrames(void(__stdcall*)(char const *, char const *, unsigned long, unsigned long));
13 | static void __stdcall Uninit(void);
14 | static int __stdcall Init(void);
15 |
16 | struct STACK_SYMBOL_INFO
17 | {
18 |
19 | };
20 |
21 | struct IMGHLPFN_LOAD
22 | {
23 |
24 | };
25 |
26 | private:
27 | static int __stdcall InitFailed(void);
28 | static int __stdcall InitializeDllInfo(void);
29 | static int __stdcall InitializeSymbols(void);
30 | static int __stdcall IsCorrectImageHlpVersion(void);
31 | static int __stdcall DllsLoaded(void);
32 | void FillSymbolInfo(STACK_SYMBOL_INFO *, unsigned __int64);
33 | unsigned __int64 GetModuleBase(void *, unsigned __int64);
34 |
35 | static int const STACKDEPTH;
36 | static int const INITIALSTACKSKIP;
37 | static IMGHLPFN_LOAD * __ptr32 s_ImageHlpFuncList;
38 | static int s_fInitFailed;
39 | static void * s_hProcess;
40 | static HINSTANCE s_hinstImageHlp;
41 | static HINSTANCE s_hinstNtDll;
42 | static API_VERSION * (__stdcall* s_pfnImagehlpApiVersionEx)(API_VERSION *);
43 | static unsigned short(__stdcall* s_pfnRtlCaptureStackBackTrace)(unsigned long, unsigned long, void * *, unsigned long *);
44 | static int(__stdcall* s_pfnSymFromAddr)(void *, unsigned __int64, unsigned __int64 *, SYMBOL_INFO *);
45 | static int(__stdcall* s_pfnSymGetModuleInfo64)(void *, unsigned __int64, IMAGEHLP_MODULE64 *);
46 | static int(__stdcall* s_pfnSymInitialize)(void *, char const *, int);
47 | static unsigned __int64(__stdcall* s_pfnSymLoadModule64)(void *, void *, char const *, char const *, unsigned __int64, unsigned long);
48 | static unsigned long(__stdcall* s_pfnSymSetOptions)(unsigned long);
49 |
50 | };
51 | }
--------------------------------------------------------------------------------
/DirectUI/Scroll.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 |
3 | namespace DirectUI
4 | {
5 | class UILIB_API ScrollProvider
6 | : public PatternProvider
7 | , public IScrollProvider
8 | {
9 | public:
10 | ScrollProvider(void);
11 | virtual ~ScrollProvider(void);
12 |
13 | virtual unsigned long __stdcall AddRef(void);
14 | virtual ProviderProxyCall GetProxyCreator(void);
15 | virtual long __stdcall QueryInterface(struct _GUID const &, void * *);
16 | virtual unsigned long __stdcall Release(void);
17 | virtual long __stdcall Scroll(enum ScrollAmount, enum ScrollAmount);
18 | virtual long __stdcall SetScrollPercent(double, double);
19 | virtual long __stdcall get_HorizontalScrollPercent(double *);
20 | virtual long __stdcall get_HorizontalViewSize(double *);
21 | virtual long __stdcall get_HorizontallyScrollable(int *);
22 | virtual long __stdcall get_VerticalScrollPercent(double *);
23 | virtual long __stdcall get_VerticalViewSize(double *);
24 | virtual long __stdcall get_VerticallyScrollable(int *);
25 |
26 | };
27 |
28 | class UILIB_API ScrollProxy : public IProxy
29 | {
30 | public:
31 | ScrollProxy(ScrollProxy const &);
32 | ScrollProxy(void);
33 | ScrollProxy & operator=(ScrollProxy const &);
34 |
35 | static ScrollProxy * __stdcall Create(Element *);
36 | static bool __stdcall IsPatternSupported(Element *);
37 |
38 | virtual long DoMethod(int, char *);
39 | protected:
40 | virtual void Init(Element *);
41 | private:
42 | BaseScrollBar * GetScrollBar(bool);
43 | long GetScrollPercent(bool, double *);
44 | long GetScrollable(bool, int *);
45 | long GetViewSize(bool, double *);
46 | long GetViewer(class Viewer * *);
47 | long Scroll(enum ScrollAmount, enum ScrollAmount);
48 | long ScrollLine(bool, bool);
49 | long ScrollPage(bool, bool);
50 | long ScrollToHorizontalPosition(int, bool);
51 | long ScrollToVerticalPosition(int, bool);
52 | long SetPercent(BaseScrollBar *, double);
53 | long SetScrollPercent(double, double);
54 |
55 | };
56 | }
--------------------------------------------------------------------------------
/DirectUI/Edit.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 |
3 | namespace DirectUI
4 | {
5 | class UILIB_API Edit : public HWNDHost
6 | {
7 | public:
8 | Edit(Edit const &);
9 | Edit(void);
10 | virtual ~Edit(void);
11 | Edit & operator=(Edit const &);
12 |
13 | static long __stdcall Create(unsigned int, Element *, unsigned long *, Element * *);
14 | static long __stdcall Create(Element *, unsigned long *, Element * *);
15 | static const PropertyInfo* __stdcall DirtyProp(void);
16 | static UID __stdcall Enter(void);
17 | static IClassInfo * __stdcall GetClassInfoPtr(void);
18 | static const PropertyInfo* __stdcall MultilineProp(void);
19 | static const PropertyInfo* __stdcall MaxLengthProp(void);
20 | static const PropertyInfo* __stdcall PasswordCharacterProp(void);
21 | static long __stdcall Register(void);
22 | static void __stdcall SetClassInfoPtr(IClassInfo *);
23 | static const PropertyInfo* __stdcall ThemedBorderProp(void);
24 | static const PropertyInfo* __stdcall WantTabsProp(void);
25 |
26 | bool GetDirty(void);
27 | int GetMaxLength(void);
28 | bool GetMultiline(void);
29 | int GetPasswordCharacter(void);
30 | bool GetThemedBorder(void);
31 | bool GetWantTabs(void);
32 | long Initialize(unsigned int, Element *, unsigned long *);
33 | long SetDirty(bool);
34 | long SetMaxLength(int);
35 | long SetMultiline(bool);
36 | long SetPasswordCharacter(int);
37 | long SetThemedBorder(bool);
38 | long SetWantTabs(bool);
39 |
40 |
41 | virtual IClassInfo * GetClassInfoW(void);
42 | virtual SIZE GetContentSize(int, int, Surface *);
43 | virtual unsigned short const * GetContentStringAsDisplayed(Value * *);
44 | virtual bool IsContentProtected(void);
45 | virtual unsigned int MessageCallback(LPGMSG);
46 | virtual void OnInput(InputEvent *);
47 | virtual bool OnNotify(UINT uMsg, WPARAM wParam, LPARAM lParam, LRESULT* plResult);
48 | virtual void OnPropertyChanged(const PropertyInfo*, int, Value *, Value *);
49 |
50 | protected:
51 | virtual HWND CreateHWND(HWND);
52 |
53 | //1
54 | virtual HWND CreateHWND(HWND, bool);
55 |
56 | private:
57 | static IClassInfo * s_pClassInfo;
58 | unsigned int GetTextHeight(void);
59 | void PropertyChangedCore(const PropertyInfo*, int, Value *, HWND);
60 |
61 | };
62 | }
--------------------------------------------------------------------------------
/DirectUI/InvokeHelper.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 |
3 | namespace DirectUI
4 | {
5 | class UILIB_API InvokeHelper : public RefcountBase
6 | {
7 | public:
8 | struct InvokeArgs
9 | {
10 |
11 | };
12 |
13 |
14 | InvokeHelper(void);
15 | InvokeHelper(const InvokeHelper&) = delete;
16 | InvokeHelper&operator=(const InvokeHelper&) = delete;
17 | virtual ~InvokeHelper(void);
18 |
19 | long DoInvoke(int, ElementProvider *, ProviderProxy * (__stdcall*)(Element *), char *);
20 | int Init(unsigned long);
21 | void Uninit(void);
22 |
23 | private:
24 | static int __stdcall _WndProc(void *, HWND hWnd, UINT uMsg, WPARAM wParam, LPARAM lParam, LRESULT* plResult);
25 | static unsigned int const s_uInvokeHelperMsg;
26 |
27 | void OnInvoke(InvokeArgs *);
28 |
29 | };
30 |
31 |
32 | class UILIB_API InvokeManager
33 | {
34 | public:
35 | InvokeManager& operator=(InvokeManager const &);
36 | static void __stdcall Close(void);
37 | static void __stdcall CloseThread(void);
38 | static long __stdcall GetInvokeHelper(InvokeHelper * *);
39 | static long __stdcall Init(void);
40 |
41 | private:
42 | static InvokeHelper * __stdcall FindInvokeHelper(unsigned int *);
43 | static UiaArray * g_pArrayInvokeHelper;
44 | static CRITICAL_SECTION g_cs;
45 | };
46 |
47 | class UILIB_API InvokeProvider
48 | : public PatternProvider
49 | , public IInvokeProvider
50 | {
51 | public:
52 | InvokeProvider(void);
53 | virtual ~InvokeProvider(void);
54 |
55 | virtual unsigned long __stdcall AddRef(void);
56 | virtual ProviderProxyCall GetProxyCreator(void);
57 | virtual long __stdcall Invoke(void);
58 | virtual long __stdcall QueryInterface(GUID const &, void * *);
59 | virtual unsigned long __stdcall Release(void);
60 | };
61 |
62 | //推测DoMethod 以及Init 来自一个纯虚类……,但是目前没有直接证据
63 | class UILIB_API InvokeProxy
64 | {
65 | public:
66 | InvokeProxy(InvokeProxy const &);
67 | InvokeProxy(void);
68 | InvokeProxy & operator=(InvokeProxy const &);
69 |
70 | static InvokeProxy * __stdcall Create(Element *);
71 | static bool __stdcall IsPatternSupported(Element *);
72 |
73 | virtual long DoMethod(int, char *);
74 |
75 | protected:
76 | virtual void Init(Element *);
77 | };
78 | }
--------------------------------------------------------------------------------
/DirectUI/TaskPage.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 |
3 | namespace DirectUI
4 | {
5 | //问号部分无法确定顺序
6 | class UILIB_API TaskPage
7 | : public IElementListener
8 | , public IXProviderCP
9 | {
10 | public:
11 | TaskPage(TaskPage const &);
12 | TaskPage();
13 | virtual ~TaskPage(void);
14 | TaskPage & operator=(TaskPage const &);
15 | operator struct _PSP *(void);
16 |
17 | long DUICreatePropertySheetPage(HINSTANCE);
18 | HWND GetParentHWND(void);
19 |
20 | protected:
21 | Element * GetElement(void);
22 | LONG_PTR PropSheet_SendMessage(UINT message, WPARAM, LPARAM);
23 |
24 | //IElementListener
25 | virtual void OnListenerAttach(Element *);
26 | virtual void OnListenerDetach(Element *);
27 | virtual bool OnListenedPropertyChanging(Element *, PropertyInfo const *, int, Value *, Value *);
28 | virtual void OnListenedPropertyChanged(Element *, PropertyInfo const *, int, Value *, Value *);
29 | virtual void OnListenedEvent(Element *, Event *);
30 | virtual void OnListenedInput(Element *, InputEvent *);
31 |
32 | //1
33 | virtual long LoadParser(DUIXmlParser * *);
34 | //2
35 | virtual long LoadPage(HWNDElement *, HINSTANCE, Element * *, DUIXmlParser * *);
36 | //??
37 | virtual unsigned int GetPageRCID(void);
38 | virtual unsigned short const * GetPageResID(void);
39 | //5
40 | virtual void InitPropSheetPage(PROPSHEETPAGEW *);
41 |
42 | //??
43 | virtual LRESULT OnKillActive(void);
44 | virtual LRESULT OnQueryCancel(void);
45 | virtual Element * OnQueryInitialFocus(void);
46 | virtual LRESULT OnReset(void);
47 | virtual LRESULT OnSetActive(void);
48 | virtual LRESULT OnWizBack(void);
49 | virtual LRESULT OnWizFinish(void);
50 | virtual LRESULT OnWizNext(void);
51 | //14
52 | virtual bool OnMessage(UINT message, WPARAM wParam, LPARAM lParam, LRESULT* plResult);
53 |
54 | private:
55 | static LRESULT __stdcall StaticXHostSubclassProc(HWND, UINT message, WPARAM wParam, LPARAM lParam);
56 | static void __stdcall StaticXmlParserError(unsigned short const *, unsigned short const *, int, void *);
57 |
58 | void FreeComCtl32(void);
59 | int OnWndMsg(UINT message, WPARAM wParam, LPARAM lParam, LRESULT* plResult);
60 | long LoadComCtl32(void);
61 | long LoadPage(Element * *, Element *, DUIXmlParser * *);
62 |
63 | //IXProviderCP
64 | virtual long CreateDUICP(HWNDElement *, HWND, HWND, Element * *, DUIXmlParser * *);
65 | virtual long CreateParserCP(DUIXmlParser * *);
66 | virtual void DestroyCP(void);
67 |
68 | };
69 | }
--------------------------------------------------------------------------------
/DirectUI/Movie.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 |
3 | namespace DirectUI
4 | {
5 | // TODO: find a place to put this
6 | class UILIB_API Movie : public Element
7 | {
8 | public:
9 | Movie(Movie const &);
10 | Movie();
11 | virtual ~Movie();
12 |
13 | Movie & operator=(Movie const &);
14 |
15 | static long WINAPI Create(unsigned int, Element*, unsigned long*, Element**);
16 | static long WINAPI Create(Element*, unsigned long*, Element**);
17 | static UID WINAPI AdvanceFrame();
18 | static void WINAPI SetClassInfoPtr(IClassInfo*);
19 | static void WINAPI RawActionProc(struct GMA_ACTIONINFO*);
20 | static long WINAPI Register();
21 | static IClassInfo* WINAPI GetClassInfoPtr();
22 | static const PropertyInfo* WINAPI AutoStartProp();
23 | static const PropertyInfo* WINAPI AutoStopProp();
24 | static const PropertyInfo* WINAPI CompositingQualityProp();
25 | static const PropertyInfo* WINAPI DrawOutlinesProp();
26 | static const PropertyInfo* WINAPI InterpolationModeProp();
27 | static const PropertyInfo* WINAPI PathProp();
28 | static const PropertyInfo* WINAPI PixelOffsetModeProp();
29 | static const PropertyInfo* WINAPI PlayAllFramesModeProp();
30 | static const PropertyInfo* WINAPI RepeatProp();
31 | static const PropertyInfo* WINAPI SmoothingModeProp();
32 |
33 | void Forward();
34 | bool GetAutoStart();
35 | bool GetAutoStop();
36 | int GetCompositingQuality();
37 | bool GetDrawOutlines();
38 | int GetInterpolationMode();
39 | UCString GetPath(Value**);
40 | int GetPixelOffsetMode();
41 | bool GetPlayAllFramesMode();
42 | bool GetRepeat();
43 | int GetSmoothingMode();
44 | HRESULT LoadFromPath(UCString);
45 | HRESULT LoadFromResource(HINSTANCE, int);
46 | void Pause();
47 | void Play();
48 | void Resume();
49 | void Rewind();
50 | long SetAutoStart(bool);
51 | long SetAutoStop(bool);
52 | long SetCompositingQuality(int);
53 | long SetDrawOutlines(bool);
54 | long SetInterpolationMode(int);
55 | long SetPath(UCString);
56 | long SetPixelOffsetMode(int);
57 | long SetPlayAllFramesMode(bool);
58 | long SetRepeat(bool);
59 | long SetSmoothingMode(int);
60 | void doAction(struct GMA_ACTIONINFO*);
61 |
62 | virtual IClassInfo* GetClassInfoW();
63 |
64 | virtual void OnDestroy();
65 | virtual void OnEvent(Event*);
66 | virtual void OnHosted(Element*);
67 | virtual void Paint(HDC, LPCRECT, LPCRECT, LPRECT, LPRECT);
68 |
69 |
70 | private:
71 | static IClassInfo* s_pClassInfo;
72 | void advanceFrameActionStart();
73 | void advanceFrameActionStop();
74 | };
75 | }
--------------------------------------------------------------------------------
/DirectUI/DialogElement.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 |
3 | namespace DirectUI
4 | {
5 | class UILIB_API DialogElement
6 | : public HWNDElement
7 | , public IElementListener
8 | {
9 | public:
10 | DialogElement(DialogElement const &);
11 | DialogElement(void);
12 | virtual ~DialogElement(void);
13 | DialogElement & operator=(DialogElement const &);
14 |
15 | static const PropertyInfo* __stdcall ButtonClassAcceptsEnterKeyProp(void);
16 | static long __stdcall Create(struct HWND__ *, bool, unsigned int, Element *, unsigned long *, Element * *);
17 | static const PropertyInfo* __stdcall DefaultButtonTrackingProp(void);
18 | static IClassInfo * __stdcall GetClassInfoPtr(void);
19 | static const PropertyInfo* __stdcall HandleEnterKeyProp(void);
20 | static long __stdcall Register(void);
21 | static const PropertyInfo* __stdcall RegisteredDefaultButtonProp(void);
22 | static void __stdcall SetClassInfoPtr(IClassInfo *);
23 |
24 | bool GetButtonClassAcceptsEnterKey(void);
25 | bool GetDefaultButtonTracking(void);
26 | bool GetHandleEnterKey(void);
27 | Element * GetRegisteredDefaultButton(void);
28 | long SetButtonClassAcceptsEnterKey(bool);
29 | long SetDefaultButtonTracking(bool);
30 | long SetHandleEnterKey(bool);
31 | long SetRegisteredDefaultButton(Element *);
32 |
33 | //基类
34 | virtual void OnDestroy(void);
35 | virtual void OnGetDlgCode(MSG *, LRESULT *);
36 | virtual void OnInput(InputEvent *);
37 | virtual void OnKeyFocusMoved(Element *, Element *);
38 | virtual void OnListenedEvent(Element *, Event *);
39 | virtual void OnListenedInput(Element *, InputEvent *);
40 | virtual void OnListenedPropertyChanged(Element *, const PropertyInfo*, int, Value *, Value *);
41 | virtual bool OnListenedPropertyChanging(Element *, const PropertyInfo*, int, Value *, Value *);
42 | virtual void OnListenerAttach(Element *);
43 | virtual void OnListenerDetach(Element *);
44 | virtual void OnPropertyChanged(const PropertyInfo*, int, Value *, Value *);
45 | virtual IClassInfo * GetClassInfoW(void);
46 |
47 | //1
48 | virtual Element * GetDefaultButton(void);
49 | //2
50 | virtual bool ClickDefaultButton(void);
51 | //3
52 | virtual void UpdateChildFocus(Element *, Element *);
53 | //4
54 | virtual bool OnChildLostFocus(Element *);
55 | //5
56 | virtual bool OnChildReceivedFocus(Element *);
57 |
58 | protected:
59 | void SetRegisteredDefaultButtonSelectedState(bool);
60 | static bool __stdcall IsButtonEnabledAndVisible(Element *);
61 |
62 | private:
63 | static IClassInfo * s_pClassInfo;
64 | };
65 | }
--------------------------------------------------------------------------------
/DirectUI/XProvider.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 |
3 | namespace DirectUI
4 | {
5 | MIDL_INTERFACE("1e3d87cb-f434-4838-a004-f14e385e736f")
6 | IXProvider : public IUnknown
7 | {
8 | public:
9 | virtual long __stdcall CreateDUI(IXElementCP *, HWND *) = 0;
10 | virtual long __stdcall SetParameter(GUID const &, void *) = 0;
11 | virtual long __stdcall GetDesiredSize(int, int, SIZE *) = 0;
12 | virtual long __stdcall IsDescendent(Element *, bool *) = 0;
13 | virtual long __stdcall SetFocus(Element *) = 0;
14 | virtual long __stdcall Navigate(int, bool *) = 0;
15 | virtual long __stdcall CanSetFocus(bool *) = 0;
16 | virtual int __stdcall FindElementWithShortcutAndDoDefaultAction(unsigned short, int) = 0;
17 | virtual long __stdcall GetHostedElementID(unsigned short *) = 0;
18 | virtual long __stdcall ForceThemeChange(UINT_PTR, LONG_PTR) = 0;
19 | virtual long __stdcall SetDefaultButtonTracking(bool) = 0;
20 | virtual int __stdcall ClickDefaultButton(void) = 0;
21 | virtual long __stdcall SetRegisteredDefaultButton(Element *) = 0;
22 | virtual long __stdcall SetButtonClassAcceptsEnterKey(bool) = 0;
23 | };
24 |
25 | class UILIB_API XProvider : public IXProvider
26 | {
27 | public:
28 | XProvider(XProvider const &);
29 | XProvider(void);
30 | virtual ~XProvider(void);
31 | XProvider & operator=(XProvider const &);
32 |
33 | static long __stdcall Create(Element *, IXProviderCP *, XProvider * *);
34 |
35 | long CreateParser(DUIXmlParser * *);
36 | long Initialize(Element *, IXProviderCP *);
37 |
38 | virtual unsigned long __stdcall AddRef(void);
39 | virtual long __stdcall CanSetFocus(bool *);
40 | virtual int __stdcall ClickDefaultButton(void);
41 | virtual long __stdcall CreateDUI(IXElementCP *, HWND *);
42 | virtual int __stdcall FindElementWithShortcutAndDoDefaultAction(unsigned short, int);
43 | virtual long __stdcall ForceThemeChange(UINT_PTR, LONG_PTR);
44 | virtual long __stdcall GetDesiredSize(int, int, SIZE *);
45 | virtual long __stdcall GetHostedElementID(unsigned short *);
46 | virtual long __stdcall IsDescendent(Element *, bool *);
47 | virtual long __stdcall Navigate(int, bool *);
48 | virtual long __stdcall QueryInterface(GUID const &, void * *);
49 | virtual unsigned long __stdcall Release(void);
50 | virtual long __stdcall SetButtonClassAcceptsEnterKey(bool);
51 | virtual long __stdcall SetDefaultButtonTracking(bool);
52 | virtual long __stdcall SetFocus(Element *);
53 | virtual long __stdcall SetParameter(GUID const &, void *);
54 | virtual long __stdcall SetRegisteredDefaultButton(Element *);
55 | protected:
56 | Element * GetRoot(void);
57 | void SetHandleEnterKey(bool);
58 |
59 | };
60 | }
--------------------------------------------------------------------------------
/DirectUI/ScrollBar.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 |
3 | namespace DirectUI
4 | {
5 | class UILIB_API ScrollBar
6 | : public Element
7 | , public BaseScrollBar
8 | {
9 | public:
10 | ScrollBar(ScrollBar const &);
11 | ScrollBar(void);
12 | virtual ~ScrollBar(void);
13 | ScrollBar & operator=(ScrollBar const &);
14 |
15 | static long __stdcall Create(Element *, unsigned long *, Element * *);
16 | static long __stdcall Create(bool, Element *, unsigned long *, Element * *);
17 | static IClassInfo * __stdcall GetClassInfoPtr(void);
18 | static PropertyInfo const * __stdcall LineProp(void);
19 | static PropertyInfo const * __stdcall MaximumProp(void);
20 | static PropertyInfo const * __stdcall MinimumProp(void);
21 | static PropertyInfo const * __stdcall OrderProp(void);
22 | static PropertyInfo const * __stdcall PageProp(void);
23 | static PropertyInfo const * __stdcall PositionProp(void);
24 | static PropertyInfo const * __stdcall ProportionalProp(void);
25 | static long __stdcall Register(void);
26 | static void __stdcall SetClassInfoPtr(IClassInfo *);
27 | static PropertyInfo const * __stdcall VerticalProp(void);
28 |
29 | int GetOrder(void);
30 | bool GetVertical(void);
31 | long Initialize(bool, Element *, unsigned long *);
32 | long SetOrder(int);
33 | long SetProportional(bool);
34 | long SetVertical(bool);
35 |
36 | virtual IClassInfo * GetClassInfoW(void);
37 | virtual Element * GetElement(void);
38 | virtual int GetLine(void);
39 | virtual int GetMaximum(void);
40 | virtual int GetMinimum(void);
41 | virtual int GetPage(void);
42 | virtual int GetPosition(void);
43 | virtual bool GetProportional(void);
44 | virtual void OnEvent(Event *);
45 | virtual void OnPropertyChanged(PropertyInfo const *, int, Value *, Value *);
46 | virtual bool OnPropertyChanging(PropertyInfo const *, int, Value *, Value *);
47 | virtual long SetLine(int);
48 | virtual long SetMaximum(int);
49 | virtual long SetMinimum(int);
50 | virtual long SetPage(int);
51 | virtual long SetPosition(int);
52 | virtual void _SelfLayoutDoLayout(int, int);
53 | virtual SIZE _SelfLayoutUpdateDesiredSize(int, int, Surface *);
54 | protected:
55 | //1
56 | virtual long CreateButtons(void);
57 | private:
58 | static IClassInfo * s_pClassInfo;
59 |
60 | };
61 |
62 | class UILIB_API ScrollBarRangeValueProxy : public IProxy
63 | {
64 | public:
65 | ScrollBarRangeValueProxy(ScrollBarRangeValueProxy const &);
66 | ScrollBarRangeValueProxy(void);
67 | ScrollBarRangeValueProxy & operator=(ScrollBarRangeValueProxy const &);
68 |
69 | virtual long DoMethod(int, char *);
70 | protected:
71 | virtual void Init(Element *);
72 |
73 | };
74 | }
--------------------------------------------------------------------------------
/.gitattributes:
--------------------------------------------------------------------------------
1 | ###############################################################################
2 | # Set default behavior to automatically normalize line endings.
3 | ###############################################################################
4 | * text=auto
5 |
6 | ###############################################################################
7 | # Set default behavior for command prompt diff.
8 | #
9 | # This is need for earlier builds of msysgit that does not have it on by
10 | # default for csharp files.
11 | # Note: This is only used by command line
12 | ###############################################################################
13 | #*.cs diff=csharp
14 |
15 | ###############################################################################
16 | # Set the merge driver for project and solution files
17 | #
18 | # Merging from the command prompt will add diff markers to the files if there
19 | # are conflicts (Merging from VS is not affected by the settings below, in VS
20 | # the diff markers are never inserted). Diff markers may cause the following
21 | # file extensions to fail to load in VS. An alternative would be to treat
22 | # these files as binary and thus will always conflict and require user
23 | # intervention with every merge. To do so, just uncomment the entries below
24 | ###############################################################################
25 | #*.sln merge=binary
26 | #*.csproj merge=binary
27 | #*.vbproj merge=binary
28 | #*.vcxproj merge=binary
29 | #*.vcproj merge=binary
30 | #*.dbproj merge=binary
31 | #*.fsproj merge=binary
32 | #*.lsproj merge=binary
33 | #*.wixproj merge=binary
34 | #*.modelproj merge=binary
35 | #*.sqlproj merge=binary
36 | #*.wwaproj merge=binary
37 |
38 | ###############################################################################
39 | # behavior for image files
40 | #
41 | # image files are treated as binary by default.
42 | ###############################################################################
43 | #*.jpg binary
44 | #*.png binary
45 | #*.gif binary
46 |
47 | ###############################################################################
48 | # diff behavior for common document formats
49 | #
50 | # Convert binary document formats to text before diffing them. This feature
51 | # is only available from the command line. Turn it on by uncommenting the
52 | # entries below.
53 | ###############################################################################
54 | #*.doc diff=astextplain
55 | #*.DOC diff=astextplain
56 | #*.docx diff=astextplain
57 | #*.DOCX diff=astextplain
58 | #*.dot diff=astextplain
59 | #*.DOT diff=astextplain
60 | #*.pdf diff=astextplain
61 | #*.PDF diff=astextplain
62 | #*.rtf diff=astextplain
63 | #*.RTF diff=astextplain
64 |
--------------------------------------------------------------------------------
/DirectUI Library.sln:
--------------------------------------------------------------------------------
1 |
2 | Microsoft Visual Studio Solution File, Format Version 12.00
3 | # Visual Studio 14
4 | VisualStudioVersion = 14.0.25123.0
5 | MinimumVisualStudioVersion = 10.0.40219.1
6 | Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "DirectUI", "DirectUI\DirectUI.vcxproj", "{0B7DE49A-33C6-41B1-A9CE-D353031F8454}"
7 | EndProject
8 | Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "UITest", "UITest\UITest.vcxproj", "{868C2D90-15DC-476A-A566-787A069F44A8}"
9 | ProjectSection(ProjectDependencies) = postProject
10 | {0B7DE49A-33C6-41B1-A9CE-D353031F8454} = {0B7DE49A-33C6-41B1-A9CE-D353031F8454}
11 | EndProjectSection
12 | EndProject
13 | Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "demangler", "demangler\demangler.vcxproj", "{7FB19DDE-AA39-4E73-AF49-51DE1825E46F}"
14 | EndProject
15 | Global
16 | GlobalSection(SolutionConfigurationPlatforms) = preSolution
17 | Debug|x64 = Debug|x64
18 | Debug|x86 = Debug|x86
19 | Release|x64 = Release|x64
20 | Release|x86 = Release|x86
21 | EndGlobalSection
22 | GlobalSection(ProjectConfigurationPlatforms) = postSolution
23 | {0B7DE49A-33C6-41B1-A9CE-D353031F8454}.Debug|x64.ActiveCfg = Debug|x64
24 | {0B7DE49A-33C6-41B1-A9CE-D353031F8454}.Debug|x64.Build.0 = Debug|x64
25 | {0B7DE49A-33C6-41B1-A9CE-D353031F8454}.Debug|x86.ActiveCfg = Debug|Win32
26 | {0B7DE49A-33C6-41B1-A9CE-D353031F8454}.Debug|x86.Build.0 = Debug|Win32
27 | {0B7DE49A-33C6-41B1-A9CE-D353031F8454}.Release|x64.ActiveCfg = Release|x64
28 | {0B7DE49A-33C6-41B1-A9CE-D353031F8454}.Release|x64.Build.0 = Release|x64
29 | {0B7DE49A-33C6-41B1-A9CE-D353031F8454}.Release|x86.ActiveCfg = Release|Win32
30 | {0B7DE49A-33C6-41B1-A9CE-D353031F8454}.Release|x86.Build.0 = Release|Win32
31 | {868C2D90-15DC-476A-A566-787A069F44A8}.Debug|x64.ActiveCfg = Debug|x64
32 | {868C2D90-15DC-476A-A566-787A069F44A8}.Debug|x64.Build.0 = Debug|x64
33 | {868C2D90-15DC-476A-A566-787A069F44A8}.Debug|x86.ActiveCfg = Debug|Win32
34 | {868C2D90-15DC-476A-A566-787A069F44A8}.Debug|x86.Build.0 = Debug|Win32
35 | {868C2D90-15DC-476A-A566-787A069F44A8}.Release|x64.ActiveCfg = Release|x64
36 | {868C2D90-15DC-476A-A566-787A069F44A8}.Release|x64.Build.0 = Release|x64
37 | {868C2D90-15DC-476A-A566-787A069F44A8}.Release|x86.ActiveCfg = Release|Win32
38 | {868C2D90-15DC-476A-A566-787A069F44A8}.Release|x86.Build.0 = Release|Win32
39 | {7FB19DDE-AA39-4E73-AF49-51DE1825E46F}.Debug|x64.ActiveCfg = Debug|x64
40 | {7FB19DDE-AA39-4E73-AF49-51DE1825E46F}.Debug|x64.Build.0 = Debug|x64
41 | {7FB19DDE-AA39-4E73-AF49-51DE1825E46F}.Debug|x86.ActiveCfg = Debug|Win32
42 | {7FB19DDE-AA39-4E73-AF49-51DE1825E46F}.Debug|x86.Build.0 = Debug|Win32
43 | {7FB19DDE-AA39-4E73-AF49-51DE1825E46F}.Release|x64.ActiveCfg = Release|x64
44 | {7FB19DDE-AA39-4E73-AF49-51DE1825E46F}.Release|x64.Build.0 = Release|x64
45 | {7FB19DDE-AA39-4E73-AF49-51DE1825E46F}.Release|x86.ActiveCfg = Release|Win32
46 | {7FB19DDE-AA39-4E73-AF49-51DE1825E46F}.Release|x86.Build.0 = Release|Win32
47 | EndGlobalSection
48 | GlobalSection(SolutionProperties) = preSolution
49 | HideSolutionNode = FALSE
50 | EndGlobalSection
51 | EndGlobal
52 |
--------------------------------------------------------------------------------
/DirectUI/EventManager.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 |
3 | namespace DirectUI
4 | {
5 | class UILIB_API EventManager
6 | {
7 | public:
8 | EventManager & operator=(EventManager const &);
9 |
10 | static long __stdcall AdviseEventAdded(int, SAFEARRAY *);
11 | static long __stdcall AdviseEventRemoved(int, SAFEARRAY *);
12 | static void __stdcall Close();
13 | static void __stdcall DestroyListener(Element *);
14 | static long __stdcall EndDefer(Element *);
15 | static long __stdcall EventListener(Element *, Event *);
16 | static bool __stdcall FWantAnyEvent(Element *);
17 | static long __stdcall FireStructureChangedEvent(Element *, StructureChangeType);
18 |
19 | static long __stdcall Init();
20 | static long __stdcall OnToolTip(Element *, unsigned long);
21 | static long __stdcall PropertyChangingListener(Element *, const PropertyInfo *, bool *);
22 | static long __stdcall PropertyListener(Element *, const PropertyInfo *, int, Value *, Value *);
23 | static bool __stdcall WantEvent(Schema::Event);
24 | static bool __stdcall WantPropertyEvent(int);
25 |
26 | private:
27 | static long __stdcall GetBool(VARIANT *, Value *);
28 | static void __stdcall GetExpandCollapseState(VARIANT *);
29 | static long __stdcall GetInt(VARIANT *, Value *);
30 | static long __stdcall GetString(VARIANT *, Value *);
31 | static void __stdcall GetToggleState(VARIANT *);
32 | static long __stdcall HandleAccChange(Element *, IRawElementProviderSimple *, Value *, Value *);
33 | static long __stdcall HandleAccDesc(Element *, IRawElementProviderSimple *, Value *, Value *);
34 | static long __stdcall HandleAccPatternChange(Element *, IRawElementProviderSimple *, unsigned int, unsigned int, int, VARIANT *, VARIANT *, void(__stdcall *)(VARIANT *));
35 | static long __stdcall HandleAccRoleEvent(IRawElementProviderSimple *, Value *, Value *);
36 | static long __stdcall HandleAccStateChange(IRawElementProviderSimple *, unsigned int, unsigned int, int, VARIANT *, VARIANT *);
37 | static long __stdcall HandleBoolProp(Element *, bool(__stdcall *)(Element *), IRawElementProviderSimple *, int, Value *, Value *);
38 | static long __stdcall HandleChildrenEvent(Element *, Value *, Value *);
39 | static long __stdcall HandleRangeValue(Element *, IRawElementProviderSimple *, Value *, Value *);
40 | static long __stdcall HandleScrollPos(Element *, IRawElementProviderSimple *, Value *, Value *);
41 | static long __stdcall HandleSelectedChange(IRawElementProviderSimple *, Value *);
42 | static long __stdcall HandleStringProp(IRawElementProviderSimple *, int, Value *, Value *);
43 | static long __stdcall HandleVisibilityChange(Element *, unsigned int);
44 |
45 | static long __stdcall AddRectangleChange(Element *, bool, bool);
46 | static bool __stdcall WantEvent(Schema::Event, int);
47 | static long __stdcall RaiseVisibilityEvents();
48 | static long __stdcall RaiseStructureEvents();
49 | static long __stdcall RaiseStructureChangedEvent(Element *, StructureChangeType);
50 | static long __stdcall RaiseChildRemovedEvent(const ElementRuntimeId &, Element *);
51 | static long __stdcall RaiseGeometryEventWorker(RectangleChange *, bool, bool, bool, bool);
52 | static long __stdcall RaiseGeometryEvents();
53 |
54 | static UiaArray * g_pArrayPropertyEvent;
55 | static bool g_fWantAnyEvent;
56 | static unsigned int * __ptr32 g_eventRegisteredMap;
57 | static CRITICAL_SECTION g_cs;
58 | static int const cChangeBulk;
59 | };
60 | }
--------------------------------------------------------------------------------
/docs/duixml/SYSTEMSETTINGSSTYLES.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
71 |
72 |
--------------------------------------------------------------------------------
/docs/duixml/dpapimig.exe.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
27 |
28 |
29 |
30 |
31 |
32 |
33 |
34 |
35 |
36 |
37 |
38 |
39 |
40 |
41 |
42 |
43 |
44 |
45 |
46 |
47 |
48 |
49 |
--------------------------------------------------------------------------------
/DirectUI/HWNDHost.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 |
3 | namespace DirectUI
4 | {
5 | class UILIB_API HWNDHost : public ElementWithHWND
6 | {
7 | public:
8 | HWNDHost(const HWNDHost &);
9 | HWNDHost();
10 | HWNDHost& operator=(const HWNDHost &);
11 |
12 | virtual ~HWNDHost();
13 |
14 | long Initialize(unsigned int, unsigned int, Element*, unsigned long*);
15 | void Detach();
16 | unsigned short GetBackgroundOwnerID();
17 | HWND GetHWNDParent();
18 | bool GetOptimizeMove();
19 | bool GetTransparent();
20 | long GetClientAccessibleImpl(IAccessible**);
21 | long SetBackgroundOwnerID(UCString);
22 | long SetOptimizeMove(bool);
23 | long SetTransparent(bool);
24 |
25 | static long WINAPI Create(unsigned int, unsigned int, Element*, unsigned long*, Element**pOut);
26 | static long WINAPI Create(Element*, unsigned long*, Element**pOut);
27 | static const PropertyInfo* WINAPI BackgroundOwnerIDProp();
28 | static IClassInfo* WINAPI GetClassInfoPtr();
29 | static const PropertyInfo* WINAPI OptimizeMoveProp();
30 | static long WINAPI Register();
31 | static void WINAPI SetClassInfoPtr(IClassInfo*);
32 | static const PropertyInfo* WINAPI ThemeChangedProp();
33 | static const PropertyInfo* WINAPI TransparentProp();
34 |
35 | //父类重载
36 | virtual IClassInfo* GetClassInfoW();
37 | virtual long GetAccessibleImpl(IAccessible**);
38 | virtual bool GetKeyFocused();
39 | virtual unsigned int MessageCallback(LPGMSG);
40 | virtual void OnDestroy();
41 | virtual void OnEvent(Event*);
42 | virtual void OnInput(InputEvent*);
43 | virtual void OnPropertyChanged(const PropertyInfo*, int, Value*, Value*);
44 |
45 | virtual void Paint(HDC, LPCRECT, LPCRECT, LPRECT, LPRECT);
46 | virtual void SetKeyFocus();
47 | virtual void SetWindowDirection(HWND);
48 | //
49 |
50 | //1
51 | virtual HWND GetHWND();
52 | //2
53 | virtual bool OnMessage(UINT uMsg, WPARAM wParam, LPARAM lParam, LRESULT*);
54 | //3
55 | virtual bool OnNotify(UINT uMsg, WPARAM wParam, LPARAM lParam, LRESULT*);
56 | //4
57 | virtual bool OnSysChar(UChar);
58 | //5
59 | virtual bool OnSinkThemeChanged(UINT uMsg, WPARAM wParam, LPARAM lParam, LRESULT*);
60 | //6
61 | virtual bool OnCtrlThemeChanged(UINT, WPARAM wParam, LPARAM lParam, LRESULT*);
62 | //7
63 | virtual void OnWindowStyleChanged(WPARAM, const STYLESTRUCT *);
64 | //8
65 | virtual int OnAdjustWindowSize(int, int, unsigned int);
66 |
67 | protected:
68 | static void WINAPI AttachCtrlSubclassProc(HWND);
69 | static LRESULT WINAPI CtrlSubclassProc(HWND hWnd, UINT uMsg, WPARAM wParam, LPARAM lParam);
70 |
71 | void PrintRTLControl(HDC, HDC, const RECT&);
72 | long SetThemeChanged(int);
73 | void SyncBackground();
74 | void SyncDirection();
75 | void SyncFont();
76 | void SyncForeground();
77 | void SyncParent();
78 | void SyncRect(unsigned int, bool);
79 | void SyncStyle();
80 | void SyncText();
81 | void SyncVisible();
82 | int VerifyParentage();
83 | HWND CreateAccNameLabel(HWND);
84 | Element* GetBackgroundOwner();
85 | HFONT GetFont();
86 | bool GetStaticColor(HDC, HBRUSH*);
87 | int GetThemeChanged();
88 | bool IsMoveDeferred();
89 | //父类重载
90 | virtual void OnHosted(Element*);
91 | virtual void OnUnHosted(Element*);
92 | //
93 |
94 | //9
95 | virtual HWND CreateHWND(HWND);
96 | //10
97 | virtual bool EraseBkgnd(HDC, LRESULT*);
98 |
99 | private:
100 | static unsigned int const (* __ptr32 g_rgMouseMap)[3];
101 | static IClassInfo* s_pClassInfo;
102 | static BOOL __stdcall _CtrlWndProc(void *, HWND hWnd, UINT uMsg, WPARAM wParam, LPARAM lParam, LRESULT* plResult);
103 | static BOOL WINAPI _SinkWndProc(void *, HWND hWnd, UINT uMsg, WPARAM wParam, LPARAM lParam, LRESULT* plResult);
104 |
105 | void ApplySinkRegion(RECT const *, bool);
106 | long GetAccessibleImpl(IAccessible**, bool);
107 | void GetSinkRect(RECT const *, LPRECT);
108 | bool HaveWin32Focus();
109 | void SyncColorsAndFonts();
110 | void UnvirtualizePosition();
111 | void _DeleteCtrlWnd();
112 | };
113 | }
--------------------------------------------------------------------------------
/DirectUI/misc.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 |
3 | namespace DirectUI {
4 | // exported for int
5 | template class UILIB_API SafeArrayAccessor {
6 | public:
7 | SafeArrayAccessor();
8 | ~SafeArrayAccessor();
9 | SafeArrayAccessor(const SafeArrayAccessor &) = delete;
10 | SafeArrayAccessor &operator=(const SafeArrayAccessor &) = delete;
11 |
12 | operator T *();
13 | long Access(SAFEARRAY *, UChar);
14 | int Count();
15 |
16 | private:
17 | void *unk1;
18 | void *unk2;
19 | void *unk3;
20 | };
21 |
22 | class UILIB_API CritSecLock {
23 | public:
24 | CritSecLock(CRITICAL_SECTION *);
25 | ~CritSecLock();
26 | CritSecLock &operator=(CritSecLock const &);
27 | void Unlock();
28 | };
29 |
30 | template class DynamicArray;
31 |
32 | class UILIB_API Expression {
33 | public:
34 | Expression() = delete;
35 | Expression(const Expression &) = delete;
36 | ~Expression() = delete;
37 |
38 | Expression &operator=(Expression const &);
39 | void Destroy(void);
40 | };
41 |
42 | /*class UID
43 | {
44 | public:
45 | };*/
46 |
47 | class UILIB_API Surface {
48 | public:
49 | enum EType {
50 |
51 | };
52 |
53 | Surface(Surface const &);
54 | Surface(void);
55 | virtual ~Surface(void);
56 | Surface &operator=(Surface const &);
57 |
58 | static enum EType __stdcall GetSurfaceType(unsigned int);
59 | static unsigned int __stdcall GetSurfaceType(enum EType);
60 |
61 | virtual void T1() = 0;
62 | };
63 |
64 | class UILIB_API DCSurface {
65 | public:
66 | DCSurface(DCSurface const &);
67 | DCSurface(HDC);
68 | virtual ~DCSurface(void);
69 | DCSurface &operator=(DCSurface const &);
70 |
71 | HDC GetHDC(void);
72 | virtual Surface::EType GetType(void) const;
73 | };
74 |
75 | enum DUSER_MSG_FLAG : UINT32 {
76 | GMF_DIRECT = 0x00000000, // OnMessage
77 | GMF_ROUTED = 0x00000001, // PreviewMessage
78 | GMF_BUBBLED = 0x00000002, // PostMessage
79 | GMF_EVENT = 0x00000003, // Message -> Event
80 | GMF_DESTINATION = 0x00000003, // Message reach dest (same as event)
81 | };
82 |
83 | enum DUSER_INPUT_DEVICE : UINT32 {
84 | GINPUT_MOUSE = 0,
85 | GINPUT_KEYBOARD = 1,
86 | GINPUT_JOYSTICK = 2,
87 | };
88 |
89 | enum DUSER_INPUT_CODE : UINT32 {
90 | GMOUSE_MOVE = 0,
91 | GMOUSE_DOWN = 1,
92 | GMOUSE_UP = 2,
93 | GMOUSE_DRAG = 3,
94 | GMOUSE_HOVER = 4,
95 | GMOUSE_WHEEL = 5,
96 | GMOUSE_MAX = 5,
97 |
98 | GBUTTON_NONE = 0,
99 | GBUTTON_LEFT = 1,
100 | GBUTTON_RIGHT = 2,
101 | GBUTTON_MIDDLE = 3,
102 | GBUTTON_MAX = 3,
103 | };
104 |
105 | // bitflags
106 | enum DUSER_INPUT_MODIFIERS : UINT32 {
107 | GMODIFIER_NONE = 0x00000000,
108 |
109 | GMODIFIER_LCONTROL = 0x00000001,
110 | GMODIFIER_RCONTROL = 0x00000002,
111 | GMODIFIER_LSHIFT = 0x00000004,
112 | GMODIFIER_RSHIFT = 0x00000008,
113 | GMODIFIER_LALT = 0x00000010,
114 | GMODIFIER_RALT = 0x00000020,
115 | GMODIFIER_LBUTTON = 0x00000040,
116 | GMODIFIER_RBUTTON = 0x00000080,
117 | GMODIFIER_MBUTTON = 0x00000100,
118 |
119 | GMODIFIER_CONTROL = (GMODIFIER_LCONTROL | GMODIFIER_RCONTROL),
120 | GMODIFIER_SHIFT = (GMODIFIER_LSHIFT | GMODIFIER_RSHIFT),
121 | GMODIFIER_ALT = (GMODIFIER_LALT | GMODIFIER_RALT),
122 | };
123 |
124 | struct Event {
125 | Element *target;
126 | UID type;
127 | bool handled;
128 | DUSER_MSG_FLAG flag;
129 | };
130 |
131 | struct InputEvent {
132 | Element *target;
133 | bool handled;
134 | DUSER_MSG_FLAG flag;
135 | DUSER_INPUT_DEVICE device;
136 | DUSER_INPUT_CODE code;
137 | DUSER_INPUT_MODIFIERS modifiers;
138 | };
139 |
140 | struct RectangleChange {};
141 |
142 | struct ElementRuntimeId {};
143 |
144 | class UILIB_API ResourceModuleHandles {
145 | public:
146 | ResourceModuleHandles(void);
147 | ~ResourceModuleHandles(void);
148 | ResourceModuleHandles &operator=(ResourceModuleHandles const &);
149 | long GetHandle(unsigned short const *, HINSTANCE *);
150 |
151 | private:
152 | static long volatile g_cRefCount;
153 | };
154 |
155 | template class UiaArray {
156 | public:
157 | };
158 |
159 | class DeferCycle {};
160 |
161 | } // namespace DirectUI
162 |
--------------------------------------------------------------------------------
/DirectUI/HWNDElement.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 |
3 | namespace DirectUI
4 | {
5 | //32位结构体大小 0x94
6 | class UILIB_API HWNDElement : public ElementWithHWND
7 | {
8 | public:
9 | HWNDElement(const HWNDElement &);
10 | HWNDElement();
11 | virtual ~HWNDElement();
12 | HWNDElement& operator=(const HWNDElement &);
13 |
14 | //0
15 | virtual void OnPropertyChanged(const PropertyInfo*, int, Value*, Value*);
16 | //1
17 | virtual void OnGroupChanged(int, bool);
18 | //2
19 | virtual void OnInput(InputEvent*);
20 | //3
21 | virtual void OnDestroy();
22 | //4
23 | virtual void OnEvent(Event*);
24 | //5
25 | virtual void UpdateTooltip(Element*);
26 |
27 | //6
28 | virtual void ActivateTooltip(Element*, unsigned long);
29 | //7
30 | virtual void RemoveTooltip(Element*);
31 |
32 | //8
33 | virtual IClassInfo* GetClassInfoW();
34 | //9
35 | virtual long GetAccessibleImpl(IAccessible**);
36 |
37 |
38 | //HWNDElement 新增函数
39 | //10
40 | virtual HWND GetHWND();
41 |
42 | //11
43 | virtual void OnThemeChanged(ThemeChangedEvent*);
44 |
45 | //12
46 | virtual void OnNoChildWithShortcutFound(KeyboardEvent*);
47 |
48 | //13
49 | virtual void OnGetDlgCode(LPMSG, LRESULT*);
50 | //14
51 | virtual void OnWmThemeChanged(WPARAM wParam, LPARAM lParam);
52 | //15
53 | virtual void OnCompositionChanged();
54 |
55 | //16
56 | virtual bool CanSetFocus();
57 |
58 | static UID WINAPI CompositionChange();
59 | static HRESULT WINAPI Create(HWND, bool, unsigned int, Element*, unsigned long*, Element**pOut);
60 | //17
61 | virtual long CreateStyleParser(DUIXmlParser**);
62 | void DelayActivateTooltip();
63 | Element* ElementFromPoint(LPPOINT);
64 | static bool WINAPI FindShortcut(unsigned short, Element*, Element**, int*, int*, int);
65 | void FlushWorkingSet();
66 | static IClassInfo* WINAPI GetClassInfoPtr();
67 |
68 | static HWNDElement* WINAPI GetFocusedHWNDElement();
69 |
70 | static Element* WINAPI GetKeyFocusedElement();
71 | unsigned short GetUIState();
72 | bool GetWrapKeyboardNavigate();
73 | long Initialize(HWND, bool, unsigned int, Element*, unsigned long*);
74 | bool IsFirstElement(Element*);
75 | bool IsLastElement(Element*);
76 |
77 |
78 | static long WINAPI Register();
79 | static void WINAPI SetClassInfoPtr(IClassInfo*);
80 |
81 | void SetFocus(bool);
82 | void SetParentSizeControl(bool);
83 | void SetScreenCenter(bool);
84 | long SetWrapKeyboardNavigate(bool);
85 | bool ShowAccel(void);
86 | bool ShowFocus(void);
87 | void ShowUIState(bool, bool);
88 | static UID WINAPI ThemeChange();
89 |
90 | void ToggleUIState(bool, bool);
91 | static const PropertyInfo* WINAPI WrapKeyboardNavigateProp();
92 |
93 | static LRESULT WINAPI StaticWndProc(HWND, UINT uMsg, WPARAM wParam, LPARAM lParam);
94 | //18
95 | virtual LRESULT WndProc(HWND, UINT uMsg, WPARAM wParam, LPARAM lParam);
96 |
97 | protected:
98 | static bool WINAPI FindShortcutRecursive(unsigned short, Element*, Element**, int*, int*, int);
99 |
100 | private:
101 | static IClassInfo* s_pClassInfo;
102 | };
103 |
104 | class UILIB_API HWNDElementProvider
105 | : public ElementProvider
106 | , public IRawElementProviderFragmentRoot
107 | {
108 | public:
109 | HWNDElementProvider(void);
110 | virtual ~HWNDElementProvider(void);
111 |
112 | HWNDElementProvider& operator=(const HWNDElementProvider&) = delete;
113 |
114 | static long __stdcall Create(HWNDElement *, InvokeHelper *, HWNDElementProvider * *);
115 |
116 | virtual unsigned long __stdcall AddRef(void);
117 | virtual long __stdcall QueryInterface(struct _GUID const &, void * *);
118 | virtual unsigned long __stdcall Release(void);
119 |
120 | virtual ProviderProxyCall GetProxyCreator(void);
121 |
122 | //IRawElementProviderFragmentRoot
123 | //1
124 | virtual long __stdcall ElementProviderFromPoint(double, double, IRawElementProviderFragment * *);
125 | //2
126 | virtual long __stdcall GetFocus(IRawElementProviderFragment * *);
127 |
128 | protected:
129 | virtual long Init(HWNDElement *, InvokeHelper *);
130 |
131 | };
132 |
133 | //此类存在问题,看虚表3有个,但是导出只有2个,怪异……
134 | class UILIB_API HWNDElementProxy : public IProxy
135 | {
136 | public:
137 | HWNDElementProxy(HWNDElementProxy const &);
138 | HWNDElementProxy(void);
139 | HWNDElementProxy & operator=(HWNDElementProxy const &);
140 |
141 | static HWNDElementProxy * __stdcall Create(HWNDElement *);
142 | virtual long DoMethod(int, char *);
143 | virtual void Init(HWNDElement *);
144 |
145 | protected:
146 | long ElementFromPoint(double, double, IRawElementProviderFragment * *);
147 | long GetFocus(IRawElementProviderFragment * *);
148 |
149 | };
150 | }
--------------------------------------------------------------------------------
/DirectUI/RichText.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 |
3 | #include
4 |
5 | namespace DirectUI {
6 |
7 | struct UILIB_API RichText : public Element {
8 |
9 | static PropertyInfo * WINAPI BaselineProp(void);
10 | static IClassInfo * WINAPI GetClassInfoPtr(void);
11 | static PropertyInfo * WINAPI LineSpacingProp(void);
12 | static PropertyInfo * WINAPI OverhangOffsetProp(void);
13 | virtual HRESULT SetMaxLineCount(UINT);
14 | static PropertyInfo * WINAPI TypographyProp(void);
15 | static PropertyInfo * WINAPI AliasedRenderingProp(void);
16 | static PropertyInfo * WINAPI ColorFontPaletteIndexProp(void);
17 | static PropertyInfo * WINAPI ConstrainLayoutProp(void);
18 | static PropertyInfo * WINAPI DisableAccTextExtendProp(void);
19 | static PropertyInfo * WINAPI FontColorRunsProp(void);
20 | static PropertyInfo * WINAPI FontSizeRunsProp(void);
21 | static PropertyInfo * WINAPI FontWeightRunsProp(void);
22 | virtual HRESULT GetColorFontPaletteIndex(void);
23 | virtual HRESULT GetConstrainLayout(void);
24 | static PropertyInfo * WINAPI LocaleProp(void);
25 | static PropertyInfo * WINAPI MapRunsToClustersProp(void);
26 | virtual void OnEvent(DirectUI::Event *);
27 | virtual void Paint(HDC__ *,tagRECT const *,tagRECT const *,tagRECT *,tagRECT *);
28 | static PropertyInfo * WINAPI TypographyRunsProp(void);
29 | static PropertyInfo * WINAPI VerticalScriptProp(void);
30 | HRESULT _EnsureLeadDrawOffsetIsSet(void);
31 | HRESULT _FlushDWrite(void);
32 | HRESULT _PrepareTextRender(void);
33 | HRESULT _SetAcceleratorAccentIfAppropriate(void);
34 | HRESULT _SetTypographyInternal(void);
35 | HRESULT SetConstrainLayout(int);
36 | HRESULT GetShortcutChar(void);
37 | HRESULT SetAliasedRendering(bool);
38 | HRESULT SetBaseline(int);
39 | HRESULT SetColorFontPaletteIndex(int);
40 | HRESULT SetDisableAccTextExtend(bool);
41 | HRESULT SetFontColorRuns(USHORT const *);
42 | HRESULT SetFontSizeRuns(USHORT const *);
43 | HRESULT SetFontWeightRuns(USHORT const *);
44 | HRESULT SetLineSpacing(int);
45 | HRESULT SetLocale(USHORT const *);
46 | HRESULT SetMapRunsToClusters(bool);
47 | HRESULT SetOverhangOffset(int);
48 | HRESULT SetTypography(USHORT const *);
49 | HRESULT SetTypographyRuns(USHORT const *);
50 | HRESULT SetVerticalScript(bool);
51 | RichText(void);
52 | virtual HRESULT CreateCache(UINT,struct IDUIRichTextCache * *);
53 | virtual SIZE GetContentSize(int,int,DirectUI::Surface *);
54 | virtual HRESULT GetFactory(void);
55 | virtual HRESULT GetFontColorRuns(DirectUI::Value * *);
56 | virtual HRESULT GetForegroundColorRef(ULONG *);
57 | virtual HRESULT GetLineCount(void);
58 | virtual HRESULT GetTrimmedLineCount(void);
59 | virtual HRESULT GetVerticalScript(void);
60 | virtual HRESULT Initialize(DirectUI::Element *,ULONG *);
61 | virtual void OnHosted(DirectUI::Element *);
62 | virtual void OnPropertyChanged(DirectUI::PropertyInfo const *,int,DirectUI::Value *,DirectUI::Value *);
63 | virtual HRESULT SetCache(ULONG, struct IDUIRichTextCache *);
64 | virtual HRESULT SetDWriteFontCollection(IDWriteFontCollection *);
65 | virtual HRESULT SetDWriteTextLayout(IDWriteTextLayout *);
66 | virtual HRESULT StopUsingCache(void);
67 | virtual HRESULT _AdjustRangeForPathJoinCharacters(DWRITE_TEXT_RANGE *);
68 | virtual HRESULT _ApplyDrawTextFlags(void);
69 | virtual HRESULT _ApplyIntratextFormatting(void);
70 | virtual HRESULT _BuildRenderStringForDWrite(USHORT const *,USHORT,bool);
71 | virtual HRESULT _CreateDWriteLayout(tagRECT const *,DirectUI::Value *);
72 | virtual HRESULT _EnsureTextFormat(void);
73 | virtual HRESULT _GetDWFontSize(float,bool);
74 | virtual HRESULT _GetDWFontWeight(void);
75 | virtual HRESULT _GetDWMetrics(DWRITE_TEXT_METRICS *);
76 | virtual HRESULT _GetDWOverhangMetrics(DWRITE_OVERHANG_METRICS *);
77 | virtual HRESULT _GetDefaultOverhang(void);
78 | virtual HRESULT _GetMinSizeWidth(void);
79 | virtual HRESULT _GetScaledOverhangOffset(void);
80 | virtual HRESULT _InitDWrite(void);
81 | virtual HRESULT _PaintStringContentDWrite(HDC__ *,tagRECT const *,tagRECT const *,DirectUI::Value *);
82 | virtual HRESULT _SetFontColorRun(USHORT const *,DWRITE_TEXT_RANGE);
83 | virtual HRESULT _SetFontSizeRun(USHORT const *,DWRITE_TEXT_RANGE);
84 | virtual HRESULT _SetFontSizeRunsInternal(void);
85 | virtual HRESULT _SetFontWeightRun(USHORT const *,DWRITE_TEXT_RANGE);
86 | virtual HRESULT _SetFontWeightRunsInternal(void);
87 | virtual HRESULT _SetLineSpacingInternal(void);
88 | virtual HRESULT _SetRangedStringRunsWithValue(USHORT const *,enum StringRunStyles);
89 | virtual HRESULT _SetStrikethrough(void);
90 | virtual HRESULT _SetTypographyRun(USHORT const *,DWRITE_TEXT_RANGE);
91 | virtual HRESULT _SetTypographyRunsInternal(void);
92 | virtual HRESULT _SetUnderline(void);
93 | virtual HRESULT _UpdateRangeForClusterMetrics(DWRITE_TEXT_RANGE *);
94 |
95 | };
96 |
97 | }
98 |
--------------------------------------------------------------------------------
/.gitignore:
--------------------------------------------------------------------------------
1 | ## Ignore Visual Studio temporary files, build results, and
2 | ## files generated by popular Visual Studio add-ons.
3 |
4 | # User-specific files
5 | *.suo
6 | *.user
7 | *.userosscache
8 | *.sln.docstates
9 |
10 | # User-specific files (MonoDevelop/Xamarin Studio)
11 | *.userprefs
12 |
13 | # Build results
14 | [Dd]ebug/
15 | [Dd]ebugPublic/
16 | [Rr]elease/
17 | [Rr]eleases/
18 | [Xx]64/
19 | [Xx]86/
20 | [Bb]uild/
21 | bld/
22 | [Bb]in/
23 | [Oo]bj/
24 |
25 | # Visual Studio 2015 cache/options directory
26 | .vs/
27 | # Uncomment if you have tasks that create the project's static files in wwwroot
28 | #wwwroot/
29 |
30 | # MSTest test Results
31 | [Tt]est[Rr]esult*/
32 | [Bb]uild[Ll]og.*
33 |
34 | # NUNIT
35 | *.VisualState.xml
36 | TestResult.xml
37 |
38 | # Build Results of an ATL Project
39 | [Dd]ebugPS/
40 | [Rr]eleasePS/
41 | dlldata.c
42 |
43 | # DNX
44 | project.lock.json
45 | artifacts/
46 |
47 | *_i.c
48 | *_p.c
49 | *_i.h
50 | *.ilk
51 | *.meta
52 | *.obj
53 | *.pch
54 | *.pdb
55 | *.pgc
56 | *.pgd
57 | *.rsp
58 | *.sbr
59 | *.tlb
60 | *.tli
61 | *.tlh
62 | *.tmp
63 | *.tmp_proj
64 | *.log
65 | *.vspscc
66 | *.vssscc
67 | .builds
68 | *.pidb
69 | *.svclog
70 | *.scc
71 |
72 | # Chutzpah Test files
73 | _Chutzpah*
74 |
75 | # Visual C++ cache files
76 | ipch/
77 | *.aps
78 | *.ncb
79 | *.opendb
80 | *.opensdf
81 | *.sdf
82 | *.cachefile
83 | *.VC.db
84 |
85 | # Visual Studio profiler
86 | *.psess
87 | *.vsp
88 | *.vspx
89 | *.sap
90 |
91 | # TFS 2012 Local Workspace
92 | $tf/
93 |
94 | # Guidance Automation Toolkit
95 | *.gpState
96 |
97 | # ReSharper is a .NET coding add-in
98 | _ReSharper*/
99 | *.[Rr]e[Ss]harper
100 | *.DotSettings.user
101 |
102 | # JustCode is a .NET coding add-in
103 | .JustCode
104 |
105 | # TeamCity is a build add-in
106 | _TeamCity*
107 |
108 | # DotCover is a Code Coverage Tool
109 | *.dotCover
110 |
111 | # NCrunch
112 | _NCrunch_*
113 | .*crunch*.local.xml
114 | nCrunchTemp_*
115 |
116 | # MightyMoose
117 | *.mm.*
118 | AutoTest.Net/
119 |
120 | # Web workbench (sass)
121 | .sass-cache/
122 |
123 | # Installshield output folder
124 | [Ee]xpress/
125 |
126 | # DocProject is a documentation generator add-in
127 | DocProject/buildhelp/
128 | DocProject/Help/*.HxT
129 | DocProject/Help/*.HxC
130 | DocProject/Help/*.hhc
131 | DocProject/Help/*.hhk
132 | DocProject/Help/*.hhp
133 | DocProject/Help/Html2
134 | DocProject/Help/html
135 |
136 | # Click-Once directory
137 | publish/
138 |
139 | # Publish Web Output
140 | *.[Pp]ublish.xml
141 | *.azurePubxml
142 |
143 | # TODO: Un-comment the next line if you do not want to checkin
144 | # your web deploy settings because they may include unencrypted
145 | # passwords
146 | #*.pubxml
147 | *.publishproj
148 |
149 | # NuGet Packages
150 | *.nupkg
151 | # The packages folder can be ignored because of Package Restore
152 | **/packages/*
153 | # except build/, which is used as an MSBuild target.
154 | !**/packages/build/
155 | # Uncomment if necessary however generally it will be regenerated when needed
156 | #!**/packages/repositories.config
157 | # NuGet v3's project.json files produces more ignoreable files
158 | *.nuget.props
159 | *.nuget.targets
160 |
161 | # Microsoft Azure Build Output
162 | csx/
163 | *.build.csdef
164 |
165 | # Microsoft Azure Emulator
166 | ecf/
167 | rcf/
168 |
169 | # Microsoft Azure ApplicationInsights config file
170 | ApplicationInsights.config
171 |
172 | # Windows Store app package directory
173 | AppPackages/
174 | BundleArtifacts/
175 |
176 | # Visual Studio cache files
177 | # files ending in .cache can be ignored
178 | *.[Cc]ache
179 | # but keep track of directories ending in .cache
180 | !*.[Cc]ache/
181 |
182 | # Others
183 | ClientBin/
184 | [Ss]tyle[Cc]op.*
185 | ~$*
186 | *~
187 | *.dbmdl
188 | *.dbproj.schemaview
189 | *.pfx
190 | *.publishsettings
191 | node_modules/
192 | orleans.codegen.cs
193 |
194 | # RIA/Silverlight projects
195 | Generated_Code/
196 |
197 | # Backup & report files from converting an old project file
198 | # to a newer Visual Studio version. Backup files are not needed,
199 | # because we have git ;-)
200 | _UpgradeReport_Files/
201 | Backup*/
202 | UpgradeLog*.XML
203 | UpgradeLog*.htm
204 |
205 | # SQL Server files
206 | *.mdf
207 | *.ldf
208 |
209 | # Business Intelligence projects
210 | *.rdl.data
211 | *.bim.layout
212 | *.bim_*.settings
213 |
214 | # Microsoft Fakes
215 | FakesAssemblies/
216 |
217 | # GhostDoc plugin setting file
218 | *.GhostDoc.xml
219 |
220 | # Node.js Tools for Visual Studio
221 | .ntvs_analysis.dat
222 |
223 | # Visual Studio 6 build log
224 | *.plg
225 |
226 | # Visual Studio 6 workspace options file
227 | *.opt
228 |
229 | # Visual Studio LightSwitch build output
230 | **/*.HTMLClient/GeneratedArtifacts
231 | **/*.DesktopClient/GeneratedArtifacts
232 | **/*.DesktopClient/ModelManifest.xml
233 | **/*.Server/GeneratedArtifacts
234 | **/*.Server/ModelManifest.xml
235 | _Pvt_Extensions
236 |
237 | # LightSwitch generated files
238 | GeneratedArtifacts/
239 | ModelManifest.xml
240 |
241 | # Paket dependency manager
242 | .paket/paket.exe
243 |
244 | # FAKE - F# Make
245 | .fake/
--------------------------------------------------------------------------------
/DirectUI/Value.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 |
3 | namespace DirectUI
4 | {
5 |
6 | enum class ValueType : int {
7 | Unavailable = -2,
8 | Unset = -1,
9 | Null = 0,
10 | Int = 1,
11 | Bool = 2,
12 | Element = 3,
13 | Ellist = 4,
14 | String = 5,
15 | Point = 6,
16 | Size = 7,
17 | Rect = 8,
18 | Color = 9,
19 | Layout = 10,
20 | Graphic = 11,
21 | Sheet = 12,
22 | Expr = 13,
23 | Atom = 14,
24 | Cursor = 15,
25 | Float = 18,
26 | DblList = 19,
27 | };
28 |
29 | class UILIB_API Value
30 | {
31 | public:
32 | Value& operator=(const Value &);
33 | void AddRef();
34 |
35 | static Value* WINAPI CreateAtom(unsigned short);
36 | static Value* WINAPI CreateAtom(UCString);
37 | static Value* WINAPI CreateBool(bool);
38 | static Value* WINAPI CreateColor(unsigned long);
39 | static Value* WINAPI CreateColor(unsigned long, unsigned long, unsigned char);
40 | static Value* WINAPI CreateColor(unsigned long, unsigned long, unsigned long, unsigned char);
41 | static Value* WINAPI CreateCursor(HICON);
42 | static Value* WINAPI CreateCursor(UCString);
43 | static Value* WINAPI CreateDFCFill(unsigned int, unsigned int);
44 | static Value* WINAPI CreateDTBFill(UCString, int, int);
45 | static Value* WINAPI CreateElementList(DynamicArray*);
46 | static Value* WINAPI CreateElementRef(class Element*);
47 | static Value* WINAPI CreateEncodedString(UCString);
48 | static Value* WINAPI CreateExpression(Expression*);
49 | static Value* WINAPI CreateFill(const struct Fill &);
50 | static Value* WINAPI CreateGraphic(HBITMAP, unsigned char, unsigned int, bool, bool, bool);
51 | static Value* WINAPI CreateGraphic(HENHMETAFILE, HENHMETAFILE);
52 | static Value* WINAPI CreateGraphic(HICON, bool, bool, bool);
53 | static Value* WINAPI CreateGraphic(UCString, unsigned char, unsigned int, unsigned short, unsigned short, HINSTANCE, bool, bool);
54 | static Value* WINAPI CreateGraphic(UCString, unsigned short, unsigned short, HINSTANCE, bool, bool);
55 | static Value* WINAPI CreateInt(int);
56 | static Value* WINAPI CreateLayout(class Layout*);
57 | static Value* WINAPI CreatePoint(int, int);
58 | static Value* WINAPI CreateRect(int, int, int, int);
59 | static Value* WINAPI CreateSize(int, int);
60 | static Value* WINAPI CreateString(UCString, HINSTANCE);
61 | static Value* WINAPI CreateStyleSheet(StyleSheet*);
62 |
63 | bool GetBool();
64 | struct Cursor* GetCursor();
65 | class Element* GetElement();
66 | DynamicArray* GetElementList();
67 | class Expression* GetExpression();
68 | const Fill* GetFill();
69 | struct Graphic* GetGraphic();
70 | void* GetImage(bool);
71 | int GetInt();
72 | class Layout* GetLayout();
73 | POINT const * GetPoint();
74 | RECT const * GetRect();
75 | int GetRefCount() const;
76 | SIZE const * GetSize();
77 | UCString GetString();
78 | StyleSheet* GetStyleSheet();
79 | int GetType() const;
80 |
81 | unsigned short GetAtom();
82 | static Value* WINAPI GetAtomZero();
83 | static Value* WINAPI GetBoolFalse();
84 | static Value* WINAPI GetBoolTrue();
85 | static Value* WINAPI GetColorTrans();
86 | static Value* WINAPI GetCursorNull();
87 | static Value* WINAPI GetElListNull();
88 | static Value* WINAPI GetElementNull();
89 | static Value* WINAPI GetExprNull();
90 | static Value* WINAPI GetIntZero();
91 | static Value* WINAPI GetLayoutNull();
92 | static Value* WINAPI GetNull();
93 | static Value* WINAPI GetPointZero();
94 | static Value* WINAPI GetRectZero();
95 | static Value* WINAPI GetSheetNull();
96 | static Value* WINAPI GetSizeZero();
97 | static Value* WINAPI GetStringNull();
98 | static Value* WINAPI GetUnavailable();
99 | static Value* WINAPI GetUnset();
100 |
101 | bool IsEqual(Value*);
102 | void Release();
103 | UString ToString(UString, unsigned int) const;
104 | private:
105 | void _ZeroRelease();
106 | static long WINAPI StrDupW(UCString, UString*);
107 | };
108 |
109 | class UILIB_API ValueProvider
110 | : public PatternProvider
111 | , public IValueProvider
112 | {
113 | public:
114 | ValueProvider(void);
115 | virtual ~ValueProvider(void);
116 | virtual unsigned long __stdcall AddRef(void);
117 | virtual ProviderProxyCall GetProxyCreator(void);
118 | virtual long __stdcall QueryInterface(GUID const &, void * *);
119 | virtual unsigned long __stdcall Release(void);
120 | virtual long __stdcall SetValue(unsigned short const *);
121 | virtual long __stdcall get_IsReadOnly(int *);
122 | virtual long __stdcall get_Value(unsigned short * *);
123 | };
124 |
125 | class UILIB_API ValueProxy : IProxy
126 | {
127 | public:
128 | ValueProxy(ValueProxy const &);
129 | ValueProxy(void);
130 | ValueProxy & operator=(ValueProxy const &);
131 | static ValueProxy * __stdcall Create(Element *);
132 | static bool __stdcall IsPatternSupported(Element *);
133 |
134 | virtual long DoMethod(int, char *);
135 |
136 | protected:
137 | virtual void Init(Element *);
138 |
139 | private:
140 | long GetIsReadOnly(int *);
141 | long GetValue(unsigned short * *);
142 | long SetValue(unsigned short const *);
143 | };
144 | }
--------------------------------------------------------------------------------
/DirectUI/base.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 |
3 | namespace DirectUI
4 | {
5 | class UILIB_API ClassInfoBase
6 | {
7 | public:
8 | ClassInfoBase(ClassInfoBase const &);
9 | ClassInfoBase();
10 | ClassInfoBase & operator=(ClassInfoBase const &);
11 |
12 | //0
13 | virtual void AddRef();
14 | //1
15 | virtual int Release();
16 |
17 | //NULL
18 | virtual HRESULT WINAPI CreateInstance(Element*, unsigned long*, Element** ) = 0;
19 |
20 | //2
21 | virtual const PropertyInfo* EnumPropertyInfo(unsigned int);
22 | //3
23 | virtual const PropertyInfo* GetByClassIndex(unsigned int);
24 | //4
25 | virtual unsigned int GetPICount() const;
26 | //5
27 | virtual unsigned int GetGlobalIndex() const;
28 |
29 | //NULL
30 | virtual IClassInfo* WINAPI GetBaseClass() = 0;
31 |
32 | //6
33 | virtual UCString GetName() const;
34 | //7
35 | virtual bool IsValidProperty(const PropertyInfo*) const;
36 | //8
37 | virtual bool IsSubclassOf(IClassInfo*) const;
38 | //9
39 | virtual void Destroy();
40 | //10
41 | virtual HINSTANCE GetModule() const;
42 | //11
43 | virtual bool IsGlobal() const;
44 |
45 | //12
46 | virtual void AddChild();
47 | //13
48 | virtual void RemoveChild();
49 | //14
50 | virtual int GetChildren() const;
51 | //15
52 | virtual void AssertPIZeroRef() const;
53 |
54 | virtual ~ClassInfoBase();
55 |
56 | static bool WINAPI ClassExist(IClassInfo**, const PropertyInfo* const*, unsigned int, IClassInfo*, HINSTANCE, UCString, bool);
57 | long Initialize(HINSTANCE, UCString, bool, const PropertyInfo* const*, unsigned int);
58 | long Register();
59 | };
60 |
61 |
62 | class UILIB_API BaseScrollBar
63 | {
64 | public:
65 | BaseScrollBar(BaseScrollBar const &);
66 | BaseScrollBar();
67 | BaseScrollBar & operator=(BaseScrollBar const &);
68 | //0
69 | virtual Element* GetElement() = 0;
70 | //1
71 | virtual int GetPosition() = 0;
72 | //2
73 | virtual int GetMaximum() = 0;
74 | //3
75 | virtual int GetMinimum() = 0;
76 | //4
77 | virtual int GetPage() = 0;
78 | //5
79 | virtual int GetLine() = 0;
80 | //6
81 | virtual long SetPosition(int) = 0;
82 | //7
83 | virtual long SetMaximum(int) = 0;
84 | //8
85 | virtual long SetMinimum(int) = 0;
86 | //9
87 | virtual long SetPage(int) = 0;
88 | //10
89 | virtual long SetLine(int) = 0;
90 | //11
91 | virtual bool CanSetFocus() = 0;
92 | //12
93 | virtual void LineUp(unsigned int);
94 | //13
95 | virtual void LineDown(unsigned int);
96 | //14
97 | virtual void PageUp(unsigned int);
98 | //15
99 | virtual void PageDown(unsigned int);
100 | //16
101 | virtual void End();
102 | //17
103 | virtual void Home();
104 |
105 | bool IsPinned();
106 | bool IsScrollable();
107 | void OnMaximumChanged(Value*);
108 | void OnMinimumChanged(Value*);
109 | void OnPageChanged(Value*);
110 | bool OnPageChanging(Value*);
111 | void OnPositionChanged(Value*);
112 | bool OnPositionChanging(Value*);
113 | static UID WINAPI Scroll();
114 | void SetPinned(bool);
115 | private:
116 | int GetPageInc();
117 | };
118 |
119 | class UILIB_API BaseScrollViewer : public Element, public IElementListener
120 | {
121 | public:
122 | BaseScrollViewer(BaseScrollViewer const &);
123 | BaseScrollViewer();
124 | //0
125 | virtual ~BaseScrollViewer();
126 | BaseScrollViewer & operator=(BaseScrollViewer const &);
127 |
128 | long Initialize(Element*, unsigned long*);
129 |
130 | //1
131 | virtual bool OnListenedPropertyChanging(Element*, const PropertyInfo*, int, Value*, Value*);
132 |
133 | //2
134 | virtual void OnPropertyChanged(const PropertyInfo*, int, Value*, Value*);
135 |
136 | //3
137 | virtual void OnInput(InputEvent*);
138 |
139 | //4
140 | virtual void OnEvent(Event*);
141 |
142 | //5
143 | virtual long Add(Element**, unsigned int);
144 |
145 | //6
146 | virtual IClassInfo* GetClassInfoW();
147 | int GetPinning();
148 | int GetXBarVisibility();
149 | int GetXOffset();
150 | bool GetXScrollable();
151 | int GetYBarVisibility();
152 | int GetYOffset();
153 | bool GetYScrollable();
154 |
155 | //第二个类虚函数表
156 | //0
157 | virtual void OnListenerAttach(Element*);
158 | //1
159 | virtual void OnListenerDetach(Element*);
160 | //2
161 | virtual bool OnPropertyChanging(const PropertyInfo*, int, Value*, Value*);
162 | //3
163 | virtual void OnListenedPropertyChanged(Element*, const PropertyInfo*, int, Value*, Value*);
164 | //4
165 | virtual void OnListenedEvent(Element*, Event*);
166 | //5
167 | virtual void OnListenedInput(Element*, InputEvent*);
168 |
169 |
170 | long SetPinning(int);
171 | long SetXBarVisibility(int);
172 | long SetXOffset(int);
173 | long SetXScrollable(bool);
174 | long SetYBarVisibility(int);
175 | long SetYOffset(int);
176 | long SetYScrollable(bool);
177 |
178 | static IClassInfo* WINAPI GetClassInfoPtr();
179 |
180 | static long WINAPI Register();
181 | static void WINAPI SetClassInfoPtr(IClassInfo*);
182 |
183 | static const PropertyInfo* WINAPI PinningProp();
184 | static const PropertyInfo* WINAPI XBarVisibilityProp();
185 | static const PropertyInfo* WINAPI XOffsetProp();
186 | static const PropertyInfo* WINAPI XScrollableProp();
187 | static const PropertyInfo* WINAPI YBarVisibilityProp();
188 | static const PropertyInfo* WINAPI YOffsetProp();
189 | static const PropertyInfo* WINAPI YScrollableProp();
190 |
191 | protected:
192 | void FireAnimationChangeEvent(bool);
193 |
194 | private:
195 | void CheckScroll(BaseScrollBar*, int, int, int);
196 | static IClassInfo* s_pClassInfo;
197 | };
198 | }
--------------------------------------------------------------------------------
/DirectUI/Interfaces.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 |
3 | namespace DirectUI
4 | {
5 | struct IElementListener
6 | {
7 | public:
8 | //0
9 | virtual void OnListenerAttach(class Element* elem) = 0;
10 | //1
11 | virtual void OnListenerDetach(class Element* elem) = 0;
12 | //2 returns false to cancel
13 | virtual bool OnPropertyChanging(class Element* elem, const struct PropertyInfo *prop, int unk, class Value *before, class Value *after) = 0;
14 | //3
15 | virtual void OnListenedPropertyChanged(class Element* elem, const struct PropertyInfo *prop, int type, class Value *before, class Value *after) = 0;
16 | //4
17 | virtual void OnListenedInput(class Element* elem, struct InputEvent *event) = 0;
18 | //5
19 | virtual void OnListenedEvent(class Element* elem, struct Event *event) = 0;
20 | };
21 |
22 | struct IClassInfo
23 | {
24 | IClassInfo();
25 | IClassInfo(const IClassInfo&) = delete;
26 | IClassInfo&operator=(const IClassInfo&) = delete;
27 |
28 | virtual LONG AddRef(void) = 0;
29 | virtual LONG Release(void) = 0;
30 | virtual HRESULT CreateInstance(Element *,ULONG *,Element * *) = 0;
31 | virtual struct PropertyInfo * EnumPropertyInfo(UINT) = 0;
32 | virtual struct PropertyInfo * GetByClassIndex(UINT) = 0;
33 | virtual UINT GetPICount(void) = 0;
34 | virtual UINT GetGlobalIndex(void) = 0;
35 | virtual IClassInfo * GetBaseClass(void) = 0;
36 | virtual UCString GetName(void) = 0;
37 | virtual bool IsValidProperty(struct PropertyInfo const *) = 0;
38 | virtual bool IsSubclassOf(IClassInfo *) = 0;
39 | virtual void Destroy(void) = 0;
40 | virtual HINSTANCE GetModule(void) = 0;
41 | virtual bool IsGlobal(void) = 0;
42 | virtual void AddChild(void) = 0;
43 | virtual void RemoveChild(void) = 0;
44 | virtual UINT GetChildren(void) = 0;
45 | virtual void AssertPIZeroRef(void) = 0;
46 |
47 | virtual ~IClassInfo();
48 | };
49 |
50 | struct UILIB_API IDataEntry
51 | {
52 | public:
53 | IDataEntry(IDataEntry const &);
54 | IDataEntry(void);
55 | virtual ~IDataEntry(void);
56 |
57 | IDataEntry & operator=(IDataEntry const &);
58 | };
59 |
60 | class DECLSPEC_NOVTABLE IProxy
61 | {
62 | public:
63 | virtual long DoMethod(int, char *) = 0;
64 |
65 | protected:
66 | virtual void Init(class Element *) = 0;
67 | };
68 |
69 | class UILIB_API Proxy
70 | {
71 | public:
72 | Proxy(Proxy const &);
73 | Proxy(void);
74 | virtual ~Proxy(void);
75 | Proxy & operator=(Proxy const &);
76 |
77 | static long __stdcall SyncCallback(struct HGADGET__ *, void *, struct EventMsg *);
78 |
79 | protected:
80 | void Invoke(unsigned int, void *);
81 | virtual void OnInvoke(unsigned int, void *);
82 |
83 | };
84 |
85 | class UILIB_API ProviderProxy : public IProxy
86 | {
87 | public:
88 | ProviderProxy(ProviderProxy const &);
89 | ProviderProxy & operator=(ProviderProxy const &);
90 |
91 | protected:
92 | ProviderProxy(void);
93 | virtual void Init(class Element *);
94 | };
95 |
96 | typedef class ProviderProxy* (__stdcall * ProviderProxyCall)(class Element *);
97 |
98 | class UILIB_API IProvider
99 | {
100 | public:
101 | IProvider(IProvider const &);
102 | IProvider(void);
103 | IProvider & operator=(IProvider const &);
104 |
105 | virtual ProviderProxyCall GetProxyCreator(void) = 0;
106 | };
107 |
108 | class UILIB_API RefcountBase
109 | {
110 | public:
111 | RefcountBase();
112 | RefcountBase(const RefcountBase&) = delete;
113 | RefcountBase&operator=(const RefcountBase&) = delete;
114 |
115 | virtual ~RefcountBase();
116 |
117 | long AddRef();
118 | long Release();
119 | };
120 |
121 |
122 | template
123 | class PatternProvider
124 | : public RefcountBase
125 | , public IProvider
126 | //, public Y
127 | {
128 | public:
129 | PatternProvider();
130 | PatternProvider(const PatternProvider&) = delete;
131 | PatternProvider& operator=(const PatternProvider&) = delete;
132 | virtual ~PatternProvider();
133 |
134 | static long WINAPI Create(class ElementProvider*, IUnknown**);
135 | virtual void Init(class ElementProvider*);
136 | //IProvider
137 | virtual ProviderProxyCall GetProxyCreator(void);
138 | protected:
139 | long DoInvoke(int, ...);
140 | private:
141 |
142 | };
143 |
144 |
145 | struct UILIB_API ISBLeak
146 | {
147 | public:
148 | ISBLeak(ISBLeak const &);
149 | ISBLeak(void);
150 | ISBLeak & operator=(ISBLeak const &);
151 |
152 | virtual void T1() = 0;
153 | virtual void T2() = 0;
154 | virtual void T3() = 0;
155 | };
156 |
157 | class UILIB_API IXProviderCP
158 | {
159 | public:
160 | IXProviderCP(IXProviderCP const &);
161 | IXProviderCP(void);
162 | IXProviderCP & operator=(IXProviderCP const &);
163 |
164 | virtual long CreateDUICP(class HWNDElement *, HWND, HWND, class Element * *, class DUIXmlParser * *) = 0;
165 | virtual long CreateParserCP(class DUIXmlParser * *) = 0;
166 | virtual void DestroyCP(void) = 0;
167 | };
168 |
169 | class UILIB_API IXElementCP
170 | {
171 | public:
172 | IXElementCP(IXElementCP const &);
173 | IXElementCP(void);
174 | IXElementCP & operator=(IXElementCP const &);
175 |
176 | virtual HWND GetNotificationSinkHWND(void) = 0;
177 | };
178 |
179 | struct UILIB_API IDataEngine
180 | {
181 | public:
182 | IDataEngine(IDataEngine const &);
183 | IDataEngine(void);
184 | IDataEngine & operator=(IDataEngine const &);
185 |
186 | virtual ~IDataEngine(void);
187 |
188 | virtual void T1() = 0;
189 | virtual void T2() = 0;
190 | };
191 |
192 | class UILIB_API StyleSheet
193 | {
194 | public:
195 | StyleSheet(StyleSheet const &);
196 | StyleSheet(void);
197 | StyleSheet & operator=(StyleSheet const &);
198 |
199 | static long __stdcall Create(StyleSheet * *);
200 |
201 | virtual void T1() = 0;
202 | virtual void T2() = 0;
203 | virtual void T3() = 0;
204 | virtual void T4() = 0;
205 | virtual void T5() = 0;
206 | virtual void T6() = 0;
207 | virtual void T7() = 0;
208 | virtual void T8() = 0;
209 | };
210 |
211 | }
--------------------------------------------------------------------------------
/DirectUI/types.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 |
3 | class UID
4 | {
5 | public:
6 | // user defined ctor
7 | // to enable correct return by outptr sematics
8 | // https://learn.microsoft.com/en-us/cpp/build/x64-calling-convention?view=msvc-170#return-values
9 | UID() { }
10 |
11 | void *value{};
12 | };
13 |
14 | inline bool operator==(UID id, UID( (*__stdcall ev)(void))) {
15 | UID z;
16 | auto p = ev();
17 | return id.value == p.value;
18 | }
19 |
20 | struct GMA_ACTIONINFO
21 | {
22 |
23 | };
24 |
25 | typedef struct tagGMSG
26 | {
27 | } GMSG, *LPGMSG;
28 |
29 |
30 | DECLARE_HANDLE(HGADGET);
31 |
32 | struct EventMsg
33 | {
34 |
35 | };
36 |
37 |
38 |
39 | //forward declares
40 | namespace DirectUI
41 | {
42 | typedef unsigned short UChar;
43 | typedef UChar* UString;
44 | typedef const unsigned short* UCString;
45 |
46 |
47 |
48 | typedef class ProviderProxy* (__stdcall * ProviderProxyCall)(class Element *);
49 |
50 |
51 | struct ThemeChangedEvent
52 | {
53 |
54 | };
55 |
56 | struct KeyboardEvent
57 | {
58 |
59 | };
60 |
61 | struct CellInfo
62 | {
63 |
64 | };
65 |
66 | //// Misc
67 | //class CritSecLock;
68 | //class LinkedList;
69 | //class DeferCycle;
70 | //class UID;
71 | //class StyleSheet;
72 | //class Value;
73 | //class Expression;
74 | //class InvokeHelper;
75 | //class ProviderProxy;
76 | //enum NavigateDirection;
77 | //enum ProviderOptions;
78 | //template class DynamicArray;
79 | //template class SafeArrayAccessor;
80 |
81 | // // Primitives
82 | //struct Fill;
83 |
84 | //struct Cursor;
85 |
86 | //struct Graphic;
87 |
88 | //struct LINEINFO;
89 |
90 | //struct XMLParserCond;
91 |
92 | //struct EnumMap;
93 |
94 | //struct UiaRect;
95 |
96 | //struct PropertyInfo;
97 |
98 | //struct DepRecs;
99 |
100 | //struct NavReference;
101 | //
102 | //// Base
103 | // class BaseScrollBar;
104 | // class BaseScrollViewer;
105 | //class ClassInfoBase;
106 | //class RefcountBase;
107 |
108 | // // Elements
109 | // class Element;
110 | //class ElementWithHWND;
111 | //class UnknownElement;
112 | // class HWNDElement;
113 | //class DialogElement;
114 | //class AnimationStrip;
115 | //class RefPointElement;
116 | // class Button;
117 | // class AutoButton;
118 | //class PushButton;
119 | //class RepeatButton;
120 | //class Progress;
121 | //class Page;
122 | //class Pages;
123 | //class ScrollBar;
124 | //class Combobox;
125 | //class Edit;
126 | //class Expandable;
127 | //class Expando;
128 | //class XElement;
129 |
130 | //// Accessibility
131 | //class DuiAccessible;
132 | // class AccessibleButton;
133 | //class HWNDElementAccessible;
134 | //class HWNDHostAccessible;
135 | //class HWNDHostClientAccessible;
136 |
137 |
138 | //// Layouts
139 | //class Layout;
140 | // class BorderLayout;
141 | //class GridLayout;
142 | //class FillLayout;
143 | //class FlowLayout;
144 | //class RowLayout;
145 | //class NineGridLayout;
146 | //class ShellBorderLayout;
147 | //class TableLayout;
148 | //class VerticalFlowLayout;
149 | //
150 | //// Common Controls
151 | //class CCAVI;
152 | //class CCBase;
153 | //class CCBaseCheckRadioButton;
154 | //class CCBaseScrollBar;
155 | //class CCCheckBox;
156 | //class CCCommandLink;
157 | //class CCHScrollBar;
158 | //class CCListBox;
159 | //class CCListView;
160 | //class CCProgressBar;
161 | //class CCPushButton;
162 | //class CCRadioButton;
163 | //class CCSysLink;
164 | //class CCTrackBar;
165 | //class CCTreeView;
166 | //class CCVScrollBar;
167 | //class CCVScrollBar;
168 | //class CCSysLink;
169 |
170 | //// Browser
171 | //class Browser;
172 | //class BrowserSelectionProxy;
173 |
174 | // // Providers
175 | // class ElementProvider;
176 | //class ExpandCollapseProvider;
177 | //class GridItemProvider;
178 | //class GridProvider;
179 | //class HWNDElementProvider;
180 | //class InvokeProvider;
181 | // template class PatternProvider;
182 | //class RangeValueProvider;
183 | //class ScrollItemProvider;
184 | //class ScrollProvider;
185 | //class SelectionItemProvider;
186 | //class SelectionProvider;
187 | //class TableItemProvider;
188 | //class TableProvider;
189 | //class ToggleProvider;
190 | //class ValueProvider;
191 | // class XProvider;
192 | // class XResourceProvider;
193 | //
194 | //// Proxies
195 | //class Proxy;
196 | //class ElementProxy;
197 | //class ExpandCollapseProxy;
198 | //class GridItemProxy;
199 | //class HWNDElementProxy;
200 | //class InvokeProxy;
201 | //class NavigatorSelectionItemProxy;
202 | //class ProgressRangeValueProxy;
203 | //class ProviderProxy;
204 | //class RangeValueProxy;
205 | //class ScrollBarRangeValueProxy;
206 | //class ScrollItemProxy;
207 | //class ScrollProxy;
208 | //class SelectionItemProxy;
209 | //class SelectionProxy;
210 | //class SelectorSelectionItemProxy;
211 | //class SelectorSelectionProxy;
212 | //class TableItemProxy;
213 | //class TableProxy;
214 | //class ToggleProxy;
215 | //class ValueProxy;
216 |
217 | //// Hosts
218 | //class NativeHWNDHost;
219 | //class HWNDHost;
220 | //class XHost;
221 |
222 | // // Events
223 | //struct Event;
224 | //struct InputEvent;
225 | //struct KeyboardEvent;
226 | //struct ThemeChangedEvent;
227 | //
228 | // // Interfaces
229 | //class IElementListener;
230 | //struct IClassInfo;
231 | //class IDataEngine;
232 | //class IDataEntry;
233 | //class IProvider;
234 | //class ISBLeak;
235 | //class IXProviderCP;
236 | //class IXElementCP;
237 | //struct IXmlReader;
238 | //struct IRawElementProviderFragment;
239 | //struct IRawElementProviderFragmentRoot;
240 | //struct IRawElementProviderSimple;
241 |
242 | // // XML Parser
243 | // class DUIXmlParser;
244 | // class Schema;
245 | //enum _DUI_PARSE_STATE;
246 | //namespace ParserTools
247 | //{
248 | // struct ExprNode;
249 | // class ValueParser;
250 | //}
251 | //
252 | //// Auto Objects
253 | //class AutoButton;
254 | //class AutoLock;
255 | //class AutoThread;
256 | //class AutoVariant;
257 |
258 | //
259 | //
260 | //// Unknown
261 | // class Bind;
262 | //class CallstackTracker;
263 | //class CheckBoxGlyph;
264 | //class Clipper;
265 | //class DCSurface;
266 | //class DUIFactory;
267 | //class ExpandoButtonGlyph;
268 | //class FontCache;
269 | //class FontCheckOut;
270 | //class Movie;
271 | //class Navigator;
272 | //class Surface;
273 | //class Thumb;
274 | //class Viewer;
275 | //class InvokeHelper;
276 | //class Macro;
277 | //class PText;
278 | //class RadioButtonGlyph;
279 | //class Repeater;
280 | //class ResourceModuleHandles;
281 | //class ScrollViewer;
282 | //class Selector;
283 | //class SelectorNoDefault;
284 | //class StyledScrollViewer;
285 | //class TaskPage;
286 | //class TextGraphic;
287 | //class XBaby;
288 | }
289 |
--------------------------------------------------------------------------------
/DirectUI/DirectUI.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 | #include
3 | #include
4 | #include
5 | #include
6 | #include
7 | #include
8 | #include
9 | #include
10 | #include
11 | #include
12 |
13 | #if defined(DIRECTUI_EXPORTS)
14 | #define UILIB_API __declspec(dllexport)
15 | #else
16 | #define UILIB_API __declspec(dllimport)
17 | #endif
18 |
19 | #include "types.h"
20 | #include "misc.h"
21 | #include "Interfaces.h"
22 |
23 | #include "AutoLock.h"
24 | #include "AutoThread.h"
25 | #include "AutoVariant.h"
26 | #include "Value.h"
27 |
28 | #include "Primitives.h"
29 | #include "parser.h"
30 | #include "element.h"
31 | #include "Browser.h"
32 | #include "Bind.h"
33 | #include "AnimationStrip.h"
34 | #include "Button.h"
35 | #include "base.h"
36 | #include "AccessibleButton.h"
37 | #include "AutoButton.h"
38 | #include "PushButton.h"
39 | #include "event.h"
40 | #include "layout.h"
41 | #include "BorderLayout.h"
42 | #include "host.h"
43 | #include "accessibility.h"
44 | #include "provider.h"
45 | #include "Movie.h"
46 | #include "ElementWithHWND.h"
47 | #include "HWNDElement.h"
48 | #include "DialogElement.h"
49 | #include "NativeHWNDHost.h"
50 | #include "HWNDHost.h"
51 | #include "CBase.h"
52 | #include "CAVI.h"
53 | #include "CPushButton.h"
54 | #include "CBaseCheckRadioButton.h"
55 | #include "CBaseScrollBar.h"
56 | #include "CHScrollBar.h"
57 | #include "CCheckBox.h"
58 | #include "CCommandLink.h"
59 | #include "CListBox.h"
60 | #include "CListView.h"
61 | #include "CProgressBar.h"
62 | #include "CRadioButton.h"
63 | #include "CCSysLink.h"
64 | #include "CTrackBar.h"
65 | #include "CTreeView.h"
66 | #include "CVScrollBar.h"
67 | #include "CallstackTracker.h"
68 | #include "CheckBoxGlyph.h"
69 | #include "Expandable.h"
70 | #include "Clipper.h"
71 | #include "Combobox.h"
72 | #include "DuiNavigate.h"
73 | #include "Edit.h"
74 | #include "Element.h"
75 | #include "EventManager.h"
76 | #include "ExpandCollapse.h"
77 | #include "Expando.h"
78 | #include "ExpandoButtonGlyph.h"
79 | #include "FontCache.h"
80 | #include "FontCheckOut.h"
81 | #include "GridItem.h"
82 | #include "Grid.h"
83 | #include "HWNDElement.h"
84 | #include "InvokeHelper.h"
85 | #include "LinkedList.h"
86 | #include "Macro.h"
87 | #include "NavScoring.h"
88 | #include "Navigator.h"
89 | #include "TextGraphic.h"
90 | #include "PText.h"
91 | #include "Page.h"
92 | #include "Progress.h"
93 | #include "RadioButtonGlyph.h"
94 | #include "RangeValue.h"
95 | #include "RefPointElement.h"
96 | #include "RepeatButton.h"
97 | #include "Repeater.h"
98 | #include "ScrollBar.h"
99 | #include "ScrollItem.h"
100 | #include "Scroll.h"
101 | #include "ScrollViewer.h"
102 | #include "SelectionItem.h"
103 | #include "Selection.h"
104 | #include "Selector.h"
105 | #include "SelectorNoDefault.h"
106 | #include "SelectorSelectionItem.h"
107 | #include "SelectorSelection.h"
108 | #include "StyledScrollViewer.h"
109 | #include "TableItem.h"
110 | #include "Table.h"
111 | #include "TaskPage.h"
112 | #include "Thumb.h"
113 | #include "Toggle.h"
114 | #include "UnknownElement.h"
115 | #include "Viewer.h"
116 | #include "XBaby.h"
117 | #include "XElement.h"
118 | #include "XProvider.h"
119 | #include "BrowserSelection.h"
120 |
121 | #include "RichText.h"
122 | #include "TouchButton.h"
123 |
124 | #include "CClassFactory.h"
125 |
126 | //UnknownElement
127 |
128 | UILIB_API void WINAPI DumpDuiTree(DirectUI::Element *, int);
129 | UILIB_API void WINAPI DumpDuiProperties(DirectUI::Element *);
130 |
131 | namespace DirectUI
132 | {
133 | extern UILIB_API unsigned long g_dwElSlot;
134 |
135 | HRESULT WINAPI InitProcessPriv(int duiVersion, unsigned short*unk1, char unk2, bool bEnableUIAutomationProvider);
136 | HRESULT WINAPI UnInitProcessPriv(unsigned short*unk1);
137 | EXTERN_C HRESULT WINAPI InitThread(int iDontKnow);
138 | void WINAPI UnInitThread();
139 |
140 | int WINAPI CreateDUIWrapper(Element*,class XProvider**);
141 | int WINAPI CreateDUIWrapperEx(Element*, class IXProviderCP*, class XProvider**);
142 | int WINAPI CreateDUIWrapperFromResource(HINSTANCE,UCString, UCString, UCString, class XResourceProvider**);
143 |
144 | int WINAPI GetScreenDPI();
145 |
146 | int WINAPI RegisterAllControls();
147 | int WINAPI RegisterBaseControls();
148 | int WINAPI RegisterBrowserControls();
149 | int WINAPI RegisterCommonControls();
150 | int WINAPI RegisterExtendedControls();
151 | int WINAPI RegisterMacroControls();
152 | int WINAPI RegisterMiscControls();
153 | int WINAPI RegisterStandardControls();
154 | int WINAPI RegisterXControls();
155 |
156 | int WINAPI StartMessagePump();
157 | int WINAPI StopMessagePump();
158 |
159 |
160 | ATOM WINAPI StrToID(UCString resId);
161 |
162 |
163 | int WINAPI UnicodeToMultiByte(UCString lpWideCharStr, int cchWideChar, int unk);
164 | int WINAPI MultiByteToUnicode(LPCSTR lpMultiByteStr, int cbMultiByte, int unk);
165 |
166 | BOOL WINAPI IsAnimationsEnabled();
167 | int WINAPI IsPalette(HWND hWnd);
168 | BOOL WINAPI IsUIAutomationProviderEnabled();
169 |
170 | int WINAPI DUIDrawShadowText(HDC hdcDest, UCString lpchText, int cchText, LPRECT hdcSrc, UINT format, COLORREF dwTextColor);
171 |
172 | int WINAPI BlurBitmap(void*, void*, void*, void*, void*);
173 |
174 | HBRUSH WINAPI BrushFromEnumI(_In_ int Index);
175 |
176 | DWORD WINAPI ColorFromEnumI(_In_ int Index);
177 |
178 | LPVOID WINAPI DisableAnimations();
179 | int WINAPI DrawShadowTextEx(HDC hdc, const WCHAR *lpchText, int cchText, LPRECT hdcSrc, UINT format, COLORREF dwTextColor, COLORREF dwBkColor, int a9, int a10, COLORREF a11, int a12);
180 | void* WINAPI ElementFromGadget(void*);
181 | LPVOID WINAPI EnableAnimations();
182 | void WINAPI FlushThemeHandles(unsigned int);
183 |
184 | //此函数仅调用DebugBreak,将程序中断
185 | void WINAPI ForceDebugBreak();
186 |
187 | DWORD WINAPI GetElementDataEntry(int a1);
188 | Macro* WINAPI GetElementMacro(int a1);
189 | LPVOID WINAPI GetFontCache();
190 |
191 | HRESULT WINAPI GetThemeHandle(LPCWSTR, void **);
192 |
193 | //此函数调用SysAllocString,并返回ppStr
194 | HRESULT WINAPI HrSysAllocString(OLECHAR *psz, BSTR* ppStr);
195 |
196 | //此函数用于复制lpString字符串,并返回ppStr
197 | HRESULT WINAPI HStrDup(LPCWSTR lpString, LPCWSTR* ppStr);
198 |
199 | //此函数是空实现,无任何作用
200 | BOOL WINAPI InitPreprocessor();
201 |
202 | HRESULT WINAPI SetDefAction(Element *a1, _In_ DWORD dwRole);
203 |
204 | BOOL WINAPI UiaHideOnGetObject(_In_ HWND hWnd, int a2, int a3);
205 |
206 | //调用RemoveProp 返回举个句柄
207 | HANDLE WINAPI UiaOnDestroySink(_In_ HWND hWnd);
208 | HRESULT WINAPI UiaOnGetObject(void* *a1, int a2, InvokeHelper *a3, int a4, int a5);
209 | BOOL WINAPI UiaOnToolTip(Element *, DWORD);
210 |
211 | void WINAPI NotifyAccessibilityEvent(DWORD event, Element *);
212 | void *WINAPI PreprocessBuffer(LPCWSTR Src, SIZE_T cSrc, BOOLEAN a3);
213 | HGDIOBJ WINAPI ProcessAlphaBitmapI(HBITMAP hgdiobj);
214 | void WINAPI PurgeThemeHandles();
215 | }
--------------------------------------------------------------------------------
/DirectUI/accessibility.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 |
3 | namespace DirectUI
4 | {
5 |
6 | class UILIB_API DuiAccessible
7 | : public IAccessible
8 | , public IEnumVARIANT
9 | , public IOleWindow
10 | , public IAccIdentity
11 | , public IServiceProvider
12 | {
13 | public:
14 | DuiAccessible();
15 | DuiAccessible(const DuiAccessible&) = delete;
16 | DuiAccessible& operator = (const DuiAccessible&) = delete;
17 |
18 | virtual ~DuiAccessible();
19 |
20 | void Initialize(Element*);
21 | static HRESULT WINAPI Create(Element*, DuiAccessible**);
22 | static Element* WINAPI GetAccessibleParent(Element*);
23 | static HRESULT WINAPI AccNavigate(Element*, long, Element**);
24 |
25 | virtual HRESULT Disconnect(void);
26 |
27 | // IUnknown
28 | virtual HRESULT WINAPI QueryInterface(REFIID riid, void**ppvObject);
29 | virtual ULONG WINAPI AddRef();
30 | virtual ULONG WINAPI Release();
31 |
32 | // IDispatch
33 | virtual HRESULT WINAPI GetTypeInfoCount(UINT*pctinfo);
34 | virtual HRESULT WINAPI GetTypeInfo(UINT iTInfo, LCID lcid, ITypeInfo**ppTInfo );
35 | virtual HRESULT WINAPI GetIDsOfNames(REFIID riid, LPOLESTR*rgszNames, UINT cNames, LCID lcid, DISPID*rgDispId);
36 | virtual HRESULT WINAPI Invoke(DISPID dispIdMember, REFIID riid, LCID lcid, WORD wFlags, DISPPARAMS*pDispParams, VARIANT*pVarResult, EXCEPINFO*pExcepInfo, UINT*puArgErr);
37 |
38 | // IAccIdentity
39 | virtual HRESULT WINAPI GetIdentityString(DWORD dwIDChild, BYTE**ppIDString, DWORD*pdwIDStringLen);
40 |
41 | // IAccessible
42 | virtual HRESULT WINAPI get_accParent(IDispatch**);
43 | virtual HRESULT WINAPI get_accChildCount(long*);
44 | virtual HRESULT WINAPI get_accChild(VARIANT, IDispatch**);
45 | virtual HRESULT WINAPI get_accName(VARIANT, BSTR*);
46 | virtual HRESULT WINAPI get_accValue(VARIANT, BSTR*);
47 | virtual HRESULT WINAPI get_accDescription(VARIANT, BSTR*);
48 | virtual HRESULT WINAPI get_accRole(VARIANT, VARIANT*);
49 | virtual HRESULT WINAPI get_accState(VARIANT, VARIANT*);
50 | virtual HRESULT WINAPI get_accHelp(VARIANT, BSTR*);
51 | virtual HRESULT WINAPI get_accHelpTopic(BSTR*, VARIANT, long*);
52 | virtual HRESULT WINAPI get_accKeyboardShortcut(VARIANT, BSTR*);
53 | virtual HRESULT WINAPI get_accFocus(VARIANT*);
54 | virtual HRESULT WINAPI get_accSelection(VARIANT*);
55 | virtual HRESULT WINAPI get_accDefaultAction(VARIANT, BSTR*);
56 |
57 | virtual HRESULT WINAPI accSelect(long flagsSelect, VARIANT varID);
58 | virtual HRESULT WINAPI accLocation(long*pxLeft, long*pyTop, long*pcxWidth, long*pcyHeight, VARIANT varID);
59 | virtual HRESULT WINAPI accNavigate(long navDir, VARIANT varStart, VARIANT*pvarEnd);
60 | virtual HRESULT WINAPI accHitTest(long xLeft, long yTop, VARIANT*pvarID);
61 | virtual HRESULT WINAPI accDoDefaultAction(VARIANT varID);
62 |
63 | virtual HRESULT WINAPI put_accName(VARIANT varID, BSTR pszValue);
64 | virtual HRESULT WINAPI put_accValue(VARIANT varID, BSTR pszValue);
65 |
66 | // IEnumVARIANT
67 | virtual HRESULT WINAPI Clone(IEnumVARIANT**ppEnum);
68 | virtual HRESULT WINAPI Next(unsigned long celt, VARIANT*rgVar, unsigned long*pCeltFetched);
69 | virtual HRESULT WINAPI Reset();
70 | virtual HRESULT WINAPI Skip(unsigned long celt);
71 |
72 | // IOleWindow
73 | virtual HRESULT WINAPI GetWindow(HWND*phwnd);
74 | virtual HRESULT WINAPI ContextSensitiveHelp(BOOL fEnterMode);
75 |
76 | // IServiceProvider
77 | virtual HRESULT WINAPI QueryService(REFGUID guidService, REFIID riid, void**ppv);
78 |
79 | protected:
80 | long GetAccName(VARIANT, int, unsigned short**);
81 | long GetAccNameFromContent(unsigned short**);
82 | long GetDispatchFromElement(Element*, IDispatch**);
83 | };
84 |
85 | class UILIB_API HWNDHostAccessible : public DuiAccessible
86 | {
87 | public:
88 | HWNDHostAccessible();
89 | virtual ~HWNDHostAccessible();
90 |
91 | long Initialize(Element*, IAccessible*);
92 | static HRESULT WINAPI Create(Element*, IAccessible*, DuiAccessible**);
93 |
94 | //IAccIdentity
95 | virtual HRESULT WINAPI GetIdentityString(unsigned long, unsigned char**, unsigned long*);
96 |
97 | virtual HRESULT WINAPI Clone(IEnumVARIANT**);
98 | virtual HRESULT WINAPI ContextSensitiveHelp(int);
99 | virtual HRESULT Disconnect();
100 | virtual HRESULT WINAPI GetWindow(HWND*);
101 | virtual HRESULT WINAPI Next(unsigned long, VARIANT*, unsigned long*);
102 | virtual HRESULT WINAPI QueryInterface(const IID &, void**);
103 | virtual HRESULT WINAPI QueryService(const IID &, const IID &, void**);
104 | virtual HRESULT WINAPI Reset();
105 | virtual HRESULT WINAPI Skip(unsigned long);
106 | virtual HRESULT WINAPI accDoDefaultAction(VARIANT);
107 | virtual HRESULT WINAPI accHitTest(long, long, VARIANT*);
108 | virtual HRESULT WINAPI accLocation(long*, long*, long*, long*, VARIANT);
109 | virtual HRESULT WINAPI accNavigate(long, VARIANT, VARIANT*);
110 | virtual HRESULT WINAPI accSelect(long, VARIANT);
111 |
112 | // IAccessible
113 | virtual HRESULT WINAPI get_accChild(VARIANT, IDispatch**);
114 | virtual HRESULT WINAPI get_accChildCount(long*);
115 | virtual HRESULT WINAPI get_accDefaultAction(VARIANT, BSTR*);
116 | virtual HRESULT WINAPI get_accDescription(VARIANT, BSTR*);
117 | virtual HRESULT WINAPI get_accFocus(VARIANT*);
118 | virtual HRESULT WINAPI get_accHelp(VARIANT, BSTR*);
119 | virtual HRESULT WINAPI get_accHelpTopic(BSTR*, VARIANT, long*);
120 | virtual HRESULT WINAPI get_accKeyboardShortcut(VARIANT, BSTR*);
121 | virtual HRESULT WINAPI get_accName(VARIANT, BSTR*);
122 | virtual HRESULT WINAPI get_accParent(IDispatch**);
123 | virtual HRESULT WINAPI get_accRole(VARIANT, VARIANT*);
124 | virtual HRESULT WINAPI get_accSelection(VARIANT*);
125 | virtual HRESULT WINAPI get_accState(VARIANT, VARIANT*);
126 | virtual HRESULT WINAPI get_accValue(VARIANT, BSTR*);
127 | virtual HRESULT WINAPI put_accName(VARIANT, BSTR);
128 | virtual HRESULT WINAPI put_accValue(VARIANT, BSTR);
129 | };
130 |
131 | class UILIB_API HWNDHostClientAccessible: public HWNDHostAccessible
132 | {
133 | public:
134 | HWNDHostClientAccessible();
135 | HWNDHostClientAccessible(const HWNDHostClientAccessible&) = delete;
136 | HWNDHostClientAccessible& operator=(const HWNDHostClientAccessible&) = delete;
137 |
138 | virtual ~HWNDHostClientAccessible();
139 |
140 | static HRESULT WINAPI Create(Element*, IAccessible*, DuiAccessible**);
141 | virtual HRESULT WINAPI accNavigate(long, VARIANT, LPVARIANT);
142 | virtual HRESULT WINAPI get_accParent(IDispatch**);
143 | virtual HRESULT WINAPI get_accRole(VARIANT, VARIANT*);
144 | };
145 |
146 | class UILIB_API HWNDElementAccessible : DuiAccessible
147 | {
148 | public:
149 | HWNDElementAccessible();
150 | virtual ~HWNDElementAccessible();
151 |
152 | long Initialize(class HWNDElement*);
153 | static HRESULT WINAPI Create(class HWNDElement*, class DuiAccessible**);
154 |
155 | virtual HRESULT Disconnect();
156 | virtual HRESULT WINAPI get_accParent(IDispatch**);
157 | };
158 |
159 |
160 | }
--------------------------------------------------------------------------------
/docs/ElementClass.g.txt:
--------------------------------------------------------------------------------
1 | ClassInfo:
2 | Base Class:
3 | Properties:
4 | [Parent]: Element
5 | [PosInLayout]: Point
6 | [SizeInLayout]: Size
7 | [DesiredSize]: Size
8 | [LastDSConst]: Int
9 | [Location]: Point
10 | [Extent]: Size
11 | [LayoutPos]: Int
12 | [Active]: Int
13 | Enum values:
14 | Inactive : 0x0 (0)
15 | Mouse : 0x1 (1)
16 | Keyboard : 0x2 (2)
17 | MouseAndKeyboard : 0x3 (3)
18 | NoSyncFocus : 0x4 (4)
19 | Pointer : 0x8 (8)
20 | [Children]: Ellist
21 | [Layout]: Layout
22 | [BorderThickness]: Rect
23 | [Padding]: Rect
24 | [Margin]: Rect
25 | [Visible]: Bool
26 | [X]: Int
27 | [Y]: Int
28 | [ContentAlign]: Int
29 | Enum values:
30 | TopLeft : 0x0 (0)
31 | TopCenter : 0x1 (1)
32 | TopRight : 0x2 (2)
33 | MiddleLeft : 0x4 (4)
34 | MiddleCenter : 0x5 (5)
35 | MiddleRight : 0x6 (6)
36 | BottomLeft : 0x8 (8)
37 | BottomCenter : 0x9 (9)
38 | BottomRight : 0xa (10)
39 | WrapLeft : 0xc (12)
40 | WrapCenter : 0xd (13)
41 | WrapRight : 0xe (14)
42 | EndEllipsis : 0x10 (16)
43 | FocusRect : 0x20 (32)
44 | PathEllipsis : 0x40 (64)
45 | NoPrefix : 0x80 (128)
46 | WordEllipsis : 0x100 (256)
47 | EditControl : 0x200 (512)
48 | StartEllipsis : 0x400 (1024)
49 | [KeyFocused]: Bool
50 | [KeyWithin]: Bool
51 | [MouseFocused]: Bool
52 | [MouseWithin]: Bool
53 | [Content]: String
54 | [Sheet]: Sheet
55 | [Width]: Int
56 | Enum values:
57 | Auto : 0xffffffff (-1)
58 | [Height]: Int
59 | Enum values:
60 | Auto : 0xffffffff (-1)
61 | [BorderStyle]: Int
62 | Enum values:
63 | Solid : 0x0 (0)
64 | Raised : 0x1 (1)
65 | Sunken : 0x2 (2)
66 | Rounded : 0x3 (3)
67 | [BorderColor]: Int
68 | [Foreground]: Int
69 | [Background]: Int
70 | [FontFace]: String
71 | [FontSize]: Int
72 | [FontWeight]: Int
73 | Enum values:
74 | DontCare : 0x0 (0)
75 | Thin : 0x64 (100)
76 | ExtraLight : 0xc8 (200)
77 | Light : 0x12c (300)
78 | SemiLight : 0x15e (350)
79 | Normal : 0x190 (400)
80 | Medium : 0x1f4 (500)
81 | SemiBold : 0x258 (600)
82 | Bold : 0x2bc (700)
83 | ExtraBold : 0x320 (800)
84 | Heavy : 0x384 (900)
85 | [FontStyle]: Int
86 | Enum values:
87 | None : 0x0 (0)
88 | Italic : 0x1 (1)
89 | Underline : 0x2 (2)
90 | StrikeOut : 0x4 (4)
91 | Shadow : 0x8 (8)
92 | [FontQuality]: Int
93 | Enum values:
94 | Default : 0x0 (0)
95 | NonAntialiased : 0x3 (3)
96 | Antialiased : 0x4 (4)
97 | ClearType : 0x5 (5)
98 | ClearType-Natural : 0x6 (6)
99 | [Class]: String
100 | [ID]: Atom
101 | [Selected]: Bool
102 | [Alpha]: Int
103 | [Animation]: Int
104 | Enum values:
105 | None : 0x0 (0)
106 | Linear : 0x1 (1)
107 | Log : 0x2 (2)
108 | Exp : 0x3 (3)
109 | S : 0x4 (4)
110 | DelayShort : 0x10 (16)
111 | DelayMedium : 0x20 (32)
112 | DelayLong : 0x30 (48)
113 | Alpha : 0x100 (256)
114 | Position : 0x1000 (4096)
115 | Size : 0x2000 (8192)
116 | SizeH : 0x3000 (12288)
117 | SizeV : 0x4000 (16384)
118 | Rectangle : 0x5000 (20480)
119 | RectangleH : 0x6000 (24576)
120 | RectangleV : 0x7000 (28672)
121 | Reverse : 0x1000000 (16777216)
122 | Scale : 0x10000 (65536)
123 | VeryFast : 0x10000000 (268435456)
124 | Fast : 0x20000000 (536870912)
125 | MediumFast : 0x30000000 (805306368)
126 | MediumSlow : 0x50000000 (1342177280)
127 | Medium : 0x40000000 (1073741824)
128 | MediumSlow : 0x50000000 (1342177280)
129 | Slow : 0x60000000 (1610612736)
130 | VerySlow : 0x70000000 (1879048192)
131 | [Cursor]: Int
132 | Enum values:
133 | Arrow : 0x0 (0)
134 | Hand : 0x1 (1)
135 | Help : 0x2 (2)
136 | No : 0x3 (3)
137 | Wait : 0x4 (4)
138 | SizeAll : 0x5 (5)
139 | SizeNESW : 0x6 (6)
140 | SizeNS : 0x7 (7)
141 | SizeNWSE : 0x8 (8)
142 | SizeWE : 0x9 (9)
143 | IBeam : 0xa (10)
144 | [Direction]: Int
145 | Enum values:
146 | LTR : 0x0 (0)
147 | RTL : 0x1 (1)
148 | [Accessible]: Bool
149 | [AccRole]: Int
150 | Enum values:
151 | TitleBar : 0x1 (1)
152 | MenuBar : 0x2 (2)
153 | ScrollBar : 0x3 (3)
154 | Grip : 0x4 (4)
155 | Sound : 0x5 (5)
156 | Cursor : 0x6 (6)
157 | Caret : 0x7 (7)
158 | Alert : 0x8 (8)
159 | Window : 0x9 (9)
160 | Client : 0xa (10)
161 | MenuPopup : 0xb (11)
162 | MenuItem : 0xc (12)
163 | Tooltip : 0xd (13)
164 | Application : 0xe (14)
165 | Document : 0xf (15)
166 | Pane : 0x10 (16)
167 | Chart : 0x11 (17)
168 | Dialog : 0x12 (18)
169 | Border : 0x13 (19)
170 | Grouping : 0x14 (20)
171 | Separator : 0x15 (21)
172 | Toolbar : 0x16 (22)
173 | Statusbar : 0x17 (23)
174 | Table : 0x18 (24)
175 | ColumnHeader : 0x19 (25)
176 | RowHeader : 0x1a (26)
177 | Column : 0x1b (27)
178 | Row : 0x1c (28)
179 | Cell : 0x1d (29)
180 | Link : 0x1e (30)
181 | HelpBalloon : 0x1f (31)
182 | Character : 0x20 (32)
183 | List : 0x21 (33)
184 | ListItem : 0x22 (34)
185 | Outline : 0x23 (35)
186 | OutlineItem : 0x24 (36)
187 | PageTab : 0x25 (37)
188 | PropertyPage : 0x26 (38)
189 | Indicator : 0x27 (39)
190 | Graphic : 0x28 (40)
191 | StaticText : 0x29 (41)
192 | Text : 0x2a (42)
193 | PushButton : 0x2b (43)
194 | CheckButton : 0x2c (44)
195 | RadioButton : 0x2d (45)
196 | ComboBox : 0x2e (46)
197 | DropList : 0x2f (47)
198 | ProgressBar : 0x30 (48)
199 | Dial : 0x31 (49)
200 | HotKeyField : 0x32 (50)
201 | Slider : 0x33 (51)
202 | SpinButton : 0x34 (52)
203 | Diagram : 0x35 (53)
204 | Animation : 0x36 (54)
205 | Equation : 0x37 (55)
206 | ButtonDropDown : 0x38 (56)
207 | ButtonMenu : 0x39 (57)
208 | ButtonDropDownGrid : 0x3a (58)
209 | Whitespace : 0x3b (59)
210 | PageTabList : 0x3c (60)
211 | Clock : 0x3d (61)
212 | SplitButton : 0x3e (62)
213 | IpAddress : 0x3f (63)
214 | OutlineButton : 0x40 (64)
215 | [AccState]: Int
216 | [AccName]: String
217 | [AccDesc]: String
218 | [AccValue]: String
219 | [AccDefAction]: String
220 | [AccHelp]: String
221 | [AccItemType]: String
222 | [AccItemStatus]: String
223 | [Shortcut]: Int
224 | Enum values:
225 | Auto : 0xffffffff (-1)
226 | None : 0x0 (0)
227 | [Enabled]: Bool
228 | [MinSize]: Size
229 | [Overhang]: Bool
230 | [Tooltip]: Bool
231 | [TooltipMaxWidth]: Int
232 | [Font]: String
233 | [WindowActive]: Bool
234 | [AbsorbsShortcut]: Bool
235 | [CompositedText]: Bool
236 | [TextGlowSize]: Int
237 | [HighDPI]: Bool
238 | [DPI]: Int
239 | [Custom]: Bool
240 | [ShadowIntensity]: Int
241 | [EdgeHighlightThickness]: Rect
242 | [EdgeHighlightColor]: Int
243 | [ScaleFactor]: Int
244 | Enum values:
245 | Scale_100 : 0x64 (100)
246 | Scale_140 : 0x8c (140)
247 | Scale_180 : 0xb4 (180)
248 | [UsesDesktopPerMonitorScaling]: Bool
249 |
--------------------------------------------------------------------------------
/docs/PagesClass.g.txt:
--------------------------------------------------------------------------------
1 | ClassInfo:
2 | Base Class:
3 | Properties:
4 | [Parent]: Element
5 | [PosInLayout]: Point
6 | [SizeInLayout]: Size
7 | [DesiredSize]: Size
8 | [LastDSConst]: Int
9 | [Location]: Point
10 | [Extent]: Size
11 | [LayoutPos]: Int
12 | [Active]: Int
13 | Enum values:
14 | Inactive : 0x0 (0)
15 | Mouse : 0x1 (1)
16 | Keyboard : 0x2 (2)
17 | MouseAndKeyboard : 0x3 (3)
18 | NoSyncFocus : 0x4 (4)
19 | Pointer : 0x8 (8)
20 | [Children]: Ellist
21 | [Layout]: Layout
22 | [BorderThickness]: Rect
23 | [Padding]: Rect
24 | [Margin]: Rect
25 | [Visible]: Bool
26 | [X]: Int
27 | [Y]: Int
28 | [ContentAlign]: Int
29 | Enum values:
30 | TopLeft : 0x0 (0)
31 | TopCenter : 0x1 (1)
32 | TopRight : 0x2 (2)
33 | MiddleLeft : 0x4 (4)
34 | MiddleCenter : 0x5 (5)
35 | MiddleRight : 0x6 (6)
36 | BottomLeft : 0x8 (8)
37 | BottomCenter : 0x9 (9)
38 | BottomRight : 0xa (10)
39 | WrapLeft : 0xc (12)
40 | WrapCenter : 0xd (13)
41 | WrapRight : 0xe (14)
42 | EndEllipsis : 0x10 (16)
43 | FocusRect : 0x20 (32)
44 | PathEllipsis : 0x40 (64)
45 | NoPrefix : 0x80 (128)
46 | WordEllipsis : 0x100 (256)
47 | EditControl : 0x200 (512)
48 | StartEllipsis : 0x400 (1024)
49 | [KeyFocused]: Bool
50 | [KeyWithin]: Bool
51 | [MouseFocused]: Bool
52 | [MouseWithin]: Bool
53 | [Content]: String
54 | [Sheet]: Sheet
55 | [Width]: Int
56 | Enum values:
57 | Auto : 0xffffffff (-1)
58 | [Height]: Int
59 | Enum values:
60 | Auto : 0xffffffff (-1)
61 | [BorderStyle]: Int
62 | Enum values:
63 | Solid : 0x0 (0)
64 | Raised : 0x1 (1)
65 | Sunken : 0x2 (2)
66 | Rounded : 0x3 (3)
67 | [BorderColor]: Int
68 | [Foreground]: Int
69 | [Background]: Int
70 | [FontFace]: String
71 | [FontSize]: Int
72 | [FontWeight]: Int
73 | Enum values:
74 | DontCare : 0x0 (0)
75 | Thin : 0x64 (100)
76 | ExtraLight : 0xc8 (200)
77 | Light : 0x12c (300)
78 | SemiLight : 0x15e (350)
79 | Normal : 0x190 (400)
80 | Medium : 0x1f4 (500)
81 | SemiBold : 0x258 (600)
82 | Bold : 0x2bc (700)
83 | ExtraBold : 0x320 (800)
84 | Heavy : 0x384 (900)
85 | [FontStyle]: Int
86 | Enum values:
87 | None : 0x0 (0)
88 | Italic : 0x1 (1)
89 | Underline : 0x2 (2)
90 | StrikeOut : 0x4 (4)
91 | Shadow : 0x8 (8)
92 | [FontQuality]: Int
93 | Enum values:
94 | Default : 0x0 (0)
95 | NonAntialiased : 0x3 (3)
96 | Antialiased : 0x4 (4)
97 | ClearType : 0x5 (5)
98 | ClearType-Natural : 0x6 (6)
99 | [Class]: String
100 | [ID]: Atom
101 | [Selected]: Bool
102 | [Alpha]: Int
103 | [Animation]: Int
104 | Enum values:
105 | None : 0x0 (0)
106 | Linear : 0x1 (1)
107 | Log : 0x2 (2)
108 | Exp : 0x3 (3)
109 | S : 0x4 (4)
110 | DelayShort : 0x10 (16)
111 | DelayMedium : 0x20 (32)
112 | DelayLong : 0x30 (48)
113 | Alpha : 0x100 (256)
114 | Position : 0x1000 (4096)
115 | Size : 0x2000 (8192)
116 | SizeH : 0x3000 (12288)
117 | SizeV : 0x4000 (16384)
118 | Rectangle : 0x5000 (20480)
119 | RectangleH : 0x6000 (24576)
120 | RectangleV : 0x7000 (28672)
121 | Reverse : 0x1000000 (16777216)
122 | Scale : 0x10000 (65536)
123 | VeryFast : 0x10000000 (268435456)
124 | Fast : 0x20000000 (536870912)
125 | MediumFast : 0x30000000 (805306368)
126 | MediumSlow : 0x50000000 (1342177280)
127 | Medium : 0x40000000 (1073741824)
128 | MediumSlow : 0x50000000 (1342177280)
129 | Slow : 0x60000000 (1610612736)
130 | VerySlow : 0x70000000 (1879048192)
131 | [Cursor]: Int
132 | Enum values:
133 | Arrow : 0x0 (0)
134 | Hand : 0x1 (1)
135 | Help : 0x2 (2)
136 | No : 0x3 (3)
137 | Wait : 0x4 (4)
138 | SizeAll : 0x5 (5)
139 | SizeNESW : 0x6 (6)
140 | SizeNS : 0x7 (7)
141 | SizeNWSE : 0x8 (8)
142 | SizeWE : 0x9 (9)
143 | IBeam : 0xa (10)
144 | [Direction]: Int
145 | Enum values:
146 | LTR : 0x0 (0)
147 | RTL : 0x1 (1)
148 | [Accessible]: Bool
149 | [AccRole]: Int
150 | Enum values:
151 | TitleBar : 0x1 (1)
152 | MenuBar : 0x2 (2)
153 | ScrollBar : 0x3 (3)
154 | Grip : 0x4 (4)
155 | Sound : 0x5 (5)
156 | Cursor : 0x6 (6)
157 | Caret : 0x7 (7)
158 | Alert : 0x8 (8)
159 | Window : 0x9 (9)
160 | Client : 0xa (10)
161 | MenuPopup : 0xb (11)
162 | MenuItem : 0xc (12)
163 | Tooltip : 0xd (13)
164 | Application : 0xe (14)
165 | Document : 0xf (15)
166 | Pane : 0x10 (16)
167 | Chart : 0x11 (17)
168 | Dialog : 0x12 (18)
169 | Border : 0x13 (19)
170 | Grouping : 0x14 (20)
171 | Separator : 0x15 (21)
172 | Toolbar : 0x16 (22)
173 | Statusbar : 0x17 (23)
174 | Table : 0x18 (24)
175 | ColumnHeader : 0x19 (25)
176 | RowHeader : 0x1a (26)
177 | Column : 0x1b (27)
178 | Row : 0x1c (28)
179 | Cell : 0x1d (29)
180 | Link : 0x1e (30)
181 | HelpBalloon : 0x1f (31)
182 | Character : 0x20 (32)
183 | List : 0x21 (33)
184 | ListItem : 0x22 (34)
185 | Outline : 0x23 (35)
186 | OutlineItem : 0x24 (36)
187 | PageTab : 0x25 (37)
188 | PropertyPage : 0x26 (38)
189 | Indicator : 0x27 (39)
190 | Graphic : 0x28 (40)
191 | StaticText : 0x29 (41)
192 | Text : 0x2a (42)
193 | PushButton : 0x2b (43)
194 | CheckButton : 0x2c (44)
195 | RadioButton : 0x2d (45)
196 | ComboBox : 0x2e (46)
197 | DropList : 0x2f (47)
198 | ProgressBar : 0x30 (48)
199 | Dial : 0x31 (49)
200 | HotKeyField : 0x32 (50)
201 | Slider : 0x33 (51)
202 | SpinButton : 0x34 (52)
203 | Diagram : 0x35 (53)
204 | Animation : 0x36 (54)
205 | Equation : 0x37 (55)
206 | ButtonDropDown : 0x38 (56)
207 | ButtonMenu : 0x39 (57)
208 | ButtonDropDownGrid : 0x3a (58)
209 | Whitespace : 0x3b (59)
210 | PageTabList : 0x3c (60)
211 | Clock : 0x3d (61)
212 | SplitButton : 0x3e (62)
213 | IpAddress : 0x3f (63)
214 | OutlineButton : 0x40 (64)
215 | [AccState]: Int
216 | [AccName]: String
217 | [AccDesc]: String
218 | [AccValue]: String
219 | [AccDefAction]: String
220 | [AccHelp]: String
221 | [AccItemType]: String
222 | [AccItemStatus]: String
223 | [Shortcut]: Int
224 | Enum values:
225 | Auto : 0xffffffff (-1)
226 | None : 0x0 (0)
227 | [Enabled]: Bool
228 | [MinSize]: Size
229 | [Overhang]: Bool
230 | [Tooltip]: Bool
231 | [TooltipMaxWidth]: Int
232 | [Font]: String
233 | [WindowActive]: Bool
234 | [AbsorbsShortcut]: Bool
235 | [CompositedText]: Bool
236 | [TextGlowSize]: Int
237 | [HighDPI]: Bool
238 | [DPI]: Int
239 | [Custom]: Bool
240 | [ShadowIntensity]: Int
241 | [EdgeHighlightThickness]: Rect
242 | [EdgeHighlightColor]: Int
243 | [ScaleFactor]: Int
244 | Enum values:
245 | Scale_100 : 0x64 (100)
246 | Scale_140 : 0x8c (140)
247 | Scale_180 : 0xb4 (180)
248 | [UsesDesktopPerMonitorScaling]: Bool
249 |
--------------------------------------------------------------------------------
/docs/BrowserClass.g.txt:
--------------------------------------------------------------------------------
1 | ClassInfo:
2 | Base Class:
3 | Properties:
4 | [Parent]: Element
5 | [PosInLayout]: Point
6 | [SizeInLayout]: Size
7 | [DesiredSize]: Size
8 | [LastDSConst]: Int
9 | [Location]: Point
10 | [Extent]: Size
11 | [LayoutPos]: Int
12 | [Active]: Int
13 | Enum values:
14 | Inactive : 0x0 (0)
15 | Mouse : 0x1 (1)
16 | Keyboard : 0x2 (2)
17 | MouseAndKeyboard : 0x3 (3)
18 | NoSyncFocus : 0x4 (4)
19 | Pointer : 0x8 (8)
20 | [Children]: Ellist
21 | [Layout]: Layout
22 | [BorderThickness]: Rect
23 | [Padding]: Rect
24 | [Margin]: Rect
25 | [Visible]: Bool
26 | [X]: Int
27 | [Y]: Int
28 | [ContentAlign]: Int
29 | Enum values:
30 | TopLeft : 0x0 (0)
31 | TopCenter : 0x1 (1)
32 | TopRight : 0x2 (2)
33 | MiddleLeft : 0x4 (4)
34 | MiddleCenter : 0x5 (5)
35 | MiddleRight : 0x6 (6)
36 | BottomLeft : 0x8 (8)
37 | BottomCenter : 0x9 (9)
38 | BottomRight : 0xa (10)
39 | WrapLeft : 0xc (12)
40 | WrapCenter : 0xd (13)
41 | WrapRight : 0xe (14)
42 | EndEllipsis : 0x10 (16)
43 | FocusRect : 0x20 (32)
44 | PathEllipsis : 0x40 (64)
45 | NoPrefix : 0x80 (128)
46 | WordEllipsis : 0x100 (256)
47 | EditControl : 0x200 (512)
48 | StartEllipsis : 0x400 (1024)
49 | [KeyFocused]: Bool
50 | [KeyWithin]: Bool
51 | [MouseFocused]: Bool
52 | [MouseWithin]: Bool
53 | [Content]: String
54 | [Sheet]: Sheet
55 | [Width]: Int
56 | Enum values:
57 | Auto : 0xffffffff (-1)
58 | [Height]: Int
59 | Enum values:
60 | Auto : 0xffffffff (-1)
61 | [BorderStyle]: Int
62 | Enum values:
63 | Solid : 0x0 (0)
64 | Raised : 0x1 (1)
65 | Sunken : 0x2 (2)
66 | Rounded : 0x3 (3)
67 | [BorderColor]: Int
68 | [Foreground]: Int
69 | [Background]: Int
70 | [FontFace]: String
71 | [FontSize]: Int
72 | [FontWeight]: Int
73 | Enum values:
74 | DontCare : 0x0 (0)
75 | Thin : 0x64 (100)
76 | ExtraLight : 0xc8 (200)
77 | Light : 0x12c (300)
78 | SemiLight : 0x15e (350)
79 | Normal : 0x190 (400)
80 | Medium : 0x1f4 (500)
81 | SemiBold : 0x258 (600)
82 | Bold : 0x2bc (700)
83 | ExtraBold : 0x320 (800)
84 | Heavy : 0x384 (900)
85 | [FontStyle]: Int
86 | Enum values:
87 | None : 0x0 (0)
88 | Italic : 0x1 (1)
89 | Underline : 0x2 (2)
90 | StrikeOut : 0x4 (4)
91 | Shadow : 0x8 (8)
92 | [FontQuality]: Int
93 | Enum values:
94 | Default : 0x0 (0)
95 | NonAntialiased : 0x3 (3)
96 | Antialiased : 0x4 (4)
97 | ClearType : 0x5 (5)
98 | ClearType-Natural : 0x6 (6)
99 | [Class]: String
100 | [ID]: Atom
101 | [Selected]: Bool
102 | [Alpha]: Int
103 | [Animation]: Int
104 | Enum values:
105 | None : 0x0 (0)
106 | Linear : 0x1 (1)
107 | Log : 0x2 (2)
108 | Exp : 0x3 (3)
109 | S : 0x4 (4)
110 | DelayShort : 0x10 (16)
111 | DelayMedium : 0x20 (32)
112 | DelayLong : 0x30 (48)
113 | Alpha : 0x100 (256)
114 | Position : 0x1000 (4096)
115 | Size : 0x2000 (8192)
116 | SizeH : 0x3000 (12288)
117 | SizeV : 0x4000 (16384)
118 | Rectangle : 0x5000 (20480)
119 | RectangleH : 0x6000 (24576)
120 | RectangleV : 0x7000 (28672)
121 | Reverse : 0x1000000 (16777216)
122 | Scale : 0x10000 (65536)
123 | VeryFast : 0x10000000 (268435456)
124 | Fast : 0x20000000 (536870912)
125 | MediumFast : 0x30000000 (805306368)
126 | MediumSlow : 0x50000000 (1342177280)
127 | Medium : 0x40000000 (1073741824)
128 | MediumSlow : 0x50000000 (1342177280)
129 | Slow : 0x60000000 (1610612736)
130 | VerySlow : 0x70000000 (1879048192)
131 | [Cursor]: Int
132 | Enum values:
133 | Arrow : 0x0 (0)
134 | Hand : 0x1 (1)
135 | Help : 0x2 (2)
136 | No : 0x3 (3)
137 | Wait : 0x4 (4)
138 | SizeAll : 0x5 (5)
139 | SizeNESW : 0x6 (6)
140 | SizeNS : 0x7 (7)
141 | SizeNWSE : 0x8 (8)
142 | SizeWE : 0x9 (9)
143 | IBeam : 0xa (10)
144 | [Direction]: Int
145 | Enum values:
146 | LTR : 0x0 (0)
147 | RTL : 0x1 (1)
148 | [Accessible]: Bool
149 | [AccRole]: Int
150 | Enum values:
151 | TitleBar : 0x1 (1)
152 | MenuBar : 0x2 (2)
153 | ScrollBar : 0x3 (3)
154 | Grip : 0x4 (4)
155 | Sound : 0x5 (5)
156 | Cursor : 0x6 (6)
157 | Caret : 0x7 (7)
158 | Alert : 0x8 (8)
159 | Window : 0x9 (9)
160 | Client : 0xa (10)
161 | MenuPopup : 0xb (11)
162 | MenuItem : 0xc (12)
163 | Tooltip : 0xd (13)
164 | Application : 0xe (14)
165 | Document : 0xf (15)
166 | Pane : 0x10 (16)
167 | Chart : 0x11 (17)
168 | Dialog : 0x12 (18)
169 | Border : 0x13 (19)
170 | Grouping : 0x14 (20)
171 | Separator : 0x15 (21)
172 | Toolbar : 0x16 (22)
173 | Statusbar : 0x17 (23)
174 | Table : 0x18 (24)
175 | ColumnHeader : 0x19 (25)
176 | RowHeader : 0x1a (26)
177 | Column : 0x1b (27)
178 | Row : 0x1c (28)
179 | Cell : 0x1d (29)
180 | Link : 0x1e (30)
181 | HelpBalloon : 0x1f (31)
182 | Character : 0x20 (32)
183 | List : 0x21 (33)
184 | ListItem : 0x22 (34)
185 | Outline : 0x23 (35)
186 | OutlineItem : 0x24 (36)
187 | PageTab : 0x25 (37)
188 | PropertyPage : 0x26 (38)
189 | Indicator : 0x27 (39)
190 | Graphic : 0x28 (40)
191 | StaticText : 0x29 (41)
192 | Text : 0x2a (42)
193 | PushButton : 0x2b (43)
194 | CheckButton : 0x2c (44)
195 | RadioButton : 0x2d (45)
196 | ComboBox : 0x2e (46)
197 | DropList : 0x2f (47)
198 | ProgressBar : 0x30 (48)
199 | Dial : 0x31 (49)
200 | HotKeyField : 0x32 (50)
201 | Slider : 0x33 (51)
202 | SpinButton : 0x34 (52)
203 | Diagram : 0x35 (53)
204 | Animation : 0x36 (54)
205 | Equation : 0x37 (55)
206 | ButtonDropDown : 0x38 (56)
207 | ButtonMenu : 0x39 (57)
208 | ButtonDropDownGrid : 0x3a (58)
209 | Whitespace : 0x3b (59)
210 | PageTabList : 0x3c (60)
211 | Clock : 0x3d (61)
212 | SplitButton : 0x3e (62)
213 | IpAddress : 0x3f (63)
214 | OutlineButton : 0x40 (64)
215 | [AccState]: Int
216 | [AccName]: String
217 | [AccDesc]: String
218 | [AccValue]: String
219 | [AccDefAction]: String
220 | [AccHelp]: String
221 | [AccItemType]: String
222 | [AccItemStatus]: String
223 | [Shortcut]: Int
224 | Enum values:
225 | Auto : 0xffffffff (-1)
226 | None : 0x0 (0)
227 | [Enabled]: Bool
228 | [MinSize]: Size
229 | [Overhang]: Bool
230 | [Tooltip]: Bool
231 | [TooltipMaxWidth]: Int
232 | [Font]: String
233 | [WindowActive]: Bool
234 | [AbsorbsShortcut]: Bool
235 | [CompositedText]: Bool
236 | [TextGlowSize]: Int
237 | [HighDPI]: Bool
238 | [DPI]: Int
239 | [Custom]: Bool
240 | [ShadowIntensity]: Int
241 | [EdgeHighlightThickness]: Rect
242 | [EdgeHighlightColor]: Int
243 | [ScaleFactor]: Int
244 | Enum values:
245 | Scale_100 : 0x64 (100)
246 | Scale_140 : 0x8c (140)
247 | Scale_180 : 0xb4 (180)
248 | [UsesDesktopPerMonitorScaling]: Bool
249 |
--------------------------------------------------------------------------------