[ros-diffs] [fireball] 30294: Dmitry Chapyshev <lentind at yandex.ru> - Start implementing telephon.cpl. - Delete flags.ico from intl.cpl, it's unused.

fireball at svn.reactos.org fireball at svn.reactos.org
Fri Nov 9 15:56:34 CET 2007


Author: fireball
Date: Fri Nov  9 17:56:33 2007
New Revision: 30294

URL: http://svn.reactos.org/svn/reactos?rev=30294&view=rev
Log:
Dmitry Chapyshev <lentind at yandex.ru>
- Start implementing telephon.cpl.
- Delete flags.ico from intl.cpl, it's unused.

Added:
    trunk/reactos/dll/cpl/telephon/
    trunk/reactos/dll/cpl/telephon/lang/
    trunk/reactos/dll/cpl/telephon/lang/en-US.rc   (with props)
    trunk/reactos/dll/cpl/telephon/lang/ru-RU.rc   (with props)
    trunk/reactos/dll/cpl/telephon/manifest.xml   (with props)
    trunk/reactos/dll/cpl/telephon/resource.h   (with props)
    trunk/reactos/dll/cpl/telephon/resources/
    trunk/reactos/dll/cpl/telephon/resources/applet.ico   (with props)
    trunk/reactos/dll/cpl/telephon/rsrc.rc   (with props)
    trunk/reactos/dll/cpl/telephon/telephon.c   (with props)
    trunk/reactos/dll/cpl/telephon/telephon.def   (with props)
    trunk/reactos/dll/cpl/telephon/telephon.h   (with props)
    trunk/reactos/dll/cpl/telephon/telephon.rbuild   (with props)
    trunk/reactos/dll/cpl/telephon/telephon.rc   (with props)
Removed:
    trunk/reactos/dll/cpl/intl/resources/flags.ico
Modified:
    trunk/reactos/baseaddress.rbuild
    trunk/reactos/dll/cpl/cpl.rbuild

Modified: trunk/reactos/baseaddress.rbuild
URL: http://svn.reactos.org/svn/reactos/trunk/reactos/baseaddress.rbuild?rev=30294&r1=30293&r2=30294&view=diff
==============================================================================
--- trunk/reactos/baseaddress.rbuild (original)
+++ trunk/reactos/baseaddress.rbuild Fri Nov  9 17:56:33 2007
@@ -5,6 +5,7 @@
   <property name="BASEADDRESS_NOTIFYHOOK" value="0x08000000" />
   <property name="BASEADDRESS_COMCAT" value="0x20A50000" />
   <property name="BASEADDRESS_DEVENUM" value="0x35680000" />
+  <property name="BASEADDRESS_TELEPHON" value="0x58750000" />
   <property name="BASEADDRESS_PWRCFG" value="0x587e0000" />
   <property name="BASEADDRESS_MMSYS" value="0x588a0000" />
   <property name="BASEADDRESS_JOY" value="0x589b0000" />

Modified: trunk/reactos/dll/cpl/cpl.rbuild
URL: http://svn.reactos.org/svn/reactos/trunk/reactos/dll/cpl/cpl.rbuild?rev=30294&r1=30293&r2=30294&view=diff
==============================================================================
--- trunk/reactos/dll/cpl/cpl.rbuild (original)
+++ trunk/reactos/dll/cpl/cpl.rbuild Fri Nov  9 17:56:33 2007
@@ -40,6 +40,9 @@
 <directory name="sysdm">
 	<xi:include href="sysdm/sysdm.rbuild" />
 </directory>
+<directory name="telephon">
+	<xi:include href="telephon/telephon.rbuild" />
+</directory>
 <directory name="timedate">
 	<xi:include href="timedate/timedate.rbuild" />
 </directory>

Removed: trunk/reactos/dll/cpl/intl/resources/flags.ico
URL: http://svn.reactos.org/svn/reactos/trunk/reactos/dll/cpl/intl/resources/flags.ico?rev=30293&view=auto
==============================================================================
Binary file - no diff available.

