SkinProgress.cpp
资源名称:MiniCA2.rar [点击查看]
上传用户:dengkfang
上传日期:2008-12-30
资源大小:5233k
文件大小:240k
源码类别:
CA认证
开发平台:
Visual C++
- /******************************************************************************/
- /* NAME : SkinProgress.cpp */
- /* PURPOSE : Place a bitmapped progress bar into the status bar */
- /* CREATED_BY : Kochise (kochise@caramail.com) */
- /* CREATION_DATE : $C_DATE=YYYY/MM/DD$ 22003/05/02 */
- /* MODIFIED_BY : Kochise (kochise@caramail.com) */
- /* MODIFICATION_DATE : $M_DATE=YYYY/MM/DD$ 2003/07/12 */
- /* LANGUAGE : MFC Visual C++ 6 */
- /* MPROC_TYPE : Microsoft Windows compatible computer */
- /* */
- /*
- $Log: E:ProjectsNoeZooArcSkinProgressTest.zooSkinProgressTestSkinProgress.cpp.adiff $
- *
- * Rev 1.02 : July 12 2003 14:01:53 (Kochise)
- * Base : CSkinProgress 1.32dev
- * extracting files : no error
- * parsing files : no error
- * diff engine : no error
- * modify.public.constructor:CSkinProgress
- * touch.protected.function:CreateCommon
- * modify.protected.function:ProgressInStatusBar
- * modify.protected.function:ProgressInDialog
- * modify.public.function:SetRange
- * touch.public.function:SetPos
- * modify.public.function:GetPos
- * touch.public.function:SetStart
- * modify.public.function:GetStart
- * modify.public.function:Reset
- * add.public.function:SetProgress
- * add.public.function:GetProgress
- * modify.public.function:RefreshPanes
- * touch.protected.function:CompactText
- * modify.protected.function:GetTimed
- * modify.protected.function:UpdateProgress
- * modify.protected.function:OnPaint
- * compiling project files : no error
- * packing files : no error
- * http://www.codeproject.com/miscctrl/CSkinProgress.asp
- *
- * Rev 1.01 : July 06 2003 22:08:37 (Kochise)
- * Base : CSkinProgress 1.28 Devel
- * extracting files : no error
- * parsing files : no error
- * diff engine : no error
- * modify.public.constructor:CSkinProgress
- * add.public.constructor:CSkinProgress
- * modify.public.function:SetBitmap
- * modify.public.function:ConvBitmap
- * modify.public.function:SetRange
- * modify.public.function:SetPos
- * modify.public.function:OffsetPos
- * modify.public.function:StepIt
- * modify.public.function:SetSize
- * add.public.function:GetSize
- * add.public.function:GetPos
- * add.public.function:GetStep
- * add.public.function:GetLower
- * add.public.function:GetUpper
- * add.public.function:SetStart
- * add.public.function:GetStart
- * add.public.function:Reset
- * modify.public.function:SetText
- * mutate.function:protected.ResizeTextPane->public.RefreshPanes
- * modify.public.function:RefreshPanes
- * mutate.function:public.Clear->protected.Clear
- * add.protected.function:GetTargetRect
- * mutate.protected.function:Create->CreateCommon
- * modify.protected.function:CreateCommon
- * add.protected.function:ProgressInStatusBar
- * add.protected.function:ProgressInDialog
- * modify.protected.function:CompactText
- * add.protected.function:UpdateProgress
- * modify.protected.function:OnPaint
- * compiling project files : no error
- * packing files : no error
- * http://www.codeproject.com/miscctrl/CSkinProgress.asp
- *
- * Rev 1.00 : May 25 2003 13:25:12 (Kochise)
- * First archived version and released onto CodeProject.
- * Base : CSkinProgress 1.12 Devel
- * add.public.constructor:CSkinProgress
- * add.public.constructor:CSkinProgress
- * add.public.function:SetRange
- * add.public.function:SetText
- * add.public.function:SetSize
- * add.public.function:SetBitmap
- * add.public.function:CopyBitmap
- * add.public.function:ConvBitmap
- * add.public.function:SetPos
- * add.public.function:OffsetPos
- * add.public.function:SetStep
- * add.public.function:StepIt
- * add.public.function:Clear
- * add.public.destructor:~CSkinProgress
- * add.protected.function:Create
- * add.protected.function:GetStatusBar
- * add.protected.function:ResizeTextPane
- * add.protected.function:CompactText
- * add.protected.function:GetTimed
- * add.protected.function:OnEraseBkgnd
- * add.protected.function:OnPaint
- * add.protected.function:OnSizing
- * add.protected.function:OnSize
- * add.protected.function:OnTimer
- * compiling project files : no error
- * packing files : no error
- * http://www.codeproject.com/useritems/CSkinProgress.asp
- *
- */
- /******************************************************************************/
- // SkinProgress.cpp : implementation file
- //
- #include "stdafx.h"
- #include "SkinProgress.h"
- #ifdef _DEBUG
- #define new DEBUG_NEW
- #undef THIS_FILE
- static char THIS_FILE[] = __FILE__;
- #endif
- /////////////////////////////////////////////////////////////////////////////
- // CSkinProgress
- // g_Global : g_ = Global
- // i_Input : i_ = Input
- // no z...
- // m_Member : m_ = Member
- // o_Output : o_ = Output
- // ... : use your imagination
- // aArray : a = Array (array)
- // bBool : b = Boolean (boolean, true/false)
- // cConstant : c = Constant (constant, whatever...)
- // dDefine : d = Define (simple define or defined value)
- // nNumber : n = Number (char, long, int, whatever...)
- // oObject : o = Object (C++ class)
- // pPointer : p = Pointer (typicaly a 32 bits ulong address)
- // sStruct : s = Struct (structure)
- // uUnion : u = Union (join two or more values of the same size under a common name)
- // poRemoteClass : po = Pointer on Object
- // cdConstantDef : cd = Constant Define, typicaly a constant defined value
- // usUnionStruct : us = Union of Structures
- // ... : use your imagination
- // o_psBitmap : CBitmap::GetBitmap((BITMAP*) o_psBitmap); // s = BITMAP, p = *, o_ means it's an output
- // <Value>
- // [Function]
- // TYPICAL LIFE TIME
- //
- // CSkinProgress(...) -------> StepIt() ----------------------------> ~CSkinProgress() USER
- // | | | SIDE
- // ..|...........................|.......................................|.........................
- // | | |
- // '-> Create(...) | '-> Clear() OBJECT
- // | | SIDE
- // +-> GetStatusBar() |
- // +-> SetRange(...) |
- // +-> SetBitmap(...) '----------->
- // '---------------------------------> RefreshPanes() --------,
- // ,---------------------------------> | |
- // | ,-> | |
- // | | | |
- // | | +-> GetStatusBar() |
- // | | +-> GetTimed(...) |
- // | | '-> CompactText(...) |
- // ........|...............................|..........................|............................
- // | | | WINDOWS
- // OnSizing(...) -> OnSize(...) OnEraseBkgnd(...) '-> OnPaint() SIDE
- #ifndef dCSP_RESOURCE_BITMAP
- /*** anAQUA_BITMAP ************************************************************/
- /* Purpose : The default embedded progress bar image, if resource bitmap not */
- /* used instead. */
- /* Unit : unsigned char */
- /* Range : [0-255] - LIMITED selection */
- /* List : None */
- /* Example : None */
- /******************************************************************************/
- unsigned char anAQUA_BITMAP[5760] =
- { // B, G, R, A -> Set to 0xFF for CAlphaBlendBitmap
- 0xBD, 0xBD, 0xBD, 0xFF, 0xBD, 0xBD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97, 0xFF,
- 0xFF, 0xDE, 0x97, 0xFF, 0xFF, 0xDE, 0x97, 0xFF, 0xFF, 0xDE, 0x97, 0xFF, 0xFF, 0xDE, 0x97, 0xFF,
- 0xFF, 0xDE, 0x97, 0xFF, 0xFF, 0xDE, 0x97, 0xFF, 0xFF, 0xDE, 0x97, 0xFF, 0xFF, 0xDE, 0x97, 0xFF,
- 0xFF, 0xCD, 0x8D, 0xFF, 0xFF, 0xC4, 0x7C, 0xFF, 0xFE, 0xB2, 0x6D, 0xFF, 0xF1, 0xA0, 0x57, 0xFF,
- 0xE3, 0x8C, 0x42, 0xFF, 0xD4, 0x80, 0x38, 0xFF, 0x9E, 0x63, 0x33, 0xFF, 0x66, 0x5C, 0x54, 0xFF,
- 0xA5, 0xA5, 0xA5, 0xFF, 0xED, 0xED, 0xED, 0xFF, 0xED, 0xED, 0xED, 0xFF, 0xED, 0xED, 0xED, 0xFF,
- 0xED, 0xED, 0xED, 0xFF, 0xED, 0xED, 0xED, 0xFF, 0xED, 0xED, 0xED, 0xFF, 0xED, 0xED, 0xED, 0xFF,
- 0xED, 0xED, 0xED, 0xFF, 0xED, 0xED, 0xED, 0xFF, 0xED, 0xED, 0xED, 0xFF, 0xED, 0xED, 0xED, 0xFF,
- 0xED, 0xED, 0xED, 0xFF, 0xED, 0xED, 0xED, 0xFF, 0xED, 0xED, 0xED, 0xFF, 0xED, 0xED, 0xED, 0xFF,
- 0xED, 0xED, 0xED, 0xFF, 0xED, 0xED, 0xED, 0xFF, 0xED, 0xED, 0xED, 0xFF, 0xED, 0xED, 0xED, 0xFF,
- 0xED, 0xED, 0xED, 0xFF, 0xED, 0xED, 0xED, 0xFF, 0xED, 0xED, 0xED, 0xFF, 0xED, 0xED, 0xED, 0xFF,
- 0xED, 0xED, 0xED, 0xFF, 0xED, 0xED, 0xED, 0xFF, 0xED, 0xED, 0xED, 0xFF, 0xED, 0xED, 0xED, 0xFF,
- 0xED, 0xED, 0xED, 0xFF, 0xED, 0xED, 0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4, 0xE4, 0xE4, 0xFF, 0xE4, 0xE4, 0xE4, 0xFF, 0xE4, 0xE4, 0xE4, 0xFF, 0xE4, 0xE4, 0xE4, 0xFF,
- 0xE4, 0xE4, 0xE4, 0xFF, 0xE4, 0xE4, 0xE4, 0xFF, 0xE4, 0xE4, 0xE4, 0xFF, 0xE4, 0xE4, 0xE4, 0xFF,
- 0xE4, 0xE4, 0xE4, 0xFF, 0xE4, 0xE4, 0xE4, 0xFF, 0xE4, 0xE4, 0xE4, 0xFF, 0xE4, 0xE4, 0xE4, 0xFF,
- };
- /*** sAQUA_BITMAP *************************************************************/
- /* Purpose : anAQUA_BITMAP's image header for CBitmap::CreateBitmapIndirect */
- /* Unit : BITMAP */
- /* Range : structure list */
- /* List : 0 - int bmType : bitmap type (0) */
- /* 1 - int bmWidth : width in pixels (>0) */
- /* 2 - int bmHeight : height in pixels (>0) */
- /* 3 - int bmWidthBytes ; number of bytes per line (%2) */
- /* 4 - unsigned char bmPlanes ; number of color planes */
- /* 5 - unsigned char bmBitsPixel : number of bits per pixel */
- /* 6 - unsigned char* bmBits : pointer to an array of shorts */
- /* Example : None */
- /* WARNING : I said SHORT for <bmBits> because the number of bytes must be */
- /* divible by 2 ! But in facts, it can be bytes, longs, whatever, */
- /* as long as the size of the array remains divisible by 2... */
- /******************************************************************************/
- BITMAP sAQUA_BITMAP =
- {
- 0, // bmType
- 90, // bmWidth
- 16, // bmHeight
- 360, // bmWidthBytes
- 1, // bmPlanes
- 32, // bmBitsPixel
- anAQUA_BITMAP // bmBits
- };
- #endif // dCSP_RESOURCE_BITMAP
- /*** anThreeDots **************************************************************/
- /* Purpose : dots for reduced string */
- /* Unit : char */
- /* Range : [0-127] - LIMITED selection */
- /* List : None */
- /* Example : None */
- /******************************************************************************/
- const char anThreeDots[] = "...";
- // *** CONSTRUCTORS ***
- /*--- START FUNCTION HEADER --------------------------------------------------*/
- /* Name : CSkinProgress */
- /* Role : Default constructor for status bar usage */
- /* Type : public */
- /* Interface : RETURN (direct value) */
- /* None */
- /* OUTPUT (pointer to value) */
- /* None */
- /* INPUT (pointer to value, direct/default value) */
- /* None */
- /* Pre-condition : None */
- /* Constraints : Sets the default values to */
- /* i_poStrMessage = "Work in progress..." */
- /* i_nUpper = 100 - from 0 to 100 */
- /* i_nProgress = cSPT_PERCENT - DISPLAY PERCENT */
- /* i_nPane = 0 - Share the text pane */
- /* i_nSize = 200 - 200 pixels FORCED WIDTH */
- /* i_poBitmap = NULL - USE EMBEDDED BITMAP */
- /* <> i_bReverse = false - normal display */
- /* Behavior : A - Create the progress bar using default parameters */
- /*----------------------------------------------------------------------------*/
- /* PROC CSkinProgress */
- /* */
- /* A..... Create a status progress bar with "Work in progress..." as text */
- /*----------------------------------------------------------------------------*/
- /*--- END FUNCTION HEADER ----------------------------------------------------*/
- CSkinProgress::CSkinProgress
- ( // Default constructor
- )
- {
- // Init
- // Process
- // A..... Create a default progress bar in Status Bar with "Work in progress..." as text
- ProgressInStatusBar("Work in progress");
- }
- /*--- START FUNCTION HEADER --------------------------------------------------*/
- /* Name : CSkinProgress */
- /* Role : Default constructor with parameters for status bar usage */
- /* Type : public */
- /* Interface : RETURN (pointer to value, direct value) */
- /* None */
- /* OUTPUT (pointer to value) */
- /* None */
- /* INPUT (pointer to value, direct/default value) */
- /* i_poStrMessage : The text message to display in pane 0 */
- /* i_nUpper : Upper limit to reach 100% (0 at 0%) */
- /* i_nProgress : Progress completion message type */
- /* i_nPane : Pane number for the progress bar */
- /* i_nSize : Progress bar width in pixel IF pane 0 */
- /* i_poBitmap : Replacement progress bar bitmap */
- /* <> i_bReverse : Reverse display of the progress bar */
- /* Pre-condition : None */
- /* Constraints : At least, <i_poStrMessage> must be provided */
- /* Behavior : A - Create the progress bar using user's parameters */
- /*----------------------------------------------------------------------------*/
- /* PROC CSkinProgress */
- /* */
- /* A..... Create the progress bar using user's parameters */
- /*----------------------------------------------------------------------------*/
- /*--- END FUNCTION HEADER ----------------------------------------------------*/
- CSkinProgress::CSkinProgress
- ( // Default constructor with parameters for status bar usage
- LPCTSTR i_poStrMessage, // Text to display
- int i_nUpper, // = 100 : Default range from 0 to i_nUpper
- int i_nProgress, // = cSPT_PERCENT : Message type to add to the text
- int i_nPane, // = 0 : Pane number in which display the progress bar
- int i_nSize, // = 200 : Size of the progress bar if in pane 0
- CBitmap* i_poBitmap // = NULL : Pointer to a user bitmap
- #ifdef dCSP_SLIDERBAR_METHOD
- ,BOOL i_bReverse // = false : Reverse display of the progress bar
- #endif // dCSP_SLIDERBAR_METHOD
- )
- {
- // Init
- // Process
- // A..... Create the progress bar using user's parameters
- ProgressInStatusBar
- (
- i_poStrMessage,
- i_nUpper,
- i_nProgress,
- i_nPane,
- i_nSize,
- i_poBitmap
- #ifdef dCSP_SLIDERBAR_METHOD
- ,i_bReverse
- #endif // dCSP_SLIDERBAR_METHOD
- );
- }
- /*--- START FUNCTION HEADER --------------------------------------------------*/
- /* Name : CSkinProgress */
- /* Role : Default constructor with parameters for dialog usage */
- /* Type : public */
- /* Interface : RETURN (direct value) */
- /* None */
- /* OUTPUT (pointer to value) */
- /* None */
- /* INPUT (pointer to value, direct/default value) */
- /* i_poWndProgress : The CWnd where to display the progress */
- /* i_nUpper : Upper limit to reach 100% (0 at 0%) */
- /* i_poBitmap : Replacement progress bar bitmap */
- /* <> i_bReverse : Reverse display of the progress bar */
- /* i_poWndMessage : The CWnd where to display the text */
- /* i_poStrMessage : The text message to display */
- /* i_nProgress : Progress completion message type */
- /* Pre-condition : None */
- /* Constraints : At least, <i_poStrMessage> must be provided */
- /* Behavior : A - Create the dialog progress bar using user's parameters */
- /*----------------------------------------------------------------------------*/
- /* PROC CSkinProgress */
- /* */
- /* A..... Create the dialog progress bar using user's parameters */
- /*----------------------------------------------------------------------------*/
- /* The most simple dialog CSkinProgress constructor : */
- /* CSkinProgress oCspBar(&oCStatic); // Use 100 as upper limit */
- /*--- END FUNCTION HEADER ----------------------------------------------------*/
- #ifdef dCSP_DIALOG_PROGRESS
- CSkinProgress::CSkinProgress
- ( // Default constructor with parameters for dialog usage
- CWnd* i_poWndProgress, // Pointer to the anchor CWnd to use for the progress bar
- int i_nUpper, // = 100, : Default range from 0 to i_nUpper
- CBitmap* i_poBitmap, // = NULL : Pointer to a user bitmap
- #ifdef dCSP_SLIDERBAR_METHOD
- BOOL i_bReverse, // = false, : Reverse display of the progress bar
- #endif // dCSP_SLIDERBAR_METHOD
- CWnd* i_poWndMessage, // = NULL, : Pointer to the anchor CWnd to use for the text pane
- LPCTSTR i_poStrMessage, // = NULL : Text to display,
- int i_nProgress // = cSPT_NONE : Message type to add to the text
- )
- {
- // Init
- // Process
- // A..... Create the progress bar using user's parameters
- ProgressInDialog
- (
- i_poWndProgress,
- i_nUpper,
- i_poBitmap,
- #ifdef dCSP_SLIDERBAR_METHOD
- i_bReverse,
- #endif // dCSP_SLIDERBAR_METHOD
- i_poWndMessage,
- i_poStrMessage,
- i_nProgress
- );
- }
- #endif // dCSP_DIALOG_PROGRESS
- // *** INITIALIZATORS ***
- /*--- START FUNCTION HEADER --------------------------------------------------*/
- /* Name : CreateCommon */
- /* Role : Initialize the progress with its basic parameters */
- /* Type : PROTECTED */
- /* Interface : RETURN (direct value) */
- /* BOOL = false : Error during progress bar creation */
- /* true : Progress bar created */
- /* OUTPUT (pointer to value) */
- /* None */
- /* INPUT (pointer to value, direct/default value) */
- /* i_poStrMessage : The text message to display in pane 0 */
- /* i_nUpper : Upper limit to reach 100% (0 at 0%) */
- /* i_nProgress : Progress completion message type */
- /* i_poBitmap : Replacement progress bar bitmap */
- /* <> i_bReverse : Reverse display of the progress bar */
- /* Pre-condition : None */
- /* Constraints : Base of progress bar is fixed to 0, must use */
- /* [SetRange(...)] to change it... */
- /* Behavior : A - Set base values */
- /* B - Set the bitmap */
- /* C - Set the progress bar values */
- /* D - Get the creation date and time of the progress bar */
- /* E - Set the refresh timer */
- /* F - Resize the text and display the whole things */
- /*----------------------------------------------------------------------------*/
- /* PROC CreateCommon */
- /* */
- /* A..... Set base values */
- /* B..... Set the bitmap */
- /* C..... Set the progress bar values */
- /* D..... Get the creation date and time of the progress bar */
- /* E..... Set the refresh timer to 500 milliseconds */
- /* F..... Resize the text and display the whole things */
- /*----------------------------------------------------------------------------*/
- /*--- END FUNCTION HEADER ----------------------------------------------------*/
- BOOL CSkinProgress::CreateCommon
- (
- LPCTSTR i_poStrMessage,
- int i_nUpper, // = 100
- int i_nProgress, // = cSPT_PERCENT
- CBitmap* i_poBitmap // = NULL
- #ifdef dCSP_SLIDERBAR_METHOD
- ,BOOL i_bReverse // = false
- #endif // dCSP_SLIDERBAR_METHOD
- )
- {
- // Init
- // A..... Set base values
- m_poBaseBmp = NULL;
- m_poCompatibleBmp = NULL;
- m_poStretchBmp = NULL;
- m_poProgressBmp = NULL;
- m_oStrPrevMessage = "";
- m_oRectPane.SetRect(0, 0, 0, 0);
- // Process + Return
- // B..... Set the bitmap
- if(
- !SetBitmap
- (
- i_poBitmap
- #ifndef dCSP_TIMED_REDRAW
- ,false
- #endif // dCSP_TIMED_REDRAW
- )
- )
- {
- return false;
- }
- else
- {
- // C..... Set the progress bar values
- // Set the progress text type
- m_nProgressText = i_nProgress;
- // Set range and step
- m_nLower = 0; // Set first parameters for the resampling
- ASSERT(i_nUpper > 0); // m_nLower is 0, m_nUpper CANNOT BE BEFORE m_nLower quite now
- m_nUpper = i_nUpper;
- #ifdef dCSP_SLIDERBAR_METHOD
- m_nLeft = 0;
- #endif // dCSP_SLIDERBAR_METHOD
- m_nRight = 0;
- SetRange
- (
- 0,
- i_nUpper,
- 1,
- false
- #ifndef dCSP_TIMED_REDRAW
- ,false // Don't resample range, and avoid display there !
- #endif // dCSP_TIMED_REDRAW
- );
- // Set and save additional values
- m_oStrMessage = i_poStrMessage;
- #ifdef dCSP_SLIDERBAR_METHOD
- m_bReverse = i_bReverse;
- #endif // dCSP_SLIDERBAR_METHOD
- // D..... Get the creation date and time of the progress bar and set its position to the beginning
- Reset
- (
- #ifndef dCSP_TIMED_REDRAW
- false
- #endif // dCSP_TIMED_REDRAW
- );
- // E..... Set the refresh timer to 500 milliseconds (or 20ms/50Hz in <dCSP_TIMED_REDRAW> mode)
- #ifndef dCSP_TIMED_REDRAW
- SetTimer((UINT) this, 500, NULL); // Use object's unique address as timer identifier
- #else
- SetTimer((UINT) this, 20, NULL); // Use object's unique address as timer identifier
- #endif // dCSP_TIMED_REDRAW
- // F..... Resize the text and display the whole things
- RefreshPanes(); // Set the text in pane 0 and do the first drawing of the SkinProgress bar
- return true;
- }
- }
- /*--- START FUNCTION HEADER --------------------------------------------------*/
- /* Name : ProgressInStatusBar */
- /* Role : Create the progress in status bar with basic parameters */
- /* Type : PROTECTED */
- /* Interface : RETURN (direct value) */
- /* BOOL = false : Error during progress bar creation */
- /* true : Progress bar created */
- /* OUTPUT (pointer to value) */
- /* None */
- /* INPUT (pointer to value, direct/default value) */
- /* i_poStrMessage : The text message to display in pane 0 */
- /* i_nUpper : Upper limit to reach 100% (0 at 0%) */
- /* i_nProgress : Progress completion message type */
- /* i_nPane : Pane number for the progress bar */
- /* i_nSize : Progress bar width in pixel IF pane 0 */
- /* i_poBitmap : Replacement progress bar bitmap */
- /* <> i_bReverse : Reverse display of the progress bar */
- /* Pre-condition : None */
- /* Constraints : Base of progress bar is fixed to 0, must use [SetRange] to */
- /* change it... */
- /* Behavior : A - Get status bar handler */
- /* B - Create a CStatic object upon the target pane */
- /* C - Specific Status Bar initialization */
- /* D - Create and initialize the progress bar */
- /*----------------------------------------------------------------------------*/
- /* PROC ProgressInStatusBar */
- /* */
- /* A..... Get status bar handler */
- /* [IF there is a status bar] */
- /* : B..... Create a CStatic object upon the target status bar pane */
- /* : [IF CStatic creation OK] */
- /* : : C..... Specific Status Bar initialization */
- /* : : D..... Create and initialize the progress bar */
- /* : [ENDIF] */
- /* [ENDIF] */
- /*----------------------------------------------------------------------------*/
- /*--- END FUNCTION HEADER ----------------------------------------------------*/
- BOOL CSkinProgress::ProgressInStatusBar
- ( // The initialization routine
- LPCTSTR i_poStrMessage, // Text to display
- int i_nUpper, // = 100, : Default range from 0 to i_nUpper
- int i_nProgress, // = cSPT_PERCENT : Message type to add to the text
- int i_nPane, // = 0, : Pane number in which display the progress bar
- int i_nSize, // = 200, : Size of the progress bar if in pane 0
- CBitmap* i_poBitmap // = NULL : Pointer to a user bitmap
- #ifdef dCSP_SLIDERBAR_METHOD
- ,BOOL i_bReverse // = false
- #endif // dCSP_SLIDERBAR_METHOD
- )
- {
- BOOL bSuccess;
- CStatusBar* poStatusBar;
- DWORD nStyleEx;
- DWORD nStyle;
- CRect oRectPane;
- LPCSTR poStrClass;
- UINT nClassStyle;
- // Init
- bSuccess = false;
- #ifdef dCSP_DIALOG_PROGRESS
- m_poWndProgress = NULL;
- m_poWndMessage = NULL;
- #endif // dCSP_DIALOG_PROGRESS
- // Process
- // A..... Get status bar handler
- poStatusBar = GetStatusBar();
- if(poStatusBar != NULL)
- {
- // B..... Create a CStatic object upon the target status bar pane
- // Set the style for the custom progress bas
- nClassStyle = 0; // CS_CLASSDC | CS_HREDRAW | CS_VREDRAW;
- nStyleEx = WS_EX_STATICEDGE;
- nStyle = WS_CHILD | WS_VISIBLE | SS_BITMAP | SS_CENTERIMAGE;
- // Get CRect coordinates for requested status bar pane
- poStatusBar->GetItemRect(i_nPane, &oRectPane);
- // Create the progress bar
- poStrClass = AfxRegisterWndClass(nClassStyle, AfxGetApp()->LoadStandardCursor(IDC_WAIT));
- bSuccess = CStatic::CreateEx(nStyleEx, poStrClass, "", nStyle, oRectPane, poStatusBar, (UINT) this); // Use object's unique address as child window identifier
- ASSERT(bSuccess);
- if(!bSuccess)
- {
- return false;
- }
- else
- {
- #ifdef dCSP_VERTICAL_BAR
- #ifndef dCSP_DISPLAY_STRETCH
- m_bVertical = false; // *ALWAYS false IN CSkinProgress while in StatusBar mode*
- #else
- m_bVertical = true; // *FORCE* vertical for m_poStretchBmp analysis
- #endif // dCSP_DISPLAY_STRETCH
- #endif // dCSP_VERTICAL_BAR
- // C..... Specific Status Bar initialization
- SetSize
- (
- i_nSize
- #ifndef dCSP_TIMED_REDRAW
- ,false // Set the size, and avoid display there !
- #endif // dCSP_TIMED_REDRAW
- );
- m_nPane = i_nPane;
- m_oStrPrevText = poStatusBar->GetPaneText(m_nPane); // Get the previous pane's text
- // D..... Create and initialize the progress bar
- bSuccess = CreateCommon
- (
- i_poStrMessage,
- i_nUpper,
- i_nProgress,
- i_poBitmap
- #ifdef dCSP_SLIDERBAR_METHOD
- ,i_bReverse
- #endif // dCSP_SLIDERBAR_METHOD
- );
- return bSuccess;
- }
- }
- else
- {
- return false;
- }
- }
- /*--- START FUNCTION HEADER --------------------------------------------------*/
- /* Name : ProgressInDialog */
- /* Role : Create the progress bar in a dialog with basic parameters */
- /* Type : PROTECTED */
- /* Interface : RETURN (direct value) */
- /* BOOL = false : Error during progress bar creation */
- /* true : Progress bar created */
- /* OUTPUT (pointer to value) */
- /* None */
- /* INPUT (pointer to value, direct/default value) */
- /* i_poWndProgress : The CWnd where to display the progress */
- /* i_nUpper : Upper limit to reach 100% (0 at 0%) */
- /* i_poBitmap : Replacement progress bar bitmap */
- /* <> i_bReverse : Reverse display of the progress bar */
- /* i_poWndMessage : The CWnd where to display the text */
- /* i_poStrMessage : The text message to display in pane 0 */
- /* i_nProgress : Progress completion message type */
- /* Pre-condition : None */
- /* Constraints : Base of progress bar is fixed to 0, must use [SetRange] to */
- /* change it... */
- /* Behavior : A - Get status bar handler */
- /* B - Create a CStatic object upon the target pane */
- /* C - Set the <m_bVertical> flag */
- /* D - Specific Status Bar initialization */
- /* E - Create and initialize the progress bar */
- /*----------------------------------------------------------------------------*/
- /* PROC ProgressInDialog */
- /* */
- /* A..... Specific Dialog initialization */
- /* B..... Create a CStatic object upon the target CWnd progress bar pane */
- /* [IF CStatic creation OK] */
- /* : C..... Set the <m_bVertical> flag if the progress bar pane is vertical */
- /* : [IF there is a CWnd anchor for a text pane to create] */
- /* : : D..... Specific Status Bar initialization */
- /* : [ENDIF] */
- /* : E..... Create and initialize the progress bar */
- /* [ENDIF] */
- /*----------------------------------------------------------------------------*/
- /* Well, sorry, I put <i_bReverse> in the middle of the function call, but */
- /* there is an obvious reason : If you want to bypass the message's Cwnd, */
- /* you can leave the ending parameters empty ! But if I had put <i_bReverse> */
- /* on the end, you had to force every text related parameter to NULL before */
- /* being able to set the <i_bReverse> value. */
- /* */
- /* You can also use yourself the <dCSP_SLIDERBAR_METHOD> define to compile */
- /* your own code according to your needs (as long as you include the .h) ! */
- /*--- END FUNCTION HEADER ----------------------------------------------------*/
- #ifdef dCSP_DIALOG_PROGRESS
- BOOL CSkinProgress::ProgressInDialog
- ( // The initialization routine
- CWnd* i_poWndProgress,
- int i_nUpper, // = 100, : Default range from 0 to i_nUpper
- CBitmap* i_poBitmap, // = NULL : Pointer to a user bitmap
- #ifdef dCSP_SLIDERBAR_METHOD
- BOOL i_bReverse, // = false
- #endif // dCSP_SLIDERBAR_METHOD
- CWnd* i_poWndMessage, // = NULL
- LPCTSTR i_poStrMessage, // = NULL : Text to display
- int i_nProgress // = cSPT_NONE : Message type to add to the text
- )
- {
- BOOL bSuccess;
- DWORD nStyleEx;
- DWORD nStyle;
- CRect oRectPane;
- LPCSTR poStrClass;
- UINT nClassStyle;
- // Init
- bSuccess = false;
- // A..... Specific Dialog initialization
- m_poWndProgress = i_poWndProgress;
- m_poWndMessage = i_poWndMessage;
- // Process + Return
- // B..... Create a CStatic object upon the target CWnd progress bar pane
- // Set the style for the custom progress bas
- nClassStyle = 0; // CS_CLASSDC | CS_HREDRAW | CS_VREDRAW;
- nStyleEx = WS_EX_STATICEDGE;
- nStyle = WS_CHILD | WS_VISIBLE | SS_BITMAP | SS_CENTERIMAGE;
- // Get CRect coordinates for requested target CWnd bar pane
- GetTargetRect(&oRectPane);
- // Create the progress bar
- poStrClass = AfxRegisterWndClass(nClassStyle, AfxGetApp()->LoadStandardCursor(IDC_WAIT));
- bSuccess = CStatic::CreateEx
- (
- nStyleEx,
- poStrClass,
- "",
- nStyle,
- oRectPane,
- m_poWndProgress->GetParent(), // Attach it not the the CWnd anchor (thus getting in its client area) but to its parent to overlap it
- (UINT) this // Use object's unique address as child window identifier
- );
- ASSERT(bSuccess);
- if(!bSuccess)
- {
- return false;
- }
- else
- {
- // C..... Set the <m_bVertical> flag if the progress bar pane is vertical
- #ifdef dCSP_VERTICAL_BAR
- #ifndef dCSP_DISPLAY_STRETCH
- if(oRectPane.Height() > oRectPane.Width())
- { // VERTICAL
- m_bVertical = true;
- }
- else
- {
- m_bVertical = false;
- }
- #else
- m_bVertical = true; // *FORCE* vertical for <m_poStretchBmp> analysis
- #endif // dCSP_DISPLAY_STRETCH
- #endif // dCSP_VERTICAL_BAR
- if(m_poWndMessage != NULL)
- {
- // D..... Specific Status Bar initialization
- m_poWndMessage->GetWindowText(m_oStrPrevText); // Get the previous pane's text
- }else{}
- if(bSuccess)
- {
- // E..... Create and initialize the progress bar
- bSuccess = CreateCommon
- (
- i_poStrMessage,
- i_nUpper,
- i_nProgress,
- i_poBitmap
- #ifdef dCSP_SLIDERBAR_METHOD
- ,i_bReverse
- #endif // dCSP_SLIDERBAR_METHOD
- );
- }else{}
- return bSuccess;
- }
- }
- #endif // dCSP_DIALOG_PROGRESS
- // *** DESCTRUCTOR ***
- /*--- START FUNCTION HEADER --------------------------------------------------*/
- /* Name : ~CSkinProgress */
- /* Role : Destructor, restore the inital states and used memory */
- /* Type : public */
- /* Interface : RETURN (direct value) */
- /* None */
- /* OUTPUT (pointer to value) */
- /* None */
- /* INPUT (pointer to value, direct/default value) */
- /* None */
- /* Pre-condition : None */
- /* Constraints : None */
- /* Behavior : A - Clear the progress bar */
- /* B - Delete the refresh timer */
- /* C - Delete the base bitmap */
- /* C - Delete the client DC compatible base bitmap */
- /* D - Delete the stretched for image list bitmap */
- /* E - Delete the displayed progress bar bitmap */
- /*----------------------------------------------------------------------------*/
- /* PROC ~CSkinProgress */
- /* */
- /* A..... Clear the progress bar */
- /* B..... Delete the refresh timer */
- /* C..... Delete the <m_poBaseBmp> base bitmap */
- /* D..... Delete the <m_poCompatibleBmp> client DC compatible base bitmap */
- /* E..... Delete the <m_poStretchBmp> stretched for image list bitmap */
- /* F..... Delete the <m_poProgressBmp> displayed progress bar bitmap */
- /*----------------------------------------------------------------------------*/
- /*--- END FUNCTION HEADER ----------------------------------------------------*/
- CSkinProgress::~CSkinProgress
- ( // Destructor
- )
- {
- // Init
- // Process
- // A..... Clear the progress bar
- Clear();
- // B..... Delete the refresh timer
- if(IsWindow(this->m_hWnd)) // Test first if <this> is the correct address of the object before using it as the right timer identifier
- {
- KillTimer((UINT) this); // Use object's unique address as timer identifier
- }else{}
- // C..... Delete the <m_poBaseBmp> base bitmap
- if(m_poBaseBmp != NULL)
- { // Delete the attached base bitmap
- delete m_poBaseBmp;
- }else{}
- // D..... Delete the <m_poCompatibleBmp> client DC compatible base bitmap
- if(m_poCompatibleBmp != NULL)
- { // Delete the attached client DC compatible base bitmap
- delete m_poCompatibleBmp;
- }else{}
- // E..... Delete the <m_poStretchBmp> stretched for image list bitmap
- if(m_poStretchBmp != NULL)
- { // Delete the attached stretched image list bitmap
- delete m_poStretchBmp;
- }else{}
- // F..... Delete the <m_poProgressBmp> displayed progress bar bitmap
- if(m_poProgressBmp != NULL)
- { // Delete the attached progress bitmap
- delete m_poProgressBmp;
- }else{}
- }
- // *** CLEANER ***
- /*--- START FUNCTION HEADER --------------------------------------------------*/
- /* Name : Clear */
- /* Role : Erase the progress */
- /* Type : PROTECTED */
- /* Interface : RETURN (direct value) */
- /* None */
- /* OUTPUT (pointer to value) */
- /* None */
- /* INPUT (pointer to value, direct/default value) */
- /* None */
- /* Pre-condition : None */
- /* Constraints : None */
- /* Behavior : A - Delete the progress bar */
- /* B - Set IDLE message in pane 0 */
- /* C - Set previous message in user pane */
- /* D - Display the changes */
- /* E - Set previous message */
- /*----------------------------------------------------------------------------*/
- /* PROC Clear */
- /* */
- /* [IF the object is still alive] */
- /* : A..... Delete the progress bar */
- /* : [IF status bar] */
- /* : : B..... Set IDLE message in pane 0 */
- /* : : C..... Set previous message in user pane */
- /* : : D..... Display the changes */
- /* : [ELSE] */
- /* : : [IF there is a text CWnd] */
- /* : : : E..... Set previous message */
- /* : : [ENDIF] */
- /* : [ENDIF] */
- /* [ENDIF] */
- /*----------------------------------------------------------------------------*/
- /*--- END FUNCTION HEADER ----------------------------------------------------*/
- void CSkinProgress::Clear
- ( // Deletion of the progress bar, restoration of the context
- )
- {
- CStatusBar* poStatusBar;
- //
- if(IsWindow(GetSafeHwnd()))
- {
- // A..... Delete the progress bar
- ModifyStyle(WS_VISIBLE, 0); // Clear the attached CStatic progress bar
- DestroyWindow(); // Destroy it
- #ifdef dCSP_DIALOG_PROGRESS
- if(m_poWndProgress == NULL)
- { // If in Status Bar, reset pane 0 and delete the progress bar
- #endif // dCSP_DIALOG_PROGRESS
- poStatusBar = GetStatusBar();
- if(poStatusBar != NULL)
- {
- // B..... Set IDLE message in pane 0
- m_oStrMessage.LoadString(AFX_IDS_IDLEMESSAGE); // Get the IDLE_MESSAGE and place 顃 in the status bar
- poStatusBar->SetPaneText(0, m_oStrMessage);
- // C..... Set previous message in user pane
- if(m_nPane != 0)
- { // If not the text pane, restore previous text in the pane
- poStatusBar->SetPaneText(m_nPane, m_oStrPrevText);
- }else{}
- // D..... Display the changes
- poStatusBar->InvalidateRect(NULL);
- }else{}
- #ifdef dCSP_DIALOG_PROGRESS
- }
- else
- {
- if(m_poWndMessage != NULL)
- {
- // E..... Set previous message
- m_poWndMessage->SetWindowText(m_oStrPrevText); // Set the previous pane's text
- }else{}
- m_poWndProgress->InvalidateRect(NULL);
- } // NOTHING TO RESET IN DIALOG MODE !!!
- #endif // dCSP_DIALOG_PROGRESS
- }else{}
- }
- // *** SYSTEM INTERFACE ***
- /*--- START FUNCTION HEADER --------------------------------------------------*/
- /* Name : GetStatusBar */
- /* Role : Get status bar's window handle */
- /* Type : PROTECTED */
- /* Interface : RETURN (direct value) */
- /* CStatusBar* : Window handle, else NULL if no status bar */
- /* OUTPUT (pointer to value) */
- /* None */
- /* INPUT (pointer to value, direct/default value) */
- /* None */
- /* Pre-condition : None */
- /* Constraints : None */
- /* Behavior : A - Get the main window handle */
- /* B - Retrieve the status bar handle */
- /*----------------------------------------------------------------------------*/
- /* PROC GetStatusBar */
- /* */
- /* A..... Get the main window handle */
- /* B..... Retrieve the status bar handle */
- /* [IF main window is based on CFrameWnd] */
- /* : BA.... Return status bar's handle from CFrameWnd main window type */
- /* :[ELSE] */
- /* : BB.... Return status bar's handle from other main window type */
- /* [ENDIF] */
- /*----------------------------------------------------------------------------*/
- /*--- END FUNCTION HEADER ----------------------------------------------------*/
- CStatusBar* CSkinProgress::GetStatusBar
- ( // Get the pointer on the current status bar
- )
- {
- CWnd* poMainWnd;
- CWnd* poMessageBar;
- // Init
- // A..... Get the main window handle
- poMainWnd = AfxGetMainWnd();
- // Process + Return
- // B..... Retrieve the status bar handle
- if(poMainWnd != NULL)
- {
- if(poMainWnd->IsKindOf(RUNTIME_CLASS(CFrameWnd)))
- { // If main window is a frame window, use normal methods
- poMessageBar = ((CFrameWnd*) poMainWnd)->GetMessageBar();
- // BA.... Return status bar's handle from CFrameWnd main window type
- return DYNAMIC_DOWNCAST(CStatusBar, poMessageBar);
- }
- else
- { // otherwise traverse children to try and find the status bar
- // BB.... Return status bar's handle from other main window type
- return DYNAMIC_DOWNCAST(CStatusBar, poMainWnd->GetDescendantWindow(AFX_IDW_STATUS_BAR));
- }
- }
- else
- {
- return NULL;
- }
- }
- /*--- START FUNCTION HEADER --------------------------------------------------*/
- /* Name : GetTargetRect */
- /* Role : Get the target CRect of the progress bar */
- /* Type : PROTECTED */
- /* Interface : RETURN (direct value) */
- /* BOOL = false : Error in getting the target rect */
- /* true : CRect returned is valid */
- /* OUTPUT (pointer to value) */
- /* o_poProgressRect : Pointer on an existing CRect */
- /* INPUT (pointer to value, direct/default value) */
- /* None */
- /* Pre-condition : None */
- /* Constraints : None */
- /* Behavior : A - Get the progress bar's CWnd anchor rectangle */
- /* B - Get the status bar selected pane rectangle */
- /*----------------------------------------------------------------------------*/
- /* PROC GetTargetRect */
- /* */
- /* [IF there is a progress bar CWnd anchor specified] */
- /* : A..... Get the progress bar's CWnd anchor rectangle */
- /* [ELSE] */
- /* : B..... Get the status bar selected pane rectangle */
- /* [ENDIF] */
- /*----------------------------------------------------------------------------*/
- /*--- END FUNCTION HEADER ----------------------------------------------------*/
- BOOL CSkinProgress::GetTargetRect
- ( // Get the target CRect for the [SetBitmap(...)]
- CRect* o_poProgressRect // Pointer on an existing CRect
- )
- {
- CStatusBar* poStatusBar;
- // Init
- // Process + Return
- #ifdef dCSP_DIALOG_PROGRESS
- if(m_poWndProgress != NULL)
- { // If dialog mode
- // A..... Get the progress bar's CWnd anchor rectangle
- m_poWndProgress->GetWindowRect(o_poProgressRect); // Return CWnd parent's screen absolute coordinates
- m_poWndProgress->GetParent()->ScreenToClient(o_poProgressRect); // Transform into parent relative coordinates
- return true;
- }
- else
- {
- #endif // dCSP_DIALOG_PROGRESS
- poStatusBar = GetStatusBar();
- if(poStatusBar != NULL)
- {
- // B..... Get the status sar selected pane rectangle
- poStatusBar->GetItemRect(m_nPane, o_poProgressRect); // Already working in parent (the status bar) relative coordinates
- return true;
- }
- else
- {
- return false;
- }
- #ifdef dCSP_DIALOG_PROGRESS
- }
- #endif // dCSP_DIALOG_PROGRESS
- }
- // *** BITMAP PROCESS ***
- /*--- START FUNCTION HEADER --------------------------------------------------*/
- /* Name : SetBitmap */
- /* Role : Create an image list for the progress bar painting */
- /* Type : public */
- /* Interface : RETURN (direct value) */
- /* BOOL = false : Error in image list creation */
- /* true : Image list created and ready to use */
- /* OUTPUT (pointer to value) */
- /* None */
- /* INPUT (pointer to value, direct/default value) */
- /* i_poCwnd : CWnd anchor to get the bitmap size to use */
- /* i_poBitmap : Image to use, use default bitmap if NULL */
- /* i_bDisplay : Display the changes */
- /* Pre-condition : None */
- /* Constraints : None */
- /* Behavior : A - Get the base bitmap for the image list creation */
- /* B - Create the stretched bitmap used for the image list */
- /* C - Create an image list compatible bitmap */
- /* D - Create the image list */
- /* E - Display the new bitmap */
- /*----------------------------------------------------------------------------*/
- /* PROC SetBitmap */
- /* */
- /* A..... Get the base bitmap for the <m_oBarImgLst> image list creation */
- /* AA.... Create the base and the device compatible bitmaps */
- /* AB.... Load the <i_poBitmap> base bitmap */
- /* AC.... Convert the <m_poBaseBmp> base bitmap in a compatible format */
- /* B..... Create the stretched bitmap used for the image list creation */
- /* BA.... Create the bitmap, and delete the previous one if there was one */
- /* BB.... Create a bitmap with mixed dimensions from the base and the pane */
- /* BC.... Set the copy parameters for the stretching */
- /* C..... Modify the base bitmap to create an image list compatible bitmap */
- /* D..... Create the <m_oBarImgLst> image list */
- /* DA.... Get the stretched bitmap size */
- /* DB.... Calculate the size of every element of the image list */
- /* DC.... Delete the previous image list the create a new one from scratch */
- /* DD.... Create the new image list in 32 bits for maximun throughput */
- /* DE.... Add the stretched bitmap in the image list */
- /* E..... Display the new bitmap */
- /*----------------------------------------------------------------------------*/
- /*--- END FUNCTION HEADER ----------------------------------------------------*/
- BOOL CSkinProgress::SetBitmap
- ( // Change of progress bar image
- CBitmap* i_poBitmap // = NULL : Pointer to an existing bitmap
- #ifndef dCSP_TIMED_REDRAW
- ,BOOL i_bDisplay // = true : Display the changes
- #endif // dCSP_TIMED_REDRAW
- )
- {
- BITMAP sBmpSrc;
- #ifdef dCSP_VERTICAL_BAR
- CBitmap oBmpVertical;
- #endif // dCSP_VERTICAL_BAR
- CBitmap* poOldBitmap;
- #ifdef dCSP_VERTICAL_BAR
- CBitmap* poOldVertical;
- #endif // dCSP_VERTICAL_BAR
- CBitmap* poOldStretch;
- CRect oRectBar;
- CDC oDcBitmap;
- #ifdef dCSP_VERTICAL_BAR
- CDC oDcVertical;
- #endif // dCSP_VERTICAL_BAR
- CDC oDcStretch;
- // Init
- m_oRectPaint.SetRect(0, 0, 0, 0); // Force redraw if the bitmap is changed while the SkinProgress object exist
- #ifdef dCSP_VERTICAL_BAR
- poOldVertical = NULL; // AVOID /W4 -> BC.... *STUPID COMPILER*
- #endif // dCSP_VERTICAL_BAR
- // Process
- if(GetTargetRect(&oRectBar))
- { // If the target rectangle is valid
- CClientDC oDC(this); // Get the current DC
- // A..... Get the <i_poBitmap> base bitmap for the <m_oBarImgLst> image list creation
- // AA.... Create the base and the device compatible bitmaps
- if(m_poBaseBmp != NULL)
- { // *IF* m_poBaseBmp already exist
- delete m_poBaseBmp;
- }else{}
- m_poBaseBmp = new CBitmap; // BEWARE : DON'T INITIALIZE IT YET !
- if(m_poCompatibleBmp != NULL)
- { // *IF* m_poCompatibleBmp already exist
- delete m_poCompatibleBmp;
- }else{}
- m_poCompatibleBmp = new CBitmap; // BEWARE : DON'T INITIALIZE IT YET !
- // AB.... Load the <i_poBitmap> base bitmap
- // Check if i_poBitmap is valid, otherwise use the resource's bitmap
- if(i_poBitmap == NULL)
- { // If no bitmap provided, takes the default bitmap
- #ifndef dCSP_RESOURCE_BITMAP
- m_poBaseBmp->CreateBitmapIndirect(&sAQUA_BITMAP);
- #else
- m_poBaseBmp->LoadBitmap(IDB_AQUABAR); // Defaut bitmap, might have to be changed !
- #endif // dCSP_RESOURCE_BITMAP
- }
- else
- { // Copy the <i_poBitmap> input bitmap as the new <m_poBaseBmp> base bitmap
- CopyBitmap(m_poBaseBmp, i_poBitmap);
- }
- // AC.... Convert the <m_poBaseBmp> base bitmap in a device compatible format
- ConvBitmap(m_poCompatibleBmp, m_poBaseBmp, &oDC);
- // Get bitmap width and height for the image list creation
- m_poCompatibleBmp->GetBitmap(&sBmpSrc);
- m_nBmpWidth = sBmpSrc.bmWidth / cSPB_EnumElements; // cSPB_EnumElements == 9, the bitmap is actually composed of 9 parts
- m_nBmpHeight = sBmpSrc.bmHeight;
- // B..... Create the <m_poStretchBmp> stretched bitmap used for the <m_oBarImgLst> image list creation
- // BA.... Create the bitmap, and if a previous one was already existing, delete it first
- if(m_poStretchBmp != NULL)
- { // *IF* m_poStretchBmp already exist
- delete m_poStretchBmp;
- }else{}
- m_poStretchBmp = new CBitmap;
- // BB.... Create a bitmap with the base bitmap width, and the despination pane height minus 2
- #ifdef dCSP_VERTICAL_BAR
- if(m_bVertical == false)
- { // Horizontal bar
- #endif // dCSP_VERTICAL_BAR
- #ifndef dCSP_CREATE_BITMAP_FILE
- m_poStretchBmp->CreateCompatibleBitmap(&oDC, sBmpSrc.bmWidth, oRectBar.Height() - 2); // Minus 2, with don't count the contour of the box
- #else
- m_poStretchBmp->CreateCompatibleBitmap(&oDC, sBmpSrc.bmWidth, sBmpSrc.bmHeight); // BITMAP CREATION IN CURRENT VIDEO MODE !
- #endif //dCSP_CREATE_BITMAP_FILE
- #ifdef dCSP_VERTICAL_BAR
- }
- else
- { // Vertical bar
- #ifndef dCSP_DISPLAY_STRETCH
- oBmpVertical.CreateCompatibleBitmap(&oDC, sBmpSrc.bmWidth, oRectBar.Width() - 2); // Minus 2, with don't count the contour of the box
- m_poStretchBmp->CreateCompatibleBitmap(&oDC, (oRectBar.Width() - 2) * cSPB_EnumElements, m_nBmpWidth); // Minus 2, with don't count the contour of the box
- #else
- oBmpVertical.CreateCompatibleBitmap(&oDC, sBmpSrc.bmWidth, oRectBar.Height() - 2); // Minus 2, with don't count the contour of the box
- m_poStretchBmp->CreateCompatibleBitmap(&oDC, (oRectBar.Height() - 2) * cSPB_EnumElements, m_nBmpWidth); // Minus 2, with don't count the contour of the box
- #endif //dCSP_DISPLAY_STRETCH
- }
- #endif // dCSP_VERTICAL_BAR
- // BC.... Set the copy parameters for the stretching
- // Set the DC
- oDcBitmap.CreateCompatibleDC(&oDC);
- poOldBitmap = oDcBitmap.SelectObject(m_poCompatibleBmp); // Source
- oDcStretch.CreateCompatibleDC(&oDC);
- poOldStretch = oDcStretch.SelectObject(m_poStretchBmp); // Destination
- #ifdef dCSP_VERTICAL_BAR
- if(m_bVertical != false)
- { // Vertical bar
- oDcVertical.CreateCompatibleDC(&oDC);
- poOldVertical = oDcVertical.SelectObject(&oBmpVertical); // Destination
- oDcVertical.SetStretchBltMode(HALFTONE);
- }
- else
- { // Horizontal bar
- #endif // dCSP_VERTICAL_BAR
- oDcStretch.SetStretchBltMode(HALFTONE);
- #ifdef dCSP_VERTICAL_BAR
- }
- #endif // dCSP_VERTICAL_BAR
- // C..... Copy the <m_poCompatibleBmp> base bitmap and apply modifications to create an image list compatible bitmap
- // Copy the picture
- #ifdef dCSP_VERTICAL_BAR
- if(m_bVertical == false)
- { // Horizontal bar
- #endif // dCSP_VERTICAL_BAR
- #ifndef dCSP_CREATE_BITMAP_FILE
- oDcStretch.StretchBlt(0, 0, sBmpSrc.bmWidth, oRectBar.Height() - 2, &oDcBitmap, 0, 0, sBmpSrc.bmWidth, sBmpSrc.bmHeight, SRCCOPY);
- #else
- oDcStretch.BitBlt(0, 0, sBmpSrc.bmWidth, sBmpSrc.bmHeight, &oDcBitmap, 0, 0, SRCCOPY); // BITMAP CREATION IN CURRENT VIDEO MODE, PLEASE USE 32 BITS, AVOID MAPPED !
- #endif //dCSP_CREATE_BITMAP_FILE
- #ifdef dCSP_VERTICAL_BAR
- }
- else
- { // Vertical bar
- #ifndef dCSP_DISPLAY_STRETCH
- oDcVertical.StretchBlt(0, 0, sBmpSrc.bmWidth, oRectBar.Width() - 2, &oDcBitmap, 0, 0, sBmpSrc.bmWidth, sBmpSrc.bmHeight, SRCCOPY);
- #else
- oDcVertical.StretchBlt(0, 0, sBmpSrc.bmWidth, oRectBar.Height() - 2, &oDcBitmap, 0, 0, sBmpSrc.bmWidth, sBmpSrc.bmHeight, SRCCOPY);
- #endif // dCSP_DISPLAY_STRETCH
- // Copy the stretched vertical picture into the m_poStretchBmp with part flip
- #ifndef dCSP_DISPLAY_STRETCH
- for(int y = 0; y < oRectBar.Width() - 2; y += 1)
- #else
- for(int y = 0; y < oRectBar.Height() - 2; y += 1)
- #endif // dCSP_DISPLAY_STRETCH
- { // Scan each line
- for(int x = 0; x < sBmpSrc.bmWidth; x += 1)
- { // Scan every pixel of the line
- #ifndef dCSP_DISPLAY_STRETCH
- oDcStretch.SetPixel(y + ((oRectBar.Width() - 2) * (x / m_nBmpWidth)), x % m_nBmpWidth, oDcVertical.GetPixel(x, y));
- #else
- oDcStretch.SetPixel(y + ((oRectBar.Height() - 2) * (x / m_nBmpWidth)), x % m_nBmpWidth, oDcVertical.GetPixel(x, y));
- #endif // dCSP_DISPLAY_STRETCH
- }
- }
- }
- #endif // dCSP_VERTICAL_BAR
- // Release the DC
- #ifdef dCSP_VERTICAL_BAR
- if(m_bVertical != false)
- { // Vertical bar
- oDcVertical.SelectObject(poOldVertical);
- oDcVertical.DeleteDC();
- }else{}
- #endif // dCSP_VERTICAL_BAR
- oDcStretch.SelectObject(poOldStretch);
- oDcStretch.DeleteDC();
- oDcBitmap.SelectObject(poOldBitmap);
- oDcBitmap.DeleteDC();
- // D..... Create the <m_oBarImgLst> image list
- // DA.... Get the stretched bitmap size
- // Get bitmap width and height for the image list creation
- m_poStretchBmp->GetBitmap(&sBmpSrc);
- #ifdef dCSP_CREATE_BITMAP_FILE
- // Fast and dirty routine to save the stretched bitmap in C format, for the people who wants to recreate the AQUA_BITMAP array with their own default bitmap, instead to provide it to the constructor
- FILE* sFileHandle;
- unsigned char* panDataBmp;
- int nCount = sBmpSrc.bmWidthBytes * sBmpSrc.bmHeight;
- unsigned char nBufferHi;
- unsigned char nBufferLo;
- panDataBmp = new unsigned char[nCount];
- if(panDataBmp != NULL)
- {
- sFileHandle = fopen("C:\aqua_bitmap.cpp", "wt"); // Change the path here
- if(sFileHandle != NULL)
- {
- m_poStretchBmp->GetBitmapBits(nCount, panDataBmp);
- fprintf(sFileHandle, "unsigned char anAQUA_BITMAP[%d] =n{n ", nCount);
- for(int nPointer = 0; nPointer < nCount; nPointer += 1)
- {
- fputs(" 0x", sFileHandle);
- nBufferHi = panDataBmp[nPointer];
- nBufferLo = nBufferHi;
- nBufferHi >>= 4;
- nBufferLo &= 0x0F;
- if(nBufferHi < 10)
- {
- nBufferHi += '0';
- }
- else
- {
- nBufferHi += 'A' - 10;
- }
- if(nBufferLo < 10)
- {
- nBufferLo += '0';
- }
- else
- {
- nBufferLo += 'A' - 10;
- }
- fputc(nBufferHi, sFileHandle);
- fputc(nBufferLo, sFileHandle);
- fputs(",", sFileHandle);
- if((nPointer % 16) == 15)
- { // 16 pixels per line
- fputs("n ", sFileHandle);
- }else{}
- }
- fputs("};nn", sFileHandle);
- fputs("BITMAP sAQUA_BITMAP =n{n", sFileHandle);
- fprintf(sFileHandle, " %d, // bmTypen", sBmpSrc.bmType);
- fprintf(sFileHandle, " %d, // bmWidthn", sBmpSrc.bmWidth);
- fprintf(sFileHandle, " %d, // bmHeightn", sBmpSrc.bmHeight);
- fprintf(sFileHandle, " %d, // bmWidthBytesn", sBmpSrc.bmWidthBytes);
- fprintf(sFileHandle, " %d, // bmPlanesn", sBmpSrc.bmPlanes);
- fprintf(sFileHandle, " %d, // bmBitsPixeln", sBmpSrc.bmBitsPixel);
- fputs(" anAQUA_BITMAP // bmBitsn", sFileHandle);
- fputs("};n", sFileHandle);
- fclose(sFileHandle);
- }else{}
- delete panDataBmp;
- }else{}
- #endif //dCSP_CREATE_BITMAP_FILE
- // DB.... Calculate the size of every element of the image list
- m_nBmpWidth = sBmpSrc.bmWidth / cSPB_EnumElements; // cSPB_EnumElements == 5, the bitmap is yet composed of 5 parts
- m_nBmpHeight = sBmpSrc.bmHeight;
- // DC.... Delete the previous image list the create a new one from scratch (useful when providing a new bitmap during SkinProgress life-time)
- // Image list creation
- m_oBarImgLst.DeleteImageList(); // Delete the previous ImageList and recreate it with the new bitmap
- // DD.... Create the new image list in 32 bits to be sure it will accept any kind of bitmap in input (if 8 bits bitmap provided, will be converted in 32 bits)
- if(!m_oBarImgLst.Create(m_nBmpWidth, m_nBmpHeight, ILC_COLOR32, 0, 0)) // ILC_COLOR32 to be sure to accept any BitMap format passed through i_poBitmap
- {
- return false;
- }
- else
- {
- // DE.... Add the stretched bitmap in the image list
- m_oBarImgLst.Add(m_poStretchBmp, RGB(0, 255, 255));
- // E..... Display the new bitmap
- #ifndef dCSP_TIMED_REDRAW
- if(i_bDisplay != false)
- {
- RefreshPanes();
- }else{}
- #endif // dCSP_TIMED_REDRAW
- return true;
- }
- }
- else
- {
- return false;
- }
- }
- /*--- START FUNCTION HEADER --------------------------------------------------*/
- /* Name : CopyBitmap */
- /* Role : Copy a bitmap */
- /* Type : public */
- /* Interface : RETURN (direct value) */
- /* BOOL = false : Error in copy */
- /* true : Image copied */
- /* OUTPUT (pointer to value) */
- /* o_poBitmap : Image where to copy */
- /* INPUT (pointer to value, direct/default value) */
- /* i_poBitmap : Image to copy */
- /* Pre-condition : Both output and input pointer must be provided ! */
- /* Also, the output bitmap MUST BE CREATED, BUT NOT */
- /* INITIALIZED */
- /* Constraints : Do not handle mapped bitmap yet... */
- /* Behavior : A - Create a remote data buffer to get the source data */
- /* B - Get the source data */
- /* C - Copy the bitmap */
- /*----------------------------------------------------------------------------*/
- /* PROC CopyBitmap */
- /* */
- /* A..... Create a remote data buffer to get the source data */
- /* [IF the remote buffer is successfully created] */
- /* : B..... Get the source data */
- /* : C..... Copy the bitmap */
- /* [ENDIF] */
- /*----------------------------------------------------------------------------*/
- /* As this STUPID [CBitmap::GetBitmap((BITMAP*) o_psBitmap)] returns NULL in */
- /* <o_psBitmap.bmBits>, we cannot reuse immediatly the returned BITMAP for a */
- /* [CBitmap::CreateBitmapIndirect((BITMAP*) i_psBitmap)], we have to get the */
- /* address of the data buffer by creating it by ourself, then get the datas */
- /* with [CBitmap::GetBitmapBits((DWORD) i_nDataCount, (LPVOID) i_panDataBmp)] */
- /*--- END FUNCTION HEADER ----------------------------------------------------*/
- BOOL CSkinProgress::CopyBitmap
- ( // Copy a bitmap
- CBitmap* o_poBitmap, // Pointer to an EXISTING but NOT INITIALIZED bitmap
- CBitmap* i_poBitmap // Pointer to the source bitmap
- )
- {
- BITMAP sBmpSrc;
- unsigned char* panDataBmp;
- DWORD nDataCount;
- BOOL bResult;
- // Init
- // Process
- if(
- (o_poBitmap == NULL)
- || (i_poBitmap == NULL)
- )
- {
- return false;
- }
- else
- {
- // A..... Create a remote data buffer to get the source data
- i_poBitmap->GetBitmap(&sBmpSrc);
- nDataCount = sBmpSrc.bmWidthBytes * sBmpSrc.bmHeight;
- panDataBmp = new unsigned char[nDataCount];
- if(panDataBmp != NULL)
- {
- // B..... Get the source data
- i_poBitmap->GetBitmapBits(nDataCount, panDataBmp);
- sBmpSrc.bmBits = panDataBmp; // Just complete the BITMAP structure
- // C..... Copy the bitmap
- bResult = o_poBitmap->CreateBitmapIndirect(&sBmpSrc);
- delete[] panDataBmp;
- return bResult;
- }
- else
- {
- return false;
- }
- }
- }
- /*--- START FUNCTION HEADER --------------------------------------------------*/
- /* Name : ConvBitmap */
- /* Role : Convert a bitmap to a specified device context */
- /* Type : public */
- /* Interface : RETURN (direct value) */
- /* BOOL = false : Error in conversion */
- /* true : Image converted */
- /* OUTPUT (pointer to value) */
- /* o_poBitmap : Image where to copy/transform */
- /* INPUT (pointer to value, direct/default value) */
- /* i_poBitmap : Image to copy/transform */
- /* i_poDC : The DC to use for the conversion */
- /* Pre-condition : Both output and input pointer must be provided ! */
- /* Also, the output bitmap MUST BE CREATED, BUT NOT */
- /* INITIALIZED */
- /* Constraints : Do not handle mapped bitmap yet... */
- /* Behavior : A - Get the current DC */
- /* B - Copy the bitmap */
- /* C - Create a remote data buffer to get the source data */
- /* D - Get the source data */
- /* E - Initialize the bitmap */
- /* F - Convert the data */
- /* G - Copy the converted bitmap */
- /*----------------------------------------------------------------------------*/
- /* PROC CopyBitmap */
- /* */
- /* [IF pointers on bitmap valids] */
- /* : [IF no DC provided] */
- /* : : A..... Get the current DC */
- /* : [ELSE] */
- /* : [IF same color format] */
- /* : : B..... Copy the bitmap */
- /* : [ELSE] */
- /* : : C..... Create a remote data buffer to get the source data */
- /* : : [IF buffer created] */
- /* : : : D..... Get the source data */
- /* : : : E..... Initialize the bitmap */
- /* : : : F..... Convert the data */
- /* : : : G..... Copy the converted bitmap */
- /* : : [ELSE] */
- /* : [ENDIF] */
- /* [ENDIF] */
- /*----------------------------------------------------------------------------*/
- /*--- END FUNCTION HEADER ----------------------------------------------------*/
- BOOL CSkinProgress::ConvBitmap
- ( // Convert a bitmap to a specified device context
- CBitmap* o_poBitmap, // Pointer to an EXISTING but NOT INITIALIZED bitmap
- CBitmap* i_poBitmap, // Pointer to the source bitmap
- CDC* i_poDC // = NULL : Pointer to the DC to use for the conversion, if NULL use the current DC
- )
- {
- BITMAP sBmpSrc;
- BITMAPINFO sBmpInfoSrc;
- HBITMAP DIB;
- unsigned char* panDataBmp;
- DWORD nDataCount;
- int nResult;
- // Init
- panDataBmp = NULL;
- // Process
- if(
- (o_poBitmap != NULL)
- && (i_poBitmap != NULL)
- )
- {
- if(i_poDC == NULL)
- { // If no target device context provided, use the current one
- // A..... Get the current DC
- CClientDC oDC(this);
- i_poDC = &oDC;
- }else{}
- i_poBitmap->GetBitmap(&sBmpSrc); // Get some infos on the source bitmap
- if(sBmpSrc.bmBitsPixel == GetDeviceCaps(*i_poDC, BITSPIXEL))
- { // If it's the same bitmap format, just copy it instead to waste some time to convert the picture (what will fail :/ )
- // B..... Copy the bitmap
- nResult = (int) CopyBitmap(o_poBitmap, i_poBitmap);
- }
- else
- {
- // C..... Create a remote data buffer to get the source data
- nDataCount = sBmpSrc.bmWidthBytes * sBmpSrc.bmHeight;
- panDataBmp = new unsigned char[nDataCount];
- if(panDataBmp != NULL)
- {
- // D..... Get the source data
- i_poBitmap->GetBitmapBits(nDataCount, panDataBmp);
- sBmpSrc.bmBits = panDataBmp;
- // E..... Initialize the bitmap
- sBmpInfoSrc.bmiColors[0].rgbBlue = 0;
- sBmpInfoSrc.bmiColors[0].rgbGreen = 0;
- sBmpInfoSrc.bmiColors[0].rgbRed = 0;
- sBmpInfoSrc.bmiColors[0].rgbReserved = 0;
- sBmpInfoSrc.bmiHeader.biSize = sizeof(BITMAPINFOHEADER);
- sBmpInfoSrc.bmiHeader.biWidth = sBmpSrc.bmWidth;
- sBmpInfoSrc.bmiHeader.biHeight = 0 - sBmpSrc.bmHeight; // 0 - HEIGHT : TOP-DOWN DIB, origin is upper/left corner
- sBmpInfoSrc.bmiHeader.biPlanes = sBmpSrc.bmPlanes;
- sBmpInfoSrc.bmiHeader.biBitCount = sBmpSrc.bmBitsPixel;
- sBmpInfoSrc.bmiHeader.biCompression = BI_RGB;
- sBmpInfoSrc.bmiHeader.biSizeImage = 0; // 0 : BI_RGB
- sBmpInfoSrc.bmiHeader.biXPelsPerMeter = 0;
- sBmpInfoSrc.bmiHeader.biYPelsPerMeter = 0;
- sBmpInfoSrc.bmiHeader.biClrUsed = 0;
- sBmpInfoSrc.bmiHeader.biClrImportant = 0;
- // F..... Convert the data
- DIB = CreateDIBitmap
- (
- i_poDC->m_hDC,
- &sBmpInfoSrc.bmiHeader,
- CBM_INIT,
- panDataBmp,
- &sBmpInfoSrc,
- DIB_RGB_COLORS
- );
- // G..... Copy the converted bitmap
- nResult = (int) CopyBitmap(o_poBitmap, CBitmap::FromHandle(DIB));
- DeleteObject(DIB);
- delete[] panDataBmp;
- if(nResult != 0)
- {
- return true;
- }else{}
- }else{}
- }
- }else{}
- return false;
- }
- // *** PROGRESS INTERFACE ***
- /*--- START FUNCTION HEADER --------------------------------------------------*/
- /* Name : SetRange */
- /* Role : None */
- /* Type : public */
- /* Interface : RETURN (direct value) */
- /* BOOL = false : Error while trying to change the range */
- /* true : New range set */
- /* OUTPUT (pointer to value) */
- /* None */
- /* INPUT (pointer to value, direct/default value) */
- /* i_nLower : Minimum value possible */
- /* i_nUpper : Maximum value possible */
- /* i_nStep : Step increment */
- /* i_bResamble : Resample the current position */
- /* i_bDisplay : Display the changes */
- /* Pre-condition : None */
- /* Constraints : None */
- /* Behavior : A - Resample the postion */
- /* B - Set the new range */
- /* C - Display the new ranged progress bar */
- /*----------------------------------------------------------------------------*/
- /* PROC SetRange */
- /* */
- /* A..... Resample the postion from the previous range to the new one */
- /* B..... Set the new range values */
- /* C..... Display the new ranged progress bar */
- /*----------------------------------------------------------------------------*/
- /*--- END FUNCTION HEADER ----------------------------------------------------*/
- BOOL CSkinProgress::SetRange
- ( // Set the new range
- int i_nLower, // Minimum limit
- int i_nUpper, // Maximum limit
- int i_nStep, // = 1 : Step increment
- BOOL i_bResamble // = false : Resample the current position from the new Lower and Upper values
- #ifndef dCSP_TIMED_REDRAW
- ,BOOL i_bDisplay // = true : Display the changes
- #endif // dCSP_TIMED_REDRAW
- )
- {
- // Init
- // Process + Return
- if(IsWindow(GetSafeHwnd()))
- {
- ASSERT((-0x7FFFFFFF <= i_nLower) && (i_nLower <= 0x7FFFFFFF));
- ASSERT((-0x7FFFFFFF <= i_nUpper) && (i_nUpper <= 0x7FFFFFFF));
- ASSERT(i_nLower < i_nUpper); // Seems to be stupid, but avoid zero divide problem in percent calculation just below
- // A..... Resample the postion from the previous range to the new one
- if(i_bResamble != false)
- { // Resample positions to readapt them to the new range
- #ifdef dCSP_SLIDERBAR_METHOD
- // Recalculate start
- m_nLeft = (int) (
- (
- (
- (LONGLONG) // Turns the whole calculation in 64 bits
- (m_nLeft - m_nLower) // Old start
- * (i_nUpper - i_nLower) // New range
- )
- / (m_nUpper - m_nLower) // Old range
- )
- + i_nLower // New start
- );
- m_nPrevLeft = m_nLeft;
- #endif // dCSP_SLIDERBAR_METHOD
- // Recalculate end
- m_nRight = (int) (
- (
- (
- (LONGLONG) // Turns the whole calculation in 64 bits
- (m_nRight - m_nLower) // Old end
- * (i_nUpper - i_nLower) // New range
- )
- / (m_nUpper - m_nLower) // Old range
- )
- + i_nLower // New end
- );
- m_nPrevRight = m_nRight;
- }else{}
- // B..... Set the new range values
- // Sets new parameters for good
- m_nLower = i_nLower;
- m_nUpper = i_nUpper;
- m_nStep = i_nStep;
- // C..... Display the new ranged progress bar
- #ifndef dCSP_TIMED_REDRAW
- if(i_bDisplay != false)
- {
- RefreshPanes();
- }else{}
- #endif // dCSP_TIMED_REDRAW
- return true;
- }
- else
- {
- return false;
- }
- }
- /*--- START FUNCTION HEADER --------------------------------------------------*/
- /* Name : SetPos */
- /* Role : None */
- /* Type : public */
- /* Interface : RETURN (direct value) */
- /* int : Previous <m_nRight> position, 0 if error */
- /* OUTPUT (pointer to value) */
- /* None */
- /* INPUT (pointer to value, direct/default value) */
- /* i_nPos : Select the new position */
- /* i_bDisplay : Display the changes */
- /* Pre-condition : None */
- /* Constraints : None */
- /* Behavior : A - Jump to a specified position */
- /* B - Display the changes */
- /* C - Return the previous position */
- /*----------------------------------------------------------------------------*/
- /* PROC SetPos */
- /* */
- /* A..... Jump to a specified <i_nEnd> position */
- /* B..... Display the changes */
- /* C..... Return the previous <m_nRight> position */
- /*----------------------------------------------------------------------------*/
- /*--- END FUNCTION HEADER ----------------------------------------------------*/
- int CSkinProgress::SetPos
- ( // Set <m_nRight> value
- int i_nPos // Set a new current position
- #ifndef dCSP_TIMED_REDRAW
- ,BOOL i_bDisplay // = true : Display the changes
- #endif // dCSP_TIMED_REDRAW
- )
- {
- // Init
- // Process + Return
- if(IsWindow(GetSafeHwnd()))
- {
- ASSERT((-0x7FFFFFFF <= i_nPos) && (i_nPos <= 0x7FFFFFFF));
- if(i_nPos > m_nUpper)
- { // Avoid problems
- i_nPos = m_nUpper;
- }else{}
- if(i_nPos < m_nLower)
- { // Avoid problems
- i_nPos = m_nLower;
- }else{}
- #ifdef dCSP_SLIDERBAR_METHOD
- if(i_nPos < m_nLeft)
- { // Avoid problems
- i_nPos = m_nLeft;
- }else{}
- #endif // dCSP_SLIDERBAR_METHOD
- m_nPrevRight = m_nRight;
- // A..... Jump to a specified <i_nEnd> position
- m_nRight = i_nPos;
- // B..... Display the changes
- #ifndef dCSP_TIMED_REDRAW
- if(i_bDisplay != false)
- {
- RefreshPanes();
- }else{}
- #endif // dCSP_TIMED_REDRAW
- // C..... Return the previous <m_nRight> position
- return m_nPrevRight;
- }
- else
- {
- return 0;
- }
- }
- /*--- START FUNCTION HEADER --------------------------------------------------*/
- /* Name : OffsetPos */
- /* Role : None */
- /* Type : public */
- /* Interface : RETURN (direct value) */
- /* int : Previous <m_nRight> position, 0 if error */
- /* OUTPUT (pointer to value) */
- /* None */
- /* INPUT (pointer to value, direct/default value) */
- /* i_nOffset : Offset the current position */
- /* i_bDisplay : Display the changes */
- /* Pre-condition : None */
- /* Constraints : None */
- /* Behavior : A - Add an offset to the current position */
- /* B - Display the changes */
- /* C - Return the previous position */
- /*----------------------------------------------------------------------------*/
- /* PROC OffsetPos */
- /* */
- /* A..... Add a <i_nEnd> offset to the current <m_nRight> position */
- /* B..... Display the changes */
- /* C..... Return the previous <m_nRight> position */
- /*----------------------------------------------------------------------------*/
- /*--- END FUNCTION HEADER ----------------------------------------------------*/
- int CSkinProgress::OffsetPos
- ( // Forward of <i_nOffset> value
- int i_nOffset // Add the offset to the current position (can be negative)
- #ifndef dCSP_TIMED_REDRAW
- ,BOOL i_bDisplay // = true : Display the changes
- #endif // dCSP_TIMED_REDRAW
- )
- {
- // Init
- // Process + Return
- if(IsWindow(GetSafeHwnd()))
- {
- m_nPrevRight = m_nRight;
- // A..... Add a <i_nEnd> offset to the current <m_nRight> position
- m_nRight += i_nOffset;
- if(m_nRight > m_nUpper)
- { // Avoid problems
- m_nRight = m_nUpper;
- }else{}
- if(m_nRight < m_nLower)
- { // Avoid problems
- m_nRight = m_nLower;
- }else{}
- #ifdef dCSP_SLIDERBAR_METHOD
- if(m_nRight < m_nLeft)
- { // Avoid problems
- m_nRight = m_nLeft;
- }else{}
- #endif // dCSP_SLIDERBAR_METHOD
- // B..... Display the changes
- #ifndef dCSP_TIMED_REDRAW
- if(i_bDisplay != false)
- {
- RefreshPanes();
- }else{}
- #endif // dCSP_TIMED_REDRAW
- // C..... Return the previous <m_nRight> position
- return m_nPrevRight;
- }
- else
- {
- return 0;
- }
- }
- /*--- START FUNCTION HEADER --------------------------------------------------*/
- /* Name : SetStep */
- /* Role : None */
- /* Type : public */
- /* Interface : RETURN (direct value) */
- /* int : Previous <m_nStep> setting, 0 if error */
- /* OUTPUT (pointer to value) */
- /* None */
- /* INPUT (pointer to value, direct/default value) */
- /* i_nStep : Set the new step increment */
- /* Pre-condition : None */
- /* Constraints : None */
- /* Behavior : A - Set the step increment value */
- /* B - Return the previous step increment value */
- /*----------------------------------------------------------------------------*/
- /* PROC SetStep */
- /* */
- /* A..... Set the <m_nStep> step increment value */
- /* C..... Return the previous <m_nStep> step increment value */
- /*----------------------------------------------------------------------------*/
- /*--- END FUNCTION HEADER ----------------------------------------------------*/
- int CSkinProgress::SetStep
- ( // Set <m_nStep> value
- int i_nStep // Set the step increment
- )
- {
- int PrevStep;
- // Init
- // Process + Return
- if(IsWindow(GetSafeHwnd()))
- {
- PrevStep = m_nStep;
- // A..... Set the <m_nStep> step increment value
- m_nStep = i_nStep;
- // B..... Return the previous <m_nStep> step increment value
- return PrevStep;
- }
- else
- {
- return 0;
- }
- }
- /*--- START FUNCTION HEADER --------------------------------------------------*/
- /* Name : StepIt */
- /* Role : None */
- /* Type : public */
- /* Interface : RETURN (direct value) */
- /* int : Previous <m_nRight> position, 0 if error */
- /* OUTPUT (pointer to value) */
- /* None */
- /* INPUT (pointer to value, direct/default value) */
- /* i_bDisplay : Display the changes */
- /* Pre-condition : None */
- /* Constraints : None */
- /* Behavior : A - Step the position */
- /* B - Display the changes */
- /* C - Return the previous position */
- /*----------------------------------------------------------------------------*/
- /* PROC StepIt */
- /* */
- /* A..... Step the <m_nRight> position from the <m_nStep> increment value */
- /* B..... Display the changes */
- /* C..... Return the previous <m_nRight> position */
- /*----------------------------------------------------------------------------*/
- /*--- END FUNCTION HEADER ----------------------------------------------------*/
- int CSkinProgress::StepIt
- ( // Forward of <m_nStep> value
- #ifndef dCSP_TIMED_REDRAW
- BOOL i_bDisplay // = true : Display the changes
- #endif // dCSP_TIMED_REDRAW
- )
- {
- // Init
- // Process + Return
- if(IsWindow(GetSafeHwnd()))
- {
- m_nPrevRight = m_nRight;
- // A..... Step the <m_nRight> position from the <m_nStep> step increment value
- m_nRight += m_nStep;
- if(m_nRight > m_nUpper)
- { // Avoid problems
- m_nRight = m_nUpper;
- }else{}
- if(m_nRight < m_nLower)
- { // Avoid problems
- m_nRight = m_nLower;
- }else{}
- #ifdef dCSP_SLIDERBAR_METHOD
- if(m_nRight < m_nLeft)
- { // Avoid problems
- m_nRight = m_nLeft;
- }else{}
- #endif // dCSP_SLIDERBAR_METHOD
- // B..... Display the changes
- #ifndef dCSP_TIMED_REDRAW
- if(i_bDisplay != false)
- {
- RefreshPanes();
- }else{}
- #endif // dCSP_TIMED_REDRAW
- // C..... Return the previous <m_nRight> position
- return m_nPrevRight;
- }
- else
- {
- return 0;
- }
- }
- // *** EXTENDED PROGRESS INTERFACE ***
- /*--- START FUNCTION HEADER --------------------------------------------------*/
- /* Name : SetSize */
- /* Role : Change the size of the progress bar if in pane 0 */
- /* Type : public */
- /* Interface : RETURN (direct value) */
- /* BOOL = false : NEVER */
- /* true : ALWAYS */
- /* OUTPUT (pointer to value) */
- /* None */
- /* INPUT (pointer to value, direct/default value) */
- /* i_nSize : The new size of the progress bar in pane 0 */
- /* i_bDisplay : Display the changes */
- /* Pre-condition : None */
- /* Constraints : None */
- /* Behavior : A - Set the new size of the progress bar */
- /* B - Display the resized progress bar */
- /*----------------------------------------------------------------------------*/
- /* PROC SetSize */
- /* */
- /* A..... Set the new size of the progress bar */
- /* B..... Display the resized progress bar */
- /*----------------------------------------------------------------------------*/
- /*--- END FUNCTION HEADER ----------------------------------------------------*/
- BOOL CSkinProgress::SetSize
- ( // Set size of the progress bar in pane 0
- int i_nSize // Set the size of the progress bar
- #ifndef dCSP_TIMED_REDRAW
- ,BOOL i_bDisplay // = true : Display the changes
- #endif // dCSP_TIMED_REDRAW
- )
- {
- // Init
- // A..... Set the new size of the progress bar
- if(i_nSize > 0)
- { // Due to pane anti-disclosure system and progress bar contour, must readapt the size
- i_nSize += 5;
- }
- else if(i_nSize < 0)
- {
- i_nSize -= 2;
- }else{}
- m_nSize = i_nSize;
- // Process
- // B..... Display the resized progress bar
- #ifndef dCSP_TIMED_REDRAW
- if(i_bDisplay != false)
- {
- RefreshPanes();
- }else{}
- #endif // dCSP_TIMED_REDRAW
- // Return
- return true;
- }
- /*--- START FUNCTION HEADER --------------------------------------------------*/
- /* Name : GetSize */
- /* Role : Get width or height of the progress bar */
- /* Type : public */
- /* Interface : RETURN (direct value) */
- /* int : The width or height in pixel of the progress bar */
- /* 0 : Error */
- /* OUTPUT (pointer to value) */
- /* None */
- /* INPUT (pointer to value, direct/default value) */
- /* None */
- /* Pre-condition : None */
- /* Constraints : None */
- /* Behavior : A - Return the current <m_nSize> value */
- /* B - Return the CWnd based pane size */
- /*----------------------------------------------------------------------------*/
- /* PROC SetStart */
- /* */
- /* [IF progress bar in status bar] */
- /* : A..... Return the current <m_nSize> value */
- /* [ELSE] */
- /* : [IF get the target pane rectangle] */
- /* : : B..... Return the CWnd based pane size */
- /* : : [IF the bar is not vertical] */
- /* : : : BA.... Return the width */
- /* : : [ELSE] */
- /* : : : BB.... Return the height */
- /* ; : [ENDIF] */
- /* : [ELSE] */
- /* : [ERROR] */
- /* ; [ENDIF] */
- /* [ENDIF] */
- /*----------------------------------------------------------------------------*/
- /*--- END FUNCTION HEADER ----------------------------------------------------*/
- int CSkinProgress::GetSize
- ( // Get width or height of the progress bar in pixel, mostly used in CSkinSlider