Many, many API updates

git-svn-id: file:///srv/svn/repos/haiku/trunk/current@2176 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
DarkWyrm
2002-12-07 21:39:48 +00:00
parent 9e159bcf9a
commit d5d7a2437a
11 changed files with 580 additions and 161 deletions
@@ -43,7 +43,7 @@ Member Functions</P>
<P class="Body" style="margin: 0px">void AddWorkspace(int32 index=-1)</P>
</TD>
<TD WIDTH=235 HEIGHT=17>
<P class="Body" style="margin: 0px">void Delete Workspace(int32 index)</P>
<P class="Body" style="margin: 0px">void DeleteWorkspace(int32 index)</P>
</TD>
</TR>
<TR>
@@ -113,16 +113,55 @@ Member Functions</P>
<P class="Body" style="margin: 0px"><BR>
1) Set driver pointer to gfxmodule</P>
<P class="Body" style="margin: 0px">2) If driver pointer is non-NULL and driver-&gt;Initialize() is true, set initialized flag to true</P>
<P class="Body" style="margin: 0px">3) If initialized, create and populate workspace list</P>
<P class="Body" style="margin: 0px">4) Clear all workspaces</P>
<P class="Body" style="margin: 0px">3) If initialized, get the appropriate display driver info and save it internally</P>
<P class="Body" style="margin: 0px">4) Create and populate workspace list</P>
<P class="Body" style="margin: 0px">5) Clear all workspaces</P>
<P class="Body" style="margin: 0px"><BR>
~Screen(void)</P>
<P class="Body" style="margin: 0px">void AddWorkspace(int32 index=-1)</P>
<P class="Body" style="margin: 0px">void Delete Workspace(int32 index)</P>
<P class="Body" style="margin: 0px">int32 CountWorkspaces(void)</P>
<P class="Body" style="margin: 0px">void SetWorkspaceCount(int32 count)</P>
<P class="Body" style="margin: 0px">int32 CurrentWorkspace(void)</P>
<P class="Body" style="margin: 0px">void SetWorkspace(int32 workspace)</P>
<span class="OBOS-Function-Def">~Screen(void)</span></P>
<P class="Body" style="margin: 0px"><BR>
1) Remove all workspaces from the list and delete them</P>
<P class="Body" style="margin: 0px">2) Delete the workspace list</P>
<P class="Body" style="margin: 0px"><BR>
<BR>
<span class="OBOS-Function-Def">void AddWorkspace(int32 index=-1)</span></P>
<P class="Body" style="margin: 0px"><BR>
Adds a workspace to the screen object, setting its settings to the default, and adding it to the list in the specified index or the end of the list if the index is -1</P>
<P class="Body" style="margin: 0px"><BR>
1) Create a workspace object</P>
<P class="Body" style="margin: 0px">2) Add it to the workspace list - to the end if the index is -1, and to the particular index if not</P>
<P class="Body" style="margin: 0px"><BR>
<BR>
<span class="OBOS-Function-Def">void DeleteWorkspace(int32 index)</span></P>
<P class="Body" style="margin: 0px"><BR>
Deletes the workspace at the specified index.</P>
<P class="Body" style="margin: 0px"><BR>
1) Remove the item at the specified index and if non-NULL, delete it.</P>
<P class="Body" style="margin: 0px"><BR>
<BR>
<span class="OBOS-Function-Def">int32 CountWorkspaces(void)</span></P>
<P class="Body" style="margin: 0px"><BR>
Returns the number of workspaces kept by the particular Screen objects</P>
<P class="Body" style="margin: 0px"><BR>
1) Return the workspace list's CountItems() value</P>
<P class="Body" style="margin: 0px"><BR>
<BR>
<span class="OBOS-Function-Def">void SetWorkspaceCount(int32 count)</span></P>
<P class="Body" style="margin: 0px"><BR>
Sets the number of workspaces available to <span style="font-style: italic">count</span>. If <span style="font-style: italic">count</span> is less than the number of current workspaces, the last workspaces are deleted first. Workspaces are added to the end of the list. If a delete workspace should include the active workspace, then the workspace with the index <span style="font-style: italic">count-1</span> is activated. There must be at least one workspace.</P>
<P class="Body" style="margin: 0px"><BR>
1) if count equals the workspace list's CountItems value, return</P>
<P class="Body" style="margin: 0px">2) If count is less than 1, set count to 1. If greater than 32, set to 32.</P>
<P class="Body" style="margin: 0px">3) If active workspace index is greater than count-1, call SetWorkspace(count-1)</P>
<P class="Body" style="margin: 0px">4) If count is greater than the workspace list's CountItems value, call AddWorkspace the appropriate number of times.</P>
<P class="Body" style="margin: 0px">5) If count is less than the workspace list's CountItems, call RemoveWorkspace the appropriate number of times</P>
<P class="Body" style="margin: 0px"><BR>
<BR>
<span class="OBOS-Function-Def">int32 CurrentWorkspace(void)</span></P>
<P class="Body" style="margin: 0px"><BR>
Returns the active workspace index</P>
<P class="Body" style="margin: 0px"><BR>
<BR>
void SetWorkspace(int32 workspace)</P>
<P class="Body" style="margin: 0px">void Activate(bool active=true)</P>
<P class="Body" style="margin: 0px">DisplayDriver *GetDriver(void)</P>
<P class="Body" style="margin: 0px">status_t SetSpace(int32 index, int32 res, bool stick=true)</P>
@@ -139,17 +178,17 @@ Member Functions</P>
<P class="Body" style="margin: 0px">Workspace class members</P>
<P class="Body" style="margin: 0px"><BR>
</P>
<TABLE WIDTH=620 HEIGHT=69 BORDER=1 CELLPADDING=1 CELLSPACING=2>
<TABLE WIDTH=610 HEIGHT=150 BORDER=1 CELLPADDING=1 CELLSPACING=2>
<TR>
<TD WIDTH=232 HEIGHT=17>
<P class="Body" style="margin: 0px">Workspace(void)</P>
<TD WIDTH=225 HEIGHT=32>
<P class="Body" style="margin: 0px">Workspace(graphics_card_info *gcinfo, frame_buffer_info *fbinfo)</P>
</TD>
<TD WIDTH=232 HEIGHT=17>
<TD WIDTH=232 HEIGHT=32>
<P class="Body" style="margin: 0px">~Workspace(void)</P>
</TD>
</TR>
<TR>
<TD WIDTH=232 HEIGHT=17>
<TD WIDTH=225 HEIGHT=17>
<P class="Body" style="margin: 0px">void SetBGColor(const RGBColor &amp;c)</P>
</TD>
<TD WIDTH=232 HEIGHT=17>
@@ -157,21 +196,66 @@ Member Functions</P>
</TD>
</TR>
<TR>
<TD WIDTH=232 HEIGHT=17>
<TD WIDTH=225 HEIGHT=32>
<P class="Body" style="margin: 0px">RootLayer *GetRoot(void)</P>
</TD>
<TD WIDTH=232 HEIGHT=17>
<TD WIDTH=232 HEIGHT=32>
<P class="Body" style="margin: 0px">void SetData(graphics_card_info *gcinfo, frame_buffer_info *fbinfo)</P>
</TD>
</TR>
<TR>
<TD WIDTH=225 HEIGHT=32>
<P class="Body" style="margin: 0px">void GetData(graphics_card_info *gcinfo, frame_buffer_info *fbinfo)</P>
</TD>
<TD WIDTH=232 HEIGHT=32>
&nbsp;
</TD>
</TR>
</TABLE>
<P class="Body" style="margin: 0px"><BR>
<BR>
Workspace(void)</P>
<P class="Body" style="margin: 0px">~Workspace(void)</P>
<P class="Body" style="margin: 0px">void SetBGColor(const RGBColor &amp;c)</P>
<P class="Body" style="margin: 0px">RGBColor BGColor(void)</P>
<P class="Body" style="margin: 0px">RootLayer *GetRoot(void)</P>
<BR>
<span class="OBOS-Function-Def">Workspace(void)</span></P>
<P class="Body" style="margin: 0px"><BR>
1) Set background color to RGB(51,102,160)</P>
<P class="Body" style="margin: 0px">2) Copy frame_buffer_info and graphics_card_info structure values</P>
<P class="Body" style="margin: 0px">3) Create a RootLayer object using the values from the two structures</P>
<P class="Body" style="margin: 0px"><BR>
<BR>
<span class="OBOS-Function-Def">~Workspace(void)</span></P>
<P class="Body" style="margin: 0px"><BR>
1) Call the RootLayer object's PruneTree method and delete it</P>
<P class="Body" style="margin: 0px"><BR>
<BR>
<span class="OBOS-Function-Def">void SetBGColor(const RGBColor &amp;c)</span></P>
<P class="Body" style="margin: 0px"><BR>
Sets the particular color for the workspace. Note that this does not refresh the display.</P>
<P class="Body" style="margin: 0px"><BR>
1) Set the internal background RGBColor object to the color parameter</P>
<P class="Body" style="margin: 0px"><BR>
<BR>
<span class="OBOS-Function-Def">RGBColor BGColor(void)</span></P>
<P class="Body" style="margin: 0px"><BR>
Returns the internal background color</P>
<P class="Body" style="margin: 0px"><BR>
<BR>
<span class="OBOS-Function-Def">RootLayer *GetRoot(void)</span></P>
<P class="Body" style="margin: 0px"><BR>
Returns the pointer to the RootLayer object</P>
<P class="Body" style="margin: 0px"><BR>
<BR>
<span class="OBOS-Function-Def">void SetData(graphics_card_info *gcinfo, frame_buffer_info *fbinfo)</span></P>
<P class="Body" style="margin: 0px"><BR>
Changes the graphics data and resizes the RootLayer accordingly.</P>
<P class="Body" style="margin: 0px"><BR>
1) Copy the two structures to the internal one</P>
<P class="Body" style="margin: 0px">2) Resize the RootLayer</P>
<P class="Body" style="margin: 0px">3) If the RootLayer was resized larger, Invalidate the new areas</P>
<P class="Body" style="margin: 0px"><BR>
<BR>
<span class="OBOS-Function-Def">void GetData(graphics_card_info *gcinfo, frame_buffer_info *fbinfo)</span></P>
<P class="Body" style="margin: 0px"><BR>
Copies the two data structures into the parameters passed.</P>
<P class="Body" style="margin: 0px"><BR>
<HR>
</P>