Added: trunk/reactos/dll/cpl/telephon/lang/en-US.rc
URL: http://svn.reactos.org/svn/reactos/trunk/reactos/dll/cpl/telephon/lang/en-US.rc?rev=30294&view=auto
==============================================================================
--- trunk/reactos/dll/cpl/telephon/lang/en-US.rc (added)
+++ trunk/reactos/dll/cpl/telephon/lang/en-US.rc Fri Nov  9 17:56:33 2007
@@ -1,0 +1,7 @@
+LANGUAGE LANG_ENGLISH, SUBLANG_ENGLISH_US
+
+STRINGTABLE 
+BEGIN
+	IDS_CPLSYSTEMNAME "Phone and Modem Options"
+	IDS_CPLSYSTEMDESCRIPTION "Configure your telephone dialing rules and modem settings."
+END

Propchange: trunk/reactos/dll/cpl/telephon/lang/en-US.rc
------------------------------------------------------------------------------
    svn:eol-style = native

Added: trunk/reactos/dll/cpl/telephon/lang/ru-RU.rc
URL: http://svn.reactos.org/svn/reactos/trunk/reactos/dll/cpl/telephon/lang/ru-RU.rc?rev=30294&view=auto
==============================================================================
--- trunk/reactos/dll/cpl/telephon/lang/ru-RU.rc (added)
+++ trunk/reactos/dll/cpl/telephon/lang/ru-RU.rc Fri Nov  9 17:56:33 2007
@@ -1,0 +1,7 @@
+LANGUAGE LANG_RUSSIAN, SUBLANG_DEFAULT
+
+STRINGTABLE 
+BEGIN
+	IDS_CPLSYSTEMNAME "Òåëåôîí è ìîäåì"
+	IDS_CPLSYSTEMDESCRIPTION "Íàñòðîéêà ïðàâèë íàáîðà íîìåðà è äðóãèõ ïàðàìåòðîâ ïðè ðàáîòå ñ ìîäåìîì."
+END

Propchange: trunk/reactos/dll/cpl/telephon/lang/ru-RU.rc
------------------------------------------------------------------------------
    svn:eol-style = native

Added: trunk/reactos/dll/cpl/telephon/manifest.xml
URL: http://svn.reactos.org/svn/reactos/trunk/reactos/dll/cpl/telephon/manifest.xml?rev=30294&view=auto
==============================================================================
--- trunk/reactos/dll/cpl/telephon/manifest.xml (added)
+++ trunk/reactos/dll/cpl/telephon/manifest.xml Fri Nov  9 17:56:33 2007
@@ -1,0 +1,24 @@
+<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
+<assembly xmlns="urn:schemas-microsoft-com:asm.v1" manifestVersion="1.0">
+ <assemblyIdentity
+  version="1.0.0.0"
+  processorArchitecture="X86"
+  name="ReactOS.System.ControlPanel.System"
+  type="win32"
+ />
+ <description>ReactOS System Control Panel</description>
+ <dependency>
+  <dependentAssembly>
+   <assemblyIdentity
+    type="win32"
+    name="Microsoft.Windows.Common-Controls"
+    version="6.0.0.0"
+    processorArchitecture="X86"
+    publicKeyToken="6595b64144ccf1df"
+    language="*"
+   />
+  </dependentAssembly>
+ </dependency>
+</assembly>
+
+<!-- EOF -->

Propchange: trunk/reactos/dll/cpl/telephon/manifest.xml
------------------------------------------------------------------------------
    svn:eol-style = native

