summaryrefslogtreecommitdiff
path: root/plugins/Import/src/wizard.cpp
diff options
context:
space:
mode:
authorGeorge Hazan <george.hazan@gmail.com>2014-08-11 13:57:21 +0000
committerGeorge Hazan <george.hazan@gmail.com>2014-08-11 13:57:21 +0000
commit579dbd890eace38528a9799def3c2cffc38bb86c (patch)
treec14745899c51db0c4b469830dba3dfeee9e16147 /plugins/Import/src/wizard.cpp
parente6b2c1aafe3e877e3a6a90df006887d0b5f59f3d (diff)
o-ok, let's complete 0.95's roadmap considering import
initial commit git-svn-id: http://svn.miranda-ng.org/main/trunk@10153 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'plugins/Import/src/wizard.cpp')
-rw-r--r--plugins/Import/src/wizard.cpp37
1 files changed, 18 insertions, 19 deletions
diff --git a/plugins/Import/src/wizard.cpp b/plugins/Import/src/wizard.cpp
index 71dc010786..936ba18ee8 100644
--- a/plugins/Import/src/wizard.cpp
+++ b/plugins/Import/src/wizard.cpp
@@ -2,7 +2,7 @@
Import plugin for Miranda NG
-Copyright (C) 2012 George Hazan
+Copyright (C) 2012-14 George Hazan
This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License
@@ -24,29 +24,30 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
INT_PTR CALLBACK WizardIntroPageProc(HWND hdlg, UINT message, WPARAM wParam, LPARAM lParam)
{
- switch( message ) {
+ switch (message) {
case WM_INITDIALOG:
TranslateDialogDefault(hdlg);
SendMessage(GetParent(hdlg), WIZM_DISABLEBUTTON, 0, 0);
return TRUE;
-
+
case WM_COMMAND:
- switch( LOWORD( wParam )) {
+ switch (LOWORD(wParam)) {
case IDOK:
PostMessage(GetParent(hdlg), WIZM_GOTOPAGE, IDD_MIRANDADB, (LPARAM)MirandaPageProc);
break;
-
+
case IDCANCEL:
PostMessage(GetParent(hdlg), WM_CLOSE, 0, 0);
break;
- } }
-
+ }
+ }
+
return FALSE;
}
INT_PTR CALLBACK FinishedPageProc(HWND hdlg, UINT message, WPARAM wParam, LPARAM lParam)
{
- switch( message ) {
+ switch (message) {
case WM_INITDIALOG:
TranslateDialogDefault(hdlg);
SendMessage(GetParent(hdlg), WIZM_DISABLEBUTTON, 0, 0);
@@ -55,18 +56,16 @@ INT_PTR CALLBACK FinishedPageProc(HWND hdlg, UINT message, WPARAM wParam, LPARAM
return TRUE;
case WM_COMMAND:
- switch( LOWORD( wParam )) {
+ switch (LOWORD(wParam)) {
case IDOK:
PostMessage(GetParent(hdlg), WIZM_GOTOPAGE, IDD_MIRANDADB, (LPARAM)MirandaPageProc);
break;
case IDCANCEL:
- if ( IsDlgButtonChecked( hdlg, IDC_DONTLOADPLUGIN )) {
+ if (IsDlgButtonChecked(hdlg, IDC_DONTLOADPLUGIN)) {
char sModuleFileName[MAX_PATH];
- char *pszFileName;
-
GetModuleFileNameA(hInst, sModuleFileName, sizeof(sModuleFileName));
- pszFileName = strrchr(sModuleFileName, '\\' );
+ char *pszFileName = strrchr(sModuleFileName, '\\');
if (pszFileName == NULL)
pszFileName = sModuleFileName;
else
@@ -93,11 +92,11 @@ INT_PTR CALLBACK WizardDlgProc(HWND hdlg, UINT message, WPARAM wParam, LPARAM lP
{
static HWND hwndPage;
- switch ( message ) {
+ switch (message) {
case WM_INITDIALOG:
TranslateDialogDefault(hdlg);
hwndPage = CreateDialog(hInst, MAKEINTRESOURCE(IDD_WIZARDINTRO), hdlg, WizardIntroPageProc);
- SetWindowPos(hwndPage, 0, 0, 0, 0, 0, SWP_NOZORDER|SWP_NOSIZE);
+ SetWindowPos(hwndPage, 0, 0, 0, 0, 0, SWP_NOZORDER | SWP_NOSIZE);
ShowWindow(hwndPage, SW_SHOW);
ShowWindow(hdlg, SW_SHOW);
SendMessage(hdlg, WM_SETICON, ICON_BIG, (LPARAM)Skin_GetIconByHandle(hIcoHandle));
@@ -110,12 +109,12 @@ INT_PTR CALLBACK WizardDlgProc(HWND hdlg, UINT message, WPARAM wParam, LPARAM lP
EnableWindow(GetDlgItem(hdlg, IDCANCEL), TRUE);
SetDlgItemText(hdlg, IDCANCEL, TranslateT("Cancel"));
hwndPage = CreateDialog(hInst, MAKEINTRESOURCE(wParam), hdlg, (DLGPROC)lParam);
- SetWindowPos(hwndPage, 0, 0, 0, 0, 0, SWP_NOZORDER|SWP_NOSIZE);
+ SetWindowPos(hwndPage, 0, 0, 0, 0, 0, SWP_NOZORDER | SWP_NOSIZE);
ShowWindow(hwndPage, SW_SHOW);
break;
case WIZM_DISABLEBUTTON:
- switch ( wParam ) {
+ switch (wParam) {
case 0:
EnableWindow(GetDlgItem(hdlg, IDC_BACK), FALSE);
break;
@@ -131,7 +130,7 @@ INT_PTR CALLBACK WizardDlgProc(HWND hdlg, UINT message, WPARAM wParam, LPARAM lP
break;
case WIZM_ENABLEBUTTON:
- switch ( wParam ) {
+ switch (wParam) {
case 0:
EnableWindow(GetDlgItem(hdlg, IDC_BACK), TRUE);
break;
@@ -159,6 +158,6 @@ INT_PTR CALLBACK WizardDlgProc(HWND hdlg, UINT message, WPARAM wParam, LPARAM lP
DestroyWindow(hdlg);
break;
}
-
+
return FALSE;
}