Author: fireball
Date: Tue Oct 16 00:45:06 2007
New Revision: 29614
URL:
http://svn.reactos.org/svn/reactos?rev=29614&view=rev
Log:
Dmitry Chapyshev <lentind(a)yandex.ru>
- Get rid of hardcoded path to downloader.xml, it properly gets the path now. Also changed
the logic slightly: now the file is firstly being searched in the local folder, and only
then in system32.
- Do a Settings dialog (choose a directory where to download files to, if a user wants to
remove installation files after the app has been installed), all options are stored /
loaded from the registry. Only the "Update server" option does not work now.
- A few GUI/designs fixes and improvements, now it looks better.
- Add a button for Settings in the main waindow.
- Fixed code formatting in a few places.
- Change bitmap to icons on the Update and Help buttons, imho it's the proper way.
- Add 3 new categories to the list.
- Other misc fixes.
- All translated resources are updated, so no translations are lost!
Added:
trunk/rosapps/downloader/resources/11.bmp (with props)
trunk/rosapps/downloader/resources/12.bmp (with props)
trunk/rosapps/downloader/resources/13.bmp (with props)
trunk/rosapps/downloader/resources/help.ico (with props)
trunk/rosapps/downloader/resources/preferences.ico (with props)
trunk/rosapps/downloader/resources/update.ico (with props)
Removed:
trunk/rosapps/downloader/resources/help.bmp
trunk/rosapps/downloader/resources/update.bmp
Modified:
trunk/rosapps/downloader/download.c
trunk/rosapps/downloader/downloader.xml
trunk/rosapps/downloader/lang/de-DE.rc
trunk/rosapps/downloader/lang/en-US.rc
trunk/rosapps/downloader/lang/es-ES.rc
trunk/rosapps/downloader/lang/fr-FR.rc
trunk/rosapps/downloader/lang/id-ID.rc
trunk/rosapps/downloader/lang/it-IT.rc
trunk/rosapps/downloader/lang/ru-RU.rc
trunk/rosapps/downloader/lang/uk-UA.rc
trunk/rosapps/downloader/main.c
trunk/rosapps/downloader/resources.h
trunk/rosapps/downloader/rsrc.rc
trunk/rosapps/downloader/xml.c
Modified: trunk/rosapps/downloader/download.c
URL:
http://svn.reactos.org/svn/reactos/trunk/rosapps/downloader/download.c?rev=…
==============================================================================
--- trunk/rosapps/downloader/download.c (original)
+++ trunk/rosapps/downloader/download.c Tue Oct 16 00:45:06 2007
@@ -5,6 +5,7 @@
* COPYRIGHT: Copyright 2001 John R. Sheets (for CodeWeavers)
* Copyright 2004 Mike McCormack (for CodeWeavers)
* Copyright 2005 Ge van Geldorp (gvg(a)reactos.org)
+ * Copyright 2007 Dmitry Chapyshev ()lentind(a)yandex.ru)
*/
/*
* Based on Wine dlls/shdocvw/shdocvw_main.c
@@ -52,17 +53,16 @@
static HRESULT WINAPI
dlQueryInterface(IBindStatusCallback* This, REFIID riid, void** ppvObject)
{
- if (NULL == ppvObject)
- {
- return E_POINTER;
+ if (NULL == ppvObject)
+ {
+ return E_POINTER;
}
- if (IsEqualIID(riid, &IID_IUnknown) ||
- IsEqualIID(riid, &IID_IBindStatusCallback))
- {
- IBindStatusCallback_AddRef( This );
- *ppvObject = This;
- return S_OK;
+ if (IsEqualIID(riid, &IID_IUnknown) || IsEqualIID(riid,
&IID_IBindStatusCallback))
+ {
+ IBindStatusCallback_AddRef( This );
+ *ppvObject = This;
+ return S_OK;
}
return E_NOINTERFACE;
@@ -71,120 +71,119 @@
static ULONG WINAPI
dlAddRef(IBindStatusCallback* iface)
{
- IBindStatusCallbackImpl *This = (IBindStatusCallbackImpl *) iface;
+ IBindStatusCallbackImpl *This = (IBindStatusCallbackImpl *) iface;
- return InterlockedIncrement(&This->ref);
+ return InterlockedIncrement(&This->ref);
}
static ULONG WINAPI
dlRelease(IBindStatusCallback* iface)
{
- IBindStatusCallbackImpl *This = (IBindStatusCallbackImpl *) iface;
- DWORD ref = InterlockedDecrement(&This->ref);
+ IBindStatusCallbackImpl *This = (IBindStatusCallbackImpl *) iface;
+ DWORD ref = InterlockedDecrement(&This->ref);
- if( !ref )
- {
- DestroyWindow( This->hDialog );
- HeapFree(GetProcessHeap(), 0, This);
+ if( !ref )
+ {
+ DestroyWindow( This->hDialog );
+ HeapFree(GetProcessHeap(), 0, This);
}
- return ref;
+ return ref;
}
static HRESULT WINAPI
dlOnStartBinding(IBindStatusCallback* iface, DWORD dwReserved, IBinding* pib)
{
- DPRINT1("OnStartBinding not implemented\n");
-
- return S_OK;
+ DPRINT1("OnStartBinding not implemented\n");
+
+ return S_OK;
}
static HRESULT WINAPI
dlGetPriority(IBindStatusCallback* iface, LONG* pnPriority)
{
- DPRINT1("GetPriority not implemented\n");
-
- return S_OK;
+ DPRINT1("GetPriority not implemented\n");
+
+ return S_OK;
}
static HRESULT WINAPI
dlOnLowResource( IBindStatusCallback* iface, DWORD reserved)
{
- DPRINT1("OnLowResource not implemented\n");
-
- return S_OK;
+ DPRINT1("OnLowResource not implemented\n");
+
+ return S_OK;
}
static HRESULT WINAPI
dlOnProgress(IBindStatusCallback* iface, ULONG ulProgress,
ULONG ulProgressMax, ULONG ulStatusCode, LPCWSTR szStatusText)
{
- IBindStatusCallbackImpl *This = (IBindStatusCallbackImpl *) iface;
- HWND Item;
- LONG r;
- WCHAR OldText[100];
-
- Item = GetDlgItem(This->hDialog, IDC_PROGRESS);
- if (NULL != Item && 0 != ulProgressMax)
- {
- SendMessageW(Item, PBM_SETPOS, (ulProgress * 100) / ulProgressMax, 0);
- }
-
- Item = GetDlgItem(This->hDialog, IDC_STATUS);
- if (NULL != Item && NULL != szStatusText)
- {
- SendMessageW(Item, WM_GETTEXT, sizeof(OldText) / sizeof(OldText[0]),
- (LPARAM) OldText);
- if (sizeof(OldText) / sizeof(OldText[0]) - 1 <= wcslen(OldText) ||
- 0 != wcscmp(OldText, szStatusText))
+ IBindStatusCallbackImpl *This = (IBindStatusCallbackImpl *) iface;
+ HWND Item;
+ LONG r;
+ WCHAR OldText[100];
+
+ Item = GetDlgItem(This->hDialog, IDC_PROGRESS);
+ if (NULL != Item && 0 != ulProgressMax)
+ {
+ SendMessageW(Item, PBM_SETPOS, (ulProgress * 100) / ulProgressMax, 0);
+ }
+
+ Item = GetDlgItem(This->hDialog, IDC_STATUS);
+ if (NULL != Item && NULL != szStatusText)
+ {
+ SendMessageW(Item, WM_GETTEXT, sizeof(OldText) / sizeof(OldText[0]),
+ (LPARAM) OldText);
+ if (sizeof(OldText) / sizeof(OldText[0]) - 1 <= wcslen(OldText) || 0 !=
wcscmp(OldText, szStatusText))
{
- SendMessageW(Item, WM_SETTEXT, 0, (LPARAM) szStatusText);
+ SendMessageW(Item, WM_SETTEXT, 0, (LPARAM) szStatusText);
}
}
- SetLastError(0);
- r = GetWindowLongPtrW(This->hDialog, GWLP_USERDATA);
- if (0 != r || 0 != GetLastError())
- {
- *This->pbCancelled = TRUE;
- DPRINT("Cancelled\n");
- return E_ABORT;
- }
-
- return S_OK;
+ SetLastError(0);
+ r = GetWindowLongPtrW(This->hDialog, GWLP_USERDATA);
+ if (0 != r || 0 != GetLastError())
+ {
+ *This->pbCancelled = TRUE;
+ DPRINT("Cancelled\n");
+ return E_ABORT;
+ }
+
+ return S_OK;
}
static HRESULT WINAPI
dlOnStopBinding(IBindStatusCallback* iface, HRESULT hresult, LPCWSTR szError)
{
- DPRINT1("OnStopBinding not implemented\n");
-
- return S_OK;
+ DPRINT1("OnStopBinding not implemented\n");
+
+ return S_OK;
}
static HRESULT WINAPI
dlGetBindInfo(IBindStatusCallback* iface, DWORD* grfBINDF, BINDINFO* pbindinfo)
{
- DPRINT1("GetBindInfo not implemented\n");
-
- return S_OK;
+ DPRINT1("GetBindInfo not implemented\n");
+
+ return S_OK;
}
static HRESULT WINAPI
dlOnDataAvailable(IBindStatusCallback* iface, DWORD grfBSCF,
DWORD dwSize, FORMATETC* pformatetc, STGMEDIUM* pstgmed)
{
- DPRINT1("OnDataAvailable implemented\n");
-
- return S_OK;
+ DPRINT1("OnDataAvailable implemented\n");
+
+ return S_OK;
}
static HRESULT WINAPI
dlOnObjectAvailable(IBindStatusCallback* iface, REFIID riid, IUnknown* punk)
{
- DPRINT1("OnObjectAvailable implemented\n");
-
- return S_OK;
+ DPRINT1("OnObjectAvailable implemented\n");
+
+ return S_OK;
}
static const IBindStatusCallbackVtbl dlVtbl =
@@ -205,93 +204,124 @@
static IBindStatusCallback*
CreateDl(HWND Dlg, BOOL *pbCancelled)
{
- IBindStatusCallbackImpl *This;
-
- This = HeapAlloc(GetProcessHeap(), 0, sizeof(IBindStatusCallbackImpl));
- This->vtbl = &dlVtbl;
- This->ref = 1;
- This->hDialog = Dlg;
- This->pbCancelled = pbCancelled;
-
- return (IBindStatusCallback*) This;
+ IBindStatusCallbackImpl *This;
+
+ This = HeapAlloc(GetProcessHeap(), 0, sizeof(IBindStatusCallbackImpl));
+ This->vtbl = &dlVtbl;
+ This->ref = 1;
+ This->hDialog = Dlg;
+ This->pbCancelled = pbCancelled;
+
+ return (IBindStatusCallback*) This;
}
static DWORD WINAPI
ThreadFunc(LPVOID Context)
{
- //static const WCHAR szUrl[] = DownloadUrl;
- IBindStatusCallback *dl;
- WCHAR path[MAX_PATH];
- LPWSTR p;
- STARTUPINFOW si;
- PROCESS_INFORMATION pi;
- HWND Dlg = (HWND) Context;
- DWORD r;
- BOOL bCancelled = FALSE;
- BOOL bTempfile = FALSE;
-
- /* built the path for the download */
- p = wcsrchr(SelectedApplication->Location, L'/');
- if (NULL == p)
- {
- goto end;
- }
- if (! GetTempPathW(MAX_PATH, path))
- {
- goto end;
- }
- wcscat(path, p + 1);
-
- /* download it */
- bTempfile = TRUE;
- dl = CreateDl(Context, &bCancelled);
- r = URLDownloadToFileW(NULL, SelectedApplication->Location, path, 0, dl);
- if (NULL != dl)
- {
- IBindStatusCallback_Release(dl);
- }
- if (S_OK != r)
- {
- MessageBoxW(0,Strings[IDS_DOWNLOAD_ERROR],0,0);
- goto end;
- }
- else if (bCancelled)
- {
- goto end;
- }
- ShowWindow(Dlg, SW_HIDE);
-
- /* run it */
- memset(&si, 0, sizeof(si));
- si.cb = sizeof(si);
- r = CreateProcessW(path, NULL, NULL, NULL, 0, 0, NULL, NULL, &si, &pi);
- if (0 == r)
- {
- goto end;
- }
- CloseHandle(pi.hThread);
- WaitForSingleObject(pi.hProcess, INFINITE);
- CloseHandle(pi.hProcess);
-
-end:
- if (bTempfile)
- {
- DeleteFileW(path);
- }
- EndDialog(Dlg, 0);
- return 0;
+ //static const WCHAR szUrl[] = DownloadUrl;
+ IBindStatusCallback *dl;
+ WCHAR path[MAX_PATH];
+ LPWSTR p;
+ STARTUPINFOW si;
+ PROCESS_INFORMATION pi;
+ HWND Dlg = (HWND) Context;
+ DWORD r;
+ BOOL bCancelled = FALSE;
+ BOOL bTempfile = FALSE;
+ HKEY hKey;
+
+ /* built the path for the download */
+ p = wcsrchr(SelectedApplication->Location, L'/');
+ if (NULL == p)
+ {
+ goto end;
+ }
+ if (RegOpenKey(HKEY_LOCAL_MACHINE,
+ TEXT("Software\\ReactOS\\Download!"),
+ &hKey) != ERROR_SUCCESS)
+ {
+ goto end;
+ }
+
+ DWORD dwSize = MAX_PATH;
+ if (RegQueryValueEx(hKey,
+ L"DownloadFolder",
+ NULL,
+ NULL,
+ (LPBYTE)&path,
+ &dwSize) != ERROR_SUCCESS)
+ {
+ goto end;
+ }
+
+ if (GetFileAttributes(path) == 0xFFFFFFFF)
+ if (!CreateDirectory((LPCTSTR)path,NULL))
+ {
+ goto end;
+ }
+ wcscat(path, L"\\");
+ wcscat(path, p + 1);
+
+ /* download it */
+ bTempfile = TRUE;
+ dl = CreateDl(Context, &bCancelled);
+ r = URLDownloadToFileW(NULL, SelectedApplication->Location, path, 0, dl);
+ if (NULL != dl)
+ {
+ IBindStatusCallback_Release(dl);
+ }
+ if (S_OK != r)
+ {
+ MessageBoxW(0,Strings[IDS_DOWNLOAD_ERROR],0,0);
+ goto end;
+ }
+ else if (bCancelled)
+ {
+ goto end;
+ }
+ ShowWindow(Dlg, SW_HIDE);
+
+ /* run it */
+ memset(&si, 0, sizeof(si));
+ si.cb = sizeof(si);
+ r = CreateProcessW(path, NULL, NULL, NULL, 0, 0, NULL, NULL, &si, &pi);
+ if (0 == r)
+ {
+ goto end;
+ }
+ CloseHandle(pi.hThread);
+ WaitForSingleObject(pi.hProcess, INFINITE);
+ CloseHandle(pi.hProcess);
+
+ end:
+ if (bTempfile)
+ {
+ DWORD dwSize = sizeof(DWORD);
+ DWORD dwValue, dwType = REG_DWORD;
+ if (RegQueryValueEx(hKey,
+ L"DeleteInstaller",
+ NULL,
+ &dwType,
+ (LPBYTE)&dwValue,
+ &dwSize) == ERROR_SUCCESS)
+ if (dwValue == 0x1)
+ DeleteFileW(path);
+ RegCloseKey(hKey);
+ }
+ EndDialog(Dlg, 0);
+ return 0;
}
INT_PTR CALLBACK
DownloadProc(HWND Dlg, UINT Msg, WPARAM wParam, LPARAM lParam)
{
- HANDLE Thread;
- DWORD ThreadId;
- HWND Item;
-
- switch (Msg)
- {
- case WM_INITDIALOG:/*
+ HANDLE Thread;
+ DWORD ThreadId;
+ HWND Item;
+
+ switch (Msg)
+ {
+ case WM_INITDIALOG:/*
Icon = LoadIconW((HINSTANCE) GetWindowLongPtr(Dlg, GWLP_HINSTANCE),
MAKEINTRESOURCEW(IDI_ICON_MAIN));
if (NULL != Icon)
@@ -299,12 +329,12 @@
SendMessageW(Dlg, WM_SETICON, ICON_BIG, (LPARAM) Icon);
SendMessageW(Dlg, WM_SETICON, ICON_SMALL, (LPARAM) Icon);
}*/
- SetWindowLongPtrW(Dlg, GWLP_USERDATA, 0);
- Item = GetDlgItem(Dlg, IDC_PROGRESS);
- if (NULL != Item)
+ SetWindowLongPtrW(Dlg, GWLP_USERDATA, 0);
+ Item = GetDlgItem(Dlg, IDC_PROGRESS);
+ if (NULL != Item)
{
- SendMessageW(Item, PBM_SETRANGE, 0, MAKELPARAM(0,100));
- SendMessageW(Item, PBM_SETPOS, 0, 0);
+ SendMessageW(Item, PBM_SETRANGE, 0, MAKELPARAM(0,100));
+ SendMessageW(Item, PBM_SETPOS, 0, 0);
}/*
Item = GetDlgItem(Dlg, IDC_REMOVE);
if (NULL != Item)
@@ -320,27 +350,27 @@
ShowWindow(Item, SW_HIDE);
}
}*/
- Thread = CreateThread(NULL, 0, ThreadFunc, Dlg, 0, &ThreadId);
- if (NULL == Thread)
- {
- return FALSE;
- }
- CloseHandle(Thread);
- return TRUE;
+ Thread = CreateThread(NULL, 0, ThreadFunc, Dlg, 0, &ThreadId);
+ if (NULL == Thread)
+ {
+ return FALSE;
+ }
+ CloseHandle(Thread);
+ return TRUE;
case WM_COMMAND:
- if (wParam == IDCANCEL)
- {
- SetWindowLongPtrW(Dlg, GWLP_USERDATA, 1);
- PostMessage(Dlg, WM_CLOSE, 0, 0);
- }
- return FALSE;
+ if (wParam == IDCANCEL)
+ {
+ SetWindowLongPtrW(Dlg, GWLP_USERDATA, 1);
+ PostMessage(Dlg, WM_CLOSE, 0, 0);
+ }
+ return FALSE;
case WM_CLOSE:
EndDialog(Dlg, 0);
return TRUE;
default:
- return FALSE;
- }
-}
+ return FALSE;
+ }
+}
Modified: trunk/rosapps/downloader/downloader.xml
URL:
http://svn.reactos.org/svn/reactos/trunk/rosapps/downloader/downloader.xml?…
==============================================================================
--- trunk/rosapps/downloader/downloader.xml (original)
+++ trunk/rosapps/downloader/downloader.xml Tue Oct 16 00:45:06 2007
@@ -161,6 +161,12 @@
<location>http://ovh.dl.sourceforge.net/sourceforge/lgames/lmarbles-1.0.6-win32.exe</location>
</application>
</category>
+ <category name="Science" icon="11">
+ </category>
+ <category name="Edutainment" icon="12">
+ </category>
+ <category name="Engineering" icon="13">
+ </category>
<category name="Tools" icon="7">
<application name="7-Zip">
<regname>7-Zip 4.52</regname>
Modified: trunk/rosapps/downloader/lang/de-DE.rc
URL:
http://svn.reactos.org/svn/reactos/trunk/rosapps/downloader/lang/de-DE.rc?r…
==============================================================================
--- trunk/rosapps/downloader/lang/de-DE.rc (original)
+++ trunk/rosapps/downloader/lang/de-DE.rc Tue Oct 16 00:45:06 2007
@@ -10,28 +10,48 @@
PUSHBUTTON "Abbrechen", IDCANCEL, 85, 58, 50, 15, WS_GROUP | WS_TABSTOP
}
+IDD_PROF DIALOGEX 6, 6, 267, 95
+STYLE WS_BORDER | WS_THICKFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU
+CAPTION "Proferences"
+FONT 8, "MS Shell Dlg", 0, 0, 0x0
+BEGIN
+ LTEXT "Download folder:", -1, 6, 10, 140, 8
+ EDITTEXT IDC_DOWNLOAD_FOLDER_EDIT, 6, 20, 205, 14, WS_VISIBLE | WS_TABSTOP
+ PUSHBUTTON "C&hoose...", IDC_CHOOSE_BUTTON, 216, 20, 45, 14
+ AUTOCHECKBOX "&Delete installation files after setup",
IDC_DELINST_FILES_CHECKBOX, 8, 40, 210, 10, WS_GROUP
+ LTEXT "Update server:", -1, 6, 55, 140, 8
+ EDITTEXT IDC_UPDATE_SERVER_EDIT, 6, 65, 255, 14, WS_VISIBLE | WS_TABSTOP
+ DEFPUSHBUTTON "&OK", IDOK, 147, 90, 54, 15
+ PUSHBUTTON "&Cancel", IDCANCEL, 207, 90, 54, 15
+END
+
STRINGTABLE DISCARDABLE
BEGIN
IDS_WINDOW_TITLE "Download ! - ReactOS Downloader"
IDS_WELCOME_TITLE "Willkommen im ReactOS Downloader"
- IDS_WELCOME "Bitte wählen Sie links eine Kategorie. Dies ist Version
1.0."
+ IDS_WELCOME "Bitte wählen Sie links eine Kategorie. Dies ist Version
1.1."
IDS_NO_APP_TITLE "Keine Anwendung ausgewählt"
IDS_NO_APP "Bitte wählen Sie eine Anwendung, bevor Sie die
Download-Schaltfläche betätigen. Wenn Sie Hilfe benötigen, drücken Sie die
Hilfe-Schaltfläche in der oberen rechten Ecke."
IDS_UPDATE_TITLE "Update"
IDS_UPDATE "Diese Funktion wurde noch nicht implementiert."
IDS_HELP_TITLE "Hilfe"
- IDS_HELP "Wählen Sie links eine Kategorie, wählen Sie eine Anwendung und drücken
Sie die Download-Schaltfläche. Um die Anwendungsinformationen zu aktualisieren, drücken
Sie die Schaltfläche neben der Hilfe-Schaltfläche."
+ IDS_HELP "Wählen Sie links eine Kategorie, wählen Sie eine Anwendung und
drücken Sie die Download-Schaltfläche. Um die Anwendungsinformationen zu aktualisieren,
drücken Sie die Schaltfläche neben der Hilfe-Schaltfläche."
IDS_NO_APPS "In dieser Kategorie sind bisher noch keine Anwendungen. Sie können
helfen, indem Sie Anwendungen hinzufügen."
IDS_CHOOSE_APP "Bitte wählen Sie eine Anwendung."
IDS_CHOOSE_SUB "Bitte wählen Sie eine Unterkategorie."
- IDS_CHOOSE_CATEGORY "Bitte wählen Sie eine Kategorie."
+ IDS_CHOOSE_CATEGORY "Bitte wählen Sie eine Kategorie."
IDS_CHOOSE_BOTH "Bitte wählen Sie eine Unterkategorie oder eine Anwendung."
IDS_XMLERROR_1 "XML Datei nicht gefunden!"
IDS_XMLERROR_2 "XML Datei kann nicht verarbeitet werden!"
- IDS_DOWNLOAD_ERROR "Die Datei konnte nicht runtergeladen werden.\nBitte prüfen
sie, ob eine Verbindung zum Internet besteht."
+ IDS_DOWNLOAD_ERROR "Die Datei konnte nicht runtergeladen werden.\nBitte prüfen
sie, ob eine Verbindung zum Internet besteht."
IDS_VERSION "Version: "
IDS_LICENCE "Lizenz: "
IDS_MAINTAINER "Maintainer: "
IDS_APPS_TITLE "Anwendungen"
IDS_CATS_TITLE "Kategorien"
+ IDS_CHOOSE_FOLDER "Please, choose the folder..."
+ IDS_NOTCREATE_REGKEY "Could not create the registry key."
+ IDS_DOWNLOAD_FOLDER "Download!"
+ IDS_UNABLECREATE_FOLDER "Unable to create a folder with this name!"
+ IDS_UPDATE_URL "http://svn.reactos.org"
END
Modified: trunk/rosapps/downloader/lang/en-US.rc
URL:
http://svn.reactos.org/svn/reactos/trunk/rosapps/downloader/lang/en-US.rc?r…
==============================================================================
--- trunk/rosapps/downloader/lang/en-US.rc (original)
+++ trunk/rosapps/downloader/lang/en-US.rc Tue Oct 16 00:45:06 2007
@@ -10,28 +10,48 @@
PUSHBUTTON "Cancel", IDCANCEL, 85, 58, 50, 15, WS_GROUP | WS_TABSTOP
}
+IDD_PROF DIALOGEX 6, 6, 267, 110
+STYLE WS_BORDER | WS_THICKFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU
+CAPTION "Proferences"
+FONT 8, "MS Shell Dlg", 0, 0, 0x0
+BEGIN
+ LTEXT "Download folder:", -1, 6, 10, 140, 8
+ EDITTEXT IDC_DOWNLOAD_FOLDER_EDIT, 6, 20, 205, 14, WS_VISIBLE | WS_TABSTOP
+ PUSHBUTTON "C&hoose...", IDC_CHOOSE_BUTTON, 216, 20, 45, 14
+ AUTOCHECKBOX "&Delete installation files after setup",
IDC_DELINST_FILES_CHECKBOX, 8, 40, 210, 10, WS_GROUP
+ LTEXT "Update server:", -1, 6, 55, 140, 8
+ EDITTEXT IDC_UPDATE_SERVER_EDIT, 6, 65, 255, 14, WS_VISIBLE | WS_TABSTOP
+ DEFPUSHBUTTON "&OK", IDOK, 147, 90, 54, 15
+ PUSHBUTTON "&Cancel", IDCANCEL, 207, 90, 54, 15
+END
+
STRINGTABLE DISCARDABLE
BEGIN
IDS_WINDOW_TITLE "Download ! - ReactOS Downloader"
IDS_WELCOME_TITLE "Welcome to the ReactOS Downloader"
- IDS_WELCOME "Please choose a category on the left. This is version 1.0."
+ IDS_WELCOME "Please choose a category on the left. This is version 1.1."
IDS_NO_APP_TITLE "No application selected"
IDS_NO_APP "Please select a Application before you click the download button,
if you need assistance please click on the question mark button on the top right
corner."
IDS_UPDATE_TITLE "Update"
IDS_UPDATE "Sorry this feature is not implemented yet."
IDS_HELP_TITLE "Help"
- IDS_HELP "Choose a category on the left, then choose a application and click the
download button. To update the application information click the button next to the help
button."
+ IDS_HELP "Choose a category on the left, then choose a application and click
the download button. To update the application information click the button next to the
help button."
IDS_NO_APPS "Sorry, there no applications in this category yet. You can help and
add more applications."
IDS_CHOOSE_APP "Please choose an application."
IDS_CHOOSE_SUB "Please choose a subcategory."
- IDS_CHOOSE_CATEGORY "Please choose a category."
+ IDS_CHOOSE_CATEGORY "Please choose a category."
IDS_CHOOSE_BOTH "Please choose a subcategory or an application."
IDS_XMLERROR_1 "Could not find the xml file !"
IDS_XMLERROR_2 "Could not parse the xml file !"
- IDS_DOWNLOAD_ERROR "Unable to download the file.\nPlease check your internet
connection."
+ IDS_DOWNLOAD_ERROR "Unable to download the file.\nPlease check your internet
connection."
IDS_VERSION "Version: "
IDS_LICENCE "Licence: "
IDS_MAINTAINER "Maintainer: "
IDS_APPS_TITLE "Applications"
IDS_CATS_TITLE "Categories"
+ IDS_CHOOSE_FOLDER "Please, choose the folder..."
+ IDS_NOTCREATE_REGKEY "Could not create the registry key."
+ IDS_DOWNLOAD_FOLDER "Download!"
+ IDS_UNABLECREATE_FOLDER "Unable to create a folder with this name!"
+ IDS_UPDATE_URL "http://svn.reactos.org"
END
Modified: trunk/rosapps/downloader/lang/es-ES.rc
URL:
http://svn.reactos.org/svn/reactos/trunk/rosapps/downloader/lang/es-ES.rc?r…
==============================================================================
--- trunk/rosapps/downloader/lang/es-ES.rc (original)
+++ trunk/rosapps/downloader/lang/es-ES.rc Tue Oct 16 00:45:06 2007
@@ -10,28 +10,48 @@
PUSHBUTTON "Cancel", IDCANCEL, 85, 58, 50, 15, WS_GROUP | WS_TABSTOP
}
+IDD_PROF DIALOGEX 6, 6, 267, 95
+STYLE WS_BORDER | WS_THICKFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU
+CAPTION "Proferences"
+FONT 8, "MS Shell Dlg", 0, 0, 0x0
+BEGIN
+ LTEXT "Download folder:", -1, 6, 10, 140, 8
+ EDITTEXT IDC_DOWNLOAD_FOLDER_EDIT, 6, 20, 205, 14, WS_VISIBLE | WS_TABSTOP
+ PUSHBUTTON "C&hoose...", IDC_CHOOSE_BUTTON, 216, 20, 45, 14
+ AUTOCHECKBOX "&Delete installation files after setup",
IDC_DELINST_FILES_CHECKBOX, 8, 40, 210, 10, WS_GROUP
+ LTEXT "Update server:", -1, 6, 55, 140, 8
+ EDITTEXT IDC_UPDATE_SERVER_EDIT, 6, 65, 255, 14, WS_VISIBLE | WS_TABSTOP
+ DEFPUSHBUTTON "&OK", IDOK, 147, 90, 54, 15
+ PUSHBUTTON "&Cancel", IDCANCEL, 207, 90, 54, 15
+END
+
STRINGTABLE DISCARDABLE
BEGIN
IDS_WINDOW_TITLE "¡Descargar! - Descargador de ReactOS"
IDS_WELCOME_TITLE "Bienvenido al descargador de ReactOS"
- IDS_WELCOME "Por favor selecciona una categoría de la izquierda. Esta es la
versión 1.0."
+ IDS_WELCOME "Por favor selecciona una categoría de la izquierda. Esta es la
versión 1.1."
IDS_NO_APP_TITLE "Ninguna aplicación seleccionada"
IDS_NO_APP "Please select a Application before you click the download button,
if you need assistance please click on the question mark button on the top right
corner."
IDS_UPDATE_TITLE "Actualizar"
IDS_UPDATE "Perdona esta característica no a sido implementada todavía."
IDS_HELP_TITLE "Ayuda"
- IDS_HELP "Selecciona una categoría de la izquierda, entonces selecciona una
aplicación y pulda el botón de descargar. Para actualizar la información de la aplicación
pulsa el botón junto al botón de ayuda."
+ IDS_HELP "Selecciona una categoría de la izquierda, entonces selecciona una
aplicación y pulda el botón de descargar. Para actualizar la información de la aplicación
pulsa el botón junto al botón de ayuda."
IDS_NO_APPS "Perdón, aun no hay ninguna aplicación en esta categoría. Puedes
ayudar y añadir más aplicaciones."
IDS_CHOOSE_APP "Por favor selecciona una aplicación."
IDS_CHOOSE_SUB "Por favor selecciona una subcategoría."
- IDS_CHOOSE_CATEGORY "Por favor selecciona una categoría."
+ IDS_CHOOSE_CATEGORY "Por favor selecciona una categoría."
IDS_CHOOSE_BOTH "Por favor selecciona una subcategoria o una aplicación."
IDS_XMLERROR_1 "¡No se a encontrado el archivo xml!"
IDS_XMLERROR_2 "¡No se ha podido analizar el archivo xml!"
- IDS_DOWNLOAD_ERROR "Imposible descargar el archivo.\nPor favor verifica tu
conexión a internet."
+ IDS_DOWNLOAD_ERROR "Imposible descargar el archivo.\nPor favor verifica tu
conexión a internet."
IDS_VERSION "Version: "
IDS_LICENCE "Licence: "
IDS_MAINTAINER "Maintainer: "
IDS_APPS_TITLE "Applications"
IDS_CATS_TITLE "Categories"
+ IDS_CHOOSE_FOLDER "Please, choose the folder..."
+ IDS_NOTCREATE_REGKEY "Could not create the registry key."
+ IDS_DOWNLOAD_FOLDER "Download!"
+ IDS_UNABLECREATE_FOLDER "Unable to create a folder with this name!"
+ IDS_UPDATE_URL "http://svn.reactos.org"
END
Modified: trunk/rosapps/downloader/lang/fr-FR.rc
URL:
http://svn.reactos.org/svn/reactos/trunk/rosapps/downloader/lang/fr-FR.rc?r…
==============================================================================
--- trunk/rosapps/downloader/lang/fr-FR.rc (original)
+++ trunk/rosapps/downloader/lang/fr-FR.rc Tue Oct 16 00:45:06 2007
@@ -10,28 +10,48 @@
PUSHBUTTON "Annuler", IDCANCEL, 85, 58, 50, 15, WS_GROUP | WS_TABSTOP
}
+IDD_PROF DIALOGEX 6, 6, 267, 95
+STYLE WS_BORDER | WS_THICKFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU
+CAPTION "Proferences"
+FONT 8, "MS Shell Dlg", 0, 0, 0x0
+BEGIN
+ LTEXT "Download folder:", -1, 6, 10, 140, 8
+ EDITTEXT IDC_DOWNLOAD_FOLDER_EDIT, 6, 20, 205, 14, WS_VISIBLE | WS_TABSTOP
+ PUSHBUTTON "C&hoose...", IDC_CHOOSE_BUTTON, 216, 20, 45, 14
+ AUTOCHECKBOX "&Delete installation files after setup",
IDC_DELINST_FILES_CHECKBOX, 8, 40, 210, 10, WS_GROUP
+ LTEXT "Update server:", -1, 6, 55, 140, 8
+ EDITTEXT IDC_UPDATE_SERVER_EDIT, 6, 65, 255, 14, WS_VISIBLE | WS_TABSTOP
+ DEFPUSHBUTTON "&OK", IDOK, 147, 90, 54, 15
+ PUSHBUTTON "&Cancel", IDCANCEL, 207, 90, 54, 15
+END
+
STRINGTABLE DISCARDABLE
BEGIN
IDS_WINDOW_TITLE "Télécharger ! - Téléchargeur de ReactOS"
IDS_WELCOME_TITLE "Bienvenue dans le Téléchargeur de ReactOS"
- IDS_WELCOME "Veuillez choisir une catégorie sur la gauche. C'est la version
1.0."
+ IDS_WELCOME "Veuillez choisir une catégorie sur la gauche. C'est la version
1.1."
IDS_NO_APP_TITLE "Aucune application selectionnée"
IDS_NO_APP "Veuillez sélectionner une application avant de cliquer sur le
bouton Télécharger, si vous avez besoin d'aide, veuillez cliquer sur le point
d'interrogation dans le coin supérieur droit."
IDS_UPDATE_TITLE "Mise à jour"
IDS_UPDATE "Désolé, cette fonctionnalité n'est pas encore
implémentée."
IDS_HELP_TITLE "Aide"
- IDS_HELP "Choisissez une catégorie sur la gauche, puis choisissez une
application et cliquez sur le bouton Télécharger. Pour mettre à jour les informations sur
l'application, cliquez sur le bouton à côté du bouton d'aide."
+ IDS_HELP "Choisissez une catégorie sur la gauche, puis choisissez une
application et cliquez sur le bouton Télécharger. Pour mettre à jour les informations sur
l'application, cliquez sur le bouton à côté du bouton d'aide."
IDS_NO_APPS "Désolé, il n'y a pas encore d'application dans cette
catégorie. Vous pouvez contribuer et ajouter plus d'applications."
IDS_CHOOSE_APP "Veuillez choisir une application."
IDS_CHOOSE_SUB "Veuillez choisir une sous-catégorie."
- IDS_CHOOSE_CATEGORY "Veuillez choisir une catégorie."
+ IDS_CHOOSE_CATEGORY "Veuillez choisir une catégorie."
IDS_CHOOSE_BOTH "Veuillez choisir une sous-catégorie ou une application."
IDS_XMLERROR_1 "Impossible de trouver le fichier xml !"
IDS_XMLERROR_2 "Impossible d'analyser le fichier xml !"
- IDS_DOWNLOAD_ERROR "Impossible de télécharger le fichier.\nVeuillez vérifier
votre connexion Internet."
+ IDS_DOWNLOAD_ERROR "Impossible de télécharger le fichier.\nVeuillez vérifier votre
connexion Internet."
IDS_VERSION "Version: "
IDS_LICENCE "Licence: "
IDS_MAINTAINER "Maintainer: "
IDS_APPS_TITLE "Applications"
IDS_CATS_TITLE "Catégories"
+ IDS_CHOOSE_FOLDER "Please, choose the folder..."
+ IDS_NOTCREATE_REGKEY "Could not create the registry key."
+ IDS_DOWNLOAD_FOLDER "Download!"
+ IDS_UNABLECREATE_FOLDER "Unable to create a folder with this name!"
+ IDS_UPDATE_URL "http://svn.reactos.org"
END
Modified: trunk/rosapps/downloader/lang/id-ID.rc
URL:
http://svn.reactos.org/svn/reactos/trunk/rosapps/downloader/lang/id-ID.rc?r…
==============================================================================
--- trunk/rosapps/downloader/lang/id-ID.rc (original)
+++ trunk/rosapps/downloader/lang/id-ID.rc Tue Oct 16 00:45:06 2007
@@ -10,28 +10,48 @@
PUSHBUTTON "Batal", IDCANCEL, 85, 58, 50, 15, WS_GROUP | WS_TABSTOP
}
+IDD_PROF DIALOGEX 6, 6, 267, 95
+STYLE WS_BORDER | WS_THICKFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU
+CAPTION "Proferences"
+FONT 8, "MS Shell Dlg", 0, 0, 0x0
+BEGIN
+ LTEXT "Download folder:", -1, 6, 10, 140, 8
+ EDITTEXT IDC_DOWNLOAD_FOLDER_EDIT, 6, 20, 205, 14, WS_VISIBLE | WS_TABSTOP
+ PUSHBUTTON "C&hoose...", IDC_CHOOSE_BUTTON, 216, 20, 45, 14
+ AUTOCHECKBOX "&Delete installation files after setup",
IDC_DELINST_FILES_CHECKBOX, 8, 40, 210, 10, WS_GROUP
+ LTEXT "Update server:", -1, 6, 55, 140, 8
+ EDITTEXT IDC_UPDATE_SERVER_EDIT, 6, 65, 255, 14, WS_VISIBLE | WS_TABSTOP
+ DEFPUSHBUTTON "&OK", IDOK, 147, 90, 54, 15
+ PUSHBUTTON "&Cancel", IDCANCEL, 207, 90, 54, 15
+END
+
STRINGTABLE DISCARDABLE
BEGIN
IDS_WINDOW_TITLE "Download ! - ReactOS Downloader"
IDS_WELCOME_TITLE "Selamat datang di ReactOS Downloader"
- IDS_WELCOME "Silahkan pilih kategori di sebelah kiri. Ini versi 1.0."
+ IDS_WELCOME "Silahkan pilih kategori di sebelah kiri. Ini versi 1.1."
IDS_NO_APP_TITLE "Tidak ada aplikasi yang dipilih"
IDS_NO_APP "Silahkan pilih Aplikasi sebelum anda mengklik tombol download,
jika anda membutuhkan asistensi silahkan klik pada tombol di sudut kanan atas."
IDS_UPDATE_TITLE "Mutakhirkan"
IDS_UPDATE "Maaf fitur ini belum diimplementasikan."
IDS_HELP_TITLE "Bantuan"
- IDS_HELP "Pilih kategori di sisi kiri, lalu pilih aplikasi dan klik tombol
download. Untuk memutakhirkan informasi aplikasi klik tombol disebelah tombol
bantuan."
+ IDS_HELP "Pilih kategori di sisi kiri, lalu pilih aplikasi dan klik tombol
download. Untuk memutakhirkan informasi aplikasi klik tombol disebelah tombol
bantuan."
IDS_NO_APPS "Maaf, belum ada aplikasi dalam kategori ini. Anda dapat membantu
dan menambahkan aplikasi lebih banyak."
IDS_CHOOSE_APP "Silahkan pilih aplikasi."
IDS_CHOOSE_SUB "Silahkan pilih subkategori."
- IDS_CHOOSE_CATEGORY "Silahkan pilih kategori."
+ IDS_CHOOSE_CATEGORY "Silahkan pilih kategori."
IDS_CHOOSE_BOTH "Silahkan pilih subkategori atau aplikasi."
IDS_XMLERROR_1 "Tidak dapat menemukan file xml !"
IDS_XMLERROR_2 "Tidak dapat mengurai file xml !"
- IDS_DOWNLOAD_ERROR "Tidak bisa mendownload file.\nSilahkan periksa koneksi
internet anda."
+ IDS_DOWNLOAD_ERROR "Tidak bisa mendownload file.\nSilahkan periksa koneksi
internet anda."
IDS_VERSION "Versi: "
IDS_LICENCE "Lisensi: "
IDS_MAINTAINER "Pemelihara: "
IDS_APPS_TITLE "Applications"
IDS_CATS_TITLE "Categories"
+ IDS_CHOOSE_FOLDER "Please, choose the folder..."
+ IDS_NOTCREATE_REGKEY "Could not create the registry key."
+ IDS_DOWNLOAD_FOLDER "Download!"
+ IDS_UNABLECREATE_FOLDER "Unable to create a folder with this name!"
+ IDS_UPDATE_URL "http://svn.reactos.org"
END
Modified: trunk/rosapps/downloader/lang/it-IT.rc
URL:
http://svn.reactos.org/svn/reactos/trunk/rosapps/downloader/lang/it-IT.rc?r…
==============================================================================
--- trunk/rosapps/downloader/lang/it-IT.rc (original)
+++ trunk/rosapps/downloader/lang/it-IT.rc Tue Oct 16 00:45:06 2007
@@ -10,28 +10,48 @@
PUSHBUTTON "Cancel", IDCANCEL, 85, 58, 50, 15, WS_GROUP | WS_TABSTOP
}
+IDD_PROF DIALOGEX 6, 6, 267, 95
+STYLE WS_BORDER | WS_THICKFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU
+CAPTION "Proferences"
+FONT 8, "MS Shell Dlg", 0, 0, 0x0
+BEGIN
+ LTEXT "Download folder:", -1, 6, 10, 140, 8
+ EDITTEXT IDC_DOWNLOAD_FOLDER_EDIT, 6, 20, 205, 14, WS_VISIBLE | WS_TABSTOP
+ PUSHBUTTON "C&hoose...", IDC_CHOOSE_BUTTON, 216, 20, 45, 14
+ AUTOCHECKBOX "&Delete installation files after setup",
IDC_DELINST_FILES_CHECKBOX, 8, 40, 210, 10, WS_GROUP
+ LTEXT "Update server:", -1, 6, 55, 140, 8
+ EDITTEXT IDC_UPDATE_SERVER_EDIT, 6, 65, 255, 14, WS_VISIBLE | WS_TABSTOP
+ DEFPUSHBUTTON "&OK", IDOK, 147, 90, 54, 15
+ PUSHBUTTON "&Cancel", IDCANCEL, 207, 90, 54, 15
+END
+
STRINGTABLE DISCARDABLE
BEGIN
IDS_WINDOW_TITLE "Download ! - ReactOS Downloader"
IDS_WELCOME_TITLE "Benvenuto al ReactOS Downloader"
- IDS_WELCOME "Scegli una categoria a sinistra. Questa è la versione 1.0."
+ IDS_WELCOME "Scegli una categoria a sinistra. Questa è la versione 1.1."
IDS_NO_APP_TITLE "Nessuna applicazione selezionata"
IDS_NO_APP "Scegli una Applicazione prima di premere il bottone di download,
se serve assistenza clicca sul punto di domanda nell'angolo in alto a destra."
IDS_UPDATE_TITLE "Aggiorna"
IDS_UPDATE "Funzione non ancora implementata."
IDS_HELP_TITLE "Aiuto"
- IDS_HELP "Scegli una categoria a sinistra, poi scegli una applicazione e clicca
il bottone download. Per aggiornare le informazioni sulla applicazione clicca il bottone
accanto a quello di aiuto."
+ IDS_HELP "Scegli una categoria a sinistra, poi scegli una applicazione e clicca
il bottone download. Per aggiornare le informazioni sulla applicazione clicca il bottone
accanto a quello di aiuto."
IDS_NO_APPS "Non ci sono ancora applicazioni in questa categoria. Puoi aiutare
aggiungendone altre."
IDS_CHOOSE_APP "Scegli una applicazione."
IDS_CHOOSE_SUB "Scegli una sottocategoria."
- IDS_CHOOSE_CATEGORY "Scegli una categoria."
+ IDS_CHOOSE_CATEGORY "Scegli una categoria."
IDS_CHOOSE_BOTH "Scegli una sottocategoria o una applicazione."
IDS_XMLERROR_1 "File xml non trovato !"
IDS_XMLERROR_2 "Impossibile trattare il contenuto del file xml !"
- IDS_DOWNLOAD_ERROR "Download del file impossibile.\nVerifica la connessione a
Internet."
+ IDS_DOWNLOAD_ERROR "Download del file impossibile.\nVerifica la connessione a
Internet."
IDS_VERSION "Versione: "
IDS_LICENCE "Licenza: "
IDS_MAINTAINER "Manutentore: "
IDS_APPS_TITLE "Applications"
IDS_CATS_TITLE "Categories"
+ IDS_CHOOSE_FOLDER "Please, choose the folder..."
+ IDS_NOTCREATE_REGKEY "Could not create the registry key."
+ IDS_DOWNLOAD_FOLDER "Download!"
+ IDS_UNABLECREATE_FOLDER "Unable to create a folder with this name!"
+ IDS_UPDATE_URL "http://svn.reactos.org"
END
Modified: trunk/rosapps/downloader/lang/ru-RU.rc
URL:
http://svn.reactos.org/svn/reactos/trunk/rosapps/downloader/lang/ru-RU.rc?r…
==============================================================================
--- trunk/rosapps/downloader/lang/ru-RU.rc (original)
+++ trunk/rosapps/downloader/lang/ru-RU.rc Tue Oct 16 00:45:06 2007
@@ -8,32 +8,52 @@
FONT 8, "MS Shell Dlg"
{
CONTROL
"Progress1",IDC_PROGRESS,"msctls_progress32",WS_BORDER|PBS_SMOOTH,10,10,200,12
- LTEXT "", IDC_STATUS, 10, 30, 200, 10, SS_CENTER
+ LTEXT "", IDC_STATUS, 10, 30, 200, 17, SS_CENTER
PUSHBUTTON "Îòìåíà", IDCANCEL, 85, 58, 50, 15, WS_GROUP | WS_TABSTOP
}
+IDD_PROF DIALOGEX 6, 6, 267, 110
+STYLE WS_BORDER | WS_THICKFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU
+CAPTION "Íàñòðîéêè"
+FONT 8, "MS Shell Dlg", 0, 0, 0x0
+BEGIN
+ LTEXT "Ïàïêà äëÿ çàêà÷êè:", -1, 6, 10, 140, 8
+ EDITTEXT IDC_DOWNLOAD_FOLDER_EDIT, 6, 20, 205, 14, WS_VISIBLE | WS_TABSTOP
+ PUSHBUTTON "&Âûáðàòü...", IDC_CHOOSE_BUTTON, 216, 20, 45, 14
+ AUTOCHECKBOX "&Óäàëÿòü óñòàíîâî÷íûå ôàéëû ïîñëå óñòàíîâêè",
IDC_DELINST_FILES_CHECKBOX, 8, 40, 210, 10, WS_GROUP
+ LTEXT "Ñåðâåð îáíîâëåíèé:", -1, 6, 55, 140, 8
+ EDITTEXT IDC_UPDATE_SERVER_EDIT, 6, 65, 255, 14, WS_VISIBLE | WS_TABSTOP
+ DEFPUSHBUTTON "&OK", IDOK, 147, 90, 54, 15
+ PUSHBUTTON "Î&òìåíà", IDCANCEL, 207, 90, 54, 15
+END
+
STRINGTABLE DISCARDABLE
BEGIN
- IDS_WINDOW_TITLE "Ñêà÷àòü! - ReactOS Downloader"
- IDS_WELCOME_TITLE "Äîáðî ïîæàëîâàòü â ReactOS Downloader"
- IDS_WELCOME "Ïîæàëóéñòà âûáåðèòå êàòåãîðèþ ñïðàâà. Âåðñèÿ 1.0."
+ IDS_WINDOW_TITLE "Ñêà÷àòü! - Ìåíåäæåð çàêà÷åê ReactOS"
+ IDS_WELCOME_TITLE "Äîáðî ïîæàëîâàòü â Ìåíåäæåð çàêà÷åê ReactOS"
+ IDS_WELCOME "Ïîæàëóéñòà âûáåðèòå êàòåãîðèþ ñïðàâà. Âåðñèÿ 1.1"
IDS_NO_APP_TITLE "Ïðèëîæåíèå íå âûáðàíî"
IDS_NO_APP "Ïîæàëóéñòà, âûáåðèòå ïðèëîæåíèå ïðåæäå, ÷åì íàæàòü êíîïêó
çàãðóçêè. Åñëè âàì íóæíà ñïðàâêà, òî íàæìèòå êíîïêó ñî çíàêîì âîïðîñà â âåðõíåì ïðàâîì
óãëó."
IDS_UPDATE_TITLE "Îáíîâèòü"
IDS_UPDATE "Èçâåíèòå, äàííàÿ âîçìîæíîñòü íà äàííûì ìîìåíò íåäîñòóïíà."
IDS_HELP_TITLE "Ñïðàâêà"
- IDS_HELP "Âûáåðèòå êàòåãîðèþ ñëåâà, çàòåì âûáåðèòå ïðèëîæåíèå è íàæìèòå êíîïêó
çàãðóçêè. Äëÿ ïîëó÷åíèÿ èíôîðìàöèè îá îáíîâëåíèÿõ íàæìèòå êíîïêó ðÿäîì ñ êíîïêîé
ñïðàâêè."
+ IDS_HELP "Âûáåðèòå êàòåãîðèþ ñëåâà, çàòåì âûáåðèòå ïðèëîæåíèå è íàæìèòå êíîïêó
çàãðóçêè. Äëÿ ïîëó÷åíèÿ èíôîðìàöèè îá îáíîâëåíèÿõ íàæìèòå êíîïêó ðÿäîì ñ êíîïêîé
ñïðàâêè."
IDS_NO_APPS "Èçâåíèòå, íà äàííûé ìîìåíò â ýòîé êàòåãîðèè ïðèëîæåíèé íåò, íî âû
ìîæåòå ïîìî÷ü äîáàâèòü èõ."
IDS_CHOOSE_APP "Ïîæàëóéñòà âûáåðèòå ïðèëîæåíèå."
IDS_CHOOSE_SUB "Ïîæàëóéñòà âûáåðèòå ïîäêàòåãîðèþ."
- IDS_CHOOSE_CATEGORY "Ïîæàëóéñòà âûáåðèòå êàòåãîðèþ."
+ IDS_CHOOSE_CATEGORY "Ïîæàëóéñòà âûáåðèòå êàòåãîðèþ."
IDS_CHOOSE_BOTH "Ïîæàëóéñòà âûáåðèòå ïîäêàòåãîðèþ èëè ïðèëîæåíèå."
IDS_XMLERROR_1 "Íå óäàëîñü íàéòè xml-ôàéë!"
IDS_XMLERROR_2 "Íå óäàëîñü îáðàáîòàòü xml-ôàéë!"
- IDS_DOWNLOAD_ERROR "Íå óäàåòñÿ çàãðóçèòü ôàéë.\nÏîæàëóéñòà ïðîâåðüòå âàøå
ïîäêëþ÷åíèå ê èíòåðíåò."
+ IDS_DOWNLOAD_ERROR "Íå óäàåòñÿ çàãðóçèòü ôàéë.\nÏîæàëóéñòà ïðîâåðüòå âàøå
ïîäêëþ÷åíèå ê èíòåðíåò."
IDS_VERSION "Âåðñèÿ: "
IDS_LICENCE "Ëèöåíçèÿ: "
IDS_MAINTAINER "Ïðîèçâîäèòåëü: "
- IDS_APPS_TITLE "Applications"
- IDS_CATS_TITLE "Categories"
+ IDS_APPS_TITLE "Ïðèëîæåíèÿ"
+ IDS_CATS_TITLE "Êàòåãîðèè"
+ IDS_CHOOSE_FOLDER "Ïîæàëóéñòâà âûáåðèòå ïàïêó..."
+ IDS_NOTCREATE_REGKEY "Íå óäàëîñü ñîçäàòü êëþ÷ â ðååñòðå."
+ IDS_DOWNLOAD_FOLDER "Ñêà÷àòü!"
+ IDS_UNABLECREATE_FOLDER "Íå óäàëîñü ñîçäàòü ïàïêó ñ òàêèì èìåíåì!"
+ IDS_UPDATE_URL "http://svn.reactos.org"
END
Modified: trunk/rosapps/downloader/lang/uk-UA.rc
URL:
http://svn.reactos.org/svn/reactos/trunk/rosapps/downloader/lang/uk-UA.rc?r…
==============================================================================
--- trunk/rosapps/downloader/lang/uk-UA.rc (original)
+++ trunk/rosapps/downloader/lang/uk-UA.rc Tue Oct 16 00:45:06 2007
@@ -18,28 +18,48 @@
PUSHBUTTON "Ñêàñóâàòè", IDCANCEL, 85, 58, 50, 15, WS_GROUP | WS_TABSTOP
}
+IDD_PROF DIALOGEX 6, 6, 267, 95
+STYLE WS_BORDER | WS_THICKFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU
+CAPTION "Proferences"
+FONT 8, "MS Shell Dlg", 0, 0, 0x0
+BEGIN
+ LTEXT "Download folder:", -1, 6, 10, 140, 8
+ EDITTEXT IDC_DOWNLOAD_FOLDER_EDIT, 6, 20, 205, 14, WS_VISIBLE | WS_TABSTOP
+ PUSHBUTTON "C&hoose...", IDC_CHOOSE_BUTTON, 216, 20, 45, 14
+ AUTOCHECKBOX "&Delete installation files after setup",
IDC_DELINST_FILES_CHECKBOX, 8, 40, 210, 10, WS_GROUP
+ LTEXT "Update server:", -1, 6, 55, 140, 8
+ EDITTEXT IDC_UPDATE_SERVER_EDIT, 6, 65, 255, 14, WS_VISIBLE | WS_TABSTOP
+ DEFPUSHBUTTON "&OK", IDOK, 147, 90, 54, 15
+ PUSHBUTTON "&Cancel", IDCANCEL, 207, 90, 54, 15
+END
+
STRINGTABLE DISCARDABLE
BEGIN
IDS_WINDOW_TITLE "Çàâàíòàæèòè ! - Çàâàíòàæóâà÷ ReactOS"
IDS_WELCOME_TITLE "Ëàñêàâî ïðîñèìî ó Çàâàíòàæóâà÷ ReactOS"
- IDS_WELCOME "Áóäü ëàñêà âèáåð³òü êàòåãîð³þ çë³âà. Öå âåðñ³ÿ 1.0."
+ IDS_WELCOME "Áóäü ëàñêà âèáåð³òü êàòåãîð³þ çë³âà. Öå âåðñ³ÿ 1.1."
IDS_NO_APP_TITLE "Äîäàòîê íå âèáðàíèé"
IDS_NO_APP "Áóäü ëàñêà, âèáåð³òü äîäàòîê ïåðø í³æ íàòèñíóòè êíîïêó
çàâàíòàæåííÿ. ßêùî Âàì ïîòð³áíà äîïîìîãà, íàòèñí³òü êíîïêó ç³ çíàêîì ïèòàííÿ ó âåðõíüîìó
ïðàâîìó êóòêó."
IDS_UPDATE_TITLE "Îíîâèòè"
IDS_UPDATE "Âèáà÷òå, äàíà ìîæëèâ³ñòü ùå íåäîñòóïíà."
IDS_HELP_TITLE "Äîâ³äêà"
- IDS_HELP "Âèáåð³òü êàòåãîð³þ çë³âà, ïîò³ì âèáåð³òü äîäàòîê ³ íàòèñí³òü êíîïêó
çàâàíòàæåííÿ. Äëÿ îòðèìàííÿ ³íôîðìàö³¿ ïðî îíîâëåííÿ íàòèñí³òü êíîïêó ïîðÿä ç êíîïêîþ
äîâ³äêè."
+ IDS_HELP "Âèáåð³òü êàòåãîð³þ çë³âà, ïîò³ì âèáåð³òü äîäàòîê ³ íàòèñí³òü êíîïêó
çàâàíòàæåííÿ. Äëÿ îòðèìàííÿ ³íôîðìàö³¿ ïðî îíîâëåííÿ íàòèñí³òü êíîïêó ïîðÿä ç êíîïêîþ
äîâ³äêè."
IDS_NO_APPS "Âèáà÷òå, â ö³é êàòåãî𳿠ùå íåìຠäîäàòê³â. Âè ìîæåòå äîïîìîãòè ³
äîäàòè á³ëüøå äîäàòê³â."
IDS_CHOOSE_APP "Áóäü ëàñêà âèáåð³òü äîäàòîê."
IDS_CHOOSE_SUB "Áóäü ëàñêà âèáåð³òü ï³äêàòåãîð³þ."
- IDS_CHOOSE_CATEGORY "Áóäü ëàñêà âèáåð³òü êàòåãîð³þ."
+ IDS_CHOOSE_CATEGORY "Áóäü ëàñêà âèáåð³òü êàòåãîð³þ."
IDS_CHOOSE_BOTH "Áóäü ëàñêà âèáåð³òü ï³äêàòåãîð³þ àáî äîäàòîê."
IDS_XMLERROR_1 "Íå âäàëîñÿ çíàéòè ôàéë xml !"
IDS_XMLERROR_2 "Íå âäàëîñÿ îáðîáèòè ôàéë xml !"
- IDS_DOWNLOAD_ERROR "Íåìîæëèâî çàâàíòàæèòè ôàéë.\nÁóäü ëàñêà ïåðåâ³ðòå âàøå
³íòåðíåò-ç'ºäíàííÿ."
+ IDS_DOWNLOAD_ERROR "Íåìîæëèâî çàâàíòàæèòè ôàéë.\nÁóäü ëàñêà ïåðåâ³ðòå âàøå
³íòåðíåò-ç'ºäíàííÿ."
IDS_VERSION "Âåðñ³ÿ: "
IDS_LICENCE "˳öåíç³ÿ: "
IDS_MAINTAINER "Âèðîáíèê: "
IDS_APPS_TITLE "Applications"
IDS_CATS_TITLE "Categories"
+ IDS_CHOOSE_FOLDER "Please, choose the folder..."
+ IDS_NOTCREATE_REGKEY "Could not create the registry key."
+ IDS_DOWNLOAD_FOLDER "Download!"
+ IDS_UNABLECREATE_FOLDER "Unable to create a folder with this name!"
+ IDS_UPDATE_URL "http://svn.reactos.org"
END
Modified: trunk/rosapps/downloader/main.c
URL:
http://svn.reactos.org/svn/reactos/trunk/rosapps/downloader/main.c?rev=2961…
==============================================================================
--- trunk/rosapps/downloader/main.c (original)
+++ trunk/rosapps/downloader/main.c Tue Oct 16 00:45:06 2007
@@ -8,14 +8,14 @@
#include <windows.h>
#include <commctrl.h>
#include <richedit.h>
+#include <tchar.h>
#include <stdio.h>
#include <shlwapi.h>
+#include <shlobj.h>
#include "resources.h"
#include "structures.h"
-#define XML_PATH "C:\\ReactOS\\system32\\downloader.xml"
-
-HWND hwnd, hCategories, hApps, hDownloadButton, hUninstallButton, hUpdateButton,
hHelpButton;
+HWND hwnd, hCategories, hApps, hDownloadButton, hUninstallButton, hUpdateButton,
hHelpButton, hProfButton;
HBITMAP hLogo, hUnderline;
WCHAR* DescriptionHeadline = L"";
WCHAR* DescriptionText = L"";
@@ -30,7 +30,8 @@
WCHAR Strings [STRING_COUNT][MAX_STRING_LENGHT];
-BOOL getUninstaller(WCHAR* RegName, WCHAR* Uninstaller) {
+BOOL
+getUninstaller(WCHAR* RegName, WCHAR* Uninstaller) {
const DWORD ArraySize = 200;
@@ -69,7 +70,8 @@
return FALSE;
}
-void ShowMessage (WCHAR* title, WCHAR* message)
+void
+ShowMessage (WCHAR* title, WCHAR* message)
{
DescriptionHeadline = title;
DescriptionText = message;
@@ -77,7 +79,8 @@
UpdateWindow(hwnd);
}
-void AddItems (HWND hwnd, struct Category* Category, struct Category* Parent)
+void
+AddItems(HWND hwnd, struct Category* Category, struct Category* Parent)
{
TV_INSERTSTRUCTW Insert;
@@ -99,7 +102,8 @@
AddItems (hwnd,Category->Children,Category);
}
-void CategoryChoosen (HWND hwnd, struct Category* Category)
+void
+CategoryChoosen(HWND hwnd, struct Category* Category)
{
struct Application* CurrentApplication;
TV_INSERTSTRUCTW Insert;
@@ -139,39 +143,84 @@
}
}
-BOOL SetupControls (HWND hwnd)
+BOOL
+SetupControls (HWND hwnd)
{
TV_INSERTSTRUCTW Insert = {0};
HIMAGELIST hImageList;
HINSTANCE hInstance = GetModuleHandle(NULL);
WCHAR Cats[MAX_STRING_LENGHT], Apps[MAX_STRING_LENGHT];
-
+ TCHAR Buf[MAX_PATH];
+ char Tmp[MAX_PATH];
+ int i;
+
+ // Getting downloader.xml path
+ if(!GetSystemDirectory(Buf,sizeof(Buf)/sizeof(char))) return FALSE;
+ lstrcat((LPTSTR)Buf, L"\\downloader.xml");
+ for (i = 0; i < _tcslen(Buf) + 1; i++) Tmp[i] = Buf[i];
+
// Parse the XML file
- if (ProcessXML (XML_PATH, &Root) == FALSE)
+ if (!ProcessXML(Tmp, &Root))
return FALSE;
- LoadStringW(hInstance, IDS_CATS_TITLE, Cats, MAX_STRING_LENGHT);
- LoadStringW(hInstance, IDS_APPS_TITLE, Apps, MAX_STRING_LENGHT);
+ LoadStringW(hInstance, IDS_CATS_TITLE, Cats, MAX_STRING_LENGHT);
+ LoadStringW(hInstance, IDS_APPS_TITLE, Apps, MAX_STRING_LENGHT);
// Set up the controls
- hCategories = CreateWindowExW(0, WC_TREEVIEWW, Cats,
WS_CHILD|WS_VISIBLE|WS_BORDER|TVS_HASLINES|TVS_LINESATROOT|TVS_HASBUTTONS|TVS_SHOWSELALWAYS,
+ hCategories = CreateWindowExW(0, WC_TREEVIEWW, Cats,
+
WS_CHILD|WS_VISIBLE|WS_BORDER|TVS_HASLINES|TVS_LINESATROOT|TVS_HASBUTTONS|TVS_SHOWSELALWAYS,
+ 0, 0, 0, 0, hwnd, NULL, hInstance, NULL);
+
+ hApps = CreateWindowExW(0, WC_TREEVIEWW, Apps,
+ WS_CHILD|WS_VISIBLE|WS_BORDER|TVS_HASLINES|TVS_LINESATROOT|TVS_HASBUTTONS|TVS_SHOWSELALWAYS,
0, 0, 0, 0, hwnd, NULL, hInstance, NULL);
- hApps = CreateWindowExW(0, WC_TREEVIEWW, Apps,
WS_CHILD|WS_VISIBLE|WS_BORDER|TVS_HASLINES|TVS_LINESATROOT|TVS_HASBUTTONS|TVS_SHOWSELALWAYS,
- 0, 0, 0, 0, hwnd, NULL, hInstance, NULL);
-
- hLogo = LoadBitmap(GetModuleHandle(NULL), MAKEINTRESOURCE(IDB_LOGO));
- hUnderline = LoadBitmap(GetModuleHandle(NULL), MAKEINTRESOURCE(IDB_UNDERLINE));
-
- hHelpButton = CreateWindowW (L"Button", L"",
WS_CHILD|WS_VISIBLE|BS_BITMAP, 550, 10, 40, 40, hwnd, 0, hInstance, NULL);
- hUpdateButton = CreateWindowW (L"Button", L"",
WS_CHILD|WS_VISIBLE|BS_BITMAP, 500, 10, 40, 40, hwnd, 0, hInstance, NULL);
- hDownloadButton = CreateWindowW (L"Button", L"",
WS_CHILD|WS_VISIBLE|BS_BITMAP, 330, 505, 140, 33, hwnd, 0, hInstance, NULL);
- hUninstallButton = CreateWindowW (L"Button", L"",
WS_CHILD|WS_VISIBLE|BS_BITMAP, 260, 505, 140, 33, hwnd, 0, hInstance, NULL);
-
- SendMessageW(hHelpButton, BM_SETIMAGE, (WPARAM)IMAGE_BITMAP,
(LPARAM)(HANDLE)LoadBitmap(hInstance, MAKEINTRESOURCE(IDB_HELP)));
- SendMessageW(hUpdateButton, BM_SETIMAGE,
(WPARAM)IMAGE_BITMAP,(LPARAM)(HANDLE)LoadBitmap(hInstance, MAKEINTRESOURCE(IDB_UPDATE)));
- SendMessageW(hDownloadButton, BM_SETIMAGE,
(WPARAM)IMAGE_BITMAP,(LPARAM)(HANDLE)LoadBitmap(hInstance,
MAKEINTRESOURCE(IDB_DOWNLOAD)));
- SendMessageW(hUninstallButton, BM_SETIMAGE,
(WPARAM)IMAGE_BITMAP,(LPARAM)(HANDLE)LoadBitmap(hInstance,
MAKEINTRESOURCE(IDB_UNINSTALL)));
+ hLogo = LoadBitmap(GetModuleHandle(NULL),
+ MAKEINTRESOURCE(IDB_LOGO));
+ hUnderline = LoadBitmap(GetModuleHandle(NULL),
+ MAKEINTRESOURCE(IDB_UNDERLINE));
+
+ hHelpButton = CreateWindowW(L"Button", L"",
+ WS_CHILD | WS_VISIBLE | BS_ICON,
+ 550, 10, 40, 40,
+ hwnd, 0, hInstance, NULL);
+ hUpdateButton = CreateWindowW(L"Button", L"",
+ WS_CHILD | WS_VISIBLE | BS_ICON,
+ 450, 10, 40, 40,
+ hwnd, 0, hInstance, NULL);
+ hProfButton = CreateWindowW(L"Button", L"",
+ WS_CHILD | WS_VISIBLE | BS_ICON,
+ 500, 10, 40, 40,
+ hwnd, 0, hInstance, NULL);
+ hDownloadButton = CreateWindowW(L"Button", L"",
+ WS_CHILD | WS_VISIBLE | BS_BITMAP,
+ 330, 505, 140, 33,
+ hwnd, 0, hInstance, NULL);
+ hUninstallButton = CreateWindowW(L"Button", L"",
+ WS_CHILD | WS_VISIBLE | BS_BITMAP,
+ 260, 505, 140, 33,
+ hwnd, 0, hInstance, NULL);
+
+ SendMessageW(hProfButton,
+ BM_SETIMAGE,
+ (WPARAM)IMAGE_ICON,
+ (LPARAM)(HANDLE)LoadIcon(hInstance,MAKEINTRESOURCE(IDI_PROF)));
+ SendMessageW(hHelpButton,
+ BM_SETIMAGE,
+ (WPARAM)IMAGE_ICON,
+ (LPARAM)(HANDLE)LoadIcon(hInstance, MAKEINTRESOURCE(IDI_HELP)));
+ SendMessageW(hUpdateButton,
+ BM_SETIMAGE,
+ (WPARAM)IMAGE_ICON,
+ (LPARAM)(HANDLE)LoadIcon(hInstance, MAKEINTRESOURCE(IDI_UPDATE)));
+ SendMessageW(hDownloadButton,
+ BM_SETIMAGE,
+ (WPARAM)IMAGE_BITMAP,
+ (LPARAM)(HANDLE)LoadBitmap(hInstance, MAKEINTRESOURCE(IDB_DOWNLOAD)));
+ SendMessageW(hUninstallButton,
+ BM_SETIMAGE,
+ (WPARAM)IMAGE_BITMAP,
+ (LPARAM)(HANDLE)LoadBitmap(hInstance, MAKEINTRESOURCE(IDB_UNINSTALL)));
ShowWindow(hUninstallButton, SW_HIDE);
// Set deflaut entry for hApps
@@ -186,17 +235,34 @@
SendMessageW(hCategories, TVM_SETIMAGELIST, TVSIL_NORMAL,
(LPARAM)(HIMAGELIST)hImageList);
SendMessageW(hApps, TVM_SETIMAGELIST, TVSIL_NORMAL, (LPARAM)(HIMAGELIST)hImageList);
- ImageList_Add(hImageList, LoadBitmap(hInstance, MAKEINTRESOURCE(IDB_TREEVIEW_ICON_0)),
NULL);
- ImageList_Add(hImageList, LoadBitmap(hInstance, MAKEINTRESOURCE(IDB_TREEVIEW_ICON_1)),
NULL);
- ImageList_Add(hImageList, LoadBitmap(hInstance, MAKEINTRESOURCE(IDB_TREEVIEW_ICON_2)),
NULL);
- ImageList_Add(hImageList, LoadBitmap(hInstance, MAKEINTRESOURCE(IDB_TREEVIEW_ICON_3)),
NULL);
- ImageList_Add(hImageList, LoadBitmap(hInstance, MAKEINTRESOURCE(IDB_TREEVIEW_ICON_4)),
NULL);
- ImageList_Add(hImageList, LoadBitmap(hInstance, MAKEINTRESOURCE(IDB_TREEVIEW_ICON_5)),
NULL);
- ImageList_Add(hImageList, LoadBitmap(hInstance, MAKEINTRESOURCE(IDB_TREEVIEW_ICON_6)),
NULL);
- ImageList_Add(hImageList, LoadBitmap(hInstance, MAKEINTRESOURCE(IDB_TREEVIEW_ICON_7)),
NULL);
- ImageList_Add(hImageList, LoadBitmap(hInstance, MAKEINTRESOURCE(IDB_TREEVIEW_ICON_8)),
NULL);
- ImageList_Add(hImageList, LoadBitmap(hInstance, MAKEINTRESOURCE(IDB_TREEVIEW_ICON_9)),
NULL);
- ImageList_Add(hImageList, LoadBitmap(hInstance, MAKEINTRESOURCE(IDB_TREEVIEW_ICON_10)),
NULL);
+ ImageList_Add(hImageList,
+ LoadBitmap(hInstance, MAKEINTRESOURCE(IDB_TREEVIEW_ICON_0)), NULL);
+ ImageList_Add(hImageList,
+ LoadBitmap(hInstance, MAKEINTRESOURCE(IDB_TREEVIEW_ICON_1)), NULL);
+ ImageList_Add(hImageList,
+ LoadBitmap(hInstance, MAKEINTRESOURCE(IDB_TREEVIEW_ICON_2)), NULL);
+ ImageList_Add(hImageList,
+ LoadBitmap(hInstance, MAKEINTRESOURCE(IDB_TREEVIEW_ICON_3)), NULL);
+ ImageList_Add(hImageList,
+ LoadBitmap(hInstance, MAKEINTRESOURCE(IDB_TREEVIEW_ICON_4)), NULL);
+ ImageList_Add(hImageList,
+ LoadBitmap(hInstance, MAKEINTRESOURCE(IDB_TREEVIEW_ICON_5)), NULL);
+ ImageList_Add(hImageList,
+ LoadBitmap(hInstance, MAKEINTRESOURCE(IDB_TREEVIEW_ICON_6)), NULL);
+ ImageList_Add(hImageList,
+ LoadBitmap(hInstance, MAKEINTRESOURCE(IDB_TREEVIEW_ICON_7)), NULL);
+ ImageList_Add(hImageList,
+ LoadBitmap(hInstance, MAKEINTRESOURCE(IDB_TREEVIEW_ICON_8)), NULL);
+ ImageList_Add(hImageList,
+ LoadBitmap(hInstance, MAKEINTRESOURCE(IDB_TREEVIEW_ICON_9)), NULL);
+ ImageList_Add(hImageList,
+ LoadBitmap(hInstance, MAKEINTRESOURCE(IDB_TREEVIEW_ICON_10)), NULL);
+ ImageList_Add(hImageList,
+ LoadBitmap(hInstance, MAKEINTRESOURCE(IDB_TREEVIEW_ICON_11)), NULL);
+ ImageList_Add(hImageList,
+ LoadBitmap(hInstance, MAKEINTRESOURCE(IDB_TREEVIEW_ICON_12)), NULL);
+ ImageList_Add(hImageList,
+ LoadBitmap(hInstance, MAKEINTRESOURCE(IDB_TREEVIEW_ICON_13)), NULL);
// Fill the TreeViews
AddItems (hCategories, Root.Children, NULL);
@@ -204,13 +270,15 @@
return TRUE;
}
-static void ResizeControl (HWND hwnd, int x1, int y1, int x2, int y2)
+static void
+ResizeControl (HWND hwnd, int x1, int y1, int x2, int y2)
{
// Make resizing a little easier
MoveWindow(hwnd, x1, y1, x2-x1, y2-y1, TRUE);
}
-static void DrawBitmap (HDC hdc, int x, int y, HBITMAP hBmp)
+static void
+DrawBitmap (HDC hdc, int x, int y, HBITMAP hBmp)
{
BITMAP bm;
HDC hdcMem = CreateCompatibleDC(hdc);
@@ -222,7 +290,8 @@
DeleteDC(hdcMem);
}
-static void DrawDescription (HDC hdc, RECT DescriptionRect)
+static void
+DrawDescription (HDC hdc, RECT DescriptionRect)
{
int i;
HFONT Font;
@@ -237,16 +306,16 @@
// Headline
Font = CreateFont(-16 , 0, 0, 0, FW_EXTRABOLD, FALSE, FALSE, FALSE, ANSI_CHARSET,
- OUT_DEFAULT_PRECIS, CLIP_DEFAULT_PRECIS, DEFAULT_QUALITY, FF_DONTCARE,
L"Arial");
+ OUT_DEFAULT_PRECIS, CLIP_DEFAULT_PRECIS, DEFAULT_QUALITY, FF_DONTCARE,
L"Arial");
SelectObject(hdc, Font);
DrawTextW(hdc, DescriptionHeadline, lstrlenW(DescriptionHeadline), &Rect,
DT_SINGLELINE|DT_NOPREFIX);
DeleteObject(Font);
// Description
Font = CreateFont(-13 , 0, 0, 0, FW_NORMAL, FALSE, FALSE, FALSE, ANSI_CHARSET,
- OUT_DEFAULT_PRECIS, CLIP_DEFAULT_PRECIS, DEFAULT_QUALITY, FF_DONTCARE,
L"Arial");
+ OUT_DEFAULT_PRECIS, CLIP_DEFAULT_PRECIS, DEFAULT_QUALITY, FF_DONTCARE,
L"Arial");
SelectObject(hdc, Font);
- Rect.top += 40;
+ Rect.top += 50;
Rect.bottom = DescriptionRect.bottom-2;
DrawTextW(hdc, DescriptionText, lstrlenW(DescriptionText), &Rect,
DT_WORDBREAK|DT_NOPREFIX); // ToDo: Call TabbedTextOut to draw a nice table
DeleteObject(Font);
@@ -257,7 +326,7 @@
int Split_Vertical = 200;
RECT Rect;
- GetClientRect(hwnd,&Rect);
+ GetClientRect(hwnd,&Rect);
ShowWindow(hUninstallButton,SW_SHOW);
MoveWindow(hDownloadButton,(Split_Vertical+Rect.right-Rect.left)/2,Rect.bottom-Rect.top-45,140,35,TRUE);;
}
@@ -266,7 +335,7 @@
int Split_Vertical = 200;
RECT Rect;
- GetClientRect(hwnd,&Rect);
+ GetClientRect(hwnd,&Rect);
ShowWindow(hUninstallButton,SW_HIDE);
MoveWindow(hDownloadButton,(Split_Vertical+Rect.right-Rect.left)/2-70,Rect.bottom-Rect.top-45,140,35,TRUE);
}
@@ -281,10 +350,257 @@
CloseHandle(pi.hThread);
// WaitForSingleObject(pi.hProcess, INFINITE); // If you want to wait for the
Unistaller
CloseHandle(pi.hProcess);
- hideUninstaller();
-}
-
-LRESULT CALLBACK WndProc (HWND hwnd, UINT Message, WPARAM wParam, LPARAM lParam)
+ hideUninstaller();
+}
+
+BOOL
+SaveSettings(HWND hwnd)
+{
+ HKEY hKey;
+ TCHAR szBuf[MAX_PATH];
+
+ if (RegOpenKey(HKEY_LOCAL_MACHINE,
+ TEXT("Software\\ReactOS\\Download!"),
+ &hKey) != ERROR_SUCCESS)
+ return FALSE;
+
+ SendMessage(GetDlgItem(hwnd, IDC_DOWNLOAD_FOLDER_EDIT), WM_GETTEXT,
sizeof(szBuf)/sizeof(TCHAR), (LPARAM)szBuf);
+ if (GetFileAttributes(szBuf) == 0xFFFFFFFF)
+ if (!CreateDirectory((LPCTSTR)szBuf,NULL))
+ {
+ LoadString(GetModuleHandle(NULL), IDS_UNABLECREATE_FOLDER, szBuf, sizeof(szBuf) /
sizeof(TCHAR));
+ MessageBox(hwnd, (LPCTSTR)szBuf, NULL, MB_ICONSTOP);
+ return FALSE;
+ }
+ if (RegSetValueEx(hKey,
+ L"DownloadFolder",
+ 0,
+ REG_SZ,
+ (LPBYTE)szBuf,
+ (DWORD)(sizeof(szBuf) / sizeof(TCHAR))))
+ return FALSE;
+
+ SendMessage(GetDlgItem(hwnd, IDC_UPDATE_SERVER_EDIT), WM_GETTEXT,
sizeof(szBuf)/sizeof(TCHAR), (LPARAM)szBuf);
+ if (RegSetValueEx(hKey,
+ L"UpdateServer",
+ 0,
+ REG_SZ,
+ (LPBYTE)szBuf,
+ (DWORD)(sizeof(szBuf) / sizeof(TCHAR))))
+ return FALSE;
+
+ DWORD dwValue;
+ if (SendMessage(GetDlgItem(hwnd, IDC_DELINST_FILES_CHECKBOX), BM_GETCHECK, 0, 0) ==
BST_CHECKED)
+ dwValue = 0x1;
+ else
+ dwValue = 0x0;
+ if (RegSetValueEx(hKey,
+ L"DeleteInstaller",
+ 0,
+ REG_DWORD,
+ (LPBYTE)&dwValue,
+ sizeof(DWORD)))
+ return FALSE;
+
+ RegCloseKey(hKey);
+
+ return TRUE;
+}
+
+BOOL
+InitProfDlg(HWND hwnd)
+{
+ HKEY hKey;
+ TCHAR Buf[MAX_PATH];
+ DWORD dwDisp, dwSize;
+
+ if (RegOpenKey(HKEY_LOCAL_MACHINE,
+ TEXT("Software\\ReactOS\\Download!"),
+ &hKey) != ERROR_SUCCESS)
+ {
+ if (RegCreateKeyEx(HKEY_LOCAL_MACHINE, L"Software\\ReactOS\\Download!",
+ 0, NULL, REG_OPTION_NON_VOLATILE,
+ KEY_WRITE, NULL, &hKey, &dwDisp))
+ {
+ LoadString(GetModuleHandle(NULL), IDS_NOTCREATE_REGKEY, Buf, sizeof(Buf) /
sizeof(TCHAR));
+ MessageBox(hwnd, (LPCTSTR)Buf, NULL, MB_ICONSTOP);
+ return FALSE;
+ }
+ }
+
+ dwSize = MAX_PATH;
+ if (RegQueryValueEx(hKey,
+ L"DownloadFolder",
+ NULL,
+ NULL,
+ (LPBYTE)&Buf,
+ &dwSize) == ERROR_SUCCESS)
+ {
+ SendMessage(GetDlgItem(hwnd, IDC_DOWNLOAD_FOLDER_EDIT), WM_SETTEXT, -1, (LPARAM)Buf);
+ }
+ else
+ {
+ if (!GetWindowsDirectory(Buf, sizeof(Buf) / sizeof(TCHAR))) return FALSE;
+
+ TCHAR DPath[256];
+ int i;
+ for (i = 0; i < 4; i++)
+ {
+ if (i == 3)
+ {
+ DPath[i] = '\0';
+ break;
+ }
+ DPath[i] = Buf[i];
+ }
+ LoadString(GetModuleHandle(NULL), IDS_DOWNLOAD_FOLDER, Buf, sizeof(Buf) /
sizeof(TCHAR));
+ lstrcat((LPTSTR)DPath, Buf);
+ if (RegSetValueEx(hKey,
+ L"DownloadFolder",
+ 0,
+ REG_SZ,
+ (LPBYTE)DPath,
+ (DWORD)(sizeof(DPath) / sizeof(TCHAR))))
+ return FALSE;
+ else
+ {
+ if (GetFileAttributes(DPath) == 0xFFFFFFFF)
+ if (!CreateDirectory((LPCTSTR)DPath,NULL)) return FALSE;
+ SendMessage(GetDlgItem(hwnd, IDC_DOWNLOAD_FOLDER_EDIT), WM_SETTEXT, -1,
(LPARAM)DPath);
+ }
+ }
+
+ dwSize = MAX_PATH;
+ if (RegQueryValueEx(hKey,
+ L"UpdateServer",
+ NULL,
+ NULL,
+ (LPBYTE)&Buf,
+ &dwSize) == ERROR_SUCCESS)
+ {
+ SendMessage(GetDlgItem(hwnd, IDC_UPDATE_SERVER_EDIT), WM_SETTEXT, -1, (LPARAM)Buf);
+ }
+ else
+ {
+ LoadString(GetModuleHandle(NULL), IDS_UPDATE_URL, Buf, sizeof(Buf) / sizeof(TCHAR));
+ if (RegSetValueEx(hKey,
+ L"UpdateServer",
+ 0,
+ REG_SZ,
+ (LPBYTE)Buf,
+ (DWORD)(sizeof(Buf) / sizeof(TCHAR))))
+ return FALSE;
+ else
+ {
+ SendMessage(GetDlgItem(hwnd, IDC_UPDATE_SERVER_EDIT), WM_SETTEXT, -1, (LPARAM)Buf);
+ }
+ }
+
+ DWORD dwValue, dwType = REG_DWORD;
+ dwSize = sizeof(DWORD);
+ if (RegQueryValueEx(hKey,
+ L"DeleteInstaller",
+ NULL,
+ &dwType,
+ (LPBYTE)&dwValue,
+ &dwSize) == ERROR_SUCCESS)
+ {
+ if (dwValue == 0x1)
+ SendMessage(GetDlgItem(hwnd, IDC_DELINST_FILES_CHECKBOX), BM_SETCHECK, 1, 1);
+ }
+ else
+ {
+ dwValue = 0x0;
+ if (RegSetValueEx(hKey,
+ L"DeleteInstaller",
+ 0,
+ REG_DWORD,
+ (LPBYTE)&dwValue,
+ sizeof(DWORD)))
+ return FALSE;
+ }
+
+ RegCloseKey(hKey);
+
+ return TRUE;
+}
+
+BOOL
+ChooseFolder(HWND hwnd)
+{
+ BROWSEINFO fi;
+ LPCITEMIDLIST lpItemList;
+ TCHAR szPath[MAX_PATH],Buf[256];
+
+ ZeroMemory(&fi, sizeof(BROWSEINFO));
+ fi.hwndOwner = hwnd;
+ LoadString(GetModuleHandle(NULL), IDS_CHOOSE_FOLDER, Buf, sizeof(Buf) / sizeof(TCHAR));
+ fi.lpszTitle = (LPCTSTR)Buf;
+ fi.ulFlags = BIF_DONTGOBELOWDOMAIN | BIF_RETURNONLYFSDIRS | BIF_BROWSEFORCOMPUTER |
BIF_NEWDIALOGSTYLE;
+ fi.lpfn = NULL;
+ fi.lParam = -1;
+ fi.iImage = 0;
+
+ if(!(lpItemList = SHBrowseForFolder(&fi))) return FALSE;
+ SHGetPathFromIDList(lpItemList, szPath);
+
+ if (_tcslen(szPath) == 0) return FALSE;
+ SendMessage(GetDlgItem(hwnd, IDC_DOWNLOAD_FOLDER_EDIT), WM_SETTEXT, -1,
(LPARAM)szPath);
+
+ return TRUE;
+}
+
+INT_PTR CALLBACK
+ProfDlgProc(HWND hDlg,
+ UINT message,
+ WPARAM wParam,
+ LPARAM lParam)
+{
+ static HICON hIcon;
+ UNREFERENCED_PARAMETER(lParam);
+
+ switch (message)
+ {
+ case WM_INITDIALOG:
+ {
+ hIcon =
LoadImage(GetModuleHandle(NULL),MAKEINTRESOURCE(IDI_MAIN),IMAGE_ICON,16,16,0);
+ SendMessage(hDlg,WM_SETICON,ICON_SMALL,(LPARAM)hIcon);
+ InitProfDlg(hDlg);
+ }
+ break;
+
+ case WM_COMMAND:
+ {
+ switch (wParam)
+ {
+ case IDC_CHOOSE_BUTTON:
+ ChooseFolder(hDlg);
+ break;
+ case IDOK:
+ {
+ SaveSettings(hDlg);
+ DestroyIcon(hIcon);
+ EndDialog(hDlg,LOWORD(wParam));
+ return TRUE;
+ }
+ break;
+ case IDCANCEL:
+ {
+ DestroyIcon(hIcon);
+ EndDialog(hDlg,LOWORD(wParam));
+ return TRUE;
+ }
+ break;
+ }
+ }
+ break;
+ }
+
+ return FALSE;
+}
+
+LRESULT CALLBACK
+WndProc (HWND hwnd, UINT Message, WPARAM wParam, LPARAM lParam)
{
static RECT DescriptionRect;
@@ -321,6 +637,13 @@
{
if(HIWORD(wParam) == BN_CLICKED)
{
+ if (lParam == (LPARAM)hProfButton)
+ {
+ DialogBox(GetModuleHandle(NULL),
+ MAKEINTRESOURCE(IDD_PROF),
+ hwnd,
+ ProfDlgProc);
+ }
if (lParam == (LPARAM)hDownloadButton)
{
if(SelectedApplication)
@@ -425,7 +748,8 @@
DescriptionRect = Rect;
MoveWindow(hHelpButton, LOWORD(lParam)-50, 10, 40, 40, TRUE);
- MoveWindow(hUpdateButton, LOWORD(lParam)-100, 10, 40, 40, TRUE);
+ MoveWindow(hUpdateButton, LOWORD(lParam)-150, 10, 40, 40, TRUE);
+ MoveWindow(hProfButton, LOWORD(lParam)-100, 10, 40, 40, TRUE);
if(IsWindowVisible(hUninstallButton))
MoveWindow(hDownloadButton, (Split_Vertical+LOWORD(lParam))/2, HIWORD(lParam)-45,
140, 35, TRUE);
else
@@ -448,8 +772,11 @@
return DefWindowProc (hwnd, Message, wParam, lParam);
}
-INT WINAPI wWinMain (HINSTANCE hInstance, HINSTANCE hPrevInst,
- LPTSTR lpCmdLine, INT nCmdShow)
+INT WINAPI
+wWinMain (HINSTANCE hInstance,
+ HINSTANCE hPrevInst,
+ LPTSTR lpCmdLine,
+ INT nCmdShow)
{
int i;
WNDCLASSEXW WndClass = {0};
@@ -477,7 +804,7 @@
WS_OVERLAPPEDWINDOW|WS_CLIPCHILDREN,
CW_USEDEFAULT,
CW_USEDEFAULT,
- 600, 550,
+ 650, 550,
NULL, NULL,
hInstance,
NULL);
Modified: trunk/rosapps/downloader/resources.h
URL:
http://svn.reactos.org/svn/reactos/trunk/rosapps/downloader/resources.h?rev…
==============================================================================
--- trunk/rosapps/downloader/resources.h (original)
+++ trunk/rosapps/downloader/resources.h Tue Oct 16 00:45:06 2007
@@ -1,11 +1,12 @@
#define IDI_MAIN 0x0
+#define IDI_UPDATE 5000
+#define IDI_HELP 5001
+#define IDI_PROF 5002
#define IDB_UNDERLINE 0x100
#define IDB_LOGO 0x101
-#define IDB_HELP 0x102
-#define IDB_UPDATE 0x103
-#define IDB_DOWNLOAD 0x104
-#define IDB_UNINSTALL 0x105
+#define IDB_DOWNLOAD 0x102
+#define IDB_UNINSTALL 0x103
#define IDB_TREEVIEW_ICON_0 0x900
#define IDB_TREEVIEW_ICON_1 0x901
#define IDB_TREEVIEW_ICON_2 0x902
@@ -17,33 +18,47 @@
#define IDB_TREEVIEW_ICON_8 0x908
#define IDB_TREEVIEW_ICON_9 0x909
#define IDB_TREEVIEW_ICON_10 0x910
+#define IDB_TREEVIEW_ICON_11 0x911
+#define IDB_TREEVIEW_ICON_12 0x912
+#define IDB_TREEVIEW_ICON_13 0x913
#define IDD_DOWNLOAD 0x100
#define IDC_PROGRESS 0x1000
#define IDC_STATUS 0x1001
#define IDC_REMOVE 0x1002
+#define IDC_DOWNLOAD_FOLDER_EDIT 0x1003
+#define IDC_CHOOSE_BUTTON 0x1004
+#define IDC_UPDATE_SERVER_EDIT 0x1005
+#define IDC_DELINST_FILES_CHECKBOX 0x1006
-#define IDS_WINDOW_TITLE 0
-#define IDS_WELCOME_TITLE 1
-#define IDS_WELCOME 2
-#define IDS_NO_APP_TITLE 3
-#define IDS_NO_APP 4
-#define IDS_UPDATE_TITLE 5
-#define IDS_UPDATE 6
-#define IDS_HELP_TITLE 7
-#define IDS_HELP 8
-#define IDS_NO_APPS 9
-#define IDS_CHOOSE_APP 10
-#define IDS_CHOOSE_SUB 11
-#define IDS_CHOOSE_CATEGORY 12
-#define IDS_CHOOSE_BOTH 13
-#define IDS_XMLERROR_1 14
-#define IDS_XMLERROR_2 15
-#define IDS_DOWNLOAD_ERROR 16
-#define IDS_VERSION 17
-#define IDS_LICENCE 18
-#define IDS_MAINTAINER 19
-#define IDS_APPS_TITLE 20
-#define IDS_CATS_TITLE 21
+#define IDS_WINDOW_TITLE 0
+#define IDS_WELCOME_TITLE 1
+#define IDS_WELCOME 2
+#define IDS_NO_APP_TITLE 3
+#define IDS_NO_APP 4
+#define IDS_UPDATE_TITLE 5
+#define IDS_UPDATE 6
+#define IDS_HELP_TITLE 7
+#define IDS_HELP 8
+#define IDS_NO_APPS 9
+#define IDS_CHOOSE_APP 10
+#define IDS_CHOOSE_SUB 11
+#define IDS_CHOOSE_CATEGORY 12
+#define IDS_CHOOSE_BOTH 13
+#define IDS_XMLERROR_1 14
+#define IDS_XMLERROR_2 15
+#define IDS_DOWNLOAD_ERROR 16
+#define IDS_VERSION 17
+#define IDS_LICENCE 18
+#define IDS_MAINTAINER 19
+#define IDS_APPS_TITLE 20
+#define IDS_CATS_TITLE 21
+#define IDS_CHOOSE_FOLDER 22
+#define IDS_NOTCREATE_REGKEY 23
+#define IDS_DOWNLOAD_FOLDER 24
+#define IDS_UNABLECREATE_FOLDER 25
+#define IDS_UPDATE_URL 26
+
+#define IDD_PROF 6000
#define STRING_COUNT 20
Added: trunk/rosapps/downloader/resources/11.bmp
URL:
http://svn.reactos.org/svn/reactos/trunk/rosapps/downloader/resources/11.bm…
==============================================================================
Binary file - no diff available.
Propchange: trunk/rosapps/downloader/resources/11.bmp
------------------------------------------------------------------------------
svn:mime-type = application/octet-stream
Added: trunk/rosapps/downloader/resources/12.bmp
URL:
http://svn.reactos.org/svn/reactos/trunk/rosapps/downloader/resources/12.bm…
==============================================================================
Binary file - no diff available.
Propchange: trunk/rosapps/downloader/resources/12.bmp
------------------------------------------------------------------------------
svn:mime-type = application/octet-stream
Added: trunk/rosapps/downloader/resources/13.bmp
URL:
http://svn.reactos.org/svn/reactos/trunk/rosapps/downloader/resources/13.bm…
==============================================================================
Binary file - no diff available.
Propchange: trunk/rosapps/downloader/resources/13.bmp
------------------------------------------------------------------------------
svn:mime-type = application/octet-stream
Removed: trunk/rosapps/downloader/resources/help.bmp
URL:
http://svn.reactos.org/svn/reactos/trunk/rosapps/downloader/resources/help.…
==============================================================================
Binary file - no diff available.
Added: trunk/rosapps/downloader/resources/help.ico
URL:
http://svn.reactos.org/svn/reactos/trunk/rosapps/downloader/resources/help.…
==============================================================================
Binary file - no diff available.
Propchange: trunk/rosapps/downloader/resources/help.ico
------------------------------------------------------------------------------
svn:mime-type = application/octet-stream
Added: trunk/rosapps/downloader/resources/preferences.ico
URL:
http://svn.reactos.org/svn/reactos/trunk/rosapps/downloader/resources/prefe…
==============================================================================
Binary file - no diff available.
Propchange: trunk/rosapps/downloader/resources/preferences.ico
------------------------------------------------------------------------------
svn:mime-type = application/octet-stream
Removed: trunk/rosapps/downloader/resources/update.bmp
URL:
http://svn.reactos.org/svn/reactos/trunk/rosapps/downloader/resources/updat…
==============================================================================
Binary file - no diff available.
Added: trunk/rosapps/downloader/resources/update.ico
URL:
http://svn.reactos.org/svn/reactos/trunk/rosapps/downloader/resources/updat…
==============================================================================
Binary file - no diff available.
Propchange: trunk/rosapps/downloader/resources/update.ico
------------------------------------------------------------------------------
svn:mime-type = application/octet-stream
Modified: trunk/rosapps/downloader/rsrc.rc
URL:
http://svn.reactos.org/svn/reactos/trunk/rosapps/downloader/rsrc.rc?rev=296…
==============================================================================
--- trunk/rosapps/downloader/rsrc.rc (original)
+++ trunk/rosapps/downloader/rsrc.rc Tue Oct 16 00:45:06 2007
@@ -1,9 +1,12 @@
LANGUAGE LANG_NEUTRAL, SUBLANG_NEUTRAL
IDI_MAIN ICON DISCARDABLE "resources/main.ico"
+IDI_UPDATE ICON DISCARDABLE "resources/update.ico"
+IDI_HELP ICON DISCARDABLE "resources/help.ico"
+IDI_PROF ICON DISCARDABLE "resources/preferences.ico"
IDB_LOGO BITMAP DISCARDABLE "resources/logo.bmp"
-IDB_HELP BITMAP DISCARDABLE "resources/help.bmp"
-IDB_UPDATE BITMAP DISCARDABLE "resources/update.bmp"
+//IDB_HELP BITMAP DISCARDABLE "resources/help.bmp"
+//IDB_UPDATE BITMAP DISCARDABLE "resources/update.bmp"
IDB_DOWNLOAD BITMAP DISCARDABLE "resources/download.bmp"
IDB_UNINSTALL BITMAP DISCARDABLE "resources/uninstall.bmp"
IDB_UNDERLINE BITMAP DISCARDABLE "resources/underline.bmp"
@@ -18,6 +21,9 @@
IDB_TREEVIEW_ICON_8 BITMAP DISCARDABLE "resources/8.bmp"
IDB_TREEVIEW_ICON_9 BITMAP DISCARDABLE "resources/9.bmp"
IDB_TREEVIEW_ICON_10 BITMAP DISCARDABLE "resources/10.bmp"
+IDB_TREEVIEW_ICON_11 BITMAP DISCARDABLE "resources/11.bmp"
+IDB_TREEVIEW_ICON_12 BITMAP DISCARDABLE "resources/12.bmp"
+IDB_TREEVIEW_ICON_13 BITMAP DISCARDABLE "resources/13.bmp"
#include "lang/de-DE.rc"
Modified: trunk/rosapps/downloader/xml.c
URL:
http://svn.reactos.org/svn/reactos/trunk/rosapps/downloader/xml.c?rev=29614…
==============================================================================
--- trunk/rosapps/downloader/xml.c (original)
+++ trunk/rosapps/downloader/xml.c Tue Oct 16 00:45:06 2007
@@ -170,10 +170,10 @@
Current = Root;
TagOpen = TRUE;
- file = fopen(filename, "r");
+ file = fopen("downloader.xml", "r");
if(!file)
{
- file = fopen("downloader.xml", "r");
+ file = fopen(filename, "r");
if(!file)
{
MessageBoxW(0,Strings[IDS_XMLERROR_1],0,0);