Added: trunk/reactos/dll/cpl/telephon/resource.h
URL: http://svn.reactos.org/svn/reactos/trunk/reactos/dll/cpl/telephon/resource.h?rev=30294&view=auto
==============================================================================
--- trunk/reactos/dll/cpl/telephon/resource.h (added)
+++ trunk/reactos/dll/cpl/telephon/resource.h Fri Nov  9 17:56:33 2007
@@ -1,0 +1,13 @@
+#ifndef __CPL_RESOURCE_H
+#define __CPL_RESOURCE_H
+
+/* icons */
+#define IDI_CPLSYSTEM	100
+
+/* strings */
+#define IDS_CPLSYSTEMNAME			1001
+#define IDS_CPLSYSTEMDESCRIPTION	2001
+
+#endif /* __CPL_RESOURCE_H */
+
+/* EOF */

Propchange: trunk/reactos/dll/cpl/telephon/resource.h
------------------------------------------------------------------------------
    svn:eol-style = native

Added: trunk/reactos/dll/cpl/telephon/resources/applet.ico
URL: http://svn.reactos.org/svn/reactos/trunk/reactos/dll/cpl/telephon/resources/applet.ico?rev=30294&view=auto
==============================================================================
Binary file - no diff available.

Propchange: trunk/reactos/dll/cpl/telephon/resources/applet.ico
------------------------------------------------------------------------------
    svn:mime-type = application/octet-stream

Added: trunk/reactos/dll/cpl/telephon/rsrc.rc
URL: http://svn.reactos.org/svn/reactos/trunk/reactos/dll/cpl/telephon/rsrc.rc?rev=30294&view=auto
==============================================================================
--- trunk/reactos/dll/cpl/telephon/rsrc.rc (added)
+++ trunk/reactos/dll/cpl/telephon/rsrc.rc Fri Nov  9 17:56:33 2007
@@ -1,0 +1,5 @@
+#include "resource.h"
+#include <windows.h>
+
+#include "lang/en-US.rc"
+#include "lang/ru-RU.rc"

Propchange: trunk/reactos/dll/cpl/telephon/rsrc.rc
------------------------------------------------------------------------------
    svn:eol-style = native

