From 05c424e7c4af69b434d9b5bf2823c6d044f2d91f Mon Sep 17 00:00:00 2001 From: Dennis Syrovatsky Date: Wed, 14 Dec 2005 11:19:19 +0000 Subject: [PATCH] Added dialog for creating a new folder. Added FTDialog::onLocalCreateFolder() and FTDialog::onRemoteCreateFolder() methods. git-svn-id: svn://svn.code.sf.net/p/tigervnc/code/trunk@446 3789f03b-4d11-0410-bbf8-ca57d06f2519 --- vncviewer/FTDialog.cxx | 23 +++++++++++ vncviewer/FTDialog.h | 4 ++ vncviewer/resource.h | 6 ++- vncviewer/vncviewer.rc | 86 +++++++++++++++++++----------------------- 4 files changed, 69 insertions(+), 50 deletions(-) diff --git a/vncviewer/FTDialog.cxx b/vncviewer/FTDialog.cxx index a4fd9a68..11f24a0f 100644 --- a/vncviewer/FTDialog.cxx +++ b/vncviewer/FTDialog.cxx @@ -235,6 +235,7 @@ FTDialog::FTDialogProc(HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM lParam) case IDM_FTRENAME: case IDM_FTDELETE: case IDM_FTCANCEL: + case IDM_FTCREATEFOLDER: _this->onFTMenuCommand(LOWORD(wParam)); return FALSE; } @@ -470,6 +471,18 @@ FTDialog::onRemoteDelete() setButtonsState(); } +void +FTDialog::onLocalCreateFolder() +{ + +} + +void +FTDialog::onRemoteCreateFolder() +{ + +} + void FTDialog::onFTCancel() { @@ -543,6 +556,16 @@ FTDialog::onFTMenuCommand(int command) } break; case IDM_FTCANCEL: onFTCancel(); break; + case IDM_FTCREATEFOLDER: + { + switch (m_FTMenuSource) + { + case IDC_FTLOCALLIST: onLocalCreateFolder(); break; + case IDC_FTREMOTELIST: onRemoteCreateFolder(); break; + default: break; + } + } + break; default: break; } diff --git a/vncviewer/FTDialog.h b/vncviewer/FTDialog.h index 928c93dc..e3d1d376 100644 --- a/vncviewer/FTDialog.h +++ b/vncviewer/FTDialog.h @@ -92,6 +92,10 @@ namespace rfb { void onLocalRButton(); void onRemoteRButton(); + + void onLocalCreateFolder(); + void onRemoteCreateFolder(); + void showFTMenu(bool copyBtnState, bool createFldBtnState, bool renameBtnState, bool deleteBtnState, bool cancelBtnState); diff --git a/vncviewer/resource.h b/vncviewer/resource.h index 8413d17b..adff6511 100644 --- a/vncviewer/resource.h +++ b/vncviewer/resource.h @@ -26,6 +26,7 @@ #define IDI_FTRELOAD 128 #define IDR_FTMENU 130 #define IDD_FTCANCELING 131 +#define IDD_FTCREATEFOLDER 132 #define IDC_PASSWORD 1000 #define IDC_CONNECTING_TEXT 1001 #define IDC_SERVER_EDIT 1002 @@ -109,6 +110,7 @@ #define IDC_CONFIRM_YESTOALL 1079 #define IDC_CONFIRM_TEXT 1080 #define IDC_EDIT2 1082 +#define IDC_FTFOLDERNAME 1083 #define ID_TOOLBAR 40002 #define ID_CLOSE 40003 #define ID_OPTIONS 40004 @@ -135,9 +137,9 @@ // #ifdef APSTUDIO_INVOKED #ifndef APSTUDIO_READONLY_SYMBOLS -#define _APS_NEXT_RESOURCE_VALUE 132 +#define _APS_NEXT_RESOURCE_VALUE 133 #define _APS_NEXT_COMMAND_VALUE 40028 -#define _APS_NEXT_CONTROL_VALUE 1083 +#define _APS_NEXT_CONTROL_VALUE 1084 #define _APS_NEXT_SYMED_VALUE 101 #endif #endif diff --git a/vncviewer/vncviewer.rc b/vncviewer/vncviewer.rc index 531a78cf..53352942 100644 --- a/vncviewer/vncviewer.rc +++ b/vncviewer/vncviewer.rc @@ -12,54 +12,6 @@ ///////////////////////////////////////////////////////////////////////////// #undef APSTUDIO_READONLY_SYMBOLS -///////////////////////////////////////////////////////////////////////////// -// Russian resources - -#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_RUS) -#ifdef _WIN32 -LANGUAGE LANG_RUSSIAN, SUBLANG_DEFAULT -#pragma code_page(1251) -#endif //_WIN32 - -///////////////////////////////////////////////////////////////////////////// -// -// Dialog -// - -IDD_FTCANCELING DIALOG DISCARDABLE 0, 0, 193, 63 -STYLE DS_SYSMODAL | DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU -CAPTION "Canceling Active File Transfer" -FONT 8, "MS Sans Serif" -BEGIN - DEFPUSHBUTTON "Yes",IDOK,40,42,50,14 - PUSHBUTTON "No",IDCANCEL,102,42,50,14 - LTEXT "FileTransfer is active.\nAre you sure you want to cancel transfer?", - IDC_STATIC,42,14,133,19 -END - - -///////////////////////////////////////////////////////////////////////////// -// -// DESIGNINFO -// - -#ifdef APSTUDIO_INVOKED -GUIDELINES DESIGNINFO DISCARDABLE -BEGIN - IDD_FTCANCELING, DIALOG - BEGIN - LEFTMARGIN, 7 - RIGHTMARGIN, 186 - TOPMARGIN, 7 - BOTTOMMARGIN, 56 - END -END -#endif // APSTUDIO_INVOKED - -#endif // Russian resources -///////////////////////////////////////////////////////////////////////////// - - ///////////////////////////////////////////////////////////////////////////// // English (U.S.) resources @@ -398,6 +350,28 @@ BEGIN 90,117,15 END +IDD_FTCANCELING DIALOG DISCARDABLE 0, 0, 193, 63 +STYLE DS_SYSMODAL | DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU +CAPTION "Canceling Active File Transfer" +FONT 8, "MS Sans Serif" +BEGIN + DEFPUSHBUTTON "Yes",IDOK,40,42,50,14 + PUSHBUTTON "No",IDCANCEL,102,42,50,14 + LTEXT "FileTransfer is active.\nAre you sure you want to cancel transfer?", + IDC_STATIC,42,14,133,19 +END + +IDD_FTCREATEFOLDER DIALOG DISCARDABLE 0, 0, 193, 63 +STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU +CAPTION "Create a New Folder" +FONT 8, "MS Sans Serif" +BEGIN + DEFPUSHBUTTON "OK",IDOK,80,42,50,14 + PUSHBUTTON "Cancel",IDCANCEL,136,42,50,14 + LTEXT "New Folder Name",IDC_STATIC,7,7,179,8 + EDITTEXT IDC_FTFOLDERNAME,7,19,179,14,ES_AUTOHSCROLL +END + ///////////////////////////////////////////////////////////////////////////// // @@ -559,6 +533,22 @@ BEGIN HORZGUIDE, 90 HORZGUIDE, 105 END + + IDD_FTCANCELING, DIALOG + BEGIN + LEFTMARGIN, 7 + RIGHTMARGIN, 186 + TOPMARGIN, 7 + BOTTOMMARGIN, 56 + END + + IDD_FTCREATEFOLDER, DIALOG + BEGIN + LEFTMARGIN, 7 + RIGHTMARGIN, 186 + TOPMARGIN, 7 + BOTTOMMARGIN, 56 + END END #endif // APSTUDIO_INVOKED -- 2.39.5