From: Ged Murphy Date: Fri, 30 Dec 2005 18:19:24 +0000 (+0000) Subject: Put skeleton in place for 'internet time' tab in the 'date and time' control panel... X-Git-Tag: backups/expat-rbuild@40467~683 X-Git-Url: https://git.reactos.org/?p=reactos.git;a=commitdiff_plain;h=ecf93b6c495aa5cd9cc426a867c41b3a3caf356c Put skeleton in place for 'internet time' tab in the 'date and time' control panel applet svn path=/trunk/; revision=20459 --- diff --git a/reactos/lib/cpl/timedate/En.rc b/reactos/lib/cpl/timedate/En.rc index d205e223827..302d2e67721 100644 --- a/reactos/lib/cpl/timedate/En.rc +++ b/reactos/lib/cpl/timedate/En.rc @@ -32,6 +32,22 @@ BEGIN END +IDD_INETTIMEPAGE DIALOGEX 0, 0, 252, 146 +STYLE DS_SETFONT | DS_FIXEDSYS | WS_CHILD | WS_DISABLED | WS_CAPTION +CAPTION "Internet Time" +FONT 8, "MS Shell Dlg", 0, 0, 0x0 +BEGIN + COMBOBOX IDC_SERVERLIST, 65, 22, 117, 136, CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP + CONTROL "Automatically synchronize with an Internet time server", IDC_AUTODAYLIGHT, + "Button", BS_AUTOCHECKBOX | WS_GROUP | WS_TABSTOP,11,7,241,10 + LTEXT "Server:", -1, 34, 22, 28, 13 + PUSHBUTTON "Update Now", IDC_UPDATEBUTTON, 187, 22, 49, 14 + LTEXT "", IDC_SUCSYNC, 16, 54, 214, 23 + LTEXT "", IDC_NEXTSYNC, 12, 96, 137, 12 + LTEXT "Synchronazation can only occur when your computer is connected to the internet.", -1, 12, 114, 225, 25 +END + + STRINGTABLE BEGIN IDS_CPLNAME "Date/Time" @@ -39,4 +55,6 @@ BEGIN IDS_TIMEZONETEXT "Current time zone: %s" IDS_TIMEZONEINVALID "Invalid" IDS_TIMEZONEUNKNOWN "Unknown" + IDS_INETTIMESUCSYNC "The time has been successfully synchronized with %s on % at %s" + IDS_INETTIMENEXTSYNC "Next synchronization: %s at %s" END diff --git a/reactos/lib/cpl/timedate/resource.h b/reactos/lib/cpl/timedate/resource.h index bca49b99325..a1e4534c195 100644 --- a/reactos/lib/cpl/timedate/resource.h +++ b/reactos/lib/cpl/timedate/resource.h @@ -14,11 +14,19 @@ #define IDC_TIMEZONELIST 111 #define IDC_AUTODAYLIGHT 113 +#define IDD_INETTIMEPAGE 120 +#define IDC_SERVERLIST 121 +#define IDC_UPDATEBUTTON 122 +#define IDC_SUCSYNC 126 +#define IDC_NEXTSYNC 127 + #define IDS_CPLNAME 1001 #define IDS_CPLDESCRIPTION 1002 #define IDS_TIMEZONETEXT 1003 #define IDS_TIMEZONEINVALID 1004 #define IDS_TIMEZONEUNKNOWN 1005 +#define IDS_INETTIMESUCSYNC 1006 +#define IDS_INETTIMENEXTSYNC 1007 #endif /* __CPL_RESOURCE_H */ diff --git a/reactos/lib/cpl/timedate/timedate.c b/reactos/lib/cpl/timedate/timedate.c index edec78490ce..da4a9730916 100644 --- a/reactos/lib/cpl/timedate/timedate.c +++ b/reactos/lib/cpl/timedate/timedate.c @@ -176,6 +176,8 @@ DateTimePageProc(HWND hwndDlg, } + + static PTIMEZONE_ENTRY GetLargerTimeZoneEntry(DWORD Index) { @@ -568,6 +570,41 @@ TimeZonePageProc(HWND hwndDlg, } +/* Property page dialog callback */ +INT_PTR CALLBACK +InetTimePageProc(HWND hwndDlg, + UINT uMsg, + WPARAM wParam, + LPARAM lParam) +{ + switch (uMsg) + { + case WM_INITDIALOG: + break; + + case WM_COMMAND: + break; + + case WM_DESTROY: + break; + + case WM_NOTIFY: + { + switch (lParam) + { + + default: + break; + } + + } + break; + } + + return FALSE; +} + + static VOID InitPropSheetPage(PROPSHEETPAGE *psp, WORD idDlg, DLGPROC DlgProc) { @@ -584,7 +621,7 @@ LONG APIENTRY Applet(HWND hwnd, UINT uMsg, LONG wParam, LONG lParam) { PROPSHEETHEADER psh; - PROPSHEETPAGE psp[2]; + PROPSHEETPAGE psp[3]; TCHAR Caption[256]; LoadString(hApplet, IDS_CPLNAME, Caption, sizeof(Caption) / sizeof(TCHAR)); @@ -602,6 +639,7 @@ Applet(HWND hwnd, UINT uMsg, LONG wParam, LONG lParam) InitPropSheetPage(&psp[0], IDD_DATETIMEPAGE, DateTimePageProc); InitPropSheetPage(&psp[1], IDD_TIMEZONEPAGE, TimeZonePageProc); + InitPropSheetPage(&psp[2], IDD_INETTIMEPAGE, InetTimePageProc); return (LONG)(PropertySheet(&psh) != -1); }