]>
Commit | Line | Data |
---|---|---|
499b2ed8 JS |
1 | % |
2 | % automatically generated by HelpGen $Revision$ from | |
3 | % gcupdatesmgr.h at 05/Jan/02 22:50:57 | |
4 | % | |
5 | ||
6 | ||
7 | \section{\class{cbGCUpdatesMgr}}\label{cbgcupdatesmgr} | |
8 | ||
9 | ||
10 | class implements optimized logic for refreshing | |
11 | areas of frame layout - which actually need to be updated. | |
12 | Is used as default updates-manager by wxFrameLayout. | |
13 | ||
14 | it is called "Garbage Collecting" u.mgr for it's implementation | |
15 | tries to find out dependencies between bars, and to order | |
16 | them ito "hierarchy", this hierarchical sorting resembles | |
17 | implemenation of heap-garbage collectors, which resolve | |
18 | dependencies between references. | |
19 | ||
20 | Example: there are situations where the order of moving | |
21 | the windows does matter: | |
22 | ||
23 | case 1) | |
24 | ------ --- | |
25 | | A | |B| | |
26 | ------ ---> | | | |
27 | --- --- ------ | |
28 | |B| | A | | |
29 | | | ------ | |
30 | --- | |
31 | (future) | |
32 | (past) | |
33 | ||
34 | past/future positions of A and B windows completely overlapp, i.e. | |
35 | depend on each other, and there is not solution for | |
36 | moving the windows witout refreshing both of them, | |
37 | -- we have cyclic dependency here. The gc. alg will | |
38 | find this cyclic dependecy and will force "refresh" | |
39 | after movement. | |
40 | ||
41 | case 2) | |
42 | ||
43 | ------ | |
44 | | A | | |
45 | ------ ---> | |
46 | --- | |
47 | |B| ------ | |
48 | | | | A | | |
49 | --- ------ | |
50 | --- | |
51 | |B| | |
52 | | | | |
53 | --- | |
54 | ||
55 | (future) | |
56 | (past) | |
57 | ||
58 | in this case past/future positions do not overlapp, thus | |
59 | it's enough only to move windows, without refreshing them. | |
60 | GC will "notice" it. | |
61 | ||
62 | there is also third case, when overlapping is partial | |
63 | in this case the refershing can be also avoided by | |
64 | moving windows in the order of "most-dependant" towards the | |
65 | "least-dependent". GC handles this automatically, by | |
66 | sorting windows by their dependency-level (or "hierarchy") | |
67 | ||
68 | See garbagec.h for more details of this method, garbagec.h/cpp | |
69 | implement sorting of generic-dependencies (does not deal | |
70 | with graphical objects directly) | |
71 | ||
72 | Summary: improves performance when complex/large windows are | |
73 | moved around, by reducing number of repaints. Also helps | |
74 | to avoid dirty non-client areas of moved windows | |
75 | in some special cases of "overlapping anomalies" | |
76 | ||
77 | \wxheading{Derived from} | |
78 | ||
79 | \helpref{cbSimpleUpdatesMgr}{cbsimpleupdatesmgr} | |
80 | ||
81 | \wxheading{Data structures} | |
82 | ||
83 | \latexignore{\rtfignore{\wxheading{Members}}} | |
84 | ||
85 | ||
86 | \membersection{cbGCUpdatesMgr::cbGCUpdatesMgr}\label{cbgcupdatesmgrcbgcupdatesmgr} | |
87 | ||
88 | \func{}{cbGCUpdatesMgr}{\void} | |
89 | ||
90 | ||
91 | \func{}{cbGCUpdatesMgr}{\param{wxFrameLayout* }{pPanel}} | |
92 | ||
93 | ||
94 | \membersection{cbGCUpdatesMgr::AddItem}\label{cbgcupdatesmgradditem} | |
95 | ||
96 | \func{void}{AddItem}{\param{wxList\& }{itemList}, \param{cbBarInfo* }{pBar}, \param{cbDockPane* }{pPane}, \param{wxRect\& }{curBounds}, \param{wxRect\& }{prevBounds}} | |
97 | ||
98 | ||
99 | \membersection{cbGCUpdatesMgr::DoRepositionItems}\label{cbgcupdatesmgrdorepositionitems} | |
100 | ||
101 | \func{void}{DoRepositionItems}{\param{wxList\& }{items}} | |
102 | ||
103 | ||
104 | \membersection{cbGCUpdatesMgr::OnStartChanges}\label{cbgcupdatesmgronstartchanges} | |
105 | ||
106 | \func{void}{OnStartChanges}{\void} | |
107 | ||
108 | notificiactions received from Frame Layout : | |
109 | ||
110 | ||
111 | \membersection{cbGCUpdatesMgr::UpdateNow}\label{cbgcupdatesmgrupdatenow} | |
112 | ||
113 | \func{void}{UpdateNow}{\void} | |
114 | ||
115 | refreshes parts of the frame layout, which need an update | |
116 |