Main Page | Namespace List | Class Hierarchy | Class List | Directories | File List | Namespace Members | Class Members | File Members

PageSettingsBandwidth.h

Go to the documentation of this file.
00001 //
00002 // PageSettingsBandwidth.h
00003 //
00004 // Copyright (c) Shareaza Development Team, 2002-2005.
00005 // This file is part of SHAREAZA (www.shareaza.com)
00006 //
00007 // Shareaza is free software; you can redistribute it
00008 // and/or modify it under the terms of the GNU General Public License
00009 // as published by the Free Software Foundation; either version 2 of
00010 // the License, or (at your option) any later version.
00011 //
00012 // Shareaza is distributed in the hope that it will be useful,
00013 // but WITHOUT ANY WARRANTY; without even the implied warranty of
00014 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00015 // GNU General Public License for more details.
00016 //
00017 // You should have received a copy of the GNU General Public License
00018 // along with Shareaza; if not, write to the Free Software
00019 // Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
00020 //
00021 
00022 #pragma once
00023 
00024 #include "WndSettingsPage.h"
00025 
00026 
00027 class CBandwidthSettingsPage : public CSettingsPage
00028 {
00029 // Construction
00030 public:
00031         CBandwidthSettingsPage();
00032         virtual ~CBandwidthSettingsPage();
00033 
00034         DECLARE_DYNCREATE(CBandwidthSettingsPage)
00035 
00036 // Dialog Data
00037 public:
00038         enum { IDD = IDD_SETTINGS_BANDWIDTH };
00039         CStatic m_wndHeadUP2;
00040         CStatic m_wndHeadUP1;
00041         CStatic m_wndHeadTransmit;
00042         CStatic m_wndHeadReceive;
00043         CString m_sUPInLimit;
00044         CString m_sUPInMax;
00045         CString m_sUPInTotal;
00046         CString m_sUPOutLimit;
00047         CString m_sUPOutMax;
00048         CString m_sUPOutTotal;
00049         CString m_sDLTotal;
00050         CString m_sInTotal;
00051         CString m_sOutTotal;
00052         CString m_sPInTotal;
00053         CString m_sPOutLimit;
00054         CString m_sPOutMax;
00055         CString m_sPOutTotal;
00056         CString m_sULTotal;
00057         CString m_sPInLimit;
00058         CString m_sPInMax;
00059         CString m_sLInLimit;
00060         CString m_sLInMax;
00061         CString m_sLInTotal;
00062         CString m_sLOutLimit;
00063         CString m_sLOutMax;
00064         CString m_sLOutTotal;
00065         CString m_sUDPTotal;
00066 
00067 // Operations
00068 public:
00069         void    Calculate(BOOL bForeward);
00070         void    Calculate(CString& strLimit, int nCount, CString& strCount, CString& strTotal, BOOL bForeward);
00071         DWORD   ToSpeed(CString& str);
00072         CString ToString(DWORD nSpeed, BOOL bUnlimited = TRUE, BOOL bUnit = FALSE);
00073         DWORD   AddString(CString& str);
00074         void    SwapBytesBits(CString& str);
00075 
00076 // Attributes
00077 protected:
00078         BOOL    m_bActive;
00079         BOOL    m_bBytes;
00080 
00081 // Overrides
00082 public:
00083         virtual void OnOK();
00084         virtual BOOL OnSetActive();
00085 protected:
00086         virtual void DoDataExchange(CDataExchange* pDX);    // DDX/DDV support
00087         virtual BOOL OnCommand(WPARAM wParam, LPARAM lParam);
00088         virtual BOOL OnNotify(WPARAM wParam, LPARAM lParam, LRESULT* pResult);
00089 
00090 // Implementation
00091 protected:
00092         DECLARE_MESSAGE_MAP()
00093         virtual BOOL OnInitDialog();
00094         afx_msg void OnTimer(UINT nIDEvent);
00095         afx_msg HBRUSH OnCtlColor(CDC* pDC, CWnd* pWnd, UINT nCtlColor);
00096 
00097 };

Generated on Thu Dec 15 10:39:45 2005 for Shareaza 2.2.1.0 by  doxygen 1.4.2