Added: trunk/reactos/dll/cpl/telephon/telephon.c
URL: http://svn.reactos.org/svn/reactos/trunk/reactos/dll/cpl/telephon/telephon.c?rev=30294&view=auto
==============================================================================
--- trunk/reactos/dll/cpl/telephon/telephon.c (added)
+++ trunk/reactos/dll/cpl/telephon/telephon.c Fri Nov  9 17:56:33 2007
@@ -1,0 +1,121 @@
+/*
+ *  ReactOS
+ *  Copyright (C) 2007 ReactOS Team
+ *
+ *  This program is free software; you can redistribute it and/or modify
+ *  it under the terms of the GNU General Public License as published by
+ *  the Free Software Foundation; either version 2 of the License, or
+ *  (at your option) any later version.
+ *
+ *  This program is distributed in the hope that it will be useful,
+ *  but WITHOUT ANY WARRANTY; without even the implied warranty of
+ *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ *  GNU General Public License for more details.
+ *
+ *  You should have received a copy of the GNU General Public License
+ *  along with this program; if not, write to the Free Software
+ *  Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+ */
+/*
+ *
+ * PROJECT:         		ReactOS Software Control Panel
+ * FILE:            		dll/cpl/telephon/telephon.c
+ * PURPOSE:         		ReactOS Software Control Panel
+ * PROGRAMMER:	Dmitry Chapyshev (lentind at yandex.ru)
+ * UPDATE HISTORY:
+ *	10-19-2007  Created
+ */
+
+#include "telephon.h"
+
+#define NUM_APPLETS	(1)
+
+LONG CALLBACK SystemApplet(VOID);
+HINSTANCE hApplet = 0;
+
+/* Applets */
+
+APPLET Applets[NUM_APPLETS] = 
+{
+    {IDI_CPLSYSTEM, IDS_CPLSYSTEMNAME, IDS_CPLSYSTEMDESCRIPTION, SystemApplet}
+};
+
+/* First Applet */
+LONG CALLBACK
+SystemApplet(VOID)
+{
+    PROPSHEETPAGE psp[1];
+    PROPSHEETHEADER psh;
+    TCHAR Caption[1024];
+
+    LoadString(hApplet, IDS_CPLSYSTEMNAME, Caption, sizeof(Caption) / sizeof(TCHAR));
+
+    ZeroMemory(&psh, sizeof(PROPSHEETHEADER));
+    psh.dwSize = sizeof(PROPSHEETHEADER);
+    psh.dwFlags =  PSH_PROPSHEETPAGE;
+    psh.hwndParent = NULL;
+    psh.hInstance = hApplet;
+    psh.hIcon = LoadIcon(hApplet, MAKEINTRESOURCE(IDI_CPLSYSTEM));
+    psh.pszCaption = Caption;
+    psh.nPages = sizeof(psp) / sizeof(PROPSHEETPAGE);
+    psh.nStartPage = 0;
+    psh.ppsp = psp;
+    psh.pfnCallback = NULL;
+
+    //InitPropSheetPage(&psp[0], IDD_PROPPAGE, (DLGPROC)PageProc);
+
+    return (LONG)(PropertySheet(&psh) != -1);
+}
+
+
+/* Control Panel Callback */
+LONG CALLBACK
+CPlApplet(HWND hwndCPl, UINT uMsg, LPARAM lParam1, LPARAM lParam2)
+{
+    CPLINFO *CPlInfo;
+    DWORD i;
+
+    UNREFERENCED_PARAMETER(hwndCPl);
+
+    i = (DWORD)lParam1;
+    switch (uMsg)
+    {
+        case CPL_INIT:
+            return TRUE;
+
+        case CPL_GETCOUNT:
+            return NUM_APPLETS;
+
+        case CPL_INQUIRE:
+            CPlInfo = (CPLINFO*)lParam2;
+            CPlInfo->lData = 0;
+            CPlInfo->idIcon = Applets[i].idIcon;
+            CPlInfo->idName = Applets[i].idName;
+            CPlInfo->idInfo = Applets[i].idDescription;
+            break;
+
+        case CPL_DBLCLK:
+            Applets[i].AppletProc();
+            break;
+    }
+
+    return FALSE;
+}
+
+
+BOOL WINAPI
+DllMain(HINSTANCE hinstDLL, DWORD dwReason, LPVOID lpvReserved)
+{
+    UNREFERENCED_PARAMETER(lpvReserved);
+
+    switch (dwReason)
+    {
+        case DLL_PROCESS_ATTACH:
+        case DLL_THREAD_ATTACH:
+            CoInitialize(NULL);
+            hApplet = hinstDLL;
+            break;
+    }
+
+    return TRUE;
+}

Propchange: trunk/reactos/dll/cpl/telephon/telephon.c
------------------------------------------------------------------------------
    svn:eol-style = native

Added: trunk/reactos/dll/cpl/telephon/telephon.def
URL: http://svn.reactos.org/svn/reactos/trunk/reactos/dll/cpl/telephon/telephon.def?rev=30294&view=auto
==============================================================================
--- trunk/reactos/dll/cpl/telephon/telephon.def (added)
+++ trunk/reactos/dll/cpl/telephon/telephon.def Fri Nov  9 17:56:33 2007
@@ -1,0 +1,6 @@
+LIBRARY telephon.cpl
+
+EXPORTS
+CPlApplet
+
+; EOF

Propchange: trunk/reactos/dll/cpl/telephon/telephon.def
------------------------------------------------------------------------------
    svn:eol-style = native

