ReactOS Fundraising Campaign 2012
 
€ 4,410 / € 30,000

Information | Donate

Home | Info | Community | Development | myReactOS | Contact Us

  1. Home
  2. Community
  3. Development
  4. myReactOS
  5. Fundraiser 2012

  1. Main Page
  2. Alphabetical List
  3. Data Structures
  4. Directories
  5. File List
  6. Data Fields
  7. Globals
  8. Related Pages

ReactOS Development > Doxygen

precomp.h
Go to the documentation of this file.
00001 #ifndef __SERVMAN_PRECOMP_H
00002 #define __SERVMAN_PRECOMP_H
00003 
00004 //#define WIN32_LEAN_AND_MEAN
00005 #include <windows.h>
00006 #include <windowsx.h> /* GET_X/Y_LPARAM */
00007 #include <stdio.h>
00008 #include <tchar.h>
00009 #include <commctrl.h>
00010 #include <shlobj.h>
00011 #include "resource.h"
00012 
00013 #ifdef _MSC_VER
00014 #pragma warning(disable : 4100)
00015 #endif
00016 
00017 #define NO_ITEM_SELECTED -1
00018 #define MAX_KEY_LENGTH 256
00019 
00020 #define LVNAME 0
00021 #define LVDESC 1
00022 #define LVSTATUS 2
00023 #define LVSTARTUP 3
00024 #define LVLOGONAS 4
00025 
00026 #define IMAGE_UNKNOWN 0
00027 #define IMAGE_SERVICE 1
00028 #define IMAGE_DRIVER 2
00029 
00030 typedef struct _MAIN_WND_INFO
00031 {
00032     HWND  hMainWnd;
00033     HWND  hListView;
00034     HWND  hStatus;
00035     HWND  hTool;
00036     HMENU hShortcutMenu;
00037     int   nCmdShow;
00038 
00039     ENUM_SERVICE_STATUS_PROCESS *pAllServices;
00040     ENUM_SERVICE_STATUS_PROCESS *pCurrentService;
00041 
00042     INT SelectedItem;/* selection number in the list view */
00043     BOOL bDlgOpen;
00044     BOOL bInMenuLoop;
00045     BOOL bIsUserAnAdmin;
00046 
00047     PVOID pTag;
00048 
00049 } MAIN_WND_INFO, *PMAIN_WND_INFO;
00050 
00051 
00052 INT_PTR CALLBACK AboutDialogProc(HWND hDlg, UINT message, WPARAM wParam, LPARAM lParam);
00053 INT_PTR CALLBACK CreateDialogProc(HWND hDlg, UINT message, WPARAM wParam, LPARAM lParam);
00054 INT_PTR CALLBACK DeleteDialogProc(HWND hDlg, UINT message, WPARAM wParam, LPARAM lParam);
00055 INT_PTR CALLBACK ProgressDialogProc(HWND hDlg, UINT Message, WPARAM wParam, LPARAM lParam);
00056 
00057 
00058 /* servman.c */
00059 extern HINSTANCE hInstance;
00060 extern HANDLE ProcessHeap;
00061 
00062 /* mainwnd.c */
00063 typedef struct _MENU_HINT
00064 {
00065     WORD CmdId;
00066     UINT HintId;
00067 } MENU_HINT, *PMENU_HINT;
00068 
00069 VOID SetMenuAndButtonStates(PMAIN_WND_INFO Info);
00070 VOID UpdateServiceCount(PMAIN_WND_INFO Info);
00071 VOID ChangeListViewText(PMAIN_WND_INFO Info, ENUM_SERVICE_STATUS_PROCESS* pService, UINT Column);
00072 BOOL InitMainWindowImpl(VOID);
00073 VOID UninitMainWindowImpl(VOID);
00074 HWND CreateMainWindow(LPCTSTR lpCaption, int nCmdShow);
00075 
00076 /* listview.c */
00077 VOID SetListViewStyle(HWND hListView, DWORD View);
00078 VOID ListViewSelectionChanged(PMAIN_WND_INFO Info, LPNMLISTVIEW pnmv);
00079 BOOL CreateListView(PMAIN_WND_INFO Info);
00080 
00081 /* start */
00082 BOOL DoStart(PMAIN_WND_INFO Info, LPWSTR lpStartParams);
00083 
00084 /* stop */
00085 typedef struct _STOP_INFO
00086 {
00087     PMAIN_WND_INFO pInfo;
00088     SC_HANDLE hSCManager;
00089     SC_HANDLE hMainService;
00090 } STOP_INFO, *PSTOP_INFO;
00091 
00092 /* control */
00093 BOOL Control(PMAIN_WND_INFO Info, HWND hProgress, DWORD Control);
00094 BOOL DoStop(PMAIN_WND_INFO Info);
00095 BOOL DoPause(PMAIN_WND_INFO Info);
00096 BOOL DoResume(PMAIN_WND_INFO Info);
00097 
00098 /* progress.c */
00099 #define DEFAULT_STEP 0
00100 HWND CreateProgressDialog(HWND hParent, UINT LabelId);
00101 BOOL DestroyProgressDialog(HWND hProgress, BOOL bComplete);
00102 VOID InitializeProgressDialog(HWND hProgress, LPWSTR lpServiceName);
00103 VOID IncrementProgressBar(HWND hProgress, UINT NewPos);
00104 VOID CompleteProgressBar(HWND hProgress);
00105 
00106 /* query.c */
00107 ENUM_SERVICE_STATUS_PROCESS* GetSelectedService(PMAIN_WND_INFO Info);
00108 LPQUERY_SERVICE_CONFIG GetServiceConfig(LPTSTR lpServiceName);
00109 BOOL SetServiceConfig(LPQUERY_SERVICE_CONFIG pServiceConfig, LPTSTR lpServiceName, LPTSTR lpPassword);
00110 LPTSTR GetServiceDescription(LPTSTR lpServiceName);
00111 BOOL SetServiceDescription(LPTSTR lpServiceName, LPTSTR lpDescription);
00112 LPTSTR GetExecutablePath(LPTSTR lpServiceName);
00113 BOOL RefreshServiceList(PMAIN_WND_INFO Info);
00114 BOOL UpdateServiceStatus(ENUM_SERVICE_STATUS_PROCESS* pService);
00115 BOOL GetServiceList(PMAIN_WND_INFO Info, DWORD *NumServices);
00116 
00117 
00118 /* propsheet.c */
00119 typedef struct _SERVICEPROPSHEET
00120 {
00121     PMAIN_WND_INFO Info;
00122     ENUM_SERVICE_STATUS_PROCESS *pService;
00123     HIMAGELIST hDependsImageList;
00124     HWND hDependsWnd;
00125     HWND hDependsTreeView1;
00126     HWND hDependsTreeView2;
00127 } SERVICEPROPSHEET, *PSERVICEPROPSHEET;
00128 
00129 
00130 HTREEITEM AddItemToTreeView(HWND hTreeView, HTREEITEM hRoot, LPTSTR lpDisplayName, LPTSTR lpServiceName, ULONG serviceType, BOOL bHasChildren);
00131 
00132 /* stop_dependencies */
00133 INT_PTR CALLBACK StopDependsDialogProc(HWND hDlg, UINT message, WPARAM wParam, LPARAM lParam);
00134 LPWSTR GetListOfServicesToStop(LPWSTR lpServiceName);
00135 
00136 /* tv1_dependencies */
00137 BOOL TV1_Initialize(PSERVICEPROPSHEET pDlgInfo, LPTSTR lpServiceName);
00138 VOID TV1_AddDependantsToTree(PSERVICEPROPSHEET pDlgInfo, HTREEITEM hParent, LPTSTR lpServiceName);
00139 
00140 /* tv2_dependencies */
00141 BOOL TV2_Initialize(PSERVICEPROPSHEET pDlgInfo, LPTSTR lpServiceName);
00142 VOID TV2_AddDependantsToTree(PSERVICEPROPSHEET pDlgInfo, HTREEITEM hParent, LPTSTR lpServiceName);
00143 BOOL TV2_HasDependantServices(LPWSTR lpServiceName);
00144 LPENUM_SERVICE_STATUS TV2_GetDependants(LPWSTR lpServiceName, LPDWORD lpdwCount);
00145 
00146 LONG APIENTRY OpenPropSheet(PMAIN_WND_INFO Info);
00147 
00148 /* propsheet window procs */
00149 INT_PTR CALLBACK DependenciesPageProc(HWND hwndDlg,
00150                                       UINT uMsg,
00151                                       WPARAM wParam,
00152                                       LPARAM lParam);
00153 INT_PTR CALLBACK GeneralPageProc(HWND hwndDlg,
00154                                  UINT uMsg,
00155                                  WPARAM wParam,
00156                                  LPARAM lParam);
00157 
00158 /* export.c */
00159 VOID ExportFile(PMAIN_WND_INFO Info);
00160 
00161 /* misc.c */
00162 INT AllocAndLoadString(OUT LPTSTR *lpTarget,
00163                        IN HINSTANCE hInst,
00164                        IN UINT uID);
00165 DWORD LoadAndFormatString(IN HINSTANCE hInstance,
00166                           IN UINT uID,
00167                           OUT LPTSTR *lpTarget,
00168                           ...);
00169 BOOL StatusBarLoadAndFormatString(IN HWND hStatusBar,
00170                                   IN INT PartId,
00171                                   IN HINSTANCE hInstance,
00172                                   IN UINT uID,
00173                                   ...);
00174 BOOL StatusBarLoadString(IN HWND hStatusBar,
00175                          IN INT PartId,
00176                          IN HINSTANCE hInstance,
00177                          IN UINT uID);
00178 INT GetTextFromEdit(OUT LPTSTR lpString,
00179                     IN HWND hDlg,
00180                     IN UINT Res);
00181 VOID GetError(VOID);
00182 VOID DisplayString(PTCHAR);
00183 HIMAGELIST InitImageList(UINT StartResource,
00184                          UINT EndResource,
00185                          UINT Width,
00186                          UINT Height,
00187                          ULONG type);
00188 
00189 #endif /* __SERVMAN_PRECOMP_H */

Generated on Sat May 26 2012 04:15:23 for ReactOS by doxygen 1.7.6.1

ReactOS is a registered trademark or a trademark of ReactOS Foundation in the United States and other countries.