Added: trunk/reactos/dll/cpl/telephon/telephon.h
URL: http://svn.reactos.org/svn/reactos/trunk/reactos/dll/cpl/telephon/telephon.h?rev=30294&view=auto
==============================================================================
--- trunk/reactos/dll/cpl/telephon/telephon.h (added)
+++ trunk/reactos/dll/cpl/telephon/telephon.h Fri Nov  9 17:56:33 2007
@@ -1,0 +1,32 @@
+#ifndef __CPL_TELEPHON_H
+#define __CPL_TELEPHON_H
+
+#include <windows.h>
+#include <commctrl.h>
+#include <cpl.h>
+#include <stdlib.h>
+#include <stdio.h>
+#include <stdarg.h>
+#include <tchar.h>
+#include <process.h>
+
+#include "resource.h"
+
+typedef LONG (CALLBACK *CPLAPPLET_PROC)(VOID);
+
+typedef struct
+{
+  int idIcon;
+  int idName;
+  int idDescription;
+  CPLAPPLET_PROC AppletProc;
+} APPLET, *PAPPLET;
+
+
+extern HINSTANCE hApplet;
+
+void ShowLastWin32Error(HWND hWndOwner);
+
+#endif /* __CPL_TELEPHON_H */
+
+/* EOF */

Propchange: trunk/reactos/dll/cpl/telephon/telephon.h
------------------------------------------------------------------------------
    svn:eol-style = native

Added: trunk/reactos/dll/cpl/telephon/telephon.rbuild
URL: http://svn.reactos.org/svn/reactos/trunk/reactos/dll/cpl/telephon/telephon.rbuild?rev=30294&view=auto
==============================================================================
--- trunk/reactos/dll/cpl/telephon/telephon.rbuild (added)
+++ trunk/reactos/dll/cpl/telephon/telephon.rbuild Fri Nov  9 17:56:33 2007
@@ -1,0 +1,19 @@
+<?xml version="1.0"?>
+<!DOCTYPE module SYSTEM "../../../tools/rbuild/project.dtd">
+<module name="telephon" type="win32dll" extension=".cpl" baseaddress="${BASEADDRESS_TELEPHON}"  installbase="system32" installname="telephon.cpl" unicode="yes">
+	<importlibrary definition="telephon.def" />
+	<include base="telephon">.</include>
+	<define name="__USE_W32API" />
+	<define name="_WIN32_IE">0x600</define>
+	<define name="_WIN32_WINNT">0x501</define>
+	<library>kernel32</library>
+	<library>advapi32</library>
+	<library>user32</library>
+	<library>comctl32</library>
+	<library>msvcrt</library>
+	<library>ole32</library>
+	<library>uuid</library>
+	<library>shell32</library>
+	<file>telephon.c</file>
+	<file>telephon.rc</file>
+</module>

Propchange: trunk/reactos/dll/cpl/telephon/telephon.rbuild
------------------------------------------------------------------------------
    svn:eol-style = native

Added: trunk/reactos/dll/cpl/telephon/telephon.rc
URL: http://svn.reactos.org/svn/reactos/trunk/reactos/dll/cpl/telephon/telephon.rc?rev=30294&view=auto
==============================================================================
--- trunk/reactos/dll/cpl/telephon/telephon.rc (added)
+++ trunk/reactos/dll/cpl/telephon/telephon.rc Fri Nov  9 17:56:33 2007
@@ -1,0 +1,20 @@
+#include "resource.h"
+#include <windows.h>
+
+LANGUAGE LANG_NEUTRAL, SUBLANG_NEUTRAL
+
+#define REACTOS_VERSION_DLL
+#define REACTOS_STR_FILE_DESCRIPTION	"ReactOS Software Control Panel\0"
+#define REACTOS_STR_INTERNAL_NAME	"telephon\0"
+#define REACTOS_STR_ORIGINAL_FILENAME	"telephon.cpl\0"
+#ifdef _MSC_VER
+#include <../../../reactos/version.rc>
+#else
+#include <reactos/version.rc>
+#endif
+
+123 24 DISCARDABLE "manifest.xml"
+
+IDI_CPLSYSTEM ICON "resources/applet.ico"
+
+#include "rsrc.rc"

Propchange: trunk/reactos/dll/cpl/telephon/telephon.rc
------------------------------------------------------------------------------
    svn:eol-style = native




More information about the Ros-diffs